Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ make check # lint + mypy + cov (run before push)
```

## Build / generate
The committed payloads under `docs/integrated/` are produced by the
The committed payloads under `integrated/` are produced by the
pipeline. To regenerate them from `sources/`:

```bash
Expand All @@ -147,15 +147,15 @@ hasn't drifted from the committed integrated payloads.
These are the `verification_commands` declared in `dist/repo.meta.json`:

```bash
make integrated # regenerates docs/integrated/ deterministically
make integrated # regenerates integrated/ deterministically
make test # full test suite
```

A green `make check-manifest` proves the committed integrated payloads
still match what the pipeline produces.

## Guardrails
- **Do not hand-edit `docs/integrated/*` files.** They are pipeline
- **Do not hand-edit `integrated/*` files.** They are pipeline
outputs; edit `sources/` + the extract/reconcile/emit stages instead.
- **Do not hand-edit `dist/repo.meta.json` `verified_on` to a future
date.** The Phase 0 smoke test rejects manifests older than 90 days;
Expand Down
18 changes: 9 additions & 9 deletions dist/repo.meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@
"agent_instructions": "AGENTS.md",
"verified_on": "2026-05-10",
"exposes": {
"grammar_surface": "docs/integrated/grammar-surface.json",
"commands": "docs/integrated/commands.tsv",
"intrinsic_functions": "docs/integrated/intrinsic-functions.tsv",
"intrinsic_special_variables": "docs/integrated/intrinsic-special-variables.tsv",
"operators": "docs/integrated/operators.tsv",
"errors": "docs/integrated/errors.tsv",
"pragmatic_standard": "docs/integrated/pragmatic-m-standard.json",
"operational_standard": "docs/integrated/operational-m-standard.json",
"va_sac_rules": "docs/integrated/va-sac-rules.tsv"
"grammar_surface": "integrated/grammar-surface.json",
"commands": "integrated/commands.tsv",
"intrinsic_functions": "integrated/intrinsic-functions.tsv",
"intrinsic_special_variables": "integrated/intrinsic-special-variables.tsv",
"operators": "integrated/operators.tsv",
"errors": "integrated/errors.tsv",
"pragmatic_standard": "integrated/pragmatic-m-standard.json",
"operational_standard": "integrated/operational-m-standard.json",
"va_sac_rules": "integrated/va-sac-rules.tsv"
},
"verification_commands": ["make integrated", "make test"]
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
26 changes: 10 additions & 16 deletions src/m_standard/tools/validate.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,25 +34,19 @@
def _integrated_dir(project_root: Path) -> Path:
"""Resolve the integrated/ directory location.

The repo layout was restructured in commit 3bfb947 (2026-04-30) to
move `integrated/` under `docs/integrated/`. Every gate in this
module reads from there. Accept either layout so a mid-migration
or older checkout still works:

1. `<project_root>/docs/integrated/` (current layout, preferred)
2. `<project_root>/integrated/` (pre-3bfb947 fallback)

Returns the first that exists; falls back to the new path even if
neither exists, so callers that probe ``.exists()`` get a path
rooted in the current layout.
The canonical layout has `integrated/` at the repo root, alongside
`per-source/`, `schemas/`, `sources/`, and `src/`. The repo briefly
held it at `docs/integrated/` (3bfb947 .. its reversion); the
fallback is kept for one release cycle so a stale checkout still
validates.
"""
new = project_root / "docs" / "integrated"
if new.is_dir():
return new
legacy = project_root / "integrated"
canonical = project_root / "integrated"
if canonical.is_dir():
return canonical
legacy = project_root / "docs" / "integrated"
if legacy.is_dir():
return legacy
return new
return canonical


# Names that are ALWAYS tracked under sources/<src>/ regardless of
Expand Down
Loading