Header not found error on speedy nodes

when I use speedy nodes, sometimes I send requests to the endpoint, and then I catch the error: {‘code’: -32000, ‘message’: ‘header not found’}. How can I solve this problem?

Hi @backfirehzy

Please provide us more info. What chain, code, description. Thank you

I use ETH and BSC nodes, but the error only happened on BSC HTTP node(archived).

My request is like this: {“jsonrpc”:“2.0”,“id”:1,“method”:“eth_call”,“params”:[{“from”:“0x0000000000000000000000000000000000000000”,“data”:“0xd06ca61f00000000000000000000000000000000000000000000000029a2241af62c0000000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000030000000000000000000000002170ed0880ac9a755fd29b2688956bd959f933f8000000000000000000000000bb4cdb9cbd36b01bd1cbaebf2de08d9173bc095c000000000000000000000000f16e81dce15b08f326220742020379b855b87df9”,“to”:“0x10ed43c718714eb63d5aa57b78b54704e256024e”},“latest”]}

This problem doesn’t happen on all requests, sometimes it happens, sometimes it’s ok. And it also happened on other companies’ nodes, such as Chainstack.

Are you making these calls via Metamask or node?
It may happen because of a big number of requests via your metamask wallet.

Looks like this issue is still not solved https://github.com/MetaMask/metamask-extension/issues/7234

I make the call with web3py, not Metamask.
I found this GitHub page a few days ago, and my problem is very similar to this issue, but they are different:

  1. Their problem happened on the ETH chain, but mine are on the BSC chain(ETH is completely ok)
  2. I have run the same code until early November with no problem, but it happened in December. I guess it is associated with the BSC Bruno upgrade. Could you please help me to check whether the problem is related to Bruno upgrade or not?

I tested this particular request now few times and it looks like it worked fine

In most situations, it’s ok. The problem only happened when the request rate is very high.
Someone said introducing a 100ms delay between requests is useful, but my program is distributed, and difficult to make the delay.

can you make that delay when you get the error and then retry same request?

Ok, I’ll try but I just wonder why this happens:upside_down_face: