question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Transaction signing fails with the Ergo dApp connector

See original GitHub issue

When trying to sign an unsigned transaction, I get the following error:

Error: genLookupOrFail no token info for {"identifier":"d58b85b6e6319796d42feccfee4f80086efbd4d9098dd435f205750845d501f9","amount":"-1","networkId":200}
    at Object.getTokenInfo (ergo.bundle.js:1)
    at Vn.renderAmountDisplay (ergo.bundle.js:1)
    at s (ergo.bundle.js:1)
    at ergo.bundle.js:1
    at Array.map (<anonymous>)
    at Vn.renderRow (ergo.bundle.js:1)
    at ergo.bundle.js:1
    at Array.map (<anonymous>)
    at Vn.render (ergo.bundle.js:1)
    at Se (813.bundle.js:2)
rs @ 587.bundle.js:2

The unsigned transaction is perfectly fine because the node is able to sign it (with the same secrets as my Yoroi wallet). The d58b85b6e6319796d42feccfee4f80086efbd4d9098dd435f205750845d501f9 is a token in one of the inputs of the transaction (not related to my wallet’s UTXOs).

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:16 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
vsubhumancommented, Jul 28, 2021

You can produce all these issues (#2157 #2160 and the error above) by following these steps:

Hi, @anon-real! Thank you for that great hosted resource and the instruction to reproduce the problems!

  • connect to your Yoroi wallet with “Configure wallet” then “connect” - this should produce the “Uncaught (in promise) Error: [mobx] An invariant failed, however the error is obfuscated because this is a production build.” error

Regarding this first problem - I am now releasing a new nightly version of Yoroi 4.5.7005 - please update to that version and try it again, this should be fixed there. I have got connection to wallet working on your page with no problems with that fix.

To be able to reproduce other problems you will have to upgrade to the changes in the latest Yoroi, tho, because the dapp-connector now requires all the output values and asset amounts to be specified as strings always, see this PR (the nightly is now built from this branch) - https://github.com/Emurgo/yoroi-frontend/pull/2246

I am getting to the point where your page receives utxos, but their values are now strings, so things seem to be breaking after that. This update will be needed in any way as we are positively making this change for safe value exchange going forward.

Once you page is updated to the strings - I will look into any further errors ASAP.

cc @oskin1 for more details if needed.

1reaction
anon-realcommented, Jul 21, 2021

I am also experiencing some other issues like “Uncaught (in promise) Error: [mobx] An invariant failed, however the error is obfuscated because this is a production build.” when trying to connect to my wallet. I have set up a test auction house so you can see the issues for yourselves: https://yoroi.ergoauctions.org/

You can produce all these issues (#2157 #2160 and the error above) by following these steps:

  • go to https://yoroi.ergoauctions.org/
  • connect to your Yoroi wallet with “Configure wallet” then “connect” - this should produce the “Uncaught (in promise) Error: [mobx] An invariant failed, however the error is obfuscated because this is a production build.” error
  • go to “Other tokens” with the left menu
  • select “place bid” - you should experience #2157 and #2160

The requested unsigned tx will be printed, the source code which you may find useful: https://github.com/anon-real/ErgoAuctionHouse/blob/yoroi/src/auction/bidYoroi.js#L123

Read more comments on GitHub >

github_iconTop Results From Across the Web

How common is it for transactions to fail with sigmausd and ...
I've had 3 transactions fail in a row and I'm just wondering as ... This won't be a concern when the Yoroi dapp...
Read more >
Integration - ErgoDocs
Failed to sign boxes#. This error can occur due to too many inputs collected in a transaction for dusty wallets. Failed to sign...
Read more >
ergo-dapp-connector - npm
This idea came out of a user from the Ergo Community suggesting creating more documentation regarding Ergo dApp Connection, apparently he ...
Read more >
Understanding and resolving MetaMask error codes
This error occurs when the dApp wants to take action concerning an account that is not authorized. For instance, to do certain actions...
Read more >
Solving a MetaMask connection issue - Ledger Support
Once your account is reset, restart your browser and try connecting your Ledger device to Metamask again. Resetting your Metamask account is ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found