metAMOS icon indicating copy to clipboard operation
metAMOS copied to clipboard

metAMOS INSTALL.py error

Open fangyuanchang opened this issue 4 years ago • 3 comments

I tried running "python2 INSTALL.py core" and fails with the following last few lines. One difference compared to instruction on the manual was that I had to run with python2 instead of python (which runs on ver 3 as default). Any help appreciated. Thanks!

src/findscforfs.py:37:16: Syntax error in simple statement list cythoning ./src/scaffold.py to ./src/scaffold.c /mnt/efs/fangyuan/metamos/metAMOS-1.5rc3/Utilities/python/lib/python/Cython-3.0a6-py3.6-linux-x86_64.egg/Cython/Compiler/Main.py:344: FutureWarning: Cython directive 'language_level' not set, using '3str' for now (Py3). This has changed from earlier releases! File: /mnt/efs/fangyuan/metamos/metAMOS-1.5rc3/src/scaffold.py tree = Parsing.p_module(s, pxd, full_module_name)

Error compiling Cython file:

... run_process(_settings, "touch %s/Scaffold/out/%s.motifs"%(_settings.rundir, _settings.PREFIX), "Scaffold") run_process(_settings, "touch %s/Logs/scaffold.skip"%(_settings.rundir), "Scaffold") return 0

if _mated == False and numMates == 0: print "No mate pair info available for scaffolding, skipping" ^

src/scaffold.py:101:13: Syntax error in simple statement list reading manifest file 'metAMOS.egg-info/SOURCES.txt' writing manifest file 'metAMOS.egg-info/SOURCES.txt' running build_scripts copying build/scripts-3.6/runPipeline.py -> /mnt/efs/fangyuan/metamos/metAMOS-1.5rc3 copying build/scripts-3.6/initPipeline.py -> /mnt/efs/fangyuan/metamos/metAMOS-1.5rc3 changing mode of /mnt/efs/fangyuan/metamos/metAMOS-1.5rc3/runPipeline.py to 755 changing mode of /mnt/efs/fangyuan/metamos/metAMOS-1.5rc3/initPipeline.py to 755 running build_ext building 'preprocess' extension x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -fPIC -I/usr/include/python3.6m -c ./src/preprocess.c -o build/temp.linux-x86_64-3.6/./src/preprocess.o ./src/preprocess.c:1:2: error: #error Do not use this file, it is the result of a failed Cython compilation. #error Do not use this file, it is the result of a failed Cython compilation. ^~~~~ error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

fangyuanchang avatar Sep 19 '20 22:09 fangyuanchang

having the same issue. how did you resolve it ?

senukobla avatar Sep 26 '20 19:09 senukobla

The above error indicates cython 3 is the default:

/mnt/efs/fangyuan/metamos/metAMOS-1.5rc3/Utilities/python/lib/python/Cython-3.0a6-py3.6-linux-x86_64.egg/Cython/Compiler/Main.py:344: FutureWarning: Cython directive
'language_level' not set, using '3str' for now (Py3). This has changed from earlier releases! File: /mnt/efs/fangyuan/metamos/metAMOS-1.5rc3/src/scaffold.py
tree = Parsing.p_module(s, pxd, full_module_name)

metAMOS requires python v2 and cython v2 as well. It looks like you didn't completely switch to python2 on the system.

skoren avatar Sep 26 '20 21:09 skoren

Hi Sergey, I installed python 2.7.14 in a conda environment, installed psutil 0.6.1 (had issues with psutil) and I got the same error message described above. The cython version coming with python 2.7.14 in the conda environment is: 0.29.21. I installed cython 0.25.2 and still got the same error message. Which version of cython do you recommend? Which version of python and cython do you use (I could not find the version 2.7.3 of python)? Any other advice for a complete switch to python2?

etiennedanis avatar Jan 13 '21 16:01 etiennedanis