1

My contract name has an apostrophe, and when deployed it shows on Etherscan as John Doe's Contract instead of, 'John Doe's Contract'.

I tried the UTF-8 \x27, and it also outputted '. I even tried converting to hex and using the unicode modifier, but it still renders as that. No luck. Are there any possible workarounds?

4
  • 1
    Can you show an example of the contract code? Etherscan is a closed source block explorer so they can show whatever they want.
    – Ismael
    Aug 31, 2021 at 1:17
  • It might just be them. The string shows fine in Remix, and on the frontend. I emailed them. The code is simply a normal string. There's no code, it's just a string misformatted. I was wondering if it related maybe to Solidity 8 rules for string literals, but I think your instinct is correct. I will update the answer if they reply affirmatively. Other questions have had similar problems, but with resolutions. I tried all of those. Aug 31, 2021 at 1:29
  • 1
    Have similar problem with adding revert message, any chance you found out how to solve this?
    – Blissful
    Jan 17, 2023 at 12:04
  • Nope, it definitely is their problem. Sigh. Jan 22, 2023 at 18:45

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.