1

Long story short, while making a blockchain crawler that would extract all ERC20 transactions I learned the hard way that ERC721 has the same "signature" as ERC20 (and probably many others that I haven't found out about yet).

However, when my crawler crashed on this cryptokitty transaction, I was puzzled ... turns out, when I look at the contract source code, the parameters of the Transfer event are not indexed at all, even though the actual ERC721 standard draft on github clearly defines them as indexed. After that, I randomly looked at some other ERC721 tokens, and some of them do not have indexed Transfer events either!

On the other hand I haven't yet seen ERC20 contract that doesn't have indexed parameters of the Transfer event yet.

Isn't this in violation of the standard ?

Is there any reason to it, other than making my life more difficult ;) ?

  • Stuff like this is usually just human oversight. There are a few ERC20 tokens that don't adhered to the standard too, but are "close enough" for most use (OMG is missing the bool return on transfer, for instance) – Raghav Sood Jul 31 '18 at 7:30
  • Related link: erc721validator.org // I have personally reviewed and confirmed MANY standard violations. One problem is that OpenZeppelin published code that did not work and did not put any disclaimers on it. Another problem is that standardization takes time, some some people are deploying before it is done. – William Entriken Sep 18 '18 at 21:46
  • Star and watch the tweet here // twitter.com/fulldecent/status/1042167582722326529 // if you are interested in the result – William Entriken Sep 18 '18 at 21:47
0

Yes, it's a violation of the standard, but these violation are ubiquitous.

ERC-721 went through many iterations before it was finalised. The standard seemed all but settled when CryptoKitties launched, but then the standardisation process quite unexpectedly got bogged down in bikeshedding, so many projects either used the CryptoKitties interface (which in hindsight, it would probably have been better to just bless as "the standard"), or used the current draft of ERC-721 at the time (which was not always a great move - some of the intermediate drafts had severe issues).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.