Skip to content

refactor(rust): VCL rename stage B (1/5) — rust-core server + openapi (#84)#144

Merged
hyperpolymath merged 1 commit into
mainfrom
vcl/rename-stage-b-rust-core
Jun 14, 2026
Merged

refactor(rust): VCL rename stage B (1/5) — rust-core server + openapi (#84)#144
hyperpolymath merged 1 commit into
mainfrom
vcl/rename-stage-b-rust-core

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

Stage B (1/5) — server core, hard rename of the VQL→VCL wire contract

First sub-stage of the Stage B code rename (#84). Per maintainer decision: hard rename including the public endpoint (no back-compat alias), and ReScript is in-scope for Stage B (later sub-stage). This PR is the server source-of-truth: rust-core/ + openapi.

Renamed (git mv + identifiers — 26 files, symmetric 418/418)

  • API: verisim-api/src/vql.rsvcl.rs; route POST /vql/execute/vcl/execute; vql_execute_handlervcl_execute_handler; pub mod vqlvcl
  • Planner/parser: verisim-planner/src/vql_bridge.rsvcl_bridge.rs; AST types VqlAst/VqlQuery/… → Vcl*
  • REPL: verisim-repl/src/vql_fmt.rsvcl_fmt.rs; binary vqlvcl; client POSTs /vcl/execute; .vqlrc.vclrc
  • Fuzz: both fuzz_vql_parser targets → fuzz_vcl_parser (file + [[bin]] name + path), importing verisim_api::vcl::tokenize
  • openapi: /api/v1/vcl/execute; tests/integration_test.rs

Coupling / planned follow-ups (out of this PR, under #84)

Sub-stage Scope
2 clients Rust/Zig/Julia/Elixir SDKs → /api/v1/vcl/execute + symbols
3 ReScript src/vql/ parser, playground, VeriSimVql.res (quarantine lifted)
4 Elixir contracts type:vql_query tag, vql_dt_active, vql-bridge/ JS dir + @parser_script_path, bench files
5 misc Coq/Idris, examples, config (CODEOWNERS/dependabot/REUSE/.hypatia-ignore)

Clients still call /api/v1/vql/execute until sub-stage 2 — CI is unaffected (they compile against their own path string; no live integration test in unit CI), runtime round-trip is restored when 2–4 land.

Verification

cargo can't build offline here (oxigraph et al. need network), so the real compile runs on this PR's CI (cargo build/test/clippy/cargo doc/fuzz-compile). Locally confirmed:

  • grep-to-zero: no vql/VQL/Vql token left in rust-core/fuzz/openapi/integration
  • ✅ no other workspace crate imports the renamed modules/types (no cross-crate breakage); Rust client is independent
  • ✅ symmetric 418/418 diff — equal-length token swaps incl. the Vql*Vcl* PascalCase pass, no structural change

Refs #84.


Generated by Claude Code

First sub-stage of the Stage B code rename (#84). Per maintainer
decision this is a hard rename including the public endpoint (no
back-compat alias).

Renamed (git mv + identifiers, 26 files):
- verisim-api/src/vql.rs -> vcl.rs; route POST /vql/execute ->
  /vcl/execute; handler vql_execute_handler -> vcl_execute_handler;
  `pub mod vql` -> `pub mod vcl`
- verisim-planner/src/vql_bridge.rs -> vcl_bridge.rs (AST types
  VqlAst/VqlQuery/... -> Vcl*); `pub mod vql_bridge` -> vcl_bridge
- verisim-repl/src/vql_fmt.rs -> vcl_fmt.rs; REPL binary "vql" -> "vcl";
  client POSTs /vcl/execute; .vqlrc -> .vclrc
- both fuzz targets fuzz_vql_parser -> fuzz_vcl_parser (file + [[bin]]
  name + path), importing verisim_api::vcl::tokenize
- connectors/shared/openapi/verisim-api-v1.yaml: /api/v1/vcl/execute
- tests/integration_test.rs

Follow-ups (tracked under #84, intentionally out of this PR):
- Client SDKs still call /api/v1/vql/execute (Elixir/Rust/Zig/Julia/
  ReScript/playground) -> clients sub-stage. CI unaffected: clients
  compile against their own string; no live integration test in unit CI.
- Elixir-internal contracts (type:vql_query tag, vql_dt_active, the
  vql-bridge/ JS dir + @parser_script_path) -> Elixir follow-up.

Verified locally (cargo cannot build offline here -- oxigraph et al.
need network, so the real compile runs on CI): grep-to-zero leaves no
vql/VQL/Vql token in rust-core/fuzz/openapi/integration; no other
workspace crate imports the renamed modules/types; symmetric 418/418
diff (equal-length token swaps, no structural change).

Refs #84.

https://claude.ai/code/session_01W9Voe3JceP66Bna9FT4jME
@hyperpolymath hyperpolymath marked this pull request as ready for review June 14, 2026 01:35
@hyperpolymath hyperpolymath merged commit 89f1f95 into main Jun 14, 2026
34 of 35 checks passed
@hyperpolymath hyperpolymath deleted the vcl/rename-stage-b-rust-core branch June 14, 2026 01:35
@github-actions

Copy link
Copy Markdown

🔍 Hypatia Security Scan

Findings: 134 issues detected

Severity Count
🔴 Critical 17
🟠 High 51
🟡 Medium 66

⚠️ Action Required: Critical security issues found!

View findings
[
  {
    "reason": "Issue in scorecard-enforcer.yml",
    "type": "scorecard_publish_with_run_step",
    "file": "scorecard-enforcer.yml",
    "action": "split_scorecard_publish_job",
    "rule_module": "workflow_audit",
    "severity": "high"
  },
  {
    "reason": "Issue in instant-sync.yml",
    "type": "secret_action_without_presence_gate",
    "file": "instant-sync.yml",
    "action": "peter-evans/repository-dispatch",
    "rule_module": "workflow_audit",
    "severity": "high"
  },
  {
    "reason": "Issue in codeql.yml",
    "type": "codeql_missing_actions_language",
    "file": "codeql.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "User-defined Coq axiom -- not verified by kernel (1 occurrences, CWE-704)",
    "type": "coq_axiom",
    "file": "/home/runner/work/verisimdb/verisimdb/formal/Provenance.v",
    "action": "flag",
    "rule_module": "code_safety",
    "severity": "medium"
  },
  {
    "reason": "User-defined Coq axiom -- not verified by kernel (2 occurrences, CWE-704)",
    "type": "coq_axiom",
    "file": "/home/runner/work/verisimdb/verisimdb/formal/PlannerSemantic.v",
    "action": "flag",
    "rule_module": "code_safety",
    "severity": "medium"
  },
  {
    "reason": "User-defined Coq axiom -- not verified by kernel (1 occurrences, CWE-704)",
    "type": "coq_axiom",
    "file": "/home/runner/work/verisimdb/verisimdb/formal/Planner.v",
    "action": "flag",
    "rule_module": "code_safety",
    "severity": "medium"
  },
  {
    "reason": "User-defined Coq axiom -- not verified by kernel (6 occurrences, CWE-704)",
    "type": "coq_axiom",
    "file": "/home/runner/work/verisimdb/verisimdb/formal/Drift.v",
    "action": "flag",
    "rule_module": "code_safety",
    "severity": "medium"
  },
  {
    "reason": "User-defined Coq axiom -- not verified by kernel (1 occurrences, CWE-704)",
    "type": "coq_axiom",
    "file": "/home/runner/work/verisimdb/verisimdb/formal/WAL.v",
    "action": "flag",
    "rule_module": "code_safety",
    "severity": "medium"
  },
  {
    "reason": "User-defined Coq axiom -- not verified by kernel (2 occurrences, CWE-704)",
    "type": "coq_axiom",
    "file": "/home/runner/work/verisimdb/verisimdb/formal/Normalizer.v",
    "action": "flag",
    "rule_module": "code_safety",
    "severity": "medium"
  },
  {
    "reason": "getExn on external data -- use pattern matching (1 occurrences, CWE-754)",
    "type": "getexn_on_external",
    "file": "/home/runner/work/verisimdb/verisimdb/src/registry/Registry.res",
    "action": "flag",
    "rule_module": "code_safety",
    "severity": "critical"
  }
]

Powered by Hypatia Neurosymbolic CI/CD Intelligence

hyperpolymath pushed a commit that referenced this pull request Jun 14, 2026
Second sub-stage of #84. Updates the four non-ReScript client SDKs to the
renamed wire contract from PR #144 (server route /api/v1/vcl/execute).

- connectors/clients/rust/src/vql.rs -> vcl.rs (mod vcl, execute_vcl,
  Vcl{Request,Response,Result,ParseError,ExecutionError})
- connectors/clients/zig/src/vql.zig -> vcl.zig
- connectors/clients/julia/src/vql.jl -> vcl.jl
- connectors/clients/elixir/lib/verisim_client/vcl.ex + types.ex
- all four now POST /api/v1/vcl/execute

Verified: grep-to-zero leaves no vql/VQL/Vql token in the four client
trees; endpoint updated in every SDK; symmetric 99/99 diff. Rust client
compiles on CI (cargo); Zig/Julia/Elixir renames are mechanical
(string + symbol).

Refs #84.

https://claude.ai/code/session_01W9Voe3JceP66Bna9FT4jME
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