Skip to content

Phase 1: capstone "run on Wasmtime" gate + memory export (#132)#149

Merged
hyperpolymath merged 2 commits into
mainfrom
claude/tender-allen-xzjBQ
Jun 1, 2026
Merged

Phase 1: capstone "run on Wasmtime" gate + memory export (#132)#149
hyperpolymath merged 2 commits into
mainfrom
claude/tender-allen-xzjBQ

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

Implements the #132 capstone "run on Wasmtime" gate.

What

  • emit() now exports the linear memory so a host (Wasmtime, JS) can read/write region data.
  • tests/execute.rs: the Phase-2 capstone gate. It asserts the emitted example-01 module passes wasmtime compile (full engine validation + Cranelift codegen — version-stable across wasmtime CLI revisions), with function invocation (get_player_hp) as a best-effort run. Skips gracefully where wasmtime is not on PATH.

The "actionable error on a violation" half of the Phase-2 gate is already the compile-time path (tw build self-verifies + emits human-readable diagnostics, #126).

Provisioning note

This environment's network policy blocks the wasmtime prebuilt/installer paths (api.github.com empty; wasmtime.dev/install.sh 403); cargo install wasmtime-cli (crates.io) is compiling in the background to verify the gate runs here. Durably, wasmtime belongs in the environment setup script — then the gate auto-runs instead of skipping.

Verification (Actions credit exhausted → local)

cargo test --workspace --locked green (codegen 29 + verifier 80); cargo fmt --check + cargo clippy -D warnings clean; no new deps. The gate currently skips (wasmtime absent); I'll confirm it executes (wasmtime compile succeeds) once the background install lands, before merge.

Part of Phase 1 (#49).

https://claude.ai/code/session_01Rq4da8i2uGnDUfanSB1Hx4


Generated by Claude Code

… 1 / #132)

- emit() now exports the linear memory so a host (Wasmtime, JS) can read/write
  region data
- tests/execute.rs: the Phase-2 capstone 'run on Wasmtime' gate — asserts the
  emitted example-01 module passes 'wasmtime compile' (engine validation +
  Cranelift codegen, version-stable), with function invocation best-effort.
  Skips gracefully where wasmtime is absent (provision via env setup).
- CHANGELOG + crate README updated

cargo test --workspace --locked green; fmt + clippy clean; no new deps. Part of
Phase 1 (#49); the gate lights up once wasmtime is provisioned in the env.

https://claude.ai/code/session_01Rq4da8i2uGnDUfanSB1Hx4
@github-actions

github-actions Bot commented Jun 1, 2026

Copy link
Copy Markdown

🔍 Hypatia Security Scan

Findings: 81 issues detected

Severity Count
🔴 Critical 1
🟠 High 9
🟡 Medium 71

⚠️ Action Required: Critical security issues found!

View findings
[
  {
    "reason": "Action perpolymath/standards/.github/workflows/governance-reusable.yml@main\n needs attention",
    "type": "unpinned_action",
    "file": "governance.yml",
    "action": "pin_sha",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in boj-build.yml",
    "type": "missing_timeout_minutes",
    "file": "boj-build.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in c5-regenerate.yml",
    "type": "missing_timeout_minutes",
    "file": "c5-regenerate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in cargo-audit.yml",
    "type": "missing_timeout_minutes",
    "file": "cargo-audit.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in codeql.yml",
    "type": "missing_timeout_minutes",
    "file": "codeql.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  }
]

Powered by Hypatia Neurosymbolic CI/CD Intelligence

The smoke job ran a bare `npm install` that has failed with ENOENT on
every PR since #133 removed the root package.json (commit d8ea28d,
"chore(deno): drop root package.json stub"). The repo is Deno-first now;
there is no package.json for npm to read.

Guard the step so it runs npm install only when a package.json exists,
and otherwise emits a CI warning explaining the Deno migration. The
downstream parser/smoke/property/benchmark steps are already guarded on
their artefacts, and the aspect + proof steps are dependency-free, so the
smoke job now goes green at source rather than red on a missing manifest.

Resolves the pre-existing smoke failure surfaced on PR #149.
@github-actions

github-actions Bot commented Jun 1, 2026

Copy link
Copy Markdown

🔍 Hypatia Security Scan

Findings: 81 issues detected

Severity Count
🔴 Critical 1
🟠 High 9
🟡 Medium 71

⚠️ Action Required: Critical security issues found!

View findings
[
  {
    "reason": "Action perpolymath/standards/.github/workflows/governance-reusable.yml@main\n needs attention",
    "type": "unpinned_action",
    "file": "governance.yml",
    "action": "pin_sha",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in boj-build.yml",
    "type": "missing_timeout_minutes",
    "file": "boj-build.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in c5-regenerate.yml",
    "type": "missing_timeout_minutes",
    "file": "c5-regenerate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in cargo-audit.yml",
    "type": "missing_timeout_minutes",
    "file": "cargo-audit.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in codeql.yml",
    "type": "missing_timeout_minutes",
    "file": "codeql.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in dogfood-gate.yml",
    "type": "missing_timeout_minutes",
    "file": "dogfood-gate.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  }
]

Powered by Hypatia Neurosymbolic CI/CD Intelligence

@hyperpolymath
hyperpolymath marked this pull request as ready for review June 1, 2026 11:24
@hyperpolymath
hyperpolymath merged commit 4d15643 into main Jun 1, 2026
31 checks passed
@hyperpolymath
hyperpolymath deleted the claude/tender-allen-xzjBQ branch June 1, 2026 11:25
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