Developers Forum for XinFin XDC Network

Discussion on: Graphnode Xinfin Compatibility Project (Done)

Collapse
eoaks profile image
Eduardo Robles •

I've been trying to implement a subgraph using graph-protocol's graph-node by changing this file to have ethereum: 'mainnet:https://rpc.apothem.network'.

But running docker-compose up with this gives the following error.
Aug 29 20:46:40.700 WARN Trying again after eth_getBlockByNumber(0, false) RPC call failed (attempt #11) with result Err(Decoder error: Error("invalid length 43, expected a (both 0x-prefixed or not) hex string with length of 40", line: 0, column: 0)), provider: mainnet-rpc-0

I was kindly pointed to this post which does say that it is possible to have a subgraph, but haven't been able to tell the difference from my code to the one in the examples.

Can someone point me in the right direction here? What am i missing?

Collapse
xu_zhaolin_fcf881856ae0b5 profile image
xu zhaolin Author •

looking into it

Collapse
xu_zhaolin_fcf881856ae0b5 profile image
xu zhaolin Author •

Hi
You need to use the GitHub we provide we have modified the graph source code to be adoptable with xdc network.

Collapse
eoaks profile image
Eduardo Robles •

I have cloned gzliudan/graph-node but still get these errors | Aug 31 13:12:23.552 WARN Trying again after eth_getBlockByNumber(0, false) RPC call failed (attempt #16) with result Err(Decoder error: Error("invalid length 43, expected a (both 0x-prefixed or not) hex string with length of 40", line: 0, column: 0)), provider: mainnet-rpc-0 and when trying to deploy Failed to deploy to Graph node http://localhost:8020/: network not supported by registrar: no network mainnet found on chain ethereum

Thread Thread
xu_zhaolin_fcf881856ae0b5 profile image
xu zhaolin Author •

let me check

Thread Thread
xu_zhaolin_fcf881856ae0b5 profile image
xu zhaolin Author •

you havent switched to the xdc branch

git checkout -b xdc origin/xdc

Collapse
xu_zhaolin_fcf881856ae0b5 profile image
xu zhaolin Author •

you need to instal from the adress we provide