YangLab / CIRCexplorer2

circular RNA analysis toolset
http://circexplorer2.readthedocs.org/
Other
76 stars 41 forks source link

Issue with fetch_uscs.py: TypeError #28

Closed Scathacheng closed 5 years ago

Scathacheng commented 5 years ago

Hey, Thanks for your works first. Recently when I use CIRCexplorer2, I meet a problem. I was downloading hg19_kg, but it turns out: Traceback (most recent call last): File "/zs32/home/jcdai/04circRNA/01package/CIRCexplorer2/circ2/fetch_ucsc.py", line 94, in main() File "/zs32/home/jcdai/04circRNA/01package/CIRCexplorer2/circ2/fetch_ucsc.py", line 90, in main fetch_file(sys.argv) File "/zs32/home/jcdai/04circRNA/01package/CIRCexplorer2/circ2/fetch_ucsc.py", line 40, in fetch_file gene = line.decode().split('\t')[4].translate(s) TypeError: character mapping must return integer, None or unicode

Sorry man, I don't know how to fix this, could you please help me?

kepbod commented 5 years ago

fetch_ucsc.py requires to download files from UCSC. Sometimes because of the network problem or other unknown issues, the downloaded file is not complete. Thus, this problem may occasionally occur. You could try to run the command again to see if this issue would occur again.

Scathacheng commented 5 years ago

Thanks for your answer. I have tried for so many times for almost a week, and the problem is still there. I downloaded the knownGene.txt and kgXref.txt from website, and compare with the file downloaded by code, there are exactly same size. I also paid attention to the update of these file, and the newest file is 2015. So I don't really know what is going on.

xingma commented 5 years ago

The problem is from different apis of python2 and python3 and is fixed in the new version CIRCexplorer2 (https://github.com/YangLab/CIRCexplorer2/commit/4720ebcfe13fd6d840a758ab6fddb7e0a69af0c6).

Scathacheng commented 5 years ago

thank you so much, it works now.

sambhav2mishra commented 4 years ago

thank you so much, it works now.

Hey can you please help me out ?? i'm extremely new to this field and i have very less idea about python, i would really appreciate if you can help me out in details. :)