nanxstats / Rcpi

💊 Molecular informatics toolkit with integration of bioinformatics and cheminformatics tools for drug discovery
https://nanx.me/Rcpi/
Artistic License 2.0
36 stars 12 forks source link

Error on Rcpi package #7

Open htorkey opened 4 years ago

htorkey commented 4 years ago

Hi

I got this error when I tied to rerun your tutorial on Rcpi

drugseq <- getSmiFromKEGG(drugid, parallel = 5) java.lang.NullPointerException at org.guha.rcdk.util.Misc.loadMolecules(Misc.java:169) Error in load.molecules(tmpfile) : org.openscience.cdk.exception.CDKException: java.lang.NullPointerException

nanxstats commented 4 years ago

@htorkey -thanks for reporting this. It seems that the KEGG API behind this now just randomly return a 403 access forbidden error instead of the correct content (in this case, the mol file). It is possible that they introduced some new rate limits to avoid people from scraping the data. Cannot say if this is going to be a transient issue or not, but let's wait and see.

The ad-hoc solution is simple -- you could get the smiles or mol from other public sources, such as DrugBank, PubChem, and ChEMBL, which are also supported by the package.