gagneurlab / drop

Pipeline to find aberrant events in RNA-Seq data, useful for diagnosis of rare disorders
MIT License
128 stars 43 forks source link

ImportError: cannot import name 'get_argument_parser' from 'snakemake' #509

Closed TechLabLgm closed 5 months ago

TechLabLgm commented 5 months ago

After I installed drop_demo using mamba I have this error: (drop_env) ➜ drop_d drop demo Traceback (most recent call last): File "/home/lgm/miniconda3/envs/drop_env/bin/drop", line 6, in from drop.cli import main File "/home/lgm/miniconda3/envs/drop_env/lib/python3.12/site-packages/drop/init.py", line 1, in from .setupDrop import * File "/home/lgm/miniconda3/envs/drop_env/lib/python3.12/site-packages/drop/setupDrop.py", line 2, in from drop.config.DropConfig import DropConfig File "/home/lgm/miniconda3/envs/drop_env/lib/python3.12/site-packages/drop/config/init.py", line 1, in from .DropConfig import DropConfig File "/home/lgm/miniconda3/envs/drop_env/lib/python3.12/site-packages/drop/config/DropConfig.py", line 1, in from .SampleAnnotation import SampleAnnotation File "/home/lgm/miniconda3/envs/drop_env/lib/python3.12/site-packages/drop/config/SampleAnnotation.py", line 1, in from drop import utils File "/home/lgm/miniconda3/envs/drop_env/lib/python3.12/site-packages/drop/utils.py", line 3, in import wbuild File "/home/lgm/miniconda3/envs/drop_env/lib/python3.12/site-packages/wbuild/init.py", line 10, in from . import autolink File "/home/lgm/miniconda3/envs/drop_env/lib/python3.12/site-packages/wbuild/autolink.py", line 6, in from wbuild.utils import Config File "/home/lgm/miniconda3/envs/drop_env/lib/python3.12/site-packages/wbuild/utils.py", line 12, in from snakemake import get_argument_parser, parse_config, SNAKEFILE_CHOICES ImportError: cannot import name 'get_argument_parser' from 'snakemake' (/home/lgm/miniconda3/envs/drop_env/lib/python3.12/site-packages/snakemake/init.py) Iinstalled drop_env with miniconda on a virtual machine with CENTOS 7. When I type which snakemake and which python I have this answer: (drop_env) ➜ drop_d which snakemake ~/miniconda3/envs/drop_env/bin/snakemake (drop_env) ➜ drop_d which python
~/miniconda3/envs/drop_env/bin/python

Thanks

vyepez88 commented 5 months ago

Hi, can you try installing DROP using the yaml file?

In the case of mamba/conda troubles we recommend using the fixed DROP_.yaml installation file we make available on our public server. Install the current version and use the full path in the following command to install the conda environment drop_env

mamba env create -f DROP_1.3.3.yaml

TechLabLgm commented 5 months ago

Using yaml file it works, thank you very much. My doubt arose because I have three identical virtual machines and the procedure was finished correctly on the first virtual machine, while on the other two the message I reported appears. Anyway using the yalm file everything works and so the problem is solved. I am very grateful for the help

vyepez88 commented 5 months ago

great to hear!