All packages
v4_pool_index_consumer

v4_pool_index_consumer

saturn012
v0.1.0/0 downloads/Repository

Package ref

v4-pool-index-consumer@v0.1.0

Run package

CLI

Run map_pool_digest from the command line.

substreams run v4-pool-index-consumer@v0.1.0 map_pool_digest -e robinhood --start-block -1
Authenticate by running substreams auth or directly on thegraph.market (see docs).

README

v4-pool-index consumer

This package is the downstream half of the composition proof. It imports the published v4-pool-index@v0.1.1 package by registry name and consumes its pools:map_initialize output; it does not copy or re-run the producer implementation.

map_pool_digest emits one consumer.v1.PoolDigests record per block with:

  • pool_count: pools emitted by the imported producer on that block;
  • nonzero_hooks: those pools with at least one nonzero hook byte;
  • dynamic_fee: those pools with the v4 dynamic-fee flag (0x800000).

Reproduce

From this directory, with a Substreams API token available through the normal CLI environment:

cargo build --manifest-path consumer/Cargo.toml --release --target wasm32-unknown-unknown
substreams pack consumer/substreams.yaml
substreams run consumer/substreams.yaml map_pool_digest --network robinhood --start-block <BLOCK> --stop-block <BLOCK+1> --output jsonl
substreams run consumer/substreams.yaml map_pool_digest --network base --start-block <BLOCK> --stop-block <BLOCK+1> --output jsonl

The package imports v4-pool-index@v0.1.1 by name; no producer source or producer package is copied into consumer/. The package is not published by this task.

Live acceptance evidence

The following bounded read-only runs used the same block for producer and consumer on each network:

base block 50994246:
  producer map_initialize: pools=1
  consumer map_pool_digest: poolCount=1, nonzeroHooks=1, dynamicFee=1
  count_match=PASS

robinhood block 56764780:
  producer map_initialize: pools=1
  consumer map_pool_digest: poolCount=1, nonzeroHooks=0, dynamicFee=0
  count_match=PASS

The full JSONL and stderr captures are kept in the task-private evidence directory, not committed to the public package.

Modules

Execution graph

2 modules
mapMain

map_pool_digest

Counts pools emitted by the published v4-pool-index map_initialize output and records the two raw decision signals consumed by the downstream rules.

from #9070
Show 1 dependency
map

pools:map_initialize

Emits PoolManager Initialize identity fields for downstream packages. The network manifest supplies a PoolManager parameter; an explicit -p map_initialize=pool_manager=0x... may override it for a bounded run. The output is composable: a downstream map may declare `map: map_initialize` as its input. Swap and ModifyLiquidity are intentionally out of scope.

from #9070