[Bug] `net_version` change error when switching from `RPC` provider to a Firehose provider
Bug report
Steps:
-
Fresh
graph-nodestart from fresh database with config below. This creates a chain for mainnet withnet_version: 1in the database.[general] [store] [store.primary] connection = "postgresql://graph-node:let-me-in@localhost:5432/graph-node" weight = 1 pool_size = 10 [chains] ingestor = "block_ingestor_node" [chains.mainnet] shard = "primary" protocol = "ethereum" provider = [ { label = "peering", url = "$RPC_NODE", features = [ "archive", "traces" ] }, ] [deployment] [[deployment.rule]] shard = "primary" indexers = [ "default" ] -
Stop
graph-nodeinstance. -
Start it back with a Firehose only provider
[general] [store] [store.primary] connection = "postgresql://graph-node:let-me-in@localhost:5432/graph-node" weight = 1 pool_size = 10 [chains] ingestor = "block_ingestor_node" [chains.mainnet] shard = "primary" protocol = "ethereum" provider = [ { label = "firehose", details = { type = "firehose", url = "$FIREHOSE_ENDPOINT", token = "$STREAMING_FAST_API_TOKEN", features = [ "compression", "filters" ] }}, ] [deployment] [[deployment.rule]] shard = "primary" indexers = [ "default" ]
Yields error message Apr 27 16:03:14.931 ERRO the net version for chain mainnet has changed from 1 to 0 since the last time we ran, component: BlockStore.
Weirdly, the network seems to still be configured correctly, so maybe it's more a warning or maybe we should just ignore net_version and keep only genesis_hash check.
Relevant log output
No response
IPFS hash
No response
Subgraph name or link to explorer
No response
Some information to help us out
- [ ] Tick this box if this bug is caused by a regression found in the latest release.
- [ ] Tick this box if this bug is specific to the hosted service.
- [X] I have searched the issue tracker to make sure this issue is not a duplicate.
OS information
macOS
is the net_version from the Firehose 0?
Looks like this issue has been open for 6 months with no activity. Is it still relevant? If not, please remember to close it.
@maoueh checking on this issue?
That is still relevant AFAIK. The net_version could be ignored and we only rely on the genesis block. Would miss someone mixing up ETH classic endpoint and ETH Mainnet endpoints. I feel this is a relative low possibility in the wild, we would still find mixing up two different networks.
Looks like this issue has been open for 6 months with no activity. Is it still relevant? If not, please remember to close it.