Skip to content

fix: bump ens-test-env devnet, refresh sepolia-v2 namespace, isolate orchestrator stack#2036

Merged
shrugs merged 17 commits intomainfrom
fix/devnet-to-latest
May 1, 2026
Merged

fix: bump ens-test-env devnet, refresh sepolia-v2 namespace, isolate orchestrator stack#2036
shrugs merged 17 commits intomainfrom
fix/devnet-to-latest

Conversation

@shrugs
Copy link
Copy Markdown
Member

@shrugs shrugs commented Apr 30, 2026

Reviewer Focus (Read This First)

  1. chainId columns widened from int4int8 across all ensdb-sdk schemas. forced by sepolia-v2's new chain id (99911155111).
  2. sepolia-v2 namespace addresses replaced wholesale and now use a custom sepoliaV2Chain (id 99911155111) on tenderly virtual sepolia.
  3. devnet chain id reverted 0xeeeeed31337 to dodge mainnet.id=1 collision introduced by the upstream devnet bump.

Problem & Motivation

  • ens-test-env devnet image stale (main-e8696c6main-53f1482).
  • upstream devnet now defaults to chain id 1, colliding with mainnet in ponder_sync cache.
  • sepolia-v2 namespace was pointing at the old deployment; new deployment lives on a virtual sepolia with new addresses.
  • new sepolia-v2 chain id overflows int4.
  • services/devnet.yml's hardcoded container_name: devnet collides with the integration-test orchestrator any time a developer runs the manual devnet stack.
  • CLAUDE.md was gitignored, so its @AGENTS.md import never reliably loaded for agents — symlinking it makes AGENTS.md the single source of truth across humans and AI tools.

What Changed (Concrete)

  1. devnet image bumped to main-53f1482; chain id reverted to 31337.
  2. sepolia-v2 namespace points at the new tenderly virtual chain; all contract addresses refreshed; legacy/wrapped controllers zeroed per ENS team.
  3. ensdb-sdk chainId columns: t.integer()t.int8({ mode: "number" }) across ensv2, protocol-acceleration, tokenscope schemas.
  4. DevnetAccounts.{deployer,owner,user,user2}.{address,resolver} replaces flat DEVNET_* constants; tests migrated.
  5. docker compose: container_name and ensdb host port 5432:5432 hoisted out of services/*.yml into the consumer compose files. docker-compose.orchestrator.yml sets neither → project-prefixed, fully isolated names; ephemeral postgres port. orchestrator wait strategy updated to match.
  6. rpc-configs-from-env and ponder-helpers updated to know about sepoliaV2Chain.
  7. CLAUDE.md is now a symlink to AGENTS.md; corresponding line removed from .gitignore.

Design & Planning

lightweight; no design doc. each step was tactical, surfaced while chasing the devnet bump. devnet host port left at 8545:8545 — making it ephemeral would require threading RPC_URL_<chainId> into the spawned ENSIndexer; deferred.

  • Planning artifacts: none
  • Reviewed / approved by: none

Self-Review

  • merge from main: resolved int8 (branch) + NormalizedAddress (main) in ensv2.schema.ts; resolved event.sender (main, HCA-aware) + DevnetAccounts.deployer.address (branch) in account.integration.test.ts.
  • simplified: disableCache check, orchestrator yml (no more inlined ensdb).
  • naming: DevnetAccounts groups address/resolver per account.
  • dead code: removed inlined ensdb block + obsolete comment in orchestrator yml.

Cross-Codebase Alignment

  • search terms: container_name, DEVNET_DEPLOYER, ensTestEnvChain, chainId: t.integer, 8545.
  • reviewed but unchanged: Address vs NormalizedAddress in non-chainId columns of protocol-acceleration and tokenscope schemas — pre-existing, out of scope.
  • deferred: ephemeral devnet host port.

Downstream & Consumer Impact

  • @ensnode/ensnode-sdk/internal: DEVNET_* removed → use DevnetAccounts.

  • @ensnode/datasources: sepoliaV2Chain newly exported; sepolia-v2 namespace addresses fully replaced.

  • docker users on docker-compose.yml / docker-compose.devnet.yml: container names preserved, no behavior change.

  • orchestrator container names now project-prefixed; any external tooling expecting literal devnet/ensdb against the orchestrator will need updating.

  • agents picking up the repo will now load AGENTS.md automatically via the CLAUDE.md symlink.

  • Public APIs affected: @ensnode/ensnode-sdk/internal, @ensnode/datasources

  • Docs updated: none required

  • Naming decisions worth calling out: DevnetAccounts, sepoliaV2Chain

Testing Evidence

  • pnpm -F typecheck passes for @ensnode/ensdb-sdk, ensapi, @ensnode/integration-test-env post-merge.

  • docker compose config clean for orchestrator + devnet compose files.

  • @shrugs ran integration tests manually end-to-end after the docker compose refactor — green.

  • Testing performed: typecheck, compose-config validation, manual end-to-end integration test

  • Known gaps: orchestrator still collides on host port 8545 with a concurrent manual devnet

  • What reviewers have to reason about manually: int8 widening is invisible at the TS layer (still number) — confirm no drizzle/postgres bigint edges are exposed

Scope Reductions

  • ephemeral host port for devnet (would require threading RPC_URL_<chainId> to ENSIndexer).
  • AddressNormalizedAddress cleanup in protocol-acceleration / tokenscope schemas.

each is independent of the devnet/sepolia-v2 bump.

  • Follow-ups: above
  • Why deferred: would balloon review surface

Risk Analysis

  • sepolia-v2 namespace addresses changed: standard re-index on next deploy.

  • devnet chain id flip 0xeeeeed31337: stale ponder caches harmless (disableCache short-circuits on ensTestEnvChain.id).

  • compose hoisting: only docker-compose.orchestrator.yml changes behavior; manual stacks preserve friendly names.

  • CLAUDE.md gitignore removal: anyone with their own personal CLAUDE.md will hit a checkout conflict and need to delete or re-symlink locally.

  • Risk areas: namespace address change, local CLAUDE.md conflicts on pull

  • Mitigations or rollback: revertable

  • Named owner if this causes problems: @shrugs

Pre-Review Checklist (Blocking)

  • I reviewed every line of this diff and understand it end-to-end
  • I'm prepared to defend this PR line-by-line in review
  • I'm comfortable being the on-call owner for this change
  • Relevant changesets are included (or explicitly not required)

Copilot AI review requested due to automatic review settings April 30, 2026 16:52
@shrugs shrugs requested a review from a team as a code owner April 30, 2026 16:52
@vercel
Copy link
Copy Markdown
Contributor

vercel Bot commented Apr 30, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
admin.ensnode.io Ready Ready Preview, Comment May 1, 2026 6:27pm
ensnode.io Ready Ready Preview, Comment May 1, 2026 6:27pm
ensrainbow.io Ready Ready Preview, Comment May 1, 2026 6:27pm

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Apr 30, 2026

🦋 Changeset detected

Latest commit: 0969378

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 24 packages
Name Type
ensindexer Major
@ensnode/ensnode-sdk Major
@ensnode/datasources Major
ensadmin Major
ensapi Major
ensrainbow Major
fallback-ensapi Major
@namehash/ens-referrals Major
@ensnode/ensdb-sdk Major
@ensnode/ensnode-react Major
@ensnode/ensrainbow-sdk Major
@ensnode/integration-test-env Major
@namehash/namehash-ui Major
@docs/ensnode Major
@docs/ensrainbow Major
enssdk Major
enscli Major
enskit Major
ensskills Major
@ensnode/ponder-sdk Major
@ensnode/ponder-subgraph Major
@ensnode/shared-configs Major
@ensnode/ensindexer-perf-testing Major
@ensnode/enskit-react-example Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Apr 30, 2026

Warning

Rate limit exceeded

@shrugs has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 52 minutes and 22 seconds before requesting another review.

To keep reviews running without waiting, you can enable usage-based add-on for your organization. This allows additional reviews beyond the hourly cap. Account admins can enable it under billing.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: b0cd53f7-e4ca-4515-9b8d-37a556ef9d58

📥 Commits

Reviewing files that changed from the base of the PR and between 92c441e and 0969378.

📒 Files selected for processing (1)
  • docker/envs/.env.docker.common
📝 Walkthrough

Walkthrough

This PR consolidates infrastructure and configuration updates: refactors devnet account constants into a structured DevnetAccounts object, introduces Sepolia V2 chain support, updates ENS test environment contract deployments, modifies database schema column types for chainId fields, adjusts Docker configuration with deterministic container names and explicit port mappings, and updates test fixtures and orchestration accordingly.

Changes

Cohort / File(s) Summary
Changesets & Metadata
.changeset/cool-friends-share.md, .changeset/tame-clowns-tell.md, .changeset/devnet-accounts-refactor.md, CLAUDE.md, .gitignore
Adds three release notes documenting minor version bumps for ensindexer and @ensnode/datasources, plus a devnet-accounts refactor API change. Removes CLAUDE.md from gitignore tracking.
Devnet Accounts Refactoring
packages/ensnode-sdk/src/shared/devnet-accounts.ts, packages/ensnode-sdk/src/omnigraph-api/example-queries.ts, apps/ensapi/src/handlers/api/resolution/resolve-primary-name.integration.test.ts, apps/ensapi/src/handlers/api/resolution/resolve-primary-names.integration.test.ts, apps/ensapi/src/handlers/api/resolution/resolve-records.integration.test.ts, apps/ensapi/src/omnigraph-api/schema/account.integration.test.ts
Consolidates DEVNET_DEPLOYER, DEVNET_OWNER, DEVNET_USER, DEVNET_USER2 into a single DevnetAccounts object with address and resolver properties per role. Updates all test files and example queries to use the new structure.
Chain Configuration & Datasources
packages/datasources/src/lib/chains.ts, packages/datasources/src/ens-test-env.ts, packages/datasources/src/sepolia-v2.ts, packages/ensnode-sdk/src/shared/config/build-rpc-urls.test.ts, packages/ensnode-sdk/src/shared/config/rpc-configs-from-env.test.ts, packages/namehash-ui/src/utils/chains.ts
Introduces sepoliaV2Chain constant, redefines ensTestEnvChain to use anvil defaults with id 31337, updates contract addresses in test environment and Sepolia V2 datasources, and adds Sepolia V2 to supported chains with custom naming.
Database Schema Updates
packages/ensdb-sdk/src/ensindexer-abstract/ensv2.schema.ts, packages/ensdb-sdk/src/ensindexer-abstract/protocol-acceleration.schema.ts, packages/ensdb-sdk/src/ensindexer-abstract/tokenscope.schema.ts
Changes chainId column type from t.integer() to t.int8({ mode: "number" }) across multiple tables in three schema files, preserving non-null constraints and type mappings.
Ponder Helpers
apps/ensindexer/src/lib/ponder-helpers.ts
Updates chainsConnectionConfig to disable cache only for ens-test-env instead of local development chain IDs 31337 and 1337.
Docker Infrastructure
docker/docker-compose.yml, docker/docker-compose.devnet.yml, docker/docker-compose.orchestrator.yml, docker/services/devnet.yml, docker/services/ensdb.yml, docker/envs/.env.docker.devnet, docker/README.md
Adds explicit port mappings (5432:5432, 5433:5432) for ensdb across compose files, updates devnet service to use new contracts-v2 image version 580c60a, assigns deterministic container names (*-orchestrator), refactors orchestrator ensdb service to extend from base definition, updates environment variable RPC_URL_15658733 to RPC_URL_31337, and fixes markdown formatting.
Integration Test Orchestrator
packages/integration-test-env/src/orchestrator.ts
Refactors container synchronization to wait for deterministic names (devnet-orchestrator, ensdb-orchestrator), switches to fixed Postgres port 5433 with precomputed ENSDB_URL, changes devnet chain-id validation from RPC mutation (anvil_setChainId) to read-only check (publicClient.getChainId()), and updates logging prefixes from [ci] to [orchestrator].

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~50 minutes

Possibly related PRs

Suggested labels

javascript

Poem

🐰 New chains bloom in Sepolia's light,
Docker names now precise and right,
Devnet accounts consolidated with care,
Schema columns refined everywhere,
Fresh addresses deployed with delight!

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 33.33% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately summarizes the three main changes: bumping ens-test-env devnet, refreshing sepolia-v2 namespace, and isolating the orchestrator stack.
Description check ✅ Passed The PR description is comprehensive and well-structured, covering all required template sections: Summary, Why, Testing, Notes for Reviewer, and Pre-Review Checklist. It exceeds minimum requirements with detailed Problem & Motivation, Concrete Changes, Testing Evidence, and Risk Analysis.
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.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/devnet-to-latest

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
Review rate limit: 0/1 reviews remaining, refill in 52 minutes and 22 seconds.

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

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented Apr 30, 2026

Greptile Summary

This PR bundles several interconnected infrastructure fixes: bumping the ens-test-env devnet image and reverting its chain id to 31337, refreshing all sepolia-v2 contract addresses on a new Tenderly virtual-Sepolia chain (id 99911155111), widening every chainId column from int4int8 to accommodate that large chain id, replacing flat DEVNET_* constants with the grouped DevnetAccounts object, and isolating the orchestrator compose stack with explicit container names and a fixed port (5433).

Confidence Score: 5/5

Safe to merge; the only finding is a P2 comment inaccuracy in the orchestrator compose file.

All changes are mechanical and well-scoped: address refreshes, schema widening with no JS precision risk, a clean API refactor, and a compose restructuring verified end-to-end. The single P2 finding does not affect runtime behaviour.

docker/docker-compose.orchestrator.yml — comment overstates isolation guarantees for parallel orchestrator runs.

Important Files Changed

Filename Overview
docker/docker-compose.orchestrator.yml Inline ensdb block replaced with extends services/ensdb.yml; explicit container_name: *-orchestrator added; port switched from ephemeral 0:5432 to fixed 5433:5432. Comment overstates isolation — parallel orchestrator runs will still collide on port 5433 and fixed container names.
packages/datasources/src/sepolia-v2.ts All contract addresses refreshed for the new Tenderly virtual-Sepolia deployment; LegacyEthRegistrarController and WrappedEthRegistrarController zeroed per ENS team guidance; startBlock updated to the new registry deploy block.
packages/ensdb-sdk/src/ensindexer-abstract/ensv2.schema.ts Six chainId columns widened from t.integer() to t.int8({ mode: "number" }) to accommodate sepolia-v2's chain id (99911155111); values remain JS number at the TypeScript layer with no precision risk.
packages/integration-test-env/src/orchestrator.ts Removed anvil_setChainId override in favour of a simple assertion; ENSDB_PORT hardcoded to 5433 matching the compose binding; wait-strategy labels updated to match new container names.
packages/datasources/src/lib/chains.ts Devnet chain id changed from 0xeeeeed to 31337 (Anvil default); new sepoliaV2Chain added with id 99911155111 on Tenderly virtual Sepolia.
packages/ensnode-sdk/src/shared/devnet-accounts.ts Flat DEVNET_* constants replaced with a DevnetAccounts object grouping address and resolver per account; all four accounts migrated cleanly.
docker/services/ensdb.yml ports block removed from the shared service definition; each consumer compose file now explicitly declares its own port binding, improving isolation.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    B[services/devnet.yml
container_name: devnet]
    C[services/ensdb.yml
no ports]

    A1[docker-compose.yml] -->|inherits devnet name
adds 5432:5432| C
    A2[docker-compose.devnet.yml] -->|inherits devnet name
adds 5432:5432| C
    A3[docker-compose.orchestrator.yml] -->|container_name: devnet-orchestrator
binds 5433:5432| C
    A3 --> B

    A3 -->|withWaitStrategy devnet-orchestrator| D[orchestrator.ts
ENSDB_PORT=5433
asserts chainId===31337]

    style A3 fill:#f9f,stroke:#333
    style D fill:#bbf,stroke:#333
Loading

Reviews (9): Last reviewed commit: "nit: disable ponder telemetry" | Re-trigger Greptile

Comment thread packages/datasources/src/lib/chains.ts Outdated
Comment thread packages/namehash-ui/src/utils/chains.ts
…tions

CLAUDE.md was gitignored; now committed as a symlink to the canonical
AGENTS.md so every agent session loads the repo's conventions instead of
relying on the @-import resolving in CLAUDE.md.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates ENSNode’s devnet + sepolia-v2 configuration to accommodate a new (int4-overflowing) chain id, refresh sepolia-v2 deployments, and avoid Docker/Testcontainers collisions in integration orchestration.

Changes:

  • Introduce sepoliaV2Chain (id 99911155111) and repoint the sepolia-v2 namespace to new virtual Sepolia addresses/start block.
  • Widen chainId columns from int4int8 across ensdb-sdk schemas.
  • Refactor devnet account constants into DevnetAccounts and adjust docker compose files to isolate orchestrator stacks (no container_name, ephemeral ensdb port).

Reviewed changes

Copilot reviewed 27 out of 29 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
packages/namehash-ui/src/utils/chains.ts Imports sepoliaV2Chain and adds a custom display name for it.
packages/integration-test-env/src/orchestrator.ts Renames log prefixes and updates Testcontainers wait strategies for non-container_name compose services.
packages/ensnode-sdk/src/shared/devnet-accounts.ts Replaces flat DEVNET_* constants with structured DevnetAccounts.
packages/ensnode-sdk/src/shared/config/rpc-configs-from-env.ts Adds special-casing to auto-provide an RPC URL for sepoliaV2Chain.
packages/ensnode-sdk/src/omnigraph-api/example-queries.ts Switches example query variables to use DevnetAccounts.
packages/ensdb-sdk/src/ensindexer-abstract/tokenscope.schema.ts Widen chainId columns to int8({ mode: "number" }).
packages/ensdb-sdk/src/ensindexer-abstract/protocol-acceleration.schema.ts Widen chainId columns to int8({ mode: "number" }).
packages/ensdb-sdk/src/ensindexer-abstract/ensv2.schema.ts Widen chainId columns to int8({ mode: "number" }).
packages/datasources/src/sepolia-v2.ts Repoints sepolia-v2 namespace to sepoliaV2Chain and refreshes contract addresses + start block.
packages/datasources/src/lib/chains.ts Reverts devnet chain id to 31337 and defines sepoliaV2Chain + RPC URL.
docker/services/ensrainbow.yml Removes container_name; reformats healthcheck array.
docker/services/ensindexer.yml Removes container_name; reformats healthcheck array.
docker/services/ensdb.yml Removes container_name and fixed port mapping; reformats healthcheck array.
docker/services/ensapi.yml Removes container_name; reformats healthcheck array.
docker/services/ensadmin.yml Removes container_name.
docker/services/devnet.yml Bumps devnet image; removes container_name; adds TODO re chain id; reformats healthcheck array.
docker/docker-compose.yml Restores friendly container_names at the consumer compose layer; restores ensdb 5432:5432.
docker/docker-compose.orchestrator.yml Uses no container_name and uses ephemeral host port for ensdb via extends.
docker/docker-compose.devnet.yml Restores friendly container_names and ensdb 5432:5432 for manual devnet stack.
docker/README.md Minor markdown whitespace tweak.
apps/ensindexer/src/lib/ponder-helpers.ts Narrows cache-disable condition to ensTestEnvChain.id.
apps/ensapi/src/omnigraph-api/schema/account.integration.test.ts Updates tests to use DevnetAccounts.
apps/ensapi/src/handlers/api/resolution/resolve-records.integration.test.ts Updates tests to use DevnetAccounts.
apps/ensapi/src/handlers/api/resolution/resolve-primary-names.integration.test.ts Updates tests to use DevnetAccounts.
apps/ensapi/src/handlers/api/resolution/resolve-primary-name.integration.test.ts Updates tests to use DevnetAccounts.
.changeset/tame-clowns-tell.md Adds a changeset for @ensnode/datasources sepolia-v2 refresh.
.changeset/cool-friends-share.md Adds a changeset for ensindexer devnet commit bump.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread docker/services/devnet.yml Outdated
Comment thread packages/ensnode-sdk/src/shared/config/rpc-configs-from-env.ts Outdated
Comment thread packages/datasources/src/lib/chains.ts
Comment thread packages/datasources/src/lib/chains.ts Outdated
Comment thread .changeset/tame-clowns-tell.md
vercel[bot]

This comment was marked as resolved.

…ify chain id

Bumps the ens-test-env devnet image to main-580c60a (which natively defaults to
chain id 31337) and updates 7 contract addresses in ens-test-env.ts that shifted
in the new deterministic deployment: LegacyEthRegistrarController,
UnwrappedEthRegistrarController, UniversalResolver (V1), UniversalResolverV2,
ETHRegistrar (v2), DefaultPublicResolver4, DefaultPublicResolver5.

Replaces the orchestrator's anvil_setChainId override with a getChainId() check
that fails fast on mismatch, since the new image already defaults to 31337.

Verified with 10 consecutive `pnpm test:integration:ci` runs, all green.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 7

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (2)
apps/ensapi/src/handlers/api/resolution/resolve-primary-names.integration.test.ts (1)

16-34: ⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Update chainIds and expected response keys to devnet 31337.

The cases around Lines 19/22 and 30/33 still use chain "1". With devnet now on 31337, these assertions are stale and may miss regressions on the active chain.

Suggested patch
-        "resolves primary names for owner address on chain 1 (no primary name set in devnet)",
+        "resolves primary names for owner address on chain 31337 (no primary name set in devnet)",
       address: DevnetAccounts.owner.address,
-      query: "chainIds=1",
+      query: "chainIds=31337",
@@
-        names: { "1": null },
+        names: { "31337": null },
@@
       description: "resolves all primary names",
       address: DevnetAccounts.owner.address,
@@
-        names: { "1": null },
+        names: { "31337": null },
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@apps/ensapi/src/handlers/api/resolution/resolve-primary-names.integration.test.ts`
around lines 16 - 34, Update the test assertions in
resolve-primary-names.integration.test.ts so they target the devnet chain id
31337 instead of "1": change the query string "chainIds=1" to "chainIds=31337"
and update the expectedBody.names keys from "1" to "31337" in both affected test
cases (the case with query "chainIds=1" and the "resolves all primary names"
case that currently expects names { "1": null }). Ensure the string keys and any
related comparisons use "31337" consistently.
apps/ensapi/src/handlers/api/resolution/resolve-primary-name.integration.test.ts (1)

16-39: ⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Use current devnet chain id in test cases (31337), not "1".

Lines 19, 28, and 36 still target "1" while devnet is now 31337. This can make the suite pass without asserting behavior on the active devnet chain.

Suggested patch
-        "resolves primary name for owner address on chain 1 (no primary name set in devnet)",
+        "resolves primary name for owner address on chain 31337 (no primary name set in devnet)",
       address: DevnetAccounts.owner.address,
-      chainId: "1",
+      chainId: "31337",
@@
-        "resolves primary name for user address on chain 1 (no primary name set in devnet)",
+        "resolves primary name for user address on chain 31337 (no primary name set in devnet)",
       address: DevnetAccounts.user.address,
-      chainId: "1",
+      chainId: "31337",
@@
       description: "owner address with accelerate=true returns accelerationRequested: true",
       address: DevnetAccounts.owner.address,
-      chainId: "1",
+      chainId: "31337",
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@apps/ensapi/src/handlers/api/resolution/resolve-primary-name.integration.test.ts`
around lines 16 - 39, The test cases in resolve-primary-name.integration.test.ts
are using chainId "1" instead of the devnet chain id 31337; update the three
test objects that set chainId to "1" (the cases referencing
DevnetAccounts.owner.address and DevnetAccounts.user.address and the
accelerate=true case) to use "31337" so they run against the active devnet
chain; modify the chainId fields in those test entries to "31337" and run the
integration tests to confirm behavior.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In @.changeset/cool-friends-share.md:
- Line 5: Update the changeset note in .changeset/cool-friends-share.md so the
devnet commit reference matches the actual image tag used in this PR: replace
the old commit string "53f1482" with the current devnet image tag "main-580c60a"
(ensure the line that currently reads "Updates ens-test-env devnet commit to
`53f1482`." becomes "Updates ens-test-env devnet commit to `main-580c60a`.").

In `@docker/services/devnet.yml`:
- Line 11: The inline YAML array for the healthcheck command under the test key
contains extra spaces inside the brackets; update the test array (the "test" key
containing "CMD" and "curl") to use compact bracket syntax with no spaces after
'[' or before ']' (e.g., change the current spaced form to a compact inline
list) so YAMLlint no longer flags the bracket spacing.

In `@docker/services/ensapi.yml`:
- Line 10: Remove the extra spaces inside the inline YAML list for the docker
Compose healthcheck; update the test value (currently `test: [ "CMD", "curl",
"--fail", "-s", "http://localhost:4334/health" ]`) to use no spaces directly
after `[` and before `]` (e.g., `test:
["CMD","curl","--fail","-s","http://localhost:4334/health"]`) so it complies
with YAMLlint and standard inline-list formatting.

In `@docker/services/ensdb.yml`:
- Line 7: The YAML inline-list for the test key contains extra spaces inside the
square brackets (the value of test:), which triggers YAMLlint; fix by
normalizing the inline sequence to remove the internal spacing so the test
mapping uses a compact inline list (update the test value associated with the
test key in docker/services/ensdb.yml).

In `@docker/services/ensindexer.yml`:
- Line 10: The YAML inline list for the healthcheck "test" entry has extra
spaces inside the brackets; update the "test" value (the healthcheck test list)
to use standard YAML inline list spacing by removing the inner spaces so it
becomes a compact list (e.g.,
["CMD","curl","--fail","-s","http://localhost:42069/health"]) ensuring the key
name "test" and its list remain unchanged semantically.

In `@docker/services/ensrainbow.yml`:
- Line 12: The YAML inline list for the healthcheck "test" key contains extra
spaces inside the square brackets; update the list in
docker/services/ensrainbow.yml (the test entry containing "CMD", "wget", "-q",
"--spider", "http://localhost:3223/health") so there are no spaces directly
inside the brackets (e.g. change from [ "CMD", ... ] to ["CMD", ...]) to satisfy
YAMLlint.

In `@packages/ensdb-sdk/src/ensindexer-abstract/ensv2.schema.ts`:
- Around line 104-106: The schema introduced a widening to int8 for chainId but
left other chain-id fields as t.integer(), causing overflow on large chain IDs;
locate fields named registrarChainId (and any other chain id fields still using
t.integer() in the registration/ensv2 schema) and replace t.integer() with
t.int8({ mode: "number" }).notNull().$type<ChainId>() (or the exact int8 pattern
used for chainId) so the column and TypeScript type match the widened chainId;
ensure you update all occurrences (e.g., registration.registrarChainId and any
similar fields referenced elsewhere in the file) to the same int8 definition.

---

Outside diff comments:
In
`@apps/ensapi/src/handlers/api/resolution/resolve-primary-name.integration.test.ts`:
- Around line 16-39: The test cases in resolve-primary-name.integration.test.ts
are using chainId "1" instead of the devnet chain id 31337; update the three
test objects that set chainId to "1" (the cases referencing
DevnetAccounts.owner.address and DevnetAccounts.user.address and the
accelerate=true case) to use "31337" so they run against the active devnet
chain; modify the chainId fields in those test entries to "31337" and run the
integration tests to confirm behavior.

In
`@apps/ensapi/src/handlers/api/resolution/resolve-primary-names.integration.test.ts`:
- Around line 16-34: Update the test assertions in
resolve-primary-names.integration.test.ts so they target the devnet chain id
31337 instead of "1": change the query string "chainIds=1" to "chainIds=31337"
and update the expectedBody.names keys from "1" to "31337" in both affected test
cases (the case with query "chainIds=1" and the "resolves all primary names"
case that currently expects names { "1": null }). Ensure the string keys and any
related comparisons use "31337" consistently.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: e320de08-05aa-4f7e-87c1-77945bfe3d2d

📥 Commits

Reviewing files that changed from the base of the PR and between 7e77c5c and d7bb0f5.

📒 Files selected for processing (30)
  • .changeset/cool-friends-share.md
  • .changeset/tame-clowns-tell.md
  • .gitignore
  • CLAUDE.md
  • apps/ensapi/src/handlers/api/resolution/resolve-primary-name.integration.test.ts
  • apps/ensapi/src/handlers/api/resolution/resolve-primary-names.integration.test.ts
  • apps/ensapi/src/handlers/api/resolution/resolve-records.integration.test.ts
  • apps/ensapi/src/omnigraph-api/schema/account.integration.test.ts
  • apps/ensindexer/src/lib/ponder-helpers.ts
  • docker/README.md
  • docker/docker-compose.devnet.yml
  • docker/docker-compose.orchestrator.yml
  • docker/docker-compose.yml
  • docker/services/devnet.yml
  • docker/services/ensadmin.yml
  • docker/services/ensapi.yml
  • docker/services/ensdb.yml
  • docker/services/ensindexer.yml
  • docker/services/ensrainbow.yml
  • packages/datasources/src/ens-test-env.ts
  • packages/datasources/src/lib/chains.ts
  • packages/datasources/src/sepolia-v2.ts
  • packages/ensdb-sdk/src/ensindexer-abstract/ensv2.schema.ts
  • packages/ensdb-sdk/src/ensindexer-abstract/protocol-acceleration.schema.ts
  • packages/ensdb-sdk/src/ensindexer-abstract/tokenscope.schema.ts
  • packages/ensnode-sdk/src/omnigraph-api/example-queries.ts
  • packages/ensnode-sdk/src/shared/config/rpc-configs-from-env.ts
  • packages/ensnode-sdk/src/shared/devnet-accounts.ts
  • packages/integration-test-env/src/orchestrator.ts
  • packages/namehash-ui/src/utils/chains.ts
💤 Files with no reviewable changes (2)
  • docker/services/ensadmin.yml
  • .gitignore

Comment thread .changeset/cool-friends-share.md Outdated
Comment thread docker/services/devnet.yml
Comment thread docker/services/ensapi.yml Outdated
Comment thread docker/services/ensdb.yml Outdated
Comment thread docker/services/ensindexer.yml Outdated
Comment thread docker/services/ensrainbow.yml Outdated
Comment thread packages/ensdb-sdk/src/ensindexer-abstract/ensv2.schema.ts
…V2Chain

sepoliaV2Chain (Tenderly virtual chain id 99911155111) bypasses Alchemy /
QuickNode / dRPC URL builders the same way ensTestEnvChain does. Update the
two affected unit tests to skip provider assertions for that chain id, mirroring
the existing lineaSepolia exception for QuickNode.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings April 30, 2026 21:36
… the Tenderly URL

- chains.ts: drop the hardcoded `rpcUrls.default` overrides on `ensTestEnvChain`
  and `sepoliaV2Chain`. Consumers must now provide RPC_URL_99911155111 to index
  sepolia-v2.
- rpc-configs-from-env.ts: remove the `if (chain.id === sepoliaV2Chain.id)`
  fallback — there's no project-specific URL to fall back to anymore.
- rpc-configs-from-env.test.ts: extend the existing namespace filter to also
  exclude sepolia-v2 (no provider supports chainId 99911155111).
- build-rpc-urls.test.ts: rename `LOCAL_CHAIN_IDS` to
  `CHAINS_WITHOUT_AUTO_RPC_SUPPORT` and include sepoliaV2Chain.id.
- devnet.yml: pin chain id via `--chain 31337` so the devnet image's default
  drift can't break us.
- .env.docker.devnet: update RPC_URL_15658733 → RPC_URL_31337 to match the
  ensTestEnvChain id revert.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 31 out of 33 changed files in this pull request and generated 4 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread packages/ensnode-sdk/src/shared/config/rpc-configs-from-env.test.ts
Comment thread docker/services/devnet.yml Outdated
Comment thread packages/namehash-ui/src/utils/chains.ts
Comment thread packages/ensdb-sdk/src/ensindexer-abstract/ensv2.schema.ts
…chestrator + fixed port 5433

Per @sevenzing's review feedback:

- services/*.yml regain `container_name:` so they're the source of truth.
- docker-compose.yml and docker-compose.devnet.yml drop their `container_name:`
  overrides (now inherited).
- docker-compose.orchestrator.yml overrides container_name to
  `devnet-orchestrator` and `ensdb-orchestrator` so its containers never
  collide with the manual stacks.
- ensdb-orchestrator binds host port `5433:5432` (was ephemeral `0:5432`),
  giving developers a well-known port for `psql -h localhost -p 5433` after
  a test run.
- orchestrator.ts: wait strategies use the new names; ENSDB_URL is now a
  fixed `localhost:5433` constant — drops the testcontainers
  `getMappedPort()` dance.
- services/devnet.yml: fix typo `--chain 31337` → `--chainId 31337` (the
  flag the contracts-v2 image actually accepts).

Verified end-to-end with `pnpm test:integration:ci` (12 files / 227 tests).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@shrugs
Copy link
Copy Markdown
Member Author

shrugs commented May 1, 2026

@greptile review

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 28 out of 30 changed files in this pull request and generated 5 comments.

Comments suppressed due to low confidence (1)

CLAUDE.md:1

  • The PR description states CLAUDE.md is a symlink to AGENTS.md, but this diff shows it as a regular file containing the text AGENTS.md. If the intent is a symlink, ensure it is committed as a Git symlink (mode 120000) so tools resolve it correctly and it stays a true single source of truth.
# ENSNode

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread packages/datasources/src/lib/chains.ts
Comment thread docker/docker-compose.orchestrator.yml
Comment thread docker/docker-compose.orchestrator.yml
Comment thread docker/docker-compose.orchestrator.yml
Comment thread packages/integration-test-env/src/orchestrator.ts
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

♻️ Duplicate comments (2)
docker/services/devnet.yml (2)

4-5: 🛠️ Refactor suggestion | 🟠 Major | ⚡ Quick win

Re-add an explicit --chainId 31337 pin in the devnet command.

This currently relies on upstream default behavior; an image bump can silently drift chain ID and break assumptions tied to RPC_URL_31337.

Suggested patch
-    command: ./script/runDevnet.ts --testNames
+    command: ./script/runDevnet.ts --testNames --chainId 31337
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docker/services/devnet.yml` around lines 4 - 5, The devnet service command
currently runs "./script/runDevnet.ts --testNames" without an explicit chain id;
update the command string for the devnet container to include "--chainId 31337"
(i.e., "./script/runDevnet.ts --testNames --chainId 31337") so the runtime no
longer relies on upstream defaults and keeps RPC_URL_31337 assumptions stable.

12-12: ⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Fix YAML inline-list spacing for healthcheck.test.

The extra spaces inside [] will keep YAMLlint failing.

Suggested patch
-      test: [ "CMD", "curl", "--fail", "-s", "http://localhost:8000/health" ]
+      test: ["CMD", "curl", "--fail", "-s", "http://localhost:8000/health"]
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docker/services/devnet.yml` at line 12, The inline list for the healthcheck
key (healthcheck.test) has extra spaces inside the square brackets causing
YAMLlint failures; edit the devnet.yml healthcheck test entry (the line
containing test: [ "CMD", "curl", "--fail", "-s", "http://localhost:8000/health"
]) to remove the interior spacing so the inline list is compact (e.g. test:
["CMD","curl","--fail","-s","http://localhost:8000/health"] or equivalent
properly spaced YAML list).
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@packages/ensnode-sdk/src/shared/config/rpc-configs-from-env.test.ts`:
- Around line 10-12: You removed SepoliaV2 from the shared test matrix
(allPublicEnsNamespaceIds) but still need a dedicated test that asserts the
intended RPC URL behavior for SepoliaV2 (RPC_URL_99911155111); add a standalone
test that targets ENSNamespaceIds.SepoliaV2 and verifies the environment-derived
RPC URL value (or resolution logic) matches RPC_URL_99911155111, mirroring
assertions used in the auto-generated-provider tests but scoped only to
SepoliaV2 so the excluded constant remains covered.

---

Duplicate comments:
In `@docker/services/devnet.yml`:
- Around line 4-5: The devnet service command currently runs
"./script/runDevnet.ts --testNames" without an explicit chain id; update the
command string for the devnet container to include "--chainId 31337" (i.e.,
"./script/runDevnet.ts --testNames --chainId 31337") so the runtime no longer
relies on upstream defaults and keeps RPC_URL_31337 assumptions stable.
- Line 12: The inline list for the healthcheck key (healthcheck.test) has extra
spaces inside the square brackets causing YAMLlint failures; edit the devnet.yml
healthcheck test entry (the line containing test: [ "CMD", "curl", "--fail",
"-s", "http://localhost:8000/health" ]) to remove the interior spacing so the
inline list is compact (e.g. test:
["CMD","curl","--fail","-s","http://localhost:8000/health"] or equivalent
properly spaced YAML list).
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: d681a8f5-c559-4830-9826-4b26289d6dce

📥 Commits

Reviewing files that changed from the base of the PR and between a9c2d3f and 92c441e.

📒 Files selected for processing (11)
  • docker/docker-compose.devnet.yml
  • docker/docker-compose.orchestrator.yml
  • docker/docker-compose.yml
  • docker/envs/.env.docker.devnet
  • docker/services/devnet.yml
  • docker/services/ensdb.yml
  • packages/datasources/src/lib/chains.ts
  • packages/datasources/src/sepolia-v2.ts
  • packages/ensnode-sdk/src/shared/config/build-rpc-urls.test.ts
  • packages/ensnode-sdk/src/shared/config/rpc-configs-from-env.test.ts
  • packages/integration-test-env/src/orchestrator.ts
💤 Files with no reviewable changes (1)
  • docker/services/ensdb.yml

Comment thread packages/ensnode-sdk/src/shared/config/rpc-configs-from-env.test.ts
@shrugs shrugs merged commit 43d8a9b into main May 1, 2026
18 checks passed
@shrugs shrugs deleted the fix/devnet-to-latest branch May 1, 2026 18:30
@github-actions github-actions Bot mentioned this pull request May 1, 2026
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.

4 participants