Renamed subregistryId to registryId across ENS Referrals#2047
Renamed subregistryId to registryId across ENS Referrals#2047Goader wants to merge 1 commit intotask/enhance-referrers-data-modelfrom
subregistryId to registryId across ENS Referrals#2047Conversation
🦋 Changeset detectedLatest commit: c73dc24 The changes in this PR will be included in the next version bump. This PR includes changesets to release 24 packages
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 |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Tip 💬 Introducing Slack Agent: The best way for teams to turn conversations into code.Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.
Built for teams:
One agent for your entire SDLC. Right inside Slack. 👉 Get your free trial and get 200 agent minutes per Slack user (a $50 value). 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. Comment |
subregistryId to registryId across ENS Referrals
Greptile SummaryThis PR renames Confidence Score: 4/5Rename is applied consistently across all 19 files with no logic regressions; the only concern is the changeset bump type. All P2 findings. The rename is mechanically complete and consistent. The sole flag is whether the changeset should be
Important Files Changed
Reviews (1): Last reviewed commit: "renamed subregistry id to registry id" | Re-trigger Greptile |
There was a problem hiding this comment.
Pull request overview
Renames the ENS Referrals rules field subregistryId to registryId throughout @namehash/ens-referrals and the ENSAPI ENSAnalytics referral leaderboard implementation to align with updated ENSv2 terminology.
Changes:
- Rename rules/config field
subregistryId→registryIdacross referral program rules, edition overlap logic, serializers, and Zod schemas. - Update ENSAPI referral leaderboard DB filtering to use
rules.registryId(while still queryingregistrarActions.subregistryId). - Update tests, docs/examples, and add a Changeset entry for the rename.
Reviewed changes
Copilot reviewed 19 out of 19 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| packages/ens-referrals/src/leaderboard-page.test.ts | Updates leaderboard page fixtures to use registryId. |
| packages/ens-referrals/src/edition.ts | Updates overlap invariant error text and grouping key to use rules.registryId. |
| packages/ens-referrals/src/edition.test.ts | Renames test fixtures/labels and inputs to registryId. |
| packages/ens-referrals/src/client.ts | Updates example output to reference rules.registryId. |
| packages/ens-referrals/src/award-models/shared/status.test.ts | Updates shared rules fixture to registryId. |
| packages/ens-referrals/src/award-models/shared/rules.ts | Renames base rules field and validation to registryId. |
| packages/ens-referrals/src/award-models/shared/api/zod-schemas.ts | Renames base rules schema key to registryId. |
| packages/ens-referrals/src/award-models/rev-share-cap/rules.ts | Renames builder parameter/property to registryId. |
| packages/ens-referrals/src/award-models/rev-share-cap/api/serialize.ts | Serializes registryId instead of subregistryId. |
| packages/ens-referrals/src/award-models/pie-split/rules.ts | Renames builder parameter/property to registryId. |
| packages/ens-referrals/src/award-models/pie-split/api/serialize.ts | Serializes registryId instead of subregistryId. |
| packages/ens-referrals/src/api/zod-schemas.ts | Updates invariant messaging and schema output to registryId. |
| packages/ens-referrals/src/api/zod-schemas.test.ts | Updates all referral API schema fixtures to registryId. |
| packages/ens-referrals/src/api/prerequisites.ts | Updates documentation comment to reference registryId. |
| packages/ens-referrals/README.md | Updates README example to reference rules.registryId. |
| apps/ensapi/src/lib/ensanalytics/referrer-leaderboard/mocks.ts | Updates ENSAnalytics mock rules to registryId. |
| apps/ensapi/src/lib/ensanalytics/referrer-leaderboard/database.ts | Filters registrar actions by stringifyAccountId(rules.registryId) and uses its chainId for referrer IDs. |
| apps/ensapi/src/cache/referral-edition-snapshots.cache.ts | Uses editionConfig.rules.registryId.chainId for indexing status lookup and error message. |
| .changeset/spotty-peas-run.md | Adds Changeset describing the rename and its impact. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| registryId: makeAccountIdSchema(`${valueLabel}.registryId`), | ||
| rulesUrl: makeUrlSchema(`${valueLabel}.rulesUrl`), | ||
| areAwardsDistributed: z.boolean(), | ||
| }) |
| * const { aggregatedMetrics, referrers, rules } = response.data; | ||
| * console.log(`Edition: ${editionSlug}`); | ||
| * console.log(`Subregistry: ${rules.subregistryId}`); | ||
| * console.log(`Registry: ${rules.registryId}`); |
| console.log(`Edition: ${editionSlug}`); | ||
| console.log(`Subregistry: ${leaderboardPage.rules.subregistryId}`); | ||
| console.log(`Registry: ${leaderboardPage.rules.registryId}`); | ||
| console.log(`Total Referrers: ${leaderboardPage.pageContext.totalRecords}`); |
Renamed
subregistryIdtoregistryIdacross ENS ReferralsTip: Review docs on the ENSNode PR process
Summary
Why
Testing
Notes for Reviewer (Optional)
Pre-Review Checklist (Blocking)