Skip to content

build(gateway): generate bindings with the CLI - #689

Merged
Mathih13 merged 2 commits into
mainfrom
t3/generated-bindings-cli
Oct 12, 2026
Merged

Mathih13 merged 2 commits into
mainfrom
t3/generated-bindings-cli

Conversation

@Mathih13

@Mathih13 Mathih13 commented Oct 11, 2026 •

Copy link
Copy Markdown
Contributor

The Gateway keeps 1,184 generated binding files in source control. Schema changes produce large diffs and require manual binding preparation.

Generate these files through ./lyracore bindings into .lyracore/generated/ and remove the committed tree. Cargo checks freshness through the installed CLI before it loads the bindings. CI prepares them before Gateway builds. Gateway code now uses the generator's field names, and schema-parity tests keep the mappings to Module column names.

CLI dependency LyraCoreProject/lyracore-cli#76 is merged. This PR pins CLI commit ca736690e5d1d40cd967e1c7e4b428109a1a8b08, which is retained in CLI main.

What you verified

  • cargo test -p lyracore-gateway: 2,155 passed, 0 failed, 31 ignored across all targets. This includes 144 schema-parity tests.

  • cargo clippy --workspace --all-targets --all-features -- -D warnings: passed.

  • cargo check --target wasm32-unknown-unknown -p lyracore-module --features=debug_reducers: passed.

  • cargo fmt --all -- --check: passed.

  • Python CI script tests: 4 passed.

  • Generated all 1,184 bindings and compared them with the former committed tree using its documented spelling and comment normalization.

  • Installed the final CLI pin through ./lyracore, prepared bindings, and passed cargo check -p lyracore-gateway.

  • Changed a Module source file and removed a generated file separately. Cargo stopped with preparation instructions in both cases. The freshness check passed after restoration.

  • CI for head 0218fa8f: Rust, durable tests, and Runtime Scripts passed. Rust tested merge 9786f7e against base a31f54ce.

  • Review follow-up 3e924e5f pins the CLI cache fix and moves preparation before documented checks. Installed that pin, generated bindings, passed the freshness check, and passed cargo check -p lyracore-gateway. All nine checks passed for this final revision: Rust, durable tests, and Runtime Scripts.

What you did NOT verify

No macOS, live Realm, or real-client verification. Local runs skipped ignored durable tests. CI passed the full configured Rust and durable workflows, including 11 Benilla tests against private Module instances. The durable workflow keeps its existing Deadmines and lethal-floor exclusions.

Risk

A fresh checkout now needs ./lyracore bindings before direct Gateway Cargo commands or editor checks. This requires the pinned SpacetimeDB CLI and standalone. dev up and CI prepare bindings automatically. Preparation is offline and publishes nothing.

Model: GPT-6-Astra. Harness: Codex in T3 Code.

@Mathih13

Mathih13 commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor Author

Both independent final reviews are clear. Review found and fixed a CLI cache omission for source directories named target, plus preparation steps placed after Gateway commands in the docs. Core follow-up 3e924e5 pins the repair and corrects the command order.

The reviewer compared all 1,184 generated files with the removed bindings and found only the intended naming and formatting differences. The installed final pin passes generation, freshness checking, and cargo check -p lyracore-gateway. CLI tests pass, 801 total, and its Rust 1.85 check passes. CLI #76 is merged; its pinned commit remains in main.

The original revision passed all nine CI jobs, including 11 Benilla tests against private Module instances. Final-revision Rust and durable checks passed. All nine checks are green on 3e924e5f. No live Realm or macOS verification.

Merged as 5bb75ba after confirming the reviewed head and base were unchanged. Gateway bindings now come from the CLI cache and are no longer tracked in source.

@Mathih13
Mathih13 merged commit 5bb75ba into main Oct 12, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant