ZeppelinSolutions / solium-plugin-zeppelin

[DEPRECATED] Solium plugin for Zeppelin audits
MIT License
17 stars 10 forks source link

constant-candidates fails with: Cannot read property 'type' of null #14

Closed come-maiz closed 6 years ago

come-maiz commented 6 years ago

I tried running the constant-candidates rule on the zeppelin-solidity project, and it failed with:

✖ [Fatal error] An error occurred while linting over /home/ubuntu/zeppelin-solidity/contracts/ownership/Heritable.sol: Cannot read property 'type' of null

duaraghav8 commented 6 years ago

originates from https://github.com/elopio/solium-plugin-zeppelin/blob/master/rules/constant-candidates.js#L41 node.value seems to be null

I'll be pushing the ability to dump stack trace in the next release of solium, that will make life easier for plugin devs

come-maiz commented 6 years ago

Yay, thanks @duaraghav8! Just mentioning the rule in the error would be very useful. The trace even better.