Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Closed
TechLabLgm opened this issue Jan 18, 2024 · 3 comments
Closed

Comments

@TechLabLgm
Copy link

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
Copy link
Collaborator

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
Copy link
Author

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
Copy link
Collaborator

great to hear!

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants