Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Longer Running Processes Disrupted by eth_getLogs/eth_getChainId calls #2885

Open
radleylewis opened this issue Nov 15, 2024 · 1 comment
Open

Comments

@radleylewis
Copy link

Overview

In our use case we are decrypting messages within the context of our MetaMask Snap. This process is quite time consuming (up to approx. 100 seconds). Our specific use case does not invoke calls to the network, however, the library used does invoke the eth_getLogs and eth_getChainId calls. In the case of their failure, the long running decryption process is interrupted.

Question

Short of changing the library code making the calls, is there a way to suspend or prevent such calls (or protect a longer running process within the context of the snap from being disrupted)?

@FrederikBolding
Copy link
Member

@radleylewis Are you referring to the Snap being terminated while waiting for decryption? Calling eth_getLogs or eth_getChainId should only get the Snap terminated if there are unhandled errors. Is it possible to simply catch these errors?

If not, then I think I need a better understanding of the problem 🤔

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants