diff --git a/.claude/rules/cross-language-porting.md b/.claude/rules/cross-language-porting.md index 4966f27c3b..618d7897a2 100644 --- a/.claude/rules/cross-language-porting.md +++ b/.claude/rules/cross-language-porting.md @@ -18,7 +18,7 @@ New vocabulary goes in its own provider pack, never in `metaobjects-core-types` Preserve the following contracts exactly across all language ports: -**Metamodel subtype vocabularies (must be identical across languages):** the `registry-conformance` gate (`fixtures/registry-conformance/`) is the structural enforcer of this rule — each port emits its registry as a canonical manifest byte-matched to `expected-registry.json`. **All five shipped ports (TS / C# / Java / Kotlin / Python) plus Rust in preview (ADR-0065, byte-identical) are live + green** (SP-G Java/Kotlin reconciliation complete; the JVM runners compose from the defined metamodel provider set so codegen-base/om classpath SPI does not pollute the measured vocabulary). See `fixtures/registry-conformance/README.md`. +**Metamodel subtype vocabularies (must be identical across languages):** the `registry-conformance` gate (`fixtures/registry-conformance/`) is the structural enforcer of this rule — each port emits its registry as a canonical manifest byte-matched to `expected-registry.json`. **All five shipped ports (TS / C# / Java / Kotlin / Python) plus Rust (ADR-0065, byte-identical) are live + green** (SP-G Java/Kotlin reconciliation complete; the JVM runners compose from the defined metamodel provider set so codegen-base/om classpath SPI does not pollute the measured vocabulary). See `fixtures/registry-conformance/README.md`. - Filter operators: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `in`, `like`, `isNull` - Object subtypes: `entity` (owns data: own identity, writable sources, lifecycle), `value` (pure shape: NO identity, NO source, ever; constructed — by caller/embedding — never populated; may `extends` entity fields for shape; a value-hosted field may carry `origin.passthrough` but never an assembly origin), `projection` (derived read-only representation: fields `extends`-bound / origin-derived / self-declared-under-external-assembly, all read-only at subtype level; identity optional and MUST extend an entity identity; sources restricted to read-only `@kind`s; the declared field set IS the exposure — inclusive list, fail-closed). A field carrying `origin.*` is derived ⇒ read-only wherever it lives (incl. on entities). An entity's primary source must be a writable `@kind` (read-only kinds only in read role). See [ADR-0028](spec/decisions/ADR-0028-object-taxonomy-projection-value-purity.md). (FR-024 Phase E — `object.projection`/`value` are registered in `expected-registry.json` and the projection/value validation passes [identity pass-through, value-purity, projection-licensing, `@via` inference/cardinality, extends/origin agreement, derived-field providability] are enforced cross-port in all 5 ports. The **B4b** entity-primary-source-readonly cutover [the "writable `@kind`" clause above — `ERR_ENTITY_PRIMARY_SOURCE_READONLY`] + the projection codegen fan-out (read-only DTOs for view-kind projections; FR-015 proc-callables for proc-kind projections in TypeScript, C# and Kotlin ONLY — Java and Python ship no callable generator at all, so the cross-port claim does NOT cover that clause; api-docs label `object.projection` units as `projection` and document their generated `Dto`) are now shipped cross-port; the declared-API surface, the last third of FR-024, is registered since 1.3.0 by ADR-0066 — see the API bullet below.) **`report` (FR-044 Plan 1)** is a root object subtype registered in all five ports, with the `dimension.attribute` / `dimension.time` / `measure.aggregate` / `measure.ratio` / `segment.filter` children on `object.entity` and the relative-date filter value — loader-validated (`ERR_INVALID_DIMENSION` / `ERR_INVALID_MEASURE` / `ERR_INVALID_REPORT` / `ERR_REPORT_FOREIGN_MEASURE`, plus `ERR_BAD_ATTR_FILTER` for relative dates off a reporting host) and, since FR-044 Plan 2, **lowered only when it declares a read-only `source.rdb` of `@kind: view`**: `meta migrate` creates that view (TypeScript only, ADR-0015), every port reads it (persistence corpus, `report-shapes.json`), C# generates its typed row and Kotlin its Exposed table object, and, since FR-044 Plan 3, every port's generators **serve it as a keyless read-only projection** (GET list with filter/sort/paging on every derived field that has a filter band, `POST` 405, no `/{id}`; row type + filter allowlist + route/controller per port, gated by the api-contract `report/` sub-corpus in the generated lane). The client UI tier (hooks, grids, forms) and a report with no view source at all stay inert, gated by the 43 `reporting` conformance fixtures and the `codegen-noop` corpus. A served report is the predicate `servedReport` (TS) / `ReportRows.IsViewBacked` (C#) / `RestSurfaceGate.isServedReport` (Java, Kotlin) / `is_served_report` (Python): concrete, read source `@kind: view`. See [docs/features/reporting.md](docs/features/reporting.md). - Source subtypes: `rdb` (paradigm; ADR-0007). The pre-v2 `dbTable`/`dbView` subtypes are RETIRED — `source.rdb` + `@kind: table|view|materializedView|storedProc|tableFunction` is the form, with read-only-ness derived from `@kind`. Multi-source via `@role` (exactly one `primary` per object). Source physical name = `@table` (NOT `@name`); field physical name = `@column` (renamed from `@dbColumn`). Referential actions on relationships: `@onDelete` / `@onUpdate`. diff --git a/AGENTS.md b/AGENTS.md index 56e4e3a9ff..81d09c4325 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -169,7 +169,7 @@ metaobjects/ ├── fixtures/conformance/ # cross-language test fixtures │ ├── server/ # runs on a server -│ ├── typescript/ java/ python/ csharp/ rust/ (preview, ADR-0065) +│ ├── typescript/ java/ python/ csharp/ rust/ (ADR-0065) │ └── client/ # runs on an end-user device ├── web/ # browser (TS-only — the browser is TS-native) diff --git a/CHANGELOG.md b/CHANGELOG.md index 30f73a5781..b7209c6a61 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -66,6 +66,15 @@ here.** a report.** For a database whose unique index on the target is hand-made and not declared in the metadata. The default, `"refuse"`, is the 1.3.0 behavior; the refusal's hint now names the setting. See [Migrations and drift](docs/features/migrations-and-drift.md). +- **Rust (ADR-0065 Amendment 3).** A project now chooses its generators in `metaobjects.config.json` +(`{ "generators": [...] }`, written by `cargo meta init`) and no longer needs to eject to drop one; +`cargo meta gen --list` shows each as configured or not. `cargo meta eject` no longer writes the +path of the machine the tool was built on into `codegen/Cargo.toml`: the owned crate names the exact +crates.io release by default, and `--engine ` names a checkout or a git +revision. The three crates lose `publish = false`, carry their packaging metadata, and the `rust` lane +runs `cargo publish --dry-run`. Nothing is published. `cargo meta verify` now runs the business-rules +gate (ADR-0066) too: the same five findings, severities and message text as the other ports, under the +four `rules.*` and `verify.lifecycle.unreachable` settings, held to `fixtures/rules-check-conformance/`. ## [1.3.0] — unreleased @@ -398,7 +407,7 @@ Each item below is described in full under Security, Added, Changed or Fixed; th effect yet: the service shells that act on it are later work. - A requirement's `@implementedBy` may name an operation (`Purchasing.decide`) or a transition (`PurchaseRequest.status.submit`). - - The Rust preview port (ADR-0065) registers the same vocabulary and runs the same loader + - The Rust port (ADR-0065) registers the same vocabulary and runs the same loader rules with the same messages, so it still passes `registry-conformance` byte for byte and the whole metamodel corpus (574 of 574, ledger empty). It reads and validates the new settings. It has no `verify`, so the rules gate does not run there. @@ -409,7 +418,7 @@ Each item below is described in full under Security, Added, Changed or Fixed; th A model that declares none of it sees no change. See `docs/features/business-rules.md`. ADR-0067 records the layering and service-seam design (a layer is a generator an app chooses; the actor is a type the app defines), and amends ADR-0045. -- **Rust port foundation, in preview (ADR-0065).** `server/rust/` is a Cargo workspace with a +- **Rust port foundation (ADR-0065).** `server/rust/` is a Cargo workspace with a pinned toolchain and one crate, `metaobjects`: the node model, the type registry and the built-in providers (strict, sealed after bootstrap, the same `ERR_*` codes), and a JSON loader that reads packages, children, subtypes, attributes, `extends` and references, with the @@ -418,7 +427,7 @@ Each item below is described in full under Security, Added, Changed or Fixed; th the other ports do. It passes `registry-conformance` byte for byte and all 526 of the metamodel fixtures, and runs every validation pass the TypeScript loader runs, in the same order (the conformance ledger is empty and may only shrink). - While the port is in preview, a new fixture that fails in Rust and is not on the ledger prints a + Until ADR-0065 turns the warning off, a new fixture that fails in Rust and is not on the ledger prints a warning and does not fail the lane; a fixture that passed and regresses still fails it, because the ledger records how many fixtures must pass. Nothing is published. Every load records how long each phase and each validation pass took (`LoadResult::timings`; the `validate` module's @@ -429,7 +438,7 @@ Each item below is described in full under Security, Added, Changed or Fixed; th `load_bench` and `gen_bench` tables (record only, printed without a baseline delta — a cross-machine delta measures the machine, not the change) in `scripts/ci-local.sh --only rust`, `pr-ci` and `local-ci`, selected by changes under `server/rust/`. -- **Rust port reads a real project, in preview.** The loader now reads YAML authoring files +- **Rust port reads a real project.** The loader now reads YAML authoring files (ADR-0006: bare type keys, scalar-body names, the `[]` suffix, sigil-free attributes, anchors and aliases, the `ERR_YAML_COERCION` guard, and a line and column on every error from a YAML file), and the crate resolves a project the way the other ports do: the `.metaobjects/config.json` @@ -437,7 +446,7 @@ Each item below is described in full under Security, Added, Changed or Fixed; th `iam` and `ai` library sources embedded in the crate, and the naming strategies, pluralizers and collection-name collision check. It passes `yaml-conformance` 18 of 19, and the `source-resolution-conformance` and `naming-conformance` corpora in full. Nothing is published. -- **Rust port generates code, in preview: `cargo meta gen` and the `entity` generator.** Two new +- **Rust port generates code: `cargo meta gen` and the `entity` generator.** Two new workspace crates. `metaobjects-codegen` holds the run engine and the generator; `metaobjects-cli` builds the binary `cargo-meta`, so cargo's external-subcommand rule makes `cargo meta gen` work (`cargo-meta gen` too). The run engine follows ADR-0064 and keeps the other ports' manifest @@ -466,7 +475,7 @@ Each item below is described in full under Security, Added, Changed or Fixed; th depend on, rather than merging. Navigation across relationships is not emitted. Nothing is published. -- **Rust port's command line, in preview: `cargo meta init`, `verify --codegen` and `eject`, and +- **Rust port's command line: `cargo meta init`, `verify --codegen` and `eject`, and the `client` and `commands` generators (ADR-0065 Amendment 1).** A Rust developer can now run the whole codegen loop on a JSON or YAML model. `init` scaffolds `.metaobjects/config.json`, the ignore rules that keep `.hashes.json` committed and a first metadata file, writing only what is @@ -478,7 +487,7 @@ Each item below is described in full under Security, Added, Changed or Fixed; th (0, 1, 2). `eject ` writes a `codegen/` crate the project owns (the copied generator and the generator list); `gen` and `verify` then build and run it, `gen --list` shows how each copy compares with the shipped source, and `eject --undo` takes back copies still identical. - There is no plugin contract: the engine's Rust API has no stability promise in preview. + There is no plugin contract: the engine's Rust API has no stability promise. The `entity` generator now also writes `Create` and `Patch` for every entity and a `validate()` on value objects and both bodies (lengths, bounds, item counts, patterns, text forms, nested value objects and the rules across members), exact decimals and signed durations @@ -508,8 +517,8 @@ Each item below is described in full under Security, Added, Changed or Fixed; th binary is built or installed and are picked up on their own once it is. `--project --out ` runs it on a private project, copies the metadata, and refuses an output inside the repository. `load_bench` gained `--dir` and `--json`, `gen-model.py` gained `--unique-names`, and Java has a warm-load - driver. New page `docs/ports/rust.md` says what the preview Rust port does and does not do, how - to build and test it, and the preview scope of `cargo meta`; the crates.io name `cargo-meta` is + driver. New page `docs/ports/rust.md` says what the Rust port does and does not do, how + to build and test it, and the scope of `cargo meta`; the crates.io name `cargo-meta` is held by an unrelated crate, so the CLI crate will publish under another name that installs a `cargo-meta` binary (a plan, not a promise). Nothing is published. - **Example and write-up: metadata-driven grids, forms and routes in TypeScript.** diff --git a/README.md b/README.md index 85d2714acb..75f0cfbf70 100644 --- a/README.md +++ b/README.md @@ -151,7 +151,7 @@ first-week wedge plan — and `meta init` picks up from there. - Already have a codebase? → Have your coding agent run the [fit assessment](#try-it-on-your-repo--nothing-to-install) — read-only, no install; it finds the drift already in your git history. -- New here? Pick your language → [`docs/ports/`](docs/ports/) (TS / Java / Kotlin / C# / Python; Rust is in [preview](docs/ports/rust.md)). +- New here? Pick your language → [`docs/ports/`](docs/ports/) (TS / Java / Kotlin / C# / Python; Rust is the sixth, see [its page](docs/ports/rust.md)). - Want the metamodel feature reference? → [`docs/features/`](docs/features/). - Want the documentation index? → [`docs/README.md`](docs/README.md). - Want the design rationale? → [`spec/`](spec/) + [`docs/superpowers/specs/`](docs/superpowers/specs/). @@ -171,7 +171,7 @@ first-week wedge plan — and `meta init` picks up from there. | Kotlin | **Maven Central `8.2.0`** — codegen tier on top of Java: 17 generators (entity, Exposed table, names, relations, repository, output-parser, output-prompt, render-helper, extractor, filter-allowlist, validator, Spring config, storedProc, Spring controller, requirement-tests, api-docs, report-export); 24 / 24 persistence-conformance | [`docs/ports/kotlin.md`](docs/ports/kotlin.md) | [`server/java/codegen-kotlin/`](server/java/codegen-kotlin/) · [`server/java/metadata-ktx/`](server/java/metadata-ktx/) | | C# | **NuGet `1.2.0`** — loader + conformance + EF Core codegen + render engine + `dotnet meta` CLI all shipped | [`docs/ports/csharp.md`](docs/ports/csharp.md) | [`server/csharp/`](server/csharp/) | | Python | **PyPI `1.2.0`** — loader + conformance + render + entity-model codegen + ObjectManager runtime shipped; schema migrations are TS-owned (ADR-0015) | [`docs/ports/python.md`](docs/ports/python.md) | [`server/python/`](server/python/) | -| Rust | **Preview, unpublished** — loader (JSON + YAML), project and source resolution, naming and all 41 validation passes; 578 / 578 metamodel conformance; `cargo meta init` / `gen` / `verify --codegen` / `eject` with the `entity`, `client` and `commands` generators (ADR-0065). Schema migrations stay with the Node `meta` tool | [`docs/ports/rust.md`](docs/ports/rust.md) | [`server/rust/`](server/rust/) | +| Rust | **Crates ready to publish, not yet published** — loader (JSON + YAML), project and source resolution, naming and all 41 validation passes; 578 / 578 metamodel conformance; `cargo meta init` / `gen` / `verify` / `eject` with the `entity`, `client` and `commands` generators (ADR-0065). Schema migrations stay with the Node `meta` tool | [`docs/ports/rust.md`](docs/ports/rust.md) | [`server/rust/`](server/rust/) | ## Capability matrix @@ -334,7 +334,7 @@ metaobjects/ │ ├── java/ # Java port (incl. codegen-kotlin + metadata-ktx) │ ├── csharp/ # C# port │ ├── python/ # Python port -│ └── rust/ # Rust port (preview, ADR-0065 — unpublished; cargo meta + entity/client/commands generators) +│ └── rust/ # Rust port (ADR-0065 — crates not yet published; cargo meta + entity/client/commands generators) │ └── client/ └── web/ # universal browser packages (React, TanStack, Angular, framework-agnostic) diff --git a/agent-context/skills/metaobjects-fit-assessment/SKILL.md b/agent-context/skills/metaobjects-fit-assessment/SKILL.md index b1e7d92685..2dc65ad3d1 100644 --- a/agent-context/skills/metaobjects-fit-assessment/SKILL.md +++ b/agent-context/skills/metaobjects-fit-assessment/SKILL.md @@ -187,8 +187,8 @@ Omitting a real option is a scored defect, just like inventing one. **M8 — The verdict-deciding fact is not always in the code.** Size you can count; trajectory you cannot. - **Structural disqualifiers ARE in the repo**: language outside the five published ports (Rust - is a sixth port in preview and unpublished: it generates code today with `cargo meta gen`, but - there is no crate to depend on, so treat it as a trial, not a fit), no + is a sixth port, a full 1.3.0 language: it generates code today with `cargo meta gen`, but + its crates are not on crates.io yet, so the estate works from a checkout), no entity-shaped data at all, a DBA-gated schema. Cite them. They rule out scopes, not the whole spectrum: a Go estate has no port, but a TypeScript web client on the other side of it may still have a seam worth a contract. @@ -332,7 +332,7 @@ invalid output). Each row rules out *scopes*, not MetaObjects wholesale: | Check | Consequence | |---|---| -| Backend language outside TS/Java/Kotlin/C#/Python | no published codegen or runtime for that side; a seam to a supported-language consumer can still take a contract, generated for that side only. **Rust is the exception in preview:** `cargo meta gen` runs the `entity`, `client` and `commands` generators from a checkout, with nothing published to depend on (`docs/ports/rust.md`), so say it is a trial, not a supported port | +| Backend language outside TS/Java/Kotlin/C#/Python | no published codegen or runtime for that side; a seam to a supported-language consumer can still take a contract, generated for that side only. **Rust is the exception:** a full 1.3.0 port whose `cargo meta gen` runs the `entity`, `client` and `commands` generators, with its crates ready to publish but not yet on crates.io (`docs/ports/rust.md`), so say it works from a checkout until the first release | | No relational store (MongoDB, Cassandra, Neo4j, a remote API) | schema pillar N/A; model the stored records as sourceless entities (`identity.primary`, no `source.*`) — types, create/PATCH schemas, filter allowlists, `verify` and prompts IN; data access is a generator the adopter owns (`docs/recipes/document-graph-and-wide-column-stores.md`) | | DB not Postgres/SQLite/D1 (MySQL, ClickHouse, SQL Server, …) | `meta migrate` / `verify --db` OUT for that database — say so; types and data access unaffected. MySQL is a supported codegen + runtime dialect (`dialect: "mysql"`; `docs/recipes/mysql.md`) | | ORM no reference generator targets (TypeORM, Sequelize, SQLAlchemy ORM, Django ORM, Hibernate-only entities on the Java lane; Prisma on TypeScript IS targeted: `orm: "prisma"` generates `schema.prisma`, so FULL keeps Prisma) | FULL means replacing the data layer — price it as such; CONTRACT SPINE and PARTIAL leave it untouched | diff --git a/agent-context/skills/metaobjects-fit-assessment/references/capability-sheet.md b/agent-context/skills/metaobjects-fit-assessment/references/capability-sheet.md index 5e9faa8ad5..69d60cca69 100644 --- a/agent-context/skills/metaobjects-fit-assessment/references/capability-sheet.md +++ b/agent-context/skills/metaobjects-fit-assessment/references/capability-sheet.md @@ -63,9 +63,10 @@ building block. Every generator is a reference helper an adopter selects, ejects (`docs/recipes/prisma.md`); - ship an AsyncAPI generator; - reach a consumer outside the five published ports (Go, Ruby, PHP, Swift…) directly. **Rust is a - sixth port in preview, unpublished** (`docs/ports/rust.md`): `cargo meta gen` runs the `entity`, - `client` and `commands` generators from a checkout of this repository, and there is no crate to - install, so a Rust estate can try it but cannot yet depend on it. + sixth port, a full language of 1.3.0, with its crates ready to publish but not yet published** + (`docs/ports/rust.md`): `cargo meta gen` runs the `entity`, `client` and `commands` generators from + a checkout of this repository, and there is no crate on crates.io yet, so a Rust estate works from + a checkout until the first release. **Each of those is a generator the project writes**, and that is the primary codegen path, not a workaround: a generator is a function from the loaded model to files, a few dozen lines, and diff --git a/docs/CONFORMANCE.md b/docs/CONFORMANCE.md index 48cc7f7811..17ba8b81c6 100644 --- a/docs/CONFORMANCE.md +++ b/docs/CONFORMANCE.md @@ -70,10 +70,11 @@ regenerate with `ls -d fixtures//*/ | wc -l` for directory-shaped corpor | [`fixtures/contract-conformance/`](../fixtures/contract-conformance/) (FR-022 — the `contract-schema` and `openapi` generators' golden trees and refusals) | 19 cases (14 trees + 5 errors) | ✓ (one neutral engine, ADR-0034 Amendment 10; the generated API lanes also hold real traffic to the documents) | — | — | — | — | | [`fixtures/explorer-conformance/`](../fixtures/explorer-conformance/) (the `explorer.json` data spine: `meta export --effective` + `meta verify --format json` + the generated-file manifest in, one explorer document out) | 1 case (`shop`) | ✓ (the builder is TypeScript, and reads only port-neutral inputs) | — | — | — | — | -**Rust (preview, ADR-0065) is not a column yet.** The sixth port runs these corpora +**Rust (ADR-0065) is not a column yet.** The sixth port runs these corpora today: `registry-conformance` (byte-identical manifest); the metamodel corpus, all 578 green, with every validation pass the TypeScript loader runs, in the same order, so `server/rust/metaobjects/tests/conformance-expected-failures.json` is empty; +`rules-check-conformance` (all 16 cases, the `verify` business-rules gate); `yaml-conformance`, 18 of 19 (the one on `yaml-conformance-expected-failures.json`, `yaml-ref-root-escape`, waits for the ADR-0059 root-level `::` reference rules, which are reference resolution, not a validation pass); `source-resolution-conformance` (all 28 @@ -86,11 +87,11 @@ crate carries; the `core` cases of `writer-conformance` (ADR-0063); and `generator-registry-conformance`, with the eject contract's census, completeness and depth (ADR-0034 Amendment 8). It also runs the codegen-compile gate (below) with every shipped generator, and a scale gate over twenty copies of the fitness model. The ledgers above may -only shrink; the corpora without one assert each case outright. While the port is in -preview, a new fixture that fails in Rust and is not on the ledger prints a warning and does -not fail the lane; it becomes a hard failure when the port leaves preview. A regression +only shrink; the corpora without one assert each case outright. A new +fixture that fails in Rust and is not on the ledger prints a warning and does not fail the +lane; it becomes a hard failure when ADR-0065 turns the warning off. A regression still fails: the ledger's `minPassing` (578) is the number of fixtures known to pass, and the -run fails when fewer do. The column joins this table when the port leaves preview. +run fails when fewer do. The column joins this table when the port runs the render, persistence and API-contract corpora. A ✓ means the port runs the corpus green; an explicit `n / m` is used where a port carries a ledgered divergence. The two ledgered YAML fixtures are documented @@ -248,7 +249,7 @@ Amendment 8). A gate, not a corpus: it has no fixtures of its own, and reads and emits what the packaged generator emits (depth). TypeScript: `cli/test/eject-contract.test.ts`. C#: `EjectContractTests`. Java: `EjectContractTest` in `maven-plugin`. Kotlin: `EjectContractTest` in `codegen-kotlin`. Python: - `tests/conformance/test_eject_contract.py`. Rust (preview) holds its three generators to + `tests/conformance/test_eject_contract.py`. Rust holds its three generators to the same assertions: census, completeness and the reference scan in `metaobjects-codegen/tests/generator_registry.rs`, and the ejected-alone build in `metaobjects-cli/tests/cli.rs`. @@ -340,7 +341,7 @@ manifest contains without moving these boundaries. — Python having no static compiler — importing the generated package (which is what resolves the imports BETWEEN modules) plus `ruff` F821 for the branches importing never executes. -- *Rust (preview) runs it too*, with `cargo check` and `rustfmt --check`, over every +- *Rust runs it too*, with `cargo check` and `rustfmt --check`, over every generator it ships: it has no framework-bound route tier to exclude, and its generated client and commands are driven over HTTP against a local stub in the same test. - *Every port excludes its framework-bound route tier* — TS `routesFile`, C# @@ -416,7 +417,7 @@ Per-port runners + commands: | Kotlin | `cd server/java && mvn -pl codegen-kotlin test` (snapshot suite) | `mvn -f server/java/integration-tests-kotlin/pom.xml test` (needs Docker) | `mvn -f server/java/integration-tests-kotlin/pom.xml test -Dtest=ApiContractConformanceTest` (needs Docker) | | C# | `dotnet test` (per project) | `scripts/integration-test.sh csharp` (needs Docker) | `dotnet test server/csharp/MetaObjects.IntegrationTests/MetaObjects.IntegrationTests.csproj --filter "FullyQualifiedName~ApiContractConformanceTest"` (needs Docker) | | Python | `pytest` (per package) | `scripts/integration-test.sh python` (needs Docker) | `cd server/python && uv run --extra integration pytest tests/integration/test_api_contract.py` (needs Docker) | -| Rust (preview) | `cd server/rust && cargo test` (registry, metamodel, YAML, source-resolution, naming, skip, validation, wire-vector, writer and generator-registry corpora; the codegen-compile and scale gates, which run `cargo check` on generated crates and drive the generated client over HTTP against a local stub) | — | — | +| Rust | `cd server/rust && cargo test` (registry, metamodel, YAML, source-resolution, naming, skip, validation, wire-vector, writer and generator-registry corpora; the codegen-compile and scale gates, which run `cargo check` on generated crates and drive the generated client over HTTP against a local stub) | — | — | The `persistence-conformance` corpus is intentionally **on-demand** — none of the unit-test runners (`bun test`, `dotnet test`, `pytest`, `mvn test`) pull Docker. @@ -786,7 +787,8 @@ transition. The expectations are written from the TypeScript reference `server/typescript/packages/cli/test/rules-check-conformance.test.ts`, `server/csharp/MetaObjects.Conformance.Tests/RulesCheckConformanceTests.cs`, `server/java/metadata/src/test/java/com/metaobjects/conformance/RulesCheckConformanceTest.java` -and `server/python/tests/conformance/test_rules_check_conformance.py`. Kotlin inherits the Java +and `server/python/tests/conformance/test_rules_check_conformance.py` and +`server/rust/metaobjects/tests/rules_check_conformance.rs`. Kotlin inherits the Java gate through the shared Maven goal. ### `fixtures/cube-model/` (46 cases) diff --git a/docs/README.md b/docs/README.md index 13a3b282d9..843b69773a 100644 --- a/docs/README.md +++ b/docs/README.md @@ -61,7 +61,7 @@ docs/ ├── kotlin.md ├── csharp.md ├── python.md - └── rust.md # the Rust port, in preview: loader, validation, cargo meta (init/gen/verify/eject) and its three generators + └── rust.md # the Rust port: loader, validation, cargo meta (init/gen/verify/eject) and its three generators ``` If this list and `ls docs/features/` ever disagree, trust the directory listing — diff --git a/docs/features/business-rules.md b/docs/features/business-rules.md index 013a9c348d..e0071d6310 100644 --- a/docs/features/business-rules.md +++ b/docs/features/business-rules.md @@ -10,9 +10,8 @@ The model never says *how* an operation works. That is code. The model says wher is needed, which moves are legal, and what a command may return, so all three can be checked. **What 1.3.0 ships.** The vocabulary, checked when it loads and by `verify`, in all five ports. -The Rust preview port loads the vocabulary and runs the same loader rules; its `verify` is the -codegen drift gate only, so the checks under "What `verify` reports" do not run there -([Rust port](../ports/rust.md)). +The Rust port loads the vocabulary and runs the same loader rules, and its `verify` runs the +same rules gate, held to `fixtures/rules-check-conformance/` ([Rust port](../ports/rust.md)). A requirement can claim an operation or a transition. Nothing is generated from the vocabulary yet: the service shells that enforce these rules at run time are later work (ADR-0067): service generators an app adds to its generator list, as it adds any generator. A lifecycle in a project diff --git a/docs/features/cli.md b/docs/features/cli.md index 2cb7085229..69427f79ea 100644 --- a/docs/features/cli.md +++ b/docs/features/cli.md @@ -41,7 +41,7 @@ command surface splits in two: | Java/Kotlin codegen | Maven plugin | `mvn metaobjects:generate` (`metaobjects:generate`) | Kotlin generators run through the same goal — see below. **No `--template-spec` flag, deliberately** — `` already loads a consumer class from the project classpath, so the declarative surface is `com.metaobjects.generator.template.TemplateScopeGenerator` wired as an ordinary `` with `