Repository navigation
Commit 13681c9
feat: [Phase 1] wire altimate-core napi-rs bindings — 34 native handlers
Replace 34 Python bridge methods with direct calls to @altimateai/altimate-core
npm package (napi-rs Node.js bindings for the Rust SQL engine).
- Add @altimateai/[email protected] dependency
- Create native/schema-resolver.ts — Schema from file/JSON/DDL with empty fallback
- Create native/altimate-core.ts — 34 registered handlers:
- All altimate_core.* methods (validate, lint, safety, transpile, explain, check,
fix, policy, semantics, testgen, equivalence, migration, schema_diff, rewrite,
correct, grade, classify_pii, query_pii, resolve_term, column_lineage,
track_lineage, format, metadata, compare, complete, optimize_context,
optimize_for_query, prune_schema, import_ddl, export_ddl, fingerprint,
introspection_sql, parse_dbt, is_safe)
- altimate_core.check is composite (validate + lint + scan_sql)
- Port IFF/QUALIFY transpile transforms from Python guard.py
- Each handler wraps results into AltimateCoreResult format
- Add registerAll() for test isolation
- Add 26 unit tests covering schema, IFF, QUALIFY, registration, wrappers, errors
- Update native/index.ts with side-effect import
Closes #216
Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>1 parent 4d1f538 commit 13681c9
6 files changed
Lines changed: 950 additions & 6 deletions
File tree
- packages/opencode
- src/altimate/native
- test/altimate
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
72 | 72 | | |
73 | 73 | | |
74 | 74 | | |
| 75 | + | |
75 | 76 | | |
76 | 77 | | |
77 | 78 | | |
| |||
0 commit comments