Skip to content

[review only] 254 7/7: qualification - #534

Draft
zeljkoX wants to merge 28 commits into
review/254-6-ts-sdkfrom
review/254-7-qualification
Draft

zeljkoX wants to merge 28 commits into
review/254-6-ts-sdkfrom
review/254-7-qualification

Conversation

@zeljkoX

@zeljkoX zeljkoX commented Oct 7, 2026 •

Copy link
Copy Markdown
Collaborator

Layer 7/7: qualification

  • Rust driver and TypeScript runner actions for the guardian-execute scenarios
  • manifest (scenarios.toml, matrix.toml, regenerated manifest.json)
  • stack: prover settings, the execution Postgres init, diagnostics
  • docs/QUALIFICATION.md

Live devnet qualification passed on both SDKs on #510.

The top of this layer has exactly the same tree as #510.

Review only

This PR is one layer of a review stack for #510. Do not merge it. #510 is the branch that is tested, qualified on devnet and merged; the top of this stack has exactly the same tree as #510.

Stack: design (#370) → 1 storage → 2 executor → 3 lifecycle → 4 API and ops → 5 Rust SDK → 6 TS SDK → 7 qualification. Each PR's base is the layer below, so the diff shows only this layer.

Review feedback is fixed on #510 and the affected layers are rebuilt from it.

Summary by CodeRabbit

  • New Features
    • Added qualification coverage for Guardian-executed proposals, including standard and delayed execution, signer additions, and execution through a base client.
    • Added checks for unavailable execution, missing or insufficient approvals, and failed execution retries.
    • Qualification runs can now target upgrade scenarios and capture Guardian execution metrics.
  • Documentation
    • Documented the new execution scenarios, configuration options, and upgrade behavior.

@coderabbitai

coderabbitai Bot commented Oct 7, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Important

Review skipped

Auto incremental reviews are disabled on this repository.

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
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 4a418215-cd83-4d89-9653-e8dabdceff77

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:

  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Essentials
  • Run ID: 10293064-c688-40f3-9450-cb12cb0c9265
📥 Commits

Reviewing files that changed from the base of the PR and between bee6aaf and eda0bdd.

📒 Files selected for processing (22)
  • crates/qualification-driver/src/fixtures.rs
  • crates/qualification-driver/src/main.rs
  • crates/qualification-driver/src/manifest/mod.rs
  • crates/qualification-driver/src/run.rs
  • crates/qualification-driver/src/scenario/account.rs
  • crates/qualification-driver/src/scenario/live.rs
  • crates/qualification-driver/src/scenario/mod.rs
  • docs/QUALIFICATION.md
  • packages/miden-multisig-client/tests/qualification/actions/account.ts
  • packages/miden-multisig-client/tests/qualification/actions/live.ts
  • packages/miden-multisig-client/tests/qualification/fixtures.ts
  • packages/miden-multisig-client/tests/qualification/live.ts
  • packages/miden-multisig-client/tests/qualification/runner.ts
  • qualification/manifest/manifest.json
  • qualification/manifest/matrix.toml
  • qualification/manifest/scenarios.toml
  • qualification/stack/compose.yml
  • qualification/stack/lib/diagnostics.sh
  • qualification/stack/lib/env.sh
  • qualification/stack/lib/restart.sh
  • qualification/stack/postgres-init/30-executing.sql
  • qualification/stack/run.sh

Included review availability: This review used your included allowance. 4 included reviews remain after this review. Your included PR review attempts over the past 7 days set your current allowance at 5 reviews per hour.

Walkthrough

The qualification suite adds deterministic checks for Guardian execution refusals and live scenarios that submit and verify Guardian-executed proposals. It also adds execution-mode selection, an execution-capable stack service, metrics capture, and upgrade-target handling.

Changes

Guardian execution qualification

Layer / File(s) Summary
Execution fixtures and deterministic refusal checks
crates/qualification-driver/src/fixtures.rs, crates/qualification-driver/src/scenario/account.rs, crates/qualification-driver/src/scenario/mod.rs, packages/miden-multisig-client/tests/qualification/actions/account.ts, packages/miden-multisig-client/tests/qualification/fixtures.ts, packages/miden-multisig-client/tests/qualification/runner.ts
Rust fixtures now provide additional proposal data and cosigner keys. Rust and TypeScript qualification actions check refusal when execution is unavailable. Rust checks also cover missing requests, unsigned proposals, failed attempts, and persisted execution state.
Execution modes and live execution actions
crates/qualification-driver/src/scenario/live.rs, crates/qualification-driver/src/scenario/mod.rs, packages/miden-multisig-client/tests/qualification/actions/live.ts, packages/miden-multisig-client/tests/qualification/live.ts, packages/miden-multisig-client/tests/qualification/runner.ts
Account creation passes the selected execution mode to cosigners. Live actions advance past a proposal’s bound, request execution through a multisig or base client, and confirm the committed result against chain state and history.
Execution scenario coverage
qualification/manifest/manifest.json, qualification/manifest/scenarios.toml, qualification/manifest/matrix.toml, docs/QUALIFICATION.md
The manifests add deterministic refusal scenarios and live execution scenarios for Falcon and ECDSA proposals, signer addition, delayed execution, and base-client execution. The documentation describes the scenarios and their stated requirements and exclusions.
Execution server and stack diagnostics
qualification/stack/compose.yml, qualification/stack/lib/env.sh, qualification/stack/postgres-init/30-executing.sql, qualification/stack/lib/diagnostics.sh, qualification/stack/run.sh, docs/QUALIFICATION.md
The stack adds an execution-capable Guardian with a separate database and keystore. It configures prover and metrics endpoints, moves the queue server to the E ports, and captures execution metrics and server logs.
Upgrade-target and restart handling
crates/qualification-driver/src/main.rs, crates/qualification-driver/src/run.rs, crates/qualification-driver/src/scenario/mod.rs, qualification/stack/lib/restart.sh, qualification/stack/run.sh, docs/QUALIFICATION.md
The CLI and runner add --upgrade-target. Upgrade runs pass the flag to the target phase, wait for all configured servers, and include the execution server in restart and image-replacement operations.

Priority: ⬇️ Low

Estimated code review effort: 4 (Complex) | ~45 minutes

Change: Other

Sequence Diagram(s)

sequenceDiagram
  participant QualificationRunner
  participant MultisigClient
  participant GUARDIAN
  participant ChainAndHistory
  QualificationRunner->>MultisigClient: select guardian_executable mode
  MultisigClient->>GUARDIAN: request proposal execution
  GUARDIAN-->>MultisigClient: return execution status
  MultisigClient->>ChainAndHistory: confirm committed execution
  ChainAndHistory-->>QualificationRunner: return confirmation result
Loading

Suggested reviewers: haseebrabbani

Merge Risk: ⚪ Minimal · up to eda0b

This layer adds qualification scenarios, stack services and documentation for Guardian execution, without changing product runtime code. No concrete defects remain, so the layer is ready from a review standpoint.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 59.62% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 52 functions across 16 files. (6 skipped:… Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title identifies this as a qualification change and matches the pull request scope. It is broad and does not mention the Guardian execution scenarios, but it remains related and understandable.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

Docstring coverage is 59.62% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 52 functions across 16 files. (6 skipped: 6 unsupported.)

✨ Finishing Touches: 💡 1
📝 Generate docstrings: 💡
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

A rabbit checks each proposal bright
Then hops where bound blocks end in sight
GUARDIAN answers, status clear
Chain and history confirm it here
The burrow saves the metrics near

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

@zeljkoX
zeljkoX added this pull request to stack #535 October 7, 2026 13:41
@zeljkoX
zeljkoX requested a balanced review from Copilot October 7, 2026 13:52

Copilot AI 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.

Copilot review overview

🟡 Changes recommended

Upgrade and restart orchestration can produce misleading qualification results, and deterministic configuration and metrics exposure need correction.

Review effort: Balanced
Findings: 1 High severity · 3 Medium severity

Open (4)
What changed in this PR

Adds qualification coverage for Guardian-managed proposal execution, completing the review-only stack for #510. This PR is not intended to be merged.

Changes:

  • Adds Rust and TypeScript execution actions and outcome checks.
  • Defines deterministic refusal and live execution scenarios.
  • Extends the stack with an execution-enabled server, prover configuration, metrics capture, and documentation.
File Description
qualification/​stack/​run.sh Wires execution endpoints, prover configuration, and metrics capture.
qualification/​stack/​postgres-init/​30-executing.sql Creates the executing server’s database.
qualification/​stack/​lib/​restart.sh Includes the executing server in image upgrades.
qualification/​stack/​lib/​env.sh Allocates additional ports and exports configuration.
qualification/​stack/​lib/​diagnostics.sh Captures execution metrics and server logs.
qualification/​stack/​compose.yml Adds the executing server and metrics listener.
qualification/​manifest/​scenarios.toml Defines execution qualification scenarios.
qualification/​manifest/​matrix.toml Updates devnet qualification exclusions.
qualification/​manifest/​manifest.json Regenerates the scenario manifest.
packages/​miden-multisig-client/​tests/​qualification/​runner.ts Dispatches execution actions and selects execution mode.
packages/​miden-multisig-client/​tests/​qualification/​live.ts Configures cosigner execution modes.
packages/​miden-multisig-client/​tests/​qualification/​fixtures.ts Exposes the deterministic fixture delta.
packages/​miden-multisig-client/​tests/​qualification/​actions/​live.ts Adds execution polling, delayed execution, and commit checks.
packages/​miden-multisig-client/​tests/​qualification/​actions/​account.ts Adds execution-unavailable assertions.
docs/​QUALIFICATION.md Documents scenarios, stack configuration, and metrics artifacts.
crates/​qualification-driver/​src/​scenario/​mod.rs Dispatches execution actions and selects execution mode.
crates/​qualification-driver/​src/​scenario/​live.rs Adds SDK and base-client execution workflows.
crates/​qualification-driver/​src/​scenario/​account.rs Adds refusal and persistence assertions.
crates/​qualification-driver/​src/​manifest/​mod.rs Registers execution action names.
crates/​qualification-driver/​src/​fixtures.rs Builds executable fixture proposals and cosigner material.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread crates/qualification-driver/src/scenario/account.rs Outdated
Comment thread crates/qualification-driver/src/scenario/account.rs
Comment thread qualification/stack/compose.yml Outdated
Comment thread qualification/stack/run.sh
zeljkoX added 22 commits October 7, 2026 16:26
# Conflicts:
#	crates/qualification-driver/src/fixtures.rs
#	qualification/manifest/manifest.json
#	qualification/manifest/scenarios.toml

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants