Skip to content

Conversation

@tk-o
Copy link
Contributor

@tk-o tk-o commented May 30, 2025

This PR includes refactorings around ENSIndexerConfig that allow dropping unnecessary imports and replace them with new derived configuration parameters: ensDeployment.

The PR also moves the requiredDatasources plugin configuration back to individual plugins and replace manual definitions (such as PLUGIN_REQUIRED_DATASOURCES) with plugin-driven ones.

Suggested review order:

  1. apps/ensindexer/ponder.config.ts: move all plugins list into its own file to avoid circular dependencies and enable creating getPlugin(pluginName: PluginName) helper function.
  2. apps/ensindexer/src/plugins/index.ts: it now includes the list of all plugins, and also helper functions working on that list
  3. apps/ensindexer/src/plugins/**/*: all plugins read the ensDeployment directly from the appConfig object, and also define requiredDatasources directly. What also changed is that static config getter was replaced with a config factory in order to break circular dependencies between plugin definitions and @/config.
  4. apps/ensindexer/src/lib/lib-config.ts: ensDeployment includes some ABIs, which I figured will be best not to be shown due to their length.
  5. apps/ensindexer/src/lib/plugin-helpers.ts: include new getters for datasources and indexed chain IDs
  6. apps/ensindexer/src/config/types.ts: including ensDeployment config param
  7. apps/ensindexer/src/config/validations.ts: use getPlugins helper to get information about a given plugin. Also, make validation input types more precise.
  8. apps/ensindexer/src/config/config.schema.ts: moved all derive functionality into its own file
  9. apps/ensindexer/src/config/derived-params.ts: derive functionality for isSubgraphCompatible (moved), and ensDeployment (newly added)

Resolves:

@changeset-bot
Copy link

changeset-bot bot commented May 30, 2025

🦋 Changeset detected

Latest commit: d13baf8

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

This PR includes changesets to release 10 packages
Name Type
ensindexer Minor
ensadmin Minor
ensrainbow Minor
@ensnode/ens-deployments Minor
@ensnode/ensrainbow-sdk Minor
@ensnode/ponder-metadata Minor
@ensnode/ensnode-schema Minor
@ensnode/ponder-subgraph Minor
@ensnode/ensnode-sdk Minor
@ensnode/shared-configs Minor

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

@vercel
Copy link

vercel bot commented May 30, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
admin.ensnode.io ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 3, 2025 7:00pm
ensnode.io ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 3, 2025 7:00pm
ensrainbow.io ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 3, 2025 7:00pm

Comment on lines -5 to -10
import type { MergedTypes } from "@/lib/plugin-helpers";

import basenamesPlugin from "@/plugins/basenames/basenames.plugin";
import lineaNamesPlugin from "@/plugins/lineanames/lineanames.plugin";
import subgraphPlugin from "@/plugins/subgraph/subgraph.plugin";
import threednsPlugin from "@/plugins/threedns/threedns.plugin";
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This refactor enabled creation of getPlugin(pluginName: PluginName) helper, which will be used in validation logic.

// combine each plugins' config into a MergedPonderConfig
const ponderConfig = activePlugins.reduce(
(memo, plugin) => mergePonderConfigs(memo, plugin.config),
(memo, plugin) => mergePonderConfigs(memo, plugin.createPluginConfig(config)),
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Plugin config required using factory function in order to calculate the PluginConfig type and pass it as a param in to ENSIndexerPlugin type.

Comment on lines -157 to -179
const derive_isSubgraphCompatible = <
CONFIG extends Pick<
ENSIndexerConfig,
"plugins" | "healReverseAddresses" | "indexAdditionalResolverRecords"
>,
>(
config: CONFIG,
): CONFIG & { isSubgraphCompatible: boolean } => {
// 1. only the subgraph plugin is active
const onlySubgraphPluginActivated =
config.plugins.length === 1 && config.plugins[0] === PluginName.Subgraph;

// 2. healReverseAddresses = false
// 3. indexAdditionalResolverRecords = false
const indexingBehaviorIsSubgraphCompatible =
!config.healReverseAddresses && !config.indexAdditionalResolverRecords;

return {
...config,
isSubgraphCompatible: onlySubgraphPluginActivated && indexingBehaviorIsSubgraphCompatible,
};
};

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Moved into a separate derived-params.ts file.

),
} as ENSIndexerConfig,
null,
(key: string, value: unknown) => (key === "abi" ? `(truncated ABI output)` : value),
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Quite handy to avoid printing very long ABIs into stdout for ENSIndexer container.

}

// Helper type to merge multiple types into one
export type MergedTypes<T> = (T extends any ? (x: T) => void : never) extends (x: infer R) => void
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Didn't want to call import config from "@/config"; while importing MergedTypes, so moved MergedTypes where it's needed (a private helper type inside @/plugins)

...args
}: ENSIndexerPluginHandlerArgs<PLUGIN_NAME> & {
handlers: Promise<{ default: ENSIndexerPluginHandler<PLUGIN_NAME> }>[];
handlers: () => Promise<{ default: ENSIndexerPluginHandler<PLUGIN_NAME> }>[];
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This change enabled lazy evaluation of dynamic imports defined on each plugin, and let resolve errors while running unit test, such as:
image

*/

export const getENSDeployment = (ensDeploymentChain: keyof typeof ENSDeployments) =>
export const getENSDeployment = (ensDeploymentChain: ENSDeploymentChain) =>
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Same type, just called directly.

@@ -1,4 +1,3 @@
import { zeroAddress } from "viem";
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Dropping unused import.

import lineaNamesPlugin from "@/plugins/lineanames/lineanames.plugin";
import subgraphPlugin from "@/plugins/subgraph/subgraph.plugin";
import threednsPlugin from "@/plugins/threedns/threedns.plugin";
import { ALL_PLUGINS, type AllPluginsConfig } from "@/plugins";
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Decoupling plugins list from ponder.config.ts file is a step towards having plugin configuration managed through ENSIndexerConfig builder.

Copy link
Member

@lightwalker-eth lightwalker-eth left a comment

Choose a reason for hiding this comment

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

@tk-o Super cool upgrades here. Nice work 🚀

// combine each plugins' config into a MergedPonderConfig
const ponderConfig = activePlugins.reduce(
(memo, plugin) => mergePonderConfigs(memo, plugin.config),
(memo, plugin) => mergePonderConfigs(memo, plugin.createPluginConfig(config)),
Copy link
Member

Choose a reason for hiding this comment

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

Noting here how I see both "ponderConfig" and "pluginConfig" language being mixed together.

Should we align this? Should createPluginConfig be renamed to createPonderConfig?

Advice appreciated 👍

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I've had mixed feelings about all of the config-related values being passed around next to each other.

We have:

  • application config of ENSIndexerConfig type, which is often referred to just as config
  • plugin config that is actually a result of createConfig function of ponder

I think renaming createPluginConfig into createPonderConfig is a good move 👍

[PluginName.Lineanames]: [DatasourceName.Lineanames],
[PluginName.ThreeDNS]: [DatasourceName.ThreeDNSOptimism, DatasourceName.ThreeDNSBase],
};
export function getPlugin(pluginName: PluginName) {
Copy link
Member

Choose a reason for hiding this comment

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

Cool utility function 👍 Could we please explicitly identify the type this function returns, or is that tricky?

If tricky, no need to worry about this comment.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's tricky, as the list of ALL_PLUGINS is marked as const type, which turns it into a literal.

* @param pluginNames A list of selected plugin names.
* @returns A list of unique datasource names.
*/
export function getRequiredDatasourceNames(pluginNames: PluginName[]): DatasourceName[] {
Copy link
Member

Choose a reason for hiding this comment

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

Nice 👍

const activePluginNames = allPluginNames.filter((pluginName) =>
config.plugins.includes(pluginName),
);
const ensDeployment = getENSDeployment(config.ensDeploymentChain);
Copy link
Member

Choose a reason for hiding this comment

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

I'm surprised this works ok? As I understand invariant_requiredDatasources is called before config is finished being built?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This works OK as invariant functions, such as invariant_requiredDatasources, are applied after the input object was already parsed into correct individual types.

Please note how Pick type is applied onto the ENSIndexerConfig type. This way, we can ensure the invariant function gets all data it needs from a slice of the whole config. The parsing process ended, but we still apply invariants, and add derived config values to the final config object.

I've build a small demo to illustrate that here:
image


if (globalBlockrange.startBlock !== undefined || globalBlockrange.endBlock !== undefined) {
const deployment = getENSDeployment(config.ensDeploymentChain);
const indexedChainIds = uniq(
Copy link
Member

Choose a reason for hiding this comment

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

I think I saw another helper function we've built now for getting the set of unique chainIds being indexed? Seems nice to reuse it here if possible?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think you refer to getIndexedChainIds function was added in this very PR inside plugin-helpers.ts. Will apply it here.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

getIndexedChainIds has implicit dependency on config value from import config from "@/config".

I've just discovered it might be tricky to replace reading from import config from "@/config"; and keep typescript inferred types working. It all comes back to ponder config expecting literal values.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

*
* See {@link ENSDeployment} for the deployment type.
*/
ensDeployment: ENSDeploymentGlobalType;
Copy link
Member

Choose a reason for hiding this comment

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

We need to document / explain what this ENSDeploymentGlobalType is here. It's not intuitive why this type is being used or what it represents.

I'm not 100% sure I'm familiar with all the background here, but what about the following?

  1. Change the definition of ENSDeploymentGlobalType from typeof ENSDeployments.mainnet to something like Required<ENSDeployment>.
  2. Rename ENSDeploymentGlobalType to something more self-describing, such as ENSDeploymentCommonType.
  3. Refine the docs for ENSDeploymentGlobalType.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The moment we change type for ENSDeploymentCommonType from:

typeof ENSDeployments.mainnet

to

Required<ENSDeployment>

whole type inference for ponder handlers falls apart.

Type error logs
pnpm -r --parallel typecheck

Scope: 12 of 13 workspace projects
apps/ensindexer typecheck$ tsc --noEmit
apps/ensadmin typecheck$ tsc --noEmit
apps/ensrainbow typecheck$ tsc --noEmit
packages/ensrainbow-sdk typecheck$ tsc --noEmit
packages/ensnode-sdk typecheck$ tsc --noEmit
packages/ponder-metadata typecheck$ tsc --noEmit
packages/ponder-subgraph typecheck$ tsc --noEmit
packages/ensrainbow-sdk typecheck: Done
packages/ensnode-sdk typecheck: Done
apps/ensrainbow typecheck: Done
packages/ponder-subgraph typecheck: Done
packages/ponder-metadata typecheck: Done
apps/ensadmin typecheck: Done
apps/ensindexer typecheck: src/handlers/NameWrapper.ts(260,11): error TS18048: 'event.block' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/NameWrapper.ts(261,11): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/NameWrapper.ts(283,13): error TS18048: 'event.block' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/NameWrapper.ts(284,13): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Registrar.ts(139,27): error TS18048: 'event.block' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Registry.ts(66,20): error TS18048: 'event.block' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Registry.ts(116,32): error TS18048: 'event.transaction' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Registry.ts(167,22): error TS18048: 'event.transaction' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Registry.ts(195,32): error TS18048: 'event.transaction' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Registry.ts(255,53): error TS18048: 'event.block' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(60,54): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(64,14): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(96,54): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(100,14): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(131,54): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(135,14): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(149,16): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(165,54): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(171,14): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(190,54): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(196,14): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(221,54): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(225,14): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(295,54): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(299,14): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(319,54): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(323,14): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(348,54): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(353,14): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(375,54): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(386,14): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(445,54): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(449,14): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(540,54): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/Resolver.ts(544,14): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/ThreeDNSToken.ts(33,3): error TS2322: Type 'unknown' is not assignable to type 'string'.
apps/ensindexer typecheck: src/handlers/ThreeDNSToken.ts(98,18): error TS18048: 'event.block' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/ThreeDNSToken.ts(205,40): error TS18048: 'event.transaction' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/ThreeDNSToken.ts(212,40): error TS18048: 'event.transaction' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/ThreeDNSToken.ts(219,40): error TS18048: 'event.transaction' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/ThreeDNSToken.ts(234,16): error TS18048: 'event.block' is possibly 'undefined'.
apps/ensindexer typecheck: src/handlers/ThreeDNSToken.ts(248,23): error TS18048: 'event.block' is possibly 'undefined'.
apps/ensindexer typecheck: src/lib/db-helpers.ts(32,30): error TS18048: 'event.block' is possibly 'undefined'.
apps/ensindexer typecheck: src/lib/db-helpers.ts(32,50): error TS18048: 'event.log' is possibly 'undefined'.
apps/ensindexer typecheck: src/lib/db-helpers.ts(33,18): error TS18048: 'event.block' is possibly 'undefined'.
apps/ensindexer typecheck: src/lib/db-helpers.ts(34,20): error TS18048: 'event.transaction' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/basenames/basenames.plugin.ts(35,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/basenames/basenames.plugin.ts(36,14): error TS18048: 'contracts.Registry' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/basenames/basenames.plugin.ts(39,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/basenames/basenames.plugin.ts(40,14): error TS18048: 'contracts.BaseRegistrar' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/basenames/basenames.plugin.ts(43,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/basenames/basenames.plugin.ts(44,14): error TS18048: 'contracts.EARegistrarController' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/basenames/basenames.plugin.ts(47,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/basenames/basenames.plugin.ts(48,14): error TS18048: 'contracts.RegistrarController' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/basenames/basenames.plugin.ts(51,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/basenames/basenames.plugin.ts(52,14): error TS18048: 'contracts.Resolver' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(34,13): error TS2345: Argument of type '"basenames/BaseRegistrar:NameRegisteredWithRecord"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(37,16): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(37,43): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(37,85): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(41,13): error TS2345: Argument of type '"basenames/BaseRegistrar:NameRegistered"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(44,16): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(44,43): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(44,85): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(48,13): error TS2345: Argument of type '"basenames/BaseRegistrar:NameRenewed"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(51,16): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(51,43): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(51,85): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(55,13): error TS2345: Argument of type '"basenames/BaseRegistrar:Transfer"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(58,16): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(58,43): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(58,85): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(62,13): error TS2345: Argument of type '"basenames/EARegistrarController:NameRegistered"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(65,16): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(65,43): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(69,13): error TS2345: Argument of type '"basenames/RegistrarController:NameRegistered"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(72,16): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(72,43): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(76,13): error TS2345: Argument of type '"basenames/RegistrarController:NameRenewed"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(79,16): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registrar.ts(79,43): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registry.ts(16,13): error TS2345: Argument of type '"basenames/Registry:NewOwner"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registry.ts(17,13): error TS2345: Argument of type '"basenames/Registry:NewResolver"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registry.ts(18,13): error TS2345: Argument of type '"basenames/Registry:NewTTL"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/basenames/handlers/Registry.ts(19,13): error TS2345: Argument of type '"basenames/Registry:Transfer"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/NameWrapper.ts(20,13): error TS2345: Argument of type '"lineanames/NameWrapper:NameWrapped"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/NameWrapper.ts(21,13): error TS2345: Argument of type '"lineanames/NameWrapper:NameUnwrapped"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/NameWrapper.ts(22,13): error TS2345: Argument of type '"lineanames/NameWrapper:FusesSet"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/NameWrapper.ts(23,13): error TS2345: Argument of type '"lineanames/NameWrapper:ExpiryExtended"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/NameWrapper.ts(24,13): error TS2345: Argument of type '"lineanames/NameWrapper:TransferSingle"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/NameWrapper.ts(25,13): error TS2345: Argument of type '"lineanames/NameWrapper:TransferBatch"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(33,13): error TS2345: Argument of type '"lineanames/BaseRegistrar:NameRegistered"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(36,16): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(36,43): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(36,85): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(40,13): error TS2345: Argument of type '"lineanames/BaseRegistrar:NameRenewed"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(43,16): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(43,43): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(43,85): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(47,13): error TS2345: Argument of type '"lineanames/BaseRegistrar:Transfer"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(51,9): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(52,26): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(52,68): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(57,13): error TS2345: Argument of type '"lineanames/EthRegistrarController:OwnerNameRegistered"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(61,9): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(63,20): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(71,13): error TS2345: Argument of type '"lineanames/EthRegistrarController:PohNameRegistered"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(75,9): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(77,20): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(85,13): error TS2345: Argument of type '"lineanames/EthRegistrarController:NameRegistered"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(89,9): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(91,20): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(93,23): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(93,45): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registrar.ts(99,13): error TS2345: Argument of type '"lineanames/EthRegistrarController:NameRenewed"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registry.ts(16,13): error TS2345: Argument of type '"lineanames/Registry:NewOwner"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registry.ts(17,13): error TS2345: Argument of type '"lineanames/Registry:NewResolver"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registry.ts(18,13): error TS2345: Argument of type '"lineanames/Registry:NewTTL"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/handlers/Registry.ts(19,13): error TS2345: Argument of type '"lineanames/Registry:Transfer"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/lineanames/lineanames.plugin.ts(36,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/lineanames/lineanames.plugin.ts(37,14): error TS18048: 'contracts.Registry' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/lineanames/lineanames.plugin.ts(40,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/lineanames/lineanames.plugin.ts(41,14): error TS18048: 'contracts.BaseRegistrar' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/lineanames/lineanames.plugin.ts(44,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/lineanames/lineanames.plugin.ts(45,14): error TS18048: 'contracts.EthRegistrarController' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/lineanames/lineanames.plugin.ts(48,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/lineanames/lineanames.plugin.ts(49,14): error TS18048: 'contracts.NameWrapper' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/lineanames/lineanames.plugin.ts(52,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/lineanames/lineanames.plugin.ts(53,14): error TS18048: 'contracts.Resolver' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(32,13): error TS2345: Argument of type '"Resolver:AddrChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(33,13): error TS2345: Argument of type '"Resolver:AddressChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(34,13): error TS2345: Argument of type '"Resolver:NameChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(35,13): error TS2345: Argument of type '"Resolver:ABIChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(36,13): error TS2345: Argument of type '"Resolver:PubkeyChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(38,5): error TS2345: Argument of type '"Resolver:TextChanged(bytes32 indexed node, string indexed indexedKey, string key)"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(42,5): error TS2345: Argument of type '"Resolver:TextChanged(bytes32 indexed node, string indexed indexedKey, string key, string value)"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(45,13): error TS2345: Argument of type '"Resolver:ContenthashChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(46,13): error TS2345: Argument of type '"Resolver:InterfaceChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(47,13): error TS2345: Argument of type '"Resolver:AuthorisationChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(48,13): error TS2345: Argument of type '"Resolver:VersionChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(52,5): error TS2345: Argument of type '"Resolver:DNSRecordChanged(bytes32 indexed node, bytes name, uint16 resource, bytes record)"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(59,5): error TS2345: Argument of type '"Resolver:DNSRecordChanged(bytes32 indexed node, bytes name, uint16 resource, uint32 ttl, bytes record)"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(62,13): error TS2345: Argument of type '"Resolver:DNSRecordDeleted"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(63,13): error TS2345: Argument of type '"Resolver:DNSZonehashChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/shared/Resolver.ts(64,13): error TS2345: Argument of type '"Resolver:ZoneCreated"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/NameWrapper.ts(20,13): error TS2345: Argument of type '"subgraph/NameWrapper:NameWrapped"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/NameWrapper.ts(21,13): error TS2345: Argument of type '"subgraph/NameWrapper:NameUnwrapped"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/NameWrapper.ts(22,13): error TS2345: Argument of type '"subgraph/NameWrapper:FusesSet"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/NameWrapper.ts(23,13): error TS2345: Argument of type '"subgraph/NameWrapper:ExpiryExtended"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/NameWrapper.ts(24,13): error TS2345: Argument of type '"subgraph/NameWrapper:TransferSingle"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/NameWrapper.ts(25,13): error TS2345: Argument of type '"subgraph/NameWrapper:TransferBatch"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(32,13): error TS2345: Argument of type '"subgraph/BaseRegistrar:NameRegistered"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(36,9): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(38,20): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(39,47): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(45,13): error TS2345: Argument of type '"subgraph/BaseRegistrar:NameRenewed"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(49,9): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(51,20): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(52,47): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(58,13): error TS2345: Argument of type '"subgraph/BaseRegistrar:Transfer"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(59,41): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(63,9): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(73,13): error TS2345: Argument of type '"subgraph/EthRegistrarControllerOld:NameRegistered"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(78,13): error TS2345: Argument of type '"subgraph/EthRegistrarControllerOld:NameRenewed"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(83,13): error TS2345: Argument of type '"subgraph/EthRegistrarController:NameRegistered"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(87,9): error TS2698: Spread types may only be created from object types.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(89,20): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(91,23): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(91,45): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registrar.ts(97,13): error TS2345: Argument of type '"subgraph/EthRegistrarController:NameRenewed"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registry.ts(33,13): error TS2345: Argument of type '"subgraph/RegistryOld:NewOwner"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registry.ts(34,58): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registry.ts(43,13): error TS2345: Argument of type '"subgraph/RegistryOld:NewResolver"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registry.ts(44,82): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registry.ts(45,30): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registry.ts(55,13): error TS2345: Argument of type '"subgraph/RegistryOld:NewTTL"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registry.ts(56,82): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registry.ts(62,13): error TS2345: Argument of type '"subgraph/RegistryOld:Transfer"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registry.ts(69,82): error TS2339: Property 'args' does not exist on type 'never'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registry.ts(75,13): error TS2345: Argument of type '"subgraph/Registry:NewOwner"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registry.ts(76,13): error TS2345: Argument of type '"subgraph/Registry:NewResolver"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registry.ts(77,13): error TS2345: Argument of type '"subgraph/Registry:NewTTL"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/handlers/Registry.ts(78,13): error TS2345: Argument of type '"subgraph/Registry:Transfer"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/subgraph/subgraph.plugin.ts(36,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/subgraph/subgraph.plugin.ts(37,14): error TS18048: 'contracts.Registry' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/subgraph/subgraph.plugin.ts(40,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/subgraph/subgraph.plugin.ts(41,14): error TS18048: 'contracts.Registry' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/subgraph/subgraph.plugin.ts(44,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/subgraph/subgraph.plugin.ts(45,14): error TS18048: 'contracts.BaseRegistrar' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/subgraph/subgraph.plugin.ts(48,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/subgraph/subgraph.plugin.ts(49,14): error TS18048: 'contracts.EthRegistrarControllerOld' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/subgraph/subgraph.plugin.ts(52,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/subgraph/subgraph.plugin.ts(53,14): error TS18048: 'contracts.EthRegistrarController' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/subgraph/subgraph.plugin.ts(56,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/subgraph/subgraph.plugin.ts(57,14): error TS18048: 'contracts.NameWrapper' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/subgraph/subgraph.plugin.ts(60,50): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/subgraph/subgraph.plugin.ts(61,14): error TS18048: 'contracts.Resolver' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(36,13): error TS2345: Argument of type '"threedns/ThreeDNSToken:NewOwner"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(37,13): error TS2345: Argument of type '"threedns/ThreeDNSToken:Transfer"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(38,13): error TS2345: Argument of type '"threedns/ThreeDNSToken:RegistrationCreated"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(39,13): error TS2345: Argument of type '"threedns/ThreeDNSToken:RegistrationExtended"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(45,13): error TS2345: Argument of type '"threedns/Resolver:AddrChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(46,13): error TS2345: Argument of type '"threedns/Resolver:AddressChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(47,13): error TS2345: Argument of type '"threedns/Resolver:NameChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(48,13): error TS2345: Argument of type '"threedns/Resolver:ABIChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(49,13): error TS2345: Argument of type '"threedns/Resolver:PubkeyChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(51,5): error TS2345: Argument of type '"threedns/Resolver:TextChanged(bytes32 indexed node, string indexed indexedKey, string key)"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(55,5): error TS2345: Argument of type '"threedns/Resolver:TextChanged(bytes32 indexed node, string indexed indexedKey, string key, string value)"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(60,13): error TS2345: Argument of type '"threedns/Resolver:ContenthashChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(61,13): error TS2345: Argument of type '"threedns/Resolver:InterfaceChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(62,13): error TS2345: Argument of type '"threedns/Resolver:AuthorisationChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(63,13): error TS2345: Argument of type '"threedns/Resolver:VersionChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(68,5): error TS2345: Argument of type '"threedns/Resolver:DNSRecordChanged(bytes32 indexed node, bytes name, uint16 resource, uint32 ttl, bytes record)"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(73,13): error TS2345: Argument of type '"threedns/Resolver:DNSRecordDeleted"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(74,13): error TS2345: Argument of type '"threedns/Resolver:DNSZonehashChanged"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/handlers/ThreeDNSToken.ts(75,13): error TS2345: Argument of type '"threedns/Resolver:ZoneCreated"' is not assignable to parameter of type 'EventNames<MergedPonderConfig>'.
apps/ensindexer typecheck: src/plugins/threedns/threedns.plugin.ts(41,49): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/threedns/threedns.plugin.ts(42,45): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/threedns/threedns.plugin.ts(44,14): error TS18048: 'optimismContracts.ThreeDNSToken' is possibly 'undefined'.
apps/ensindexer typecheck: src/plugins/threedns/threedns.plugin.ts(48,49): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/threedns/threedns.plugin.ts(49,45): error TS2345: Argument of type 'ContractConfig | undefined' is not assignable to parameter of type 'ContractConfig'.
apps/ensindexer typecheck:   Type 'undefined' is not assignable to type 'ContractConfig'.
apps/ensindexer typecheck: src/plugins/threedns/threedns.plugin.ts(51,14): error TS18048: 'optimismContracts.Resolver' is possibly 'undefined'.
apps/ensindexer typecheck: Failed
/Users/tko/dev/github/namehash/ensnode/apps/ensindexer:
 ERR_PNPM_RECURSIVE_RUN_FIRST_FAIL  [email protected] typecheck: `tsc --noEmit`
Exit status 2
 ELIFECYCLE  Command failed with exit code 2.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think we have to stick to passing literal types around so we keen the value exported from ponder.config.ts derived from literal types and Ponder can properly infer types about indexing handlers.

@djstrong
Copy link
Contributor

djstrong commented Jun 3, 2025

BugBot run

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Bug: Duplicate Chain IDs in Indexed Chain Retrieval

The getIndexedChainIds function in plugin-helpers.ts does not return unique chain IDs as stated in its documentation. Multiple datasources can be configured for the same chain, causing the function to return duplicate chain IDs. The function should use uniq() to deduplicate the results before returning, consistent with similar logic elsewhere in the codebase.

apps/ensindexer/src/lib/plugin-helpers.ts#L124-L133

/**
* Get a list of unique indexed chain IDs for selected plugin names.
*/
export function getIndexedChainIds(pluginNames: PluginName[]): number[] {
const datasources = getDatasources(pluginNames);
const indexedChainIds = datasources.map((datasource) => datasource.chain.id);
return indexedChainIds;
}

Fix in Cursor


BugBot free trial expires on June 9, 2025
You have used $0.00 of your $5.00 spend limit so far. Manage your spend limit in the Cursor dashboard.

Was this report helpful? Give feedback by reacting with 👍 or 👎

@tk-o tk-o force-pushed the feat/757-761-improve-ensindexerconfig-ext branch from f92cf86 to d13baf8 Compare June 3, 2025 18:57
@tk-o tk-o merged commit 58fa0b2 into main Jun 3, 2025
7 checks passed
@tk-o tk-o deleted the feat/757-761-improve-ensindexerconfig-ext branch June 3, 2025 19:04
@github-actions github-actions bot mentioned this pull request Jun 3, 2025
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