feat(independent): independent_v1 composer and live canary runner - #148
Conversation
The live SN39 path still relays a hub-signed vector. This lineage composes u16 dests/weights locally from a 2-of-3 PolicyBundle, Hamilton G9, and H1 forfeit-to-burn, then journals them with broadcast locked off so a later canary can match the wire without using the live relay wallet. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
Git 2.55 on the Python 3.11 runner creates then unlinks objects/maintenance.lock during the rglob walk, so chmod races to FileNotFoundError. Tracked release files are the only modes the porcelain check cares about. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
The composer can name the Compute lane and refuse it for a stated reason. Construction without a quote verifier is AdapterUnavailable, collateral must be Intel PCS, and probe returns no mass even when a mock verifier PASSes. Funded Compute stays BROADCAST_BLOCKED until #120 and an open QVL digest close. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 54c677bc94
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Compose now requires a key registry and checks 2-of-3 before journaling, and refuses a successor that does not follow genesis or last-good. Also pin the weight cap exactly, require observed hotkey and genesis on the CLI, refresh the fetch deadline per chunk, include the journal newline in the byte bound, and send Host with a non-default port. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
http.client and cryptography both load ssl, which subclasses socket at import time. Leave those imports inside the functions that need them so importing independent_v1 still has no socket side effects. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
Validators mint a 32-byte attributable nonce and POST /v1/evidence over an injected transport. The copied REPORT_DATA v2 preimage is pinned to the sandbox vector. A PASS quote still contributes no mass: Compute allocation stays 0 and compose remains BROADCAST_BLOCKED. No dialer, no live axon, no chain write. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
urlsplit stores IPv6 literals without brackets. Rebuilding an evidence URL or Host header from the raw host produced https://2001:db8::1/... which is not a valid authority. Bracket the host whenever it contains a colon, including non-443 ports. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
submit_canary_once calls an injected transport exactly once after COMPOSED, a funded Compute row, a dry-run u16 match, and the dedicated canary hotkey. DEGRADED and BROADCAST_BLOCKED cannot spend the slot. The lock is a separate independent-canary.json, claimed before the transport. No chain client, no --broadcast, no --canary, Compute allocation stays 0. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
File fsync alone leaves the new directory entry in the page cache. A crash after submit_canary_once then looks like the slot was never spent. Fsync the parent after the O_EXCL claim and after replace so the one-write fence survives power loss. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
A ComputeAdapter with a pinned QVL digest and independently bound integer mass is now contributing. mass_map probes that adapter, leftover folds to burn, and compose can emit COMPOSED so the one-write canary has a real payable vector. Unpinned mocks still cannot move SN39 mass. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
cathedral-independent-live lives outside the import-graph ban. It lists or rents a sealed Intel TDX Worker, snapshots SN39 serving axons, collects v2 evidence over public HTTPS, composes from pinned-QVL verified mass, and submits set_mechanism_weights through the dedicated canary transport. Fast CPU keep-warm is refused at create. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
…lock The live runner was hashing a future tempo close, which is not a produced block for 359 of every 360 blocks. It now freezes the closed tempo. load_verifier refuses any binary whose digest is not the SN39 launch QVL pin, so a mock script cannot bind mass. Serving axons skip the canary identity, and the canary transport re-checks mecid, version_key, and genesis before signing. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
Substrate //Bob is public. The dedicated canary identity is now an unpublished ss58, and require_canary_hotkey refuses Alice through Ferdie including stash and ed25519 variants. The refuse-list stays exactly the live relay plus the burn destination. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
…tate A QVL PASS is admission, not payment. The live runner records pass count and leaves verified_units empty until SAT work units exist. State defaults to /var/lib/cathedral-validator at 0o700, inclusion re-snapshots the metagraph after collect, --rent is gated on custom.v1 TDX, --confirm-canary is required to spend the lock, local policy keys are ephemeral, and the QVL pin is the published binary-blob digest. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
|
@codex review Please re-review HEAD after the fail-closed QA pass (
Do not treat attestation as payment. Do not use the live SN39 relay hotkey. The sealed package must still have no chain client. |
|
To use Codex here, create a Codex account and connect to github. |
The canary signs the vector, so paying it is a self-payment. Compose now folds refuse-listed and canary destinations to burn the same way as an inclusion remap, and submit_canary_once refuses a hand-assembled vector that still names one. The burn dest remains the single payable exception on the refuse-list. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
SubstrateCanaryTransport now rebuilds kwargs through build_mechanism_weights_kwargs and refuses unless the one-write lock is already pending for this identity and vector. It never claims the lock itself. A direct call with no compose result cannot reach submit_extrinsic. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
cmd_run now chooses the closed-tempo anchor first, then reads the metagraph, collects, and re-reads inclusion. --confirm-canary and a missing wallet refuse before prepare_mechanism_weights, so an unconfirmed epoch journals compose and not a submission. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
Inclusion names every contributing dest before Hamilton drops sub-u16 dust. Requiring those bindings to equal the paid dests rejected a real COMPOSED mix that had one dust miner. Require paid dests to be a subset of the inclusion bindings instead. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
A funded Compute row on the bundle in hand did not prove the vector was composed from that document. Require the composition's bundle_digest to equal bundle.digest().hex() before claiming the one-write lock. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
Run 32984573867 concluded failure with Python 3.11/3.12, Publisher, and Integration still queued and no steps executed. Local independent tests were 469 passed. This empty commit retriggers the pull_request workflow. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
A pinned-QVL quote still only admits a machine. The live runner now commits to a canonical audit instance, POSTs it to the axon's /v1/sat-work, and binds Compute mass from the integer clause count this validator re-derives. Miner-claimed units and non-canonical jobs never move mass. A local fake-miner loop reaches COMPOSED and fires the one-write canary through an injected transport. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit b80cc1a. Configure here.
A flaky axon's HTTPException is not an OSError, so catching only the named SAT errors aborted cmd_run for every miner. Catch Exception the same way evidence collect does, and keep KeyboardInterrupt aborting. After a successful SAT round, assert_machine_identity now records the observed TLS SPKI. A second hotkey claiming that machine forfeits both claimants so one TDX guest cannot collect two Compute shares. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
There was a problem hiding this comment.
Stale comment
Agentic security review found one high-severity issue on the live miner HTTPS path: IP axons disable TLS certificate verification, and quote REPORT_DATA is bound to the client-observed SPKI rather than an enclave-held TLS key. Prior findings: missing
assert_machine_identityis addressed;at_anchorstill does not gate compose/submit.Sent by Cursor Security Agent: Security Reviewer
IP axons terminate TLS inside the guest with a self-signed cert, so CERT_NONE stays the IP trust model. Authentication is the v2 REPORT_DATA binding of the observed SPKI; an honest guest will not quote a foreign key. The collected cert_chain is no longer unread: a non-empty leaf must be the X.509 certificate this connection hashed. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
probe-sn39 and the live run report a skip census so an empty serving set is diagnosable. The live relay is still never listed as dialable. Co-authored-by: Ancient Runner <wallscaler@users.noreply.github.com>
Require the exact closed-tempo metagraph before any billable Worker or miner I/O, and treat QVL infrastructure failures as validator-wide uncertainty. Claim quote-bound machine identities before SAT and leave proportional integer remainder to burn so duplicate and economics failures cannot become payout.
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_fef30d58-b9a8-49b5-9950-aca7748eb6b2) |
Exact-head merge-readiness recordReviewed SHA: Outcome: READY for dependency-order merge as a bounded, one-write SN39 Compute canary. This is not approval for continuous production operation and is not live-chain proof. Validated repairs in this head
Exact-head verification
Independent Fable reviewClaude Fable performed a read-only exact-tree review and returned: merge-ready as a bounded one-write canary, no blockers. Fable independently falsified the signature, economics-lineage, anchor-fallback, identity-order, SPKI/channel-binding, Hamilton/remainder, self-payment, confirmation-bypass, one-write, QVL-INFRA, bundle-splice, and chain-call concerns against the current source and tests. Nonblocking follow-ups
Trust and rollout boundaryThe live runner still uses a process-local ephemeral 2-of-3 policy and matching local commitment. It proves canary pipeline mechanics, not external policy authorization. Self-signed miner TLS relies on pinned-QVL REPORT_DATA binding to the observed SPKI. The chain transport waits for inclusion only. Finalized chain reads are required before any on-chain success statement. No emissions or reward claim follows from this PR. The PR body now records the complete outcome target, acceptance checks, rollout, rollback, trust boundary, launch inputs, and remaining risks. No merge, deployment, wallet access, signing, or broadcast occurred during this review. |
|
PM after #148 merge ( Live cathedral.computer catalog unchanged (validator source, not a site/PolarIS deploy). PolarIS prod still This merge is reviewed source only. No GHCR audit image from sandbox #171 is public (anonymous index pull just verified): Next:
Did not ping Astro. |



Outcome target
Deliver a bounded, one-write SN39 Compute canary whose weight vector originates from this validator, not the Cathedral relay feed.
The runner must read the exact closed-tempo chain view, collect Intel TDX evidence from registered SN39 axons, derive canonical SAT work units, compose one independently authorized
set_mechanism_weightsvector, and submit only through the dedicated canary hotkey after an explicit operator confirmation.This PR targets merge-ready source and canary controls. It does not claim a production deployment, a finalized on-chain write, subnet emissions, or miner rewards.
Acceptance checks
Pre-spend and chain snapshot
Policy authorization and economics
10^11mass. CyberGym and Voice remain at zero.Evidence and scoring
35bb55f89f411d5dcf5f72be90488e999ee68c41dfc0429a0dcb8cc2b448b6bb.KeyboardInterruptandSystemExitas process stops.Identity and allocation
floor(allocation * units / total_units). Leave integer remainder unassigned so the composer folds it to burn.One-write chain boundary
cathedral_thin.independentfree of Bittensor, relay-fetch, and writer imports.--confirm-canary, the dedicated canary wallet identity, a COMPOSED result, exact u16 arguments, identified paid destinations, and a durableO_EXCLcanary lock before transport.SubtensorModule.set_mechanism_weights(netuid, mecid, dests, weights, version_key)with a mortal era and inclusion wait.--broadcastpath.Verification at head
681cbf39cd374a4d6553f3eff7cf3185e2f42ca6608 passedacrosstests/thin/test_independent_*.py.608 passedacross the same scope.git diff --check, and changed-diff secret-pattern scan: pass.GitHub CI for this exact head must also pass before merge.
Trust boundary
CATHPOL1policy. It generates ephemeral process-local Ed25519 keys, signs a fixed genesis EconomicsSet, and creates its matching local commitment. This proves independent composition mechanics. It is not production policy authorization.Rollout
--confirm-canary. Require an exact historical anchor, QVL PASS with no INFRA result, expected miner identities, verified SAT units, and the intended composed destinations and weights.--confirm-canaryand the dedicated canary wallet supplied outside the repository.Rollback
--confirm-canary, or revert this PR. No chain state changes.681cbf3restores the prior source behavior but does not undo any existing chain state.Remaining risks and launch inputs
/v1/evidenceand/v1/sat-workendpoints.Out of scope
config/validator-thin-sn39-relay.toml.