Gnosis Safe – How to Fix 404 Error When Loading Just Created Safe Wallet

gnosis-safe

I'm using the instruction from https://github.com/gnosis/safe-infrastructure to setup a local test environment (using local Docker) for connecting Gnosis Safe to my EVM-Compatible side-chain. I did deploy safe-contracts to the chain, updated the RPC endpoint in the .env, started docker compose and follow all the steps to setup the chainInfo. The log from tkx-worker seems to be ok as below.

enter image description here

I cloned safe-react, make necessary changes to make it start and can create a new safe. Unfortunately, once the safe is created, there's an ajax call to retrieve the safe info from the Client Gateway (http://localhost:8000/api/v1/safes/0xEaD3904076de4d7d56AA02e3e9C6B58d91Aa2b0E) but this request returns 404. My understanding is that transaction service is listening to the event from the Safe L2 contract and capture the new created safe in the datastore, maybe I'm wrong about this assumption. Could you please point me where to check to see why the GET url above returns 404.

Best Answer

The services are indeed monitoring the events from the L2 Safe contracts. To properly monitor this it is required to setup the service with the correct contract addresses.

The easiest is if you deploy the contracts to your local network using the tagged version of the safe-contracts repo. This should result in the same contract addresses as on mainnet.

Then you need to add the proxy factory in the django admin. enter image description here

After this you also need to add the master copy of your network.

enter image description here

For the block numbers you should be able to use 0 or if you want to do it more correctly use the block number of the deployment of the Safe contracts.

Related Topic