Skip to content

cli+e2e G-NODE-07: decdn node rotate-key #1034

Closed

Description

@alpergundogdu

Build first: decdn node rotate-key — a wrapper over the runbook (bindNodeId / re-stake / session-key swap). Depends on: e2e harness.

  • Steps: rotate the operator key → SIGHUP reload → assert new NodeId slashable immediately, old key cannot serve; an in-flight voucher signed by the old key still settles.
  • Negative: rotation without on-chain rebind leaves the node un-slashable (must be rejected/flagged).

Spec anchor: internal/Product/gaps-and-e2e-test-specs.md#g-node-07.

Activity

  1. added
    prio:medium
    kind:test
    area:cli
    on Jun 30, 2026
  2. yigitdot commented on Jul 18, 2026

    @yigitdot
    Contributor

    Triage note: automated dispatch skipped this — crates/common/src/cli/node.rs:58 NodeCommand has no RotateKey variant, so the CLI half must be built first (as the issue says). Splitting the CLI subcommand into its own issue would make the e2e half dispatchable afterward.

  3. self-assigned this
    on Aug 5, 2026
  4. yigitdot commented on Aug 5, 2026

    @yigitdot
    Contributor

    Follow-up: right-size the anvil-e2e timeout budgets

    Noting this here as a record for whoever picks it up. It surfaced while landing #1614 (which added the G-NODE-07 journey and, following the job comment's stated rule, pushed anvil-e2e-journeys to timeout-minutes: 200). Same analysis is on that PR.

    The budgets are incoherent, not merely large. The job bound is ~25× the observed run, while the per-test ceilings are smaller than the fixture retry ladders they are supposed to contain. Both follow from the same mistake: every figure in that comment is derived from other figures, and none is anchored to a measurement.

    Measured

    anvil e2e (journeys) on main, four consecutive runs (2026-08-05): 5m23s, 5m40s, 6m00s, 8m37s, against a 200m bound. anvil e2e (settlement): 2m02s against 60m.

    Full suite locally at --test-threads 1: 377s for all 36 tests. Only two tests exceed 25s:

    test measured its ceiling
    origin_stream_while_store::…rejects_a_corrupt_outboard… 94.4s 300s
    cli_publish::publish_namespace_and_assign_land_on_chain 72.3s 780s
    g_node_06_unbond::… 22.7s 780s
    g_gov_02_rate_bounds::… 11.1s 1200s
    slash_appeal::slash_detection_appeal_and_grant 10.2s 1200s

    The rest are ≤ 16s. The 1200s tier runs ~110× faster than its ceiling.

    The contradiction

    Under CI, ci_scaled doubles the fixture budgets (crates/e2e/src/chain.rs:95, CI_TIMEOUT_MULTIPLIER = 2). A test that exhausts its setup retry ladders needs forge build 300s × 2 × 3 attempts = 1800s, plus DeployProtocol 60s × 2 × 4 attempts = 480s — ~38m of setup inside a test whose largest ceiling is 20m.

    So the ladders are partly unreachable: a test that hits them trips its own OVERALL_TIMEOUT first and reports as a generic timeout rather than as the deploy flake it is. #1384 is exactly that flake, which suggests this has already cost debugging time.

    Scope

    1. Anchor per-test OVERALL_TIMEOUT values to observed p100 with a CI margin — roughly 180s / 300s tiers, replacing today's 300/600/780/1200s spread — and put the rule in the constant's doc so the next journey inherits it.
    2. Make the retry ladders fit. Preferably hoist forge build out of the fixture into a job step that runs once: fixtures share contracts/out, so only the first test pays a cold build, and this removes the 1800s worst case from every test at once. Items 1 and 2 must land together — cutting a ceiling below the ladder it contains just inverts the bug.
    3. Derive the job bound from observed job duration instead of a sum of ceilings (that model assumes every test simultaneously burns its full budget, which cannot happen). Target timeout-minutes: 30 for journeys — ~3.5× the worst observed run, with room for the cold-cache compile the job must also cover.
    4. anvil-e2e-settlement by the same rule: ~15m.
    5. Optionally, the two tests above 25s: cli_publish has a hardcoded 60s poll deadline (crates/e2e/tests/cli_publish.rs:318); the corrupt-outboard test's 94s is spent waiting out a real pull deadline, not a sleep.

    Constraint to respect: the runner is a 4-vCPU box at --test-threads 2, so two anvils and two forge deploys contend. Margins have to survive that.

    Note for whoever edits the comment block: its own history records going stale four times. Replace the derived-arithmetic table with a rule plus a measurement date.

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

Metadata

Metadata

Assignees

Labels

area:clikind:testprio:medium

Type

No type

Fields

Priority

None yet

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions