Possibly bogus warning adding Gnosis chain

If you go to gnosis dot io and click on “Add to MetaMask” at the top-right of the page, MetaMask shows a warning “The submitted currency symbol does not match what we expect for this chain ID.” The link is adding the chain currency as “xDai”. The MetaMask documentation explicitly says (if you follow the link from that warning) that the Gnosis chain currency is “xDAI” – it uses Gnosis as its example!

I looked at the source code for the extension and found that this is probably a case sensitivity issue: “xDai” (from the site) vs “xDAI” (from the fetched networks list).

I wondering if this merits a bug report. Are symbols supposed to be case sensitive in general?

2 Likes

Hey!

This has been passed along to the team for inquiry. Thank you!

1 Like

The problem code is at lines 125-129 of ui/pages/confirmation/templates/add-ethereum-chain.js in MetaMask extension. I can’t post a link, it seems.

If you’ve made a GitHub issue I can post all the details there.

1 Like

No GitHub issue opened currently, but will pass this along.

It does appear these are case sensitive.

3 Likes

Back with a clarification. This issue is mostly on Gnosis website’s part. The token is xDAI not xDai, so it’s only them who can fix that little inconvenience. You can add the network disregarding their website method of adding by using Chainlist or manually. The warning from MetaMask is there to make sure, in other cases, people don’t interact with the wrong networks.

4 Likes

Thanks. I can imagine that trying to introduce case insensitivity or similar could make people vulnerable to being fooled by fake tokens, so I agree it’s better to keep the strict compare and keep the warning.

Submitted issue 2 to gnosischain/issues on GitHub. (Sorry, can’t link here!)

5 Likes

This topic was automatically closed after 30 days. New replies are no longer allowed.