mcs07 / PubChemPy

Python wrapper for the PubChem PUG REST API.
http://pubchempy.readthedocs.io
MIT License
392 stars 110 forks source link

fix #13 check if identifier is None and raise an exception to let the user know that the identifier is invalid #14

Closed llazzaro closed 8 years ago

llazzaro commented 8 years ago

I had a bug and the original error confused me a lot. I understand that checking invalid input types in python does not make sense in a duck typing sense, however the case for None I think it needs to be checked. Feel free to close without merge. I think that the original bug is on get_compounds that returns a cid as None.

coveralls commented 8 years ago

Coverage Status

Coverage increased (+0.8%) to 93.894% when pulling f2cfc9a1a982ce31b81015e2d6fd652bdd9c18b4 on llazzaro:master into 9de4f2cca694c7e7daf6ab419bc14cc8cba94203 on mcs07:master.

mcs07 commented 8 years ago

Thanks!