Skip to content
Discussion options

You must be logged in to vote

If the chain changes to another chain that your contract is deployed to, aren't you going to have to unwatch first, and then call watchReadContract again with new parameters, specifically a new contract address?

Some contracts share the same address across chains, so can make sense for those scenarios (without needing to unwatch/watch again).

This is not an error that is passed to the callback; rather just a background error that seems un-catchable.

You can catch it by wrapping watchReadContract in a try/catch block.

watchReadContract has a return value that is not specified in the docs.

Thanks! We can update this.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by cilphex
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants