Conversation
🦋 Changeset detectedLatest commit: 1c14d8e The changes in this PR will be included in the next version bump. This PR includes changesets to release 18 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.
|
📝 WalkthroughWalkthroughRemoved the Changes
Sequence Diagram(s)sequenceDiagram
participant Handler as ENSNode API Handler
participant Builder as IndexingStatusBuilder
participant SDK as ensnode-sdk (buildCrossChain...)
participant Projection as RealtimeProjectionCreator
rect rgba(200,200,255,0.5)
Handler->>Builder: getOmnichainIndexingStatusSnapshot()
end
rect rgba(200,255,200,0.5)
Builder-->>Handler: omnichainSnapshot
end
rect rgba(255,200,200,0.5)
Handler->>SDK: buildCrossChainIndexingStatusSnapshotOmnichain(omnichainSnapshot, snapshotTime)
SDK-->>Handler: crossChainSnapshot
end
rect rgba(200,255,200,0.5)
Handler->>Projection: createRealtimeIndexingStatusProjection(crossChainSnapshot, projectedAt)
Projection-->>Handler: realtimeIndexingStatusProjection
end
Handler-->>Client: return Ok(serializedResponse)
Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches
🧪 Generate unit tests (beta)
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 |
There was a problem hiding this comment.
Pull request overview
Cleans up legacy Ponder metadata code by removing the deprecated @ensnode/ponder-metadata package and consolidating ENSIndexer’s Indexing Status modeling around the ENSNode SDK/Local Ponder Client data model.
Changes:
- Removed the legacy
@ensnode/ponder-metadataworkspace package and all remaining monorepo references to it (runtime, release workflows, changeset config). - Moved/standardized cross-chain snapshot construction into
@ensnode/ensnode-sdkviabuildCrossChainIndexingStatusSnapshotOmnichain()and updated ENSIndexer to use it. - Deleted the older ENSIndexer “ponder-metadata” indexing-status implementation paths and tests, keeping the newer indexing-status-builder path.
Reviewed changes
Copilot reviewed 47 out of 48 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| pnpm-lock.yaml | Drops lockfile entries for the removed packages/ponder-metadata workspace package. |
| packages/ponder-metadata/vitest.config.ts | Removes legacy package test config. |
| packages/ponder-metadata/tsup.config.ts | Removes legacy package build config. |
| packages/ponder-metadata/tsconfig.json | Removes legacy package TS config. |
| packages/ponder-metadata/src/types/parse-prometheus-text-format.ts | Removes legacy module type declarations. |
| packages/ponder-metadata/src/types/common.ts | Removes legacy shared types (BlockInfo, ChainIndexingStatus, etc.). |
| packages/ponder-metadata/src/types/api.ts | Removes legacy middleware option/response types. |
| packages/ponder-metadata/src/prometheus-metrics.ts | Removes legacy Prometheus parsing/utilities. |
| packages/ponder-metadata/src/prometheus-metrics.test.ts | Removes legacy Prometheus parsing tests. |
| packages/ponder-metadata/src/middleware.ts | Removes legacy Hono middleware for metadata/status composition. |
| packages/ponder-metadata/src/index.ts | Removes legacy package exports. |
| packages/ponder-metadata/src/db-helpers.ts | Removes legacy DB helper for _ponder_meta. |
| packages/ponder-metadata/package.json | Removes the legacy package manifest (package removal). |
| packages/ponder-metadata/README.md | Removes legacy package documentation. |
| packages/ponder-metadata/LICENSE | Removes legacy package license file (package removal). |
| packages/ponder-metadata/CHANGELOG.md | Removes legacy package changelog. |
| packages/ensnode-sdk/src/indexing-status/cross-chain-indexing-status-snapshot.ts | Adds SDK-level buildCrossChainIndexingStatusSnapshotOmnichain() helper (validated build). |
| packages/ensnode-sdk/src/indexing-status/cross-chain-indexing-status-snapshot.test.ts | Updates tests to use local module imports and exercise the SDK builder. |
| apps/ensindexer/src/lib/ponder-helpers.ts | Removes legacy Ponder-metadata-related helper utilities and simplifies imports. |
| apps/ensindexer/src/lib/ponder-helpers.test.ts | Removes tests for deleted helpers (keeps constrainBlockrange tests). |
| apps/ensindexer/src/lib/indexing-status/ponder-metadata/zod-schemas.ts | Deletes legacy zod schema layer for Ponder metadata ingestion. |
| apps/ensindexer/src/lib/indexing-status/ponder-metadata/validations.ts | Deletes legacy validation helpers tied to PrometheusMetrics. |
| apps/ensindexer/src/lib/indexing-status/ponder-metadata/status.ts | Deletes legacy /status fetcher wrapper. |
| apps/ensindexer/src/lib/indexing-status/ponder-metadata/rpc.ts | Deletes legacy RPC block ref fetching utility. |
| apps/ensindexer/src/lib/indexing-status/ponder-metadata/ponder-metadata.test.ts | Deletes legacy indexing-status builder tests based on ponder-metadata modules. |
| apps/ensindexer/src/lib/indexing-status/ponder-metadata/metrics.ts | Deletes legacy /metrics fetcher wrapper. |
| apps/ensindexer/src/lib/indexing-status/ponder-metadata/index.ts | Deletes legacy barrel export for ponder-metadata indexing-status modules. |
| apps/ensindexer/src/lib/indexing-status/ponder-metadata/config.ts | Deletes legacy ponder.config.ts parsing for per-chain ranges. |
| apps/ensindexer/src/lib/indexing-status/ponder-metadata/chains.ts | Deletes legacy chain snapshot composition logic based on metrics/status/config. |
| apps/ensindexer/src/lib/indexing-status/ponder-metadata/block-refs.ts | Deletes legacy block ref derivation logic. |
| apps/ensindexer/src/lib/indexing-status/build-index-status.ts | Deletes legacy entrypoint for building indexing status via ponder-metadata pathway. |
| apps/ensindexer/src/lib/indexing-status-builder/omnichain-indexing-status-snapshot.ts | Deletes superseded builder implementation (now sourced from SDK). |
| apps/ensindexer/src/lib/indexing-status-builder/omnichain-indexing-status-snapshot.test.ts | Deletes tests for removed omnichain builder implementation. |
| apps/ensindexer/src/lib/indexing-status-builder/index.ts | Adds barrel export to allow import { IndexingStatusBuilder } from "@/lib/indexing-status-builder". |
| apps/ensindexer/src/lib/indexing-status-builder/cross-chain-indexing-status-snapshot.ts | Deletes app-local cross-chain builder (replaced by SDK helper). |
| apps/ensindexer/src/lib/indexing-status-builder/chain-indexing-status-snapshot.ts | Deletes app-local chain snapshot builder implementation. |
| apps/ensindexer/src/lib/indexing-status-builder/chain-indexing-status-snapshot.test.ts | Deletes tests for removed chain snapshot builder. |
| apps/ensindexer/src/lib/indexing-status-builder/chain-indexing-metadata.ts | Deletes removed metadata interface. |
| apps/ensindexer/src/lib/indexing-status-builder/chain-indexing-metadata.mock.ts | Deletes mocks for removed metadata interface. |
| apps/ensindexer/src/lib/indexing-status-builder/backfill-scope.ts | Deletes removed backfill scope type. |
| apps/ensindexer/ponder/src/api/handlers/ensnode-api.ts | Switches to SDK buildCrossChainIndexingStatusSnapshotOmnichain() and new index-status-builder barrel import. |
| apps/ensindexer/package.json | Drops dependency on @ensnode/ponder-metadata. |
| apps/ensadmin/package.json | Drops dependency on @ensnode/ponder-metadata. |
| AGENTS.md | Removes the documentation reference to the deleted packages/ponder-metadata. |
| .github/workflows/release_preview.yml | Removes installing/publishing @ensnode/ponder-metadata in preview release workflow. |
| .github/workflows/release.yml | Removes @ensnode/ponder-metadata from the release package filter. |
| .changeset/config.json | Removes @ensnode/ponder-metadata from changesets’ fixed package list. |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Actionable comments posted: 3
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
packages/ensnode-sdk/src/indexing-status/cross-chain-indexing-status-snapshot.test.ts (1)
25-401: 🧹 Nitpick | 🔵 TrivialAdd one failure-path test for snapshot-time invariant.
The new builder validates invariants, but this suite only checks successful paths. Please add an assertion that invalid
snapshotTimethrows, so this contract is protected.Suggested test case
describe("buildCrossChainIndexingStatusSnapshotOmnichain", () => { + it("throws when snapshotTime is below the highest known block timestamp", () => { + const chains = new Map([ + [ + 1, + { + chainStatus: ChainIndexingStatusIds.Completed, + config: { + rangeType: RangeTypeIds.Bounded, + startBlock: earliestBlockRef, + endBlock: latestBlockRef, + }, + latestIndexedBlock: latestBlockRef, + } satisfies ChainIndexingStatusSnapshotCompleted, + ], + ]); + + const omnichainSnapshot = { + omnichainStatus: OmnichainIndexingStatusIds.Completed, + chains, + omnichainIndexingCursor: latestBlockRef.timestamp, + } satisfies OmnichainIndexingStatusSnapshotCompleted; + + expect(() => + buildCrossChainIndexingStatusSnapshotOmnichain( + omnichainSnapshot, + earliestBlockRef.timestamp, + ), + ).toThrow("Invalid CrossChainIndexingStatusSnapshot"); + });🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@packages/ensnode-sdk/src/indexing-status/cross-chain-indexing-status-snapshot.test.ts` around lines 25 - 401, Add a new test in the describe("buildCrossChainIndexingStatusSnapshotOmnichain") block that verifies buildCrossChainIndexingStatusSnapshotOmnichain throws when snapshotTime violates the builder's invariant (e.g., pass an omnichainSnapshot where a chain has endBlock/latestKnownBlock with timestamp > snapshotTime and assert that calling buildCrossChainIndexingStatusSnapshotOmnichain(omnichainSnapshot, invalidSnapshotTime) throws). Use the existing pattern for arranging chains/omnichainSnapshot (reuse ChainIndexingStatusSnapshotBackfill/Completed/Following/Unstarted shapes) and assert thrown error with expect(...).toThrow() to protect the snapshot-time contract.
🤖 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/purple-rings-swim.md:
- Line 6: The changeset message "Stopped having dependency on
`@ensnode/ponder-metadata` package." is awkwardly phrased—update that line to a
clearer, concise phrasing such as "Removed dependency on
`@ensnode/ponder-metadata` package." or "No longer depends on
`@ensnode/ponder-metadata` package." so the intent reads naturally in the
changelog; locate and replace the exact sentence in
.changeset/purple-rings-swim.md.
In `@apps/ensindexer/ponder/src/api/handlers/ensnode-api.ts`:
- Around line 57-60: The call to
buildCrossChainIndexingStatusSnapshotOmnichain(omnichainSnapshot, snapshotTime)
can throw due to validation (snapshotTime captured before async retrieval) and
currently escapes the handler; wrap that call in a try/catch inside the handler
in ensnode-api.ts, catch any thrown error, create/serialize an
IndexingStatusResponseError (preserving the API response shape used elsewhere)
with a clear message and error details, and return/respond with that error
object instead of allowing an unstructured 500. Ensure you reference
buildCrossChainIndexingStatusSnapshotOmnichain, omnichainSnapshot, snapshotTime,
and IndexingStatusResponseError when locating where to add the try/catch.
In
`@packages/ensnode-sdk/src/indexing-status/cross-chain-indexing-status-snapshot.ts`:
- Around line 121-127: Remove the redundant JSDoc `@returns` line from the JSDoc
block that documents buildCrossChainIndexingStatusSnapshot (the "Build a
Cross-Chain Indexing Status Snapshot..." comment) so the summary isn't restated;
leave the param tags intact and keep only a concise JSDoc summary without the
duplicate `@returns` entry.
---
Outside diff comments:
In
`@packages/ensnode-sdk/src/indexing-status/cross-chain-indexing-status-snapshot.test.ts`:
- Around line 25-401: Add a new test in the
describe("buildCrossChainIndexingStatusSnapshotOmnichain") block that verifies
buildCrossChainIndexingStatusSnapshotOmnichain throws when snapshotTime violates
the builder's invariant (e.g., pass an omnichainSnapshot where a chain has
endBlock/latestKnownBlock with timestamp > snapshotTime and assert that calling
buildCrossChainIndexingStatusSnapshotOmnichain(omnichainSnapshot,
invalidSnapshotTime) throws). Use the existing pattern for arranging
chains/omnichainSnapshot (reuse
ChainIndexingStatusSnapshotBackfill/Completed/Following/Unstarted shapes) and
assert thrown error with expect(...).toThrow() to protect the snapshot-time
contract.
ℹ️ Review info
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (47)
.changeset/config.json.changeset/purple-rings-swim.md.github/workflows/release.yml.github/workflows/release_preview.ymlAGENTS.mdapps/ensadmin/package.jsonapps/ensindexer/package.jsonapps/ensindexer/ponder/src/api/handlers/ensnode-api.tsapps/ensindexer/src/lib/indexing-status-builder/backfill-scope.tsapps/ensindexer/src/lib/indexing-status-builder/chain-indexing-metadata.mock.tsapps/ensindexer/src/lib/indexing-status-builder/chain-indexing-metadata.tsapps/ensindexer/src/lib/indexing-status-builder/chain-indexing-status-snapshot.test.tsapps/ensindexer/src/lib/indexing-status-builder/chain-indexing-status-snapshot.tsapps/ensindexer/src/lib/indexing-status-builder/cross-chain-indexing-status-snapshot.tsapps/ensindexer/src/lib/indexing-status-builder/index.tsapps/ensindexer/src/lib/indexing-status-builder/omnichain-indexing-status-snapshot.test.tsapps/ensindexer/src/lib/indexing-status-builder/omnichain-indexing-status-snapshot.tsapps/ensindexer/src/lib/indexing-status/build-index-status.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/block-refs.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/chains.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/config.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/index.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/metrics.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/ponder-metadata.test.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/rpc.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/status.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/validations.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/zod-schemas.tsapps/ensindexer/src/lib/ponder-helpers.test.tsapps/ensindexer/src/lib/ponder-helpers.tspackages/ensnode-sdk/src/indexing-status/cross-chain-indexing-status-snapshot.test.tspackages/ensnode-sdk/src/indexing-status/cross-chain-indexing-status-snapshot.tspackages/ponder-metadata/CHANGELOG.mdpackages/ponder-metadata/LICENSEpackages/ponder-metadata/README.mdpackages/ponder-metadata/package.jsonpackages/ponder-metadata/src/db-helpers.tspackages/ponder-metadata/src/index.tspackages/ponder-metadata/src/middleware.tspackages/ponder-metadata/src/prometheus-metrics.test.tspackages/ponder-metadata/src/prometheus-metrics.tspackages/ponder-metadata/src/types/api.tspackages/ponder-metadata/src/types/common.tspackages/ponder-metadata/src/types/parse-prometheus-text-format.tspackages/ponder-metadata/tsconfig.jsonpackages/ponder-metadata/tsup.config.tspackages/ponder-metadata/vitest.config.ts
💤 Files with no reviewable changes (40)
- AGENTS.md
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/rpc.ts
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/validations.ts
- apps/ensindexer/package.json
- apps/ensindexer/src/lib/indexing-status-builder/omnichain-indexing-status-snapshot.ts
- packages/ponder-metadata/src/types/common.ts
- packages/ponder-metadata/README.md
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/index.ts
- packages/ponder-metadata/LICENSE
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/chains.ts
- apps/ensindexer/src/lib/indexing-status-builder/backfill-scope.ts
- apps/ensindexer/src/lib/indexing-status/build-index-status.ts
- apps/ensindexer/src/lib/indexing-status-builder/omnichain-indexing-status-snapshot.test.ts
- .github/workflows/release.yml
- apps/ensindexer/src/lib/indexing-status-builder/chain-indexing-status-snapshot.ts
- apps/ensindexer/src/lib/indexing-status-builder/cross-chain-indexing-status-snapshot.ts
- apps/ensindexer/src/lib/indexing-status-builder/chain-indexing-metadata.ts
- packages/ponder-metadata/src/prometheus-metrics.test.ts
- apps/ensadmin/package.json
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/status.ts
- packages/ponder-metadata/CHANGELOG.md
- packages/ponder-metadata/src/index.ts
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/metrics.ts
- .github/workflows/release_preview.yml
- packages/ponder-metadata/src/types/parse-prometheus-text-format.ts
- packages/ponder-metadata/src/middleware.ts
- .changeset/config.json
- packages/ponder-metadata/src/types/api.ts
- packages/ponder-metadata/src/db-helpers.ts
- packages/ponder-metadata/vitest.config.ts
- packages/ponder-metadata/tsup.config.ts
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/config.ts
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/ponder-metadata.test.ts
- packages/ponder-metadata/tsconfig.json
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/zod-schemas.ts
- apps/ensindexer/src/lib/indexing-status-builder/chain-indexing-status-snapshot.test.ts
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/block-refs.ts
- packages/ponder-metadata/package.json
- apps/ensindexer/src/lib/indexing-status-builder/chain-indexing-metadata.mock.ts
- packages/ponder-metadata/src/prometheus-metrics.ts
packages/ensnode-sdk/src/indexing-status/cross-chain-indexing-status-snapshot.ts
Show resolved
Hide resolved
Greptile SummaryThis PR removes the legacy
The PR achieves its goal of zero API changes while cleaning up technical debt. All removed code is verified to be unused, and the functionality is properly migrated with tests. Confidence Score: 5/5
Important Files Changed
Last reviewed commit: 1c14d8e |
b8c2629 to
db39c72
Compare
…CrossChainIndexingStatusSnapshotOmnichain` from ENSNode SDK This change makes room for code cleanup at `@/lib/indexing-status` path.
Remove all files matching `@/lib/indexing-status*` path. The removed module has been replaced with `@/lib/indexing-status-builder"` one.
These modules were used by the LocalPonderClient implementation 1.0, and all of these modules became obsolete when PR 1675 got merged.
Multiple functions and types in this file were obsolete.
db39c72 to
1c14d8e
Compare
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 47 out of 48 changed files in this pull request and generated no new comments.
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
♻️ Duplicate comments (1)
packages/ensnode-sdk/src/indexing-status/cross-chain-indexing-status-snapshot.ts (1)
121-129: 🧹 Nitpick | 🔵 TrivialRemove redundant
@returnsJSDoc text.The
@returnsline restates the summary and should be removed for consistency with coding guidelines.Proposed cleanup
/** * Build a Cross-Chain Indexing Status Snapshot based on the omnichain indexing status snapshot. * * `@param` omnichainSnapshot - The omnichain indexing status snapshot. * `@param` snapshotTime - The timestamp when the cross-chain indexing status snapshot was generated. - * `@returns` The cross-chain indexing status snapshot. * `@throws` if the generated snapshot does not satisfy the invariants defined * in {`@link` CrossChainIndexingStatusSnapshotOmnichain} */As per coding guidelines: "Do not add JSDoc
@returnstags that merely restate the method summary; remove redundancy during PR review."
,🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@packages/ensnode-sdk/src/indexing-status/cross-chain-indexing-status-snapshot.ts` around lines 121 - 129, The JSDoc for the function that builds a cross-chain indexing status snapshot contains a redundant "@returns" line that merely restates the summary; remove the "@returns" tag from the JSDoc above the buildCrossChainIndexingStatusSnapshot (the function that generates a CrossChainIndexingStatusSnapshot from an omnichain snapshot) so the documentation only has the summary and the `@throws/`@param tags (keep references to CrossChainIndexingStatusSnapshotOmnichain and snapshotTime as needed).
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Duplicate comments:
In
`@packages/ensnode-sdk/src/indexing-status/cross-chain-indexing-status-snapshot.ts`:
- Around line 121-129: The JSDoc for the function that builds a cross-chain
indexing status snapshot contains a redundant "@returns" line that merely
restates the summary; remove the "@returns" tag from the JSDoc above the
buildCrossChainIndexingStatusSnapshot (the function that generates a
CrossChainIndexingStatusSnapshot from an omnichain snapshot) so the
documentation only has the summary and the `@throws/`@param tags (keep references
to CrossChainIndexingStatusSnapshotOmnichain and snapshotTime as needed).
ℹ️ Review info
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (47)
.changeset/config.json.changeset/purple-rings-swim.md.github/workflows/release.yml.github/workflows/release_preview.ymlAGENTS.mdapps/ensadmin/package.jsonapps/ensindexer/package.jsonapps/ensindexer/ponder/src/api/handlers/ensnode-api.tsapps/ensindexer/src/lib/indexing-status-builder/backfill-scope.tsapps/ensindexer/src/lib/indexing-status-builder/chain-indexing-metadata.mock.tsapps/ensindexer/src/lib/indexing-status-builder/chain-indexing-metadata.tsapps/ensindexer/src/lib/indexing-status-builder/chain-indexing-status-snapshot.test.tsapps/ensindexer/src/lib/indexing-status-builder/chain-indexing-status-snapshot.tsapps/ensindexer/src/lib/indexing-status-builder/cross-chain-indexing-status-snapshot.tsapps/ensindexer/src/lib/indexing-status-builder/index.tsapps/ensindexer/src/lib/indexing-status-builder/omnichain-indexing-status-snapshot.test.tsapps/ensindexer/src/lib/indexing-status-builder/omnichain-indexing-status-snapshot.tsapps/ensindexer/src/lib/indexing-status/build-index-status.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/block-refs.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/chains.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/config.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/index.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/metrics.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/ponder-metadata.test.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/rpc.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/status.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/validations.tsapps/ensindexer/src/lib/indexing-status/ponder-metadata/zod-schemas.tsapps/ensindexer/src/lib/ponder-helpers.test.tsapps/ensindexer/src/lib/ponder-helpers.tspackages/ensnode-sdk/src/indexing-status/cross-chain-indexing-status-snapshot.test.tspackages/ensnode-sdk/src/indexing-status/cross-chain-indexing-status-snapshot.tspackages/ponder-metadata/CHANGELOG.mdpackages/ponder-metadata/LICENSEpackages/ponder-metadata/README.mdpackages/ponder-metadata/package.jsonpackages/ponder-metadata/src/db-helpers.tspackages/ponder-metadata/src/index.tspackages/ponder-metadata/src/middleware.tspackages/ponder-metadata/src/prometheus-metrics.test.tspackages/ponder-metadata/src/prometheus-metrics.tspackages/ponder-metadata/src/types/api.tspackages/ponder-metadata/src/types/common.tspackages/ponder-metadata/src/types/parse-prometheus-text-format.tspackages/ponder-metadata/tsconfig.jsonpackages/ponder-metadata/tsup.config.tspackages/ponder-metadata/vitest.config.ts
💤 Files with no reviewable changes (40)
- packages/ponder-metadata/tsup.config.ts
- apps/ensindexer/src/lib/indexing-status-builder/cross-chain-indexing-status-snapshot.ts
- apps/ensindexer/src/lib/indexing-status-builder/chain-indexing-status-snapshot.ts
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/ponder-metadata.test.ts
- packages/ponder-metadata/LICENSE
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/status.ts
- .changeset/config.json
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/rpc.ts
- packages/ponder-metadata/src/types/common.ts
- apps/ensindexer/src/lib/indexing-status-builder/omnichain-indexing-status-snapshot.test.ts
- apps/ensindexer/src/lib/indexing-status/build-index-status.ts
- .github/workflows/release_preview.yml
- packages/ponder-metadata/src/db-helpers.ts
- apps/ensindexer/package.json
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/metrics.ts
- packages/ponder-metadata/README.md
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/block-refs.ts
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/config.ts
- packages/ponder-metadata/package.json
- AGENTS.md
- apps/ensindexer/src/lib/indexing-status-builder/chain-indexing-metadata.ts
- packages/ponder-metadata/src/types/api.ts
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/zod-schemas.ts
- apps/ensindexer/src/lib/indexing-status-builder/chain-indexing-metadata.mock.ts
- packages/ponder-metadata/src/types/parse-prometheus-text-format.ts
- .github/workflows/release.yml
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/chains.ts
- packages/ponder-metadata/vitest.config.ts
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/index.ts
- apps/ensadmin/package.json
- apps/ensindexer/src/lib/indexing-status/ponder-metadata/validations.ts
- packages/ponder-metadata/src/prometheus-metrics.test.ts
- apps/ensindexer/src/lib/indexing-status-builder/chain-indexing-status-snapshot.test.ts
- apps/ensindexer/src/lib/indexing-status-builder/omnichain-indexing-status-snapshot.ts
- packages/ponder-metadata/src/prometheus-metrics.ts
- apps/ensindexer/src/lib/indexing-status-builder/backfill-scope.ts
- packages/ponder-metadata/tsconfig.json
- packages/ponder-metadata/src/index.ts
- packages/ponder-metadata/src/middleware.ts
- packages/ponder-metadata/CHANGELOG.md
tk-o
left a comment
There was a problem hiding this comment.
Self-review completed
| const omnichainSnapshot = await indexingStatusBuilder.getOmnichainIndexingStatusSnapshot(); | ||
|
|
||
| const crossChainSnapshot = buildCrossChainIndexingStatusSnapshotOmnichain( | ||
| omnichainSnapshot, | ||
| snapshotTime, | ||
| ); | ||
|
|
||
| const projectedAt = getUnixTime(new Date()); | ||
| const realtimeProjection = createRealtimeIndexingStatusProjection( | ||
| crossChainSnapshot, | ||
| projectedAt, | ||
| ); | ||
|
|
||
| return c.json( | ||
| serializeIndexingStatusResponse({ | ||
| responseCode: IndexingStatusResponseCodes.Ok, | ||
| realtimeProjection, | ||
| } satisfies IndexingStatusResponseOk), | ||
| ); |
There was a problem hiding this comment.
This is a more concise form for the response handler, that keeps error response generation in tact.
| * @throws if the generated snapshot does not satisfy the invariants defined | ||
| * in {@link CrossChainIndexingStatusSnapshotOmnichain} | ||
| */ | ||
| export function buildCrossChainIndexingStatusSnapshotOmnichain( |
There was a problem hiding this comment.
Replaces createCrossChainIndexingStatusSnapshotOmnichain function from ENSIndexer (see @/lib/indexing-status/build-index-status).
|
@greptile review |
lightwalker-eth
left a comment
There was a problem hiding this comment.
@tk-o Awesome to see almost 4k lines removed in this PR. Nice 👍
Lite PR
Tip: Review docs on the ENSNode PR process
Summary
@ensnode/ponder-metadatapackage across runtime logic, CI scripts, and docs.@ensnode/ponder-metadatapackage.Why
@ensnode/ponder-metadatapackage has been present in ENSNode codebase for a long time, but it has now been fully replaced with more mature APIs.Testing
Notes for Reviewer (Optional)
Pre-Review Checklist (Blocking)
Resolves #908