Skip to content

feat(engine): add reylo-engine, the engine crate a rust host links - #100

Merged
colinhacks merged 3 commits into
mainfrom
rust-engine-crate
Oct 24, 2026
Merged

colinhacks merged 3 commits into
mainfrom
rust-engine-crate

Conversation

@colinhacks

Copy link
Copy Markdown
Owner

Adds reylo-engine (engine/facade/), one crate a Rust host links to run an analysis to its end against a live database, built on the replay loop of #83.

  • Each database's engine behind a feature: postgres, sqlite, mysql. The crate re-exports the replay loop (replay, Answerer, AsyncAnswerer, AnswerCache, ReplayError) and the analysis types, so a host depends on this crate alone.
  • A client per feature, answering the engine's needs: tokio-postgres, rusqlite and mysql_async. Each module has an Answers type and an analyze(client, sql, cache) function. A database's refusal is an answer the engine reads; a failure that never reached the server, such as a closed connection, is the host's error and ends the replay.
  • The oracle answers through it. The answering code of its three hosts moved here unchanged, along with the MySQL catalog-query interpolation test, so the oracle's run now tests this crate's clients.
  • Not published (publish = false).

CI's engine job and the guide's cargo test list add -p reylo-engine, and engine/README.md describes the crate. No engine source changes, so the committed engine.wasm artifacts are unchanged.

Copilot AI balanced review requested due to automatic review settings October 23, 2026 23:49
@vercel

vercel Bot commented Oct 23, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated
reylo Ignored Ignored Preview Oct 24, 2026 12:45am UTC

Request Review

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ℹ️ No critical issues. One small cleanup is suggested inline.

Reviewed changes

This review covers the new reylo-engine facade crate and the move of the oracle's three answerers into it.

  • reylo-engine crate: there is one feature per database engine, and each client feature (tokio-postgres, rusqlite, mysql_async) turns on its engine. The crate re-exports core's replay loop and analysis types, and adds HostError.
  • Clients: each client module has an Answers and an analyze(client, sql, cache). The bodies match the oracle code they replace; the error type changed from String to HostError. The one behavior change: the rusqlite client now binds catalog-query parameters, where the oracle bound []. That's harmless. The SQLite engine only sends empty parameter lists (engine/sqlite/src/sqlite.rs:147-148), and binding them matches src/sqlite-describe.ts.
  • Oracle: it now answers through the facade's clients, so the oracle run tests them. The MySQL interpolation test moves with the code.
  • CI and docs: -p reylo-engine is added to the engine job's cargo test and to AGENTS.md, and engine/README.md describes the crate. The facade's own test only compiles with its client features on. It gets them through feature unification with -p reylo-oracle in the same command, which the README explains.

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using claude-opus-5-5 | 𝕏

Comment thread oracle/Cargo.toml Resolved

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes

This review covers the one commit since the last Pullfrog review, which handles that review's only finding.

  • Removed the oracle's direct engine dependencies: oracle/Cargo.toml no longer lists reylo-engine-postgres, reylo-engine-sqlite or reylo-engine-mysql. They now come in only through reylo-engine's client features. reylo-engine-core stays because the oracle uses analysis::CONSTANT_KEY and schema_type::admits. Nothing in oracle/src names the removed crates any more, and Cargo.lock was updated to match.

Pullfrog  | View workflow run | Using claude-opus-5-5 | 𝕏

Each database's engine behind a feature, and behind a client feature
the answers to its needs over tokio-postgres, rusqlite or mysql_async,
with an analyze that runs a statement's whole replay on that client.
The oracle answers through it instead of its own copies.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ℹ️ No critical issues. The rebase dropped one small docs edit, described below.

Reviewed changes

This push rebased the branch onto main (f1394c1), whose test.yml now picks checks by path. A range-diff shows bf38e2a is identical to the previously reviewed 247952f. 20a95bd differs from d243607 only where it adapts to the new workflow:

  • Added reylo-engine to the run-everything test list: everything() now passes -p reylo-engine to cargo test.
  • Made engine/facade/ run every check: the path filter's grep now includes facade, and its comment names the crate the oracle answers through. A pull request that changes only one database still builds the facade through cargo build --workspace --all-targets.
  • Updated the guide's CI description: the engine bullet in AGENTS.md lists -p reylo-engine and engine/facade/.

ℹ️ The rebase dropped the guide's Setup → Rust edits

Before the rebase, the PR also changed the Setup → Rust section of AGENTS.md. Those edits are gone now. The workspace paragraph no longer lists engine/facade, and the local cargo test command no longer has -p reylo-engine. Someone following the guide's setup therefore never runs the facade's tests. The guide also disagrees with engine/README.md, CI's everything() list, and the guide's own engine bullet.

Technical details
# Restore the AGENTS.md Setup → Rust edits lost in the rebase

## Affected sites
- AGENTS.md:76 — the workspace paragraph no longer lists `engine/facade` (`reylo-engine`, the crate a Rust host links: each database's engine behind a feature, and the answers to its needs over `tokio-postgres`, `rusqlite` or `mysql_async`)
- AGENTS.md:80 — `cargo test -p reylo-engine-core -p reylo-engine-postgres -p reylo-engine-sqlite -p reylo-engine-mysql -p reylo-oracle` lacks `-p reylo-engine`

## Required outcome
- Both lines match what d243607 had: line 76 names `engine/facade`, and line 80's command includes `-p reylo-engine` before `-p reylo-oracle`, the same as `engine/README.md:20` and the `everything()` list in `.github/workflows/test.yml:53`

Pullfrog  | Fix it ➔ | View workflow run | Using claude-opus-5-5 | 𝕏

@colinhacks

Copy link
Copy Markdown
Owner Author

The rebase did drop the Setup → Rust edits to AGENTS.md. Restored in e286ba8: the workspace paragraph names engine/facade again, and the local cargo test command includes -p reylo-engine.

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ No new issues found.

Reviewed changes

This review covers the one commit since the last Pullfrog review. It addresses that review's only finding.

  • Restored the guide's Setup → Rust edits: the workspace paragraph in AGENTS.md names engine/facade (reylo-engine) again, and the local cargo test command has -p reylo-engine again, just before -p reylo-oracle. The guide now agrees with engine/README.md, the everything() list in test.yml, and its own engine bullet.

Pullfrog  | View workflow run | Using claude-opus-5-5 | 𝕏

@pullfrog

pullfrog Bot commented Oct 24, 2026

Copy link
Copy Markdown
Contributor

Your Claude Pro/Max subscription has hit its usage limit. It resets at Oct 26, 8am (UTC). Re-trigger after that, or connect an Anthropic API key, which Pullfrog falls back to automatically.

The provider's response
You've hit your weekly limit · resets Oct 26, 8am (UTC)

Connect a provider →

Pullfrog  | Rerun failed job ➔ | View workflow run | via Pullfrog | Using claude-opus-5-5

@colinhacks
colinhacks merged commit 3533b46 into main Oct 24, 2026
10 of 11 checks passed
@colinhacks
colinhacks deleted the rust-engine-crate branch October 24, 2026 00:49
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.

2 participants