Skip to content

docs(v3): sync scalar-domain guide with implementation; drop deleted-Python refs#264

Merged
tobyhede merged 1 commit into
eql_v3from
v3-sync-guide
Jun 9, 2026
Merged

docs(v3): sync scalar-domain guide with implementation; drop deleted-Python refs#264
tobyhede merged 1 commit into
eql_v3from
v3-sync-guide

Conversation

@tobyhede

@tobyhede tobyhede commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

What

Two subagents cross-checked docs/reference/adding-a-scalar-encrypted-domain-type.md against the current eql-scalars / eql-codegen / SQLx harness implementation. This PR fixes the stale claims they found, then removes every dangling reference to the deleted Python codegen toolchain across the codebase.

Guide corrections

  • Matrix macros unified. ordered_numeric_matrix! / eq_only_scalar_matrix! no longer exist — they were merged into a single scalar_matrix! wrapper selected by a caps = [eq] / caps = [eq, ord] marker (over the low-level scalar_domain_matrix!). Updated in §3 and §4.
  • Term::returns is fictional. The real Term methods are json_key / extractor / ctor / role / operators / requires; the "Returns" column is eql_v3. + ctor.
  • Schema constant is SCHEMA, not CORE_SCHEMA (crates/eql-codegen/src/consts.rs).
  • Temporal impls are emitted by the temporal_values! declarative macro in scalar_domains.rs, not hand-written.

Deleted-Python cleanup

Removed/redirected every reference to the removed tasks/codegen/ Python system (terms.py, templates.py, operator_surface.py, test_operator_surface.py, generate.py, writer.py, the types/*.toml manifests, load_spec, TERM_CATALOG):

  • crates/eql-scalars/src/lib.rs — module header, 6 × Mirrors terms.py::… lines, 2 × verbatim from …toml provenance lines.
  • crates/eql-codegen/src/{generate,writer,operator_surface}.rs, consts.rs(port of *.py) headers.
  • tests/sqlx/tests/encrypted_domain/family/jsonb_operator_surface.rs — "source of truth" comments + assert message re-pointed to crates/eql-codegen/src/operator_surface.rs (OPERATORS).
  • Guide load_spec reference reworded.

Intentionally left as-is: the CHANGELOG.md [Unreleased] entry that documents the Python removal (correct past-tense reference), and a coincidental .py} byte sequence inside an encrypted ciphertext blob in migrations/005_*.sql.

Verification

  • cargo check -p eql-scalars -p eql-codegen passes (exit 0).
  • All edits are comments / one assert-message string — no behavioral changes.
  • Final repo-wide grep is clean of the deleted-Python tokens.

Summary by CodeRabbit

  • New Features

    • Added public API for managing generated files, including validation, deletion, and safe writing with integrity checks.
  • Documentation

    • Updated and clarified documentation for scalar types, encrypted domain implementations, and code generation processes.
  • Tests

    • Improved test documentation to reflect current source of truth for operator definitions.

…Python refs

Cross-checked docs/reference/adding-a-scalar-encrypted-domain-type.md against
the current eql-scalars / eql-codegen / sqlx harness and corrected stale claims:

- Matrix macros: the two wrappers ordered_numeric_matrix! / eq_only_scalar_matrix!
  were unified into scalar_matrix! (caps = [eq] / [eq, ord] over scalar_domain_matrix!).
- Term::returns is not a real method; the methods are json_key/extractor/ctor/
  role/operators/requires (the Returns column is eql_v3. + ctor).
- Schema const is SCHEMA, not CORE_SCHEMA.
- Temporal impls are emitted by the temporal_values! declarative macro, not hand-written.

Also removed every dangling reference to the deleted Python codegen toolchain
(tasks/codegen/*.py, terms.py, templates.py, operator_surface.py, *.toml type
manifests, load_spec) across eql-scalars, eql-codegen, and the jsonb operator
surface guard test, re-pointing them at the Rust sources of truth. The
CHANGELOG [Unreleased] entry that documents the removal is left intact.
@coderabbitai

coderabbitai Bot commented Jun 9, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 1fddd4a4-ae07-4e43-92bb-ca18daa8e47e

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • ✅ Review completed - (🔄 Check again to review again)
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch v3-sync-guide

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@tobyhede tobyhede merged commit 6a95ebc into eql_v3 Jun 9, 2026
11 checks passed
@tobyhede tobyhede deleted the v3-sync-guide branch June 9, 2026 00:54
tobyhede added a commit that referenced this pull request Jun 9, 2026
…guide

Post-rebase verification of the implementation against the updated guide
(docs/reference/adding-a-scalar-encrypted-domain-type.md) surfaced two
documentation-only drifts:

- §7 still described text/date dispatch via a `[text]`/`[temporal]` harness
  marker. Dispatch is catalog-derived (ScalarKind) — the markers were removed in
  the macro reduction. Reworded to match.
- §1 TL;DR said "seven small registrations" while §3 (correctly) says "two"
  (the single scalar_types! line + the EqlPlaintext impl). Pre-existing in
  origin/eql_v3 #264; aligned to two.

No implementation changes — the audit found zero code defects.
tobyhede added a commit that referenced this pull request Jun 20, 2026
docs(v3): sync scalar-domain guide with implementation; drop deleted-Python refs
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