Skip to content

fix(devnet): quiet status-registry probes and bump evm-upgrade to v1.20.2 - #209

Open
akobrin1 wants to merge 7 commits into
masterfrom
fix/devnet-evmigration-status-registry
Open

fix(devnet): quiet status-registry probes and bump evm-upgrade to v1.20.2#209
akobrin1 wants to merge 7 commits into
masterfrom
fix/devnet-evmigration-status-registry

Conversation

@akobrin1

Copy link
Copy Markdown
Contributor

Summary

  • Add lookupStatusRegistryMnemonic, a silent status-registry lookup used when probing infrastructure-key candidates that legitimately don't exist on a host (e.g. governance_key on a secondary validator), eliminating spurious WARN logs; readStatusRegistryMnemonic still warns for keys that are expected to be registered
  • Silence updateStatusRegistryAddress for untracked accounts — generated pre-evm-* fixtures live only in accounts-devnet.json, so a missing registry entry is the normal case
  • Remove the unused appendStatusRegistryAccount helper
  • Fix the Height format verb (%d%s) in supernode migration verification error messages
  • Bump the devnet-evm-upgrade flow from v1.20.1 to v1.20.2 (new devnet-upgrade-1202 target)
  • Add unit tests for the status-registry lookup helpers

Test plan

  • go test ./devnet/tests/evmigration/... (status registry unit tests)
  • make devnet-evm-upgrade end-to-end on the shared devnet host

🤖 Generated with Claude Code

…20.2

- Add lookupStatusRegistryMnemonic, a silent registry lookup for probing
  infrastructure-key candidates that legitimately don't exist on a host
  (e.g. governance_key on a secondary validator), so probes no longer
  emit spurious WARN logs; readStatusRegistryMnemonic keeps warning for
  keys that are expected to be registered
- Silence updateStatusRegistryAddress for untracked accounts: generated
  pre-evm-* fixtures live only in accounts-devnet.json, so a missing
  registry entry is the normal case
- Remove unused appendStatusRegistryAccount
- Fix Height format verb (%d -> %s) in supernode migration verification
- Bump devnet-evm-upgrade target from v1.20.1 to v1.20.2 (via new
  devnet-upgrade-1202)
- Add unit tests for status registry lookup helpers

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

@cd devnet/scripts && ./upgrade.sh v1.20.2 auto-height ../bin

P1 Badge Separate the upgrade plan name from the binary version

When this target is run from the current post-v1.20.3 source tree, devnet-refresh-bin produces a binary stamped 1.20.3 (the CHANGELOG explicitly requires that binary for the on-chain v1.20.2 plan), but passing v1.20.2 here also makes upgrade-binaries.sh require the source binary's core version to be 1.20.2. Consequently, the flow can successfully schedule and halt the chain for v1.20.2 and then fail the binary swap with Source lumerad version mismatch, leaving the devnet halted; pass the plan name and expected binary version separately or otherwise permit the required 1.20.3 binary.

ℹ️ 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".

@akobrin1

Copy link
Copy Markdown
Contributor Author

Addressed the review feedback and both failing CI paths in 545f7c69 (branch updated through current master at bc2efb91):

  • keeps the on-chain plan name v1.20.2 while independently validating/installing the required v1.20.3 binary
  • removes the concurrent hidden JSON-RPC port-selection race seen in the system job and drains node waiters before their owning test completes
  • retries only the observed transient startup exceeds block gas limit rejection for the fixed 21k integration-test transfer
  • adds regression coverage for the version split, port mapping, and retry classifier

Focused local checks passed, including the formerly failing system scenario twice and the JSON-RPC scenario three times.

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Aug 31, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-08-31T22:48:36.081401Z 8e41d46 Manual request
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: bc2efb914a

ℹ️ 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".

Comment thread cmd/lumera/cmd/commands.go Outdated
@akobrin1

Copy link
Copy Markdown
Contributor Author

Follow-up 2942b487 fixes the non-root CI regression found by the refreshed integration matrix: deterministic internal JSON-RPC ports are now rotated strictly within the unprivileged 1024..65535 range. Added ephemeral-port regression coverage.

The two affected packages pass locally after the correction:

  • tests/integration/evm/mempool (221.926s)
  • tests/integration/evm/precisebank (89.076s)

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2942b487f0

ℹ️ 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".

Comment thread cmd/lumera/cmd/commands.go Outdated
@akobrin1

Copy link
Copy Markdown
Contributor Author

Addressed the latest occupied-upstream P2 in 69f8c15f:

  • preserves the deterministic primary mapping
  • falls back through a deterministic permutation of the unprivileged port range when the primary is occupied
  • excludes the operator-configured public listener from fallback selection
  • adds a regression test that occupies the primary and verifies an available unprivileged fallback

Focused command tests and the JSON-RPC tests under the race detector pass.

@codex review

@akobrin1

Copy link
Copy Markdown
Contributor Author

Follow-up 1edc7280 serializes tests that mutate Cosmos SDK globals. The full cmd/lumera/cmd package now passes under go test -race; production behavior is unchanged.

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 1edc7280a3

ℹ️ 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".

Comment thread cmd/lumera/cmd/commands.go Outdated
@akobrin1

Copy link
Copy Markdown
Contributor Author

Addressed the latest listener-collision P2 in 8e41d466:

  • excludes configured WS, JSON-RPC metrics, geth metrics, API, gRPC, rate-limit proxy, and CometBFT RPC/P2P/pprof/prometheus/validator ports from upstream selection
  • handles both plain host:port and scheme-prefixed listener addresses
  • adds the exact regression case where public :39267 derives default WS :8546

The full command package passes normally and under -race.

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 👍

Reviewed commit: 8e41d4666b

ℹ️ 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".

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.

🔵 Needs a closer look

It bundles a substantial, undescribed rework of production JSON-RPC startup port selection (plus other undocumented test-infra changes) that warrants human review beyond the stated devnet scope.

Pull request overview

This PR is primarily a devnet/test-stabilization change. As described, it quiets spurious WARN logs from the evmigration status-registry probes by splitting the lookup into a silent lookupStatusRegistryMnemonic (used for infrastructure-key candidates that legitimately don't exist on a given host) and the warning readStatusRegistryMnemonic (for keys expected to be registered), makes updateStatusRegistryAddress skip untracked accounts silently, removes the unused appendStatusRegistryAccount helper, corrects the Height format verb, and bumps the devnet-evm-upgrade flow to a v1.20.2 plan that installs a superseding v1.20.3 binary. Beyond the stated scope, the diff also reworks production JSON-RPC alias port selection in cmd/lumera/cmd/commands.go, adds a transient-error retry to an EVM integration test helper, refactors system-test node cleanup, and drops t.Parallel() from several tests.

Changes:

  • Silent vs. warning status-registry lookups; silent skip of untracked accounts; removal of appendStatusRegistryAccount; Height verb fix (%d%s, correct since the local JSON struct field is a string).
  • Devnet upgrade plumbing: upgrade.sh gains an optional expected-binary-version arg, devnet-upgrade-1202 installs the v1.20.3 binary for the v1.20.2 plan, and devnet-evm-upgrade targets v1.20.2.
  • Undescribed additions: deterministic/exclusion-aware reserveLoopbackAddr in commands.go, EVM tx-helper retry, system-test t.Cleanup refactor, and t.Parallel() removals.
File summaries
File Description
devnet/tests/evmigration/status_registry.go Splits lookup into silent/warning variants; silences untracked-account updates; removes unused append helper
devnet/tests/evmigration/status_registry_test.go New unit tests for lookup/update helpers via a temp registry file
devnet/tests/evmigration/prepare.go Uses the silent lookup when probing infrastructure-key candidates
devnet/tests/evmigration/migrate_validators.go Corrects Height verb to %s (local JSON struct field is a string)
Makefile.devnet Bumps devnet-evm-upgrade to v1.20.2 and passes v1.20.3 as the superseding binary
devnet/scripts/upgrade.sh Adds optional expected-binary-version arg for plan-vs-binary version divergence
tests/scripts/devnet-makefile.bats Adds a dry-run test asserting the v1.20.2 plan installs the v1.20.3 binary
cmd/lumera/cmd/commands.go Undescribed: deterministic, exclusion-aware internal JSON-RPC loopback port selection
cmd/lumera/cmd/commands_test.go Tests for the new loopback address selection logic
tests/integration/evmtest/tx_helpers.go Undescribed: retries legacy tx send on transient "exceeds block gas limit"
tests/integration/evmtest/tx_helpers_test.go Test for the transient-error classifier
tests/systemtests/system.go Undescribed: moves node-result draining into t.Cleanup and stops the chain there
cmd/lumera/cmd/root_test.go, config_migrate_test.go Undescribed: removes t.Parallel() from config/EVM-flag tests
Review details
  • Files reviewed: 14/14 changed files
  • Comments generated: 1
  • Review effort level: Balanced

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


func reserveLoopbackAddr() (string, error) {
ln, err := net.Listen("tcp", "127.0.0.1:0")
func reserveLoopbackAddr(publicAddr string, excludedAddrs ...string) (string, error) {
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