Skip to content

Commit

Permalink
Use block range
Browse files Browse the repository at this point in the history
  • Loading branch information
Inkvi committed Apr 26, 2024
1 parent f1bf7f2 commit b28eab4
Showing 1 changed file with 15 additions and 7 deletions.
22 changes: 15 additions & 7 deletions ponder.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,48 +24,56 @@ function mustInt(val?: string) {
return parseInt(val);
}

let RANGE = parseInt(process.env.RANGE ?? "100000");

export default createConfig({
networks: {
base: {
chainId: 84532,
transport: http(process.env.PONDER_RPC_URL_84532),
pollingInterval: 5_000,
pollingInterval: 2_000,
},
optimism: {
chainId: 11155420,
transport: http(process.env.PONDER_RPC_URL_11155420),
pollingInterval: 5_000,
},
molten: {
chainId: 49483,
transport: http(process.env.PONDER_RPC_URL_49483),
pollingInterval: 5_000,
pollingInterval: 2_000,
},
// molten: {
// chainId: 49483,
// transport: http(process.env.PONDER_RPC_URL_49483),
// pollingInterval: 2_000,
// },
},
contracts: {
sim: {
maxBlockRange: 2000,
abi: DispatcherAbi,
network: {
base: {
address: mustAddress(process.env.DISPATCHER_ADDRESS_BASE_SIMCLIENT),
startBlock: mustInt(process.env.DISPATCHER_ADDRESS_BASE_SIMCLIENT_START_BLOCK),
// endBlock: mustInt(process.env.DISPATCHER_ADDRESS_BASE_SIMCLIENT_START_BLOCK) + RANGE,
},
optimism: {
address: mustAddress(process.env.DISPATCHER_ADDRESS_OPTIMISM_SIMCLIENT),
startBlock: mustInt(process.env.DISPATCHER_ADDRESS_OPTIMISM_SIMCLIENT_START_BLOCK),
// endBlock: mustInt(process.env.DISPATCHER_ADDRESS_OPTIMISM_SIMCLIENT_START_BLOCK)+RANGE,
},
},
},
proof: {
abi: DispatcherAbi,
maxBlockRange: 2000,
network: {
base: {
address: mustAddress(process.env.DISPATCHER_ADDRESS_BASE),
startBlock: mustInt(process.env.DISPATCHER_ADDRESS_BASE_START_BLOCK),
// endBlock: mustInt(process.env.DISPATCHER_ADDRESS_BASE_START_BLOCK)+RANGE,
},
optimism: {
address: mustAddress(process.env.DISPATCHER_ADDRESS_OPTIMISM),
startBlock: mustInt(process.env.DISPATCHER_ADDRESS_OPTIMISM_START_BLOCK),
// endBlock: mustInt(process.env.DISPATCHER_ADDRESS_OPTIMISM_START_BLOCK)+RANGE,
},
},
},
Expand Down

0 comments on commit b28eab4

Please sign in to comment.