Hi guys, I updated the price of $BIO on the pyth base contract via basescan. However, when I try doing same via vscode via forking mainnet I get 0x6ce2251a can’t really pinpoint what custom error message this points to
Hello @0xcredence, thanks for your prompt response, the update data I used was gotten from Swagger UI which is were I got the update data I used to update the price via basescan which worked.
@c-note the error doesn’t seem to be related to Pyth and I suspect it is because forking doesn’t fork all the contracts properly (and I have faced it in the past too). Many contracts are used in this call: proxy and main contract for Pyth and proxy and main contract for Wormhole.
For testing I generally recommend using MockPyth contract so you can set your own prices and simulate your desired protocol behaviours with it.
@ali I meant sent a tx via the mainnet paid for gas and all but failed with same error message gotten when I just forked mainnet.
My point is when I interact with fork-mainnet or base mainnet i still get same error message when I make this call via vscode. (But everything works well when I do this via basescan)
@c-note thanks for sharing this script as it helped a lot to troubleshoot it. The problem is that in forge assigning update data to bytes like that is not right. You need to use hex"deadbeef..." and by fixing it I could send the transaction successfully.
p.s: I found the error was about Wormhole saying the message format is invalid (see this) and it made me realize that the update data format was wrong.