-
Notifications
You must be signed in to change notification settings - Fork 5k
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
[Bug]: MetaMask stays loading indefinetly and get error StreamProvider - Unknown response id for response: [object Object]
when doing *some* contract interactions
#17467
Comments
StreamProvider - Unknown response id for response: [object Object]
when minting an ERC1155StreamProvider - Unknown response id for response: [object Object]
when doing *some* contract interactions
This looks like a duplicate of #17154 though this one has much more detail in the description, so it might be fair to close that one as a duplicate of this.
To get to the next confirmation, you have to close out of MetaMask and ignore any "MetaMask Notification" popup window (because clicking X on that will be treated as a rejection), then re-open MetaMask from the button on the browser toolbar. |
Hi! I have this problem too. Can you please tell me what is causing this error and how to solve it? |
The cause is unclear; it appears to be a bug in MetaMask. You can get a short term solution by clicking in some blank area in your browser, then clicking on the MetaMask pinned icon extension to get it to reload and hopefully display the next confirmation prompt, though it sometimes crashes then too (just keep trying). Do NOT click the X on the crashed "Metamask Notification" popup as this is treated as a signature rejection. For the medium term, the only way to really solve it seems to be to use an alternative (see whatthefox.com as an example listing; no endorsement of their proposed alternative implied). For a long term fix, someone will have to take a deep dive into MetaMask code, ideally after being able to reliably reproduce the issue. That's easier said than done though. |
I can reproduce this error, it occurs after running certain contract methods on my site. When calling certain functions on my site that call certain methods on my contract, this error appears in MetaMask. I think that this is not a problem in MetaMask, but in the contract method call |
Do you have (or can you make) clear steps for reproduction that don't cost real-world money? (e.g. something on a test network). |
I get this performing most actions. I have around 10 wallets in my metamask and simply switching between them presents me with this infinite loading issue. Extremely annoying and have resulted in performing my day to day activities on firefox rather than chrome whilst this persists. Has anyone found a fix? |
Do you only have this problem in Chrome browser? |
And please tell me which MacOS, Linux or Windows system do you use? It's just that I'm currently testing on Windows and don't see this error. By the way, if you have error, you can remove it. You just need to go to the MetaMask settings and reset the account, after that the error disappears. |
Windows 11, chrome version 111.0.5563.65, metamask 10.25.0. Yes the error is specific to chrome and unfortunately resetting account data does not remove the issue. I have reset the account, and even completely uninstalled and reinstalled and the issue persists. |
I'm also seeing it on Windows 10 w/Chrome. |
Yes, that is right. This bug appeared in the latest version of MetaMask v10.25.0. I installed the previous version of MetaMask 10.24.2 and everything works fine. I also put debuggers in the MetaMask v10.25.0 code and noticed that when calling certain methods of my smart-controct, this error starts to appear, because MetaMask stops receiving id, as far as I understand, this is a store id, which is constantly generated. In general, this bug is due to updating MetaMask to version 10.25.0. The second screenshot shows that the id was not generated and it simply does not exist, although it should be. |
I also noticed that in the previous version of MetaMask this function is not called when the contract method is called, and in the latest version of MetaMask this function is called for some reason when I call the contract method, but no id is generated and an object without an id comes in response. |
But unfortunately, I still cannot figure out why MetaMask v10.25.0 cannot generate this id and why this happens. I also noticed that not all methods of my smart contract cause this error, only some. |
This reverts commit 6f6984f. That commit was an RPC middleware refactor intended to move the subscribe and filter middleware into the network controller, to simplify the process of sharing this middleware between clients. This refactor resulted in `eth_subscribe` notifications being sent on the wrong connections, causing the UI to break in some cases (the UI `provider` connection does not support notifications). This happened because the `setupProviderEngine` function runs per-connection, whereas the engine setup inside the network controller is global. The global network client cannot support notifications because it has no way to route them; they'll need to stay in the per-connection provider engine. Closes #17467
@DimasikS12 @wbt @Samclay8 thank you all for your contributions. We have identified the issue and have a fix for it. It will take a couple of weeks in order to be released in production. You should see it fixed once it is released 👍 |
This reverts commit 6f6984f. That commit was an RPC middleware refactor intended to move the subscribe and filter middleware into the network controller, to simplify the process of sharing this middleware between clients. This refactor resulted in `eth_subscribe` notifications being sent on the wrong connections, causing the UI to break in some cases (the UI `provider` connection does not support notifications). This happened because the `setupProviderEngine` function runs per-connection, whereas the engine setup inside the network controller is global. The global network client cannot support notifications because it has no way to route them; they'll need to stay in the per-connection provider engine. Closes #17467
…18129) * Revert "Moved subscribe and filter into network controller (#16693)" This reverts commit 6f6984f. That commit was an RPC middleware refactor intended to move the subscribe and filter middleware into the network controller, to simplify the process of sharing this middleware between clients. This refactor resulted in `eth_subscribe` notifications being sent on the wrong connections, causing the UI to break in some cases (the UI `provider` connection does not support notifications). This happened because the `setupProviderEngine` function runs per-connection, whereas the engine setup inside the network controller is global. The global network client cannot support notifications because it has no way to route them; they'll need to stay in the per-connection provider engine. Closes #17467 * Add e2e test An e2e test has been added that confirms subscriptions are only broadcast to the site that registered them. This test fails on `develop`.
…18129) * Revert "Moved subscribe and filter into network controller (#16693)" This reverts commit 6f6984f. That commit was an RPC middleware refactor intended to move the subscribe and filter middleware into the network controller, to simplify the process of sharing this middleware between clients. This refactor resulted in `eth_subscribe` notifications being sent on the wrong connections, causing the UI to break in some cases (the UI `provider` connection does not support notifications). This happened because the `setupProviderEngine` function runs per-connection, whereas the engine setup inside the network controller is global. The global network client cannot support notifications because it has no way to route them; they'll need to stay in the per-connection provider engine. Closes #17467 * Add e2e test An e2e test has been added that confirms subscriptions are only broadcast to the site that registered them. This test fails on `develop`.
Describe the bug
Problem: when I call the function for mint an ERC1155 token, MetaMask stays loading indefinetly and I get the console error
Error in event handler: Error: StreamProvider - Unknown response id for response: [object Object]
.mint-erc1155-streamprovider.mp4
This also happens when I call another contract function.
streamprovider-error.mp4
[EDITED] It seems the error could start whenever we deploy a contract. It's not 100% deterministic, so further investigation needs to be done.
Steps to reproduce [EDITED]
After this, we are into a broken state, shown in the videos above.
Error messages or log output
No response
Version
develop [EDITED]
Build type
None
Browser
Chrome
Operating system
Linux
Hardware wallet
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: