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

Snakemake issue with asyncio / python3.11 #497

Open
abel-betraoui opened this issue Nov 7, 2022 · 4 comments
Open

Snakemake issue with asyncio / python3.11 #497

abel-betraoui opened this issue Nov 7, 2022 · 4 comments

Comments

@abel-betraoui
Copy link

Hi all,

Snakemake is encountering this issue snakemake/snakemake#1952 which leads to this error when running pangolin:

****
Pangolin running in usher mode.
****
Maximum ambiguity allowed is 0.3.
****
Query file:     /pangolin/data/SRR14855875.consensus.fa
****
Data files found:
usher_pb:       /opt/conda/envs/pangolin/lib/python3.11/site-packages/pangolin_data/data/lineageTree.pb
****
Traceback (most recent call last):
  File "/opt/conda/envs/pangolin/lib/python3.11/site-packages/snakemake/__init__.py", line 699, in snakemake
    success = workflow.execute(
              ^^^^^^^^^^^^^^^^^
  File "/opt/conda/envs/pangolin/lib/python3.11/site-packages/snakemake/workflow.py", line 960, in execute
    self.scheduler = JobScheduler(
                     ^^^^^^^^^^^^^
  File "/opt/conda/envs/pangolin/lib/python3.11/site-packages/snakemake/scheduler.py", line 98, in __init__
    from ratelimiter import RateLimiter
  File "/opt/conda/envs/pangolin/lib/python3.11/site-packages/ratelimiter.py", line 36, in <module>
    class RateLimiter(object):
  File "/opt/conda/envs/pangolin/lib/python3.11/site-packages/ratelimiter.py", line 127, in RateLimiter
    __aexit__ = asyncio.coroutine(__exit__)
                ^^^^^^^^^^^^^^^^^
AttributeError: module 'asyncio' has no attribute 'coroutine'

The problem is only encountered with python3.11 but this can be a problem when using the pangolin docker image as there is no constraint on the python version when using base image continuumio/miniconda3:4.9.2-alpine.

Cheers

@kapsakcj
Copy link

kapsakcj commented Nov 9, 2022

I maintain a separate pangolin docker image here if you'd like to use it. It contains python 3.8.13 in the conda/micromamba environment

https://github.com/StaPH-B/docker-builds/tree/master/pangolin/4.1.3

https://hub.docker.com/r/staphb/pangolin/tags

@wm75
Copy link
Contributor

wm75 commented Nov 10, 2022

Thanks for the heads-up @abel-betraoui. With the pangolin docker image you mean the biocontainers ones at https://quay.io/repository/biocontainers/pangolin?tab=history? These are built from bioconda package builds of https://github.com/bioconda/bioconda-recipes/tree/master/recipes/pangolin and should currently use Python 3.8, too.

@abel-betraoui
Copy link
Author

abel-betraoui commented Nov 10, 2022

I was thinking of the Dockerhub ones, built using the Dockerfile in this very repo.
It starts with :

FROM continuumio/miniconda3:4.9.2-alpine

And even though I couln't find how the base image continuumio/miniconda3:4.9.2-alpine is being built, I noticed a python version upgrade recently in it from 3.10.6 on the 2nd of november to 3.11.0 on the 7th of november

@wm75
Copy link
Contributor

wm75 commented Nov 10, 2022

Ah, I see. The biocontainers images have a rather big community and user-base so, personally, I would always prefer these.
But I agree that if the repo here has a Dockerfile it should also produce a working image.

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

3 participants