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

install fails if setuptools >= 58 #332

Open
myourshaw opened this issue Sep 29, 2021 · 1 comment
Open

install fails if setuptools >= 58 #332

myourshaw opened this issue Sep 29, 2021 · 1 comment

Comments

@myourshaw
Copy link

pip3 install PyVCF (version 0.6.8) will fail when setuptools version is >=58. Instead PyVCF will install version 0.4.3, which fails to run with this error:
ImportError: cannot import name 'Reader' from 'parser' (/home/myourshaw/.local/lib/python3.9/lib-dynload/parser.cpython-39-x86_64-linux-gnu.so)

Python version is 3.9.7
`
pip3 install --upgrade PyVCF;

Collecting PyVCF
Downloading PyVCF-0.6.8.tar.gz (34 kB)
ERROR: Command errored out with exit status 1:
command: /home/myourshaw/.venv/dnanexus/bin/python3 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-nl16n6e2/pyvcf_8e753a9cb7b248d2b23cefa5ff04feb8/setup.py'"'"'; file='"'"'/tmp/pip-install-nl16n6e2/pyvcf_8e753a9cb7b248d2b23cefa5ff04feb8/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-d_w3yhiw
cwd: /tmp/pip-install-nl16n6e2/pyvcf_8e753a9cb7b248d2b23cefa5ff04feb8/
Complete output (1 lines):
error in PyVCF setup command: use_2to3 is invalid.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/20/b6/36bfb1760f6983788d916096193fc14c83cce512c7787c93380e09458c09/PyVCF-0.6.8.tar.gz#sha256=e9d872513d179d229ab61da47a33f42726e9613784d1cb2bac3f8e2642f6f9d9 (from https://pypi.org/simple/pyvcf/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading PyVCF-0.6.7.tar.gz (31 kB)
ERROR: Command errored out with exit status 1:
command: /home/myourshaw/.venv/dnanexus/bin/python3 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-nl16n6e2/pyvcf_d5e4c3e5adf04c4d9a808ae6dbee023c/setup.py'"'"'; file='"'"'/tmp/pip-install-nl16n6e2/pyvcf_d5e4c3e5adf04c4d9a808ae6dbee023c/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-1rmgoulv
cwd: /tmp/pip-install-nl16n6e2/pyvcf_d5e4c3e5adf04c4d9a808ae6dbee023c/
Complete output (1 lines):
error in PyVCF setup command: use_2to3 is invalid.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/64/1b/7c393d0cd5b1de2bb025d6ef45f71a013258214ae3564ede54adbd74ad00/PyVCF-0.6.7.tar.gz#sha256=998361f824f828f689e8e1043f795403c11e561d719cc85cdd17c3679fa9b4aa (from https://pypi.org/simple/pyvcf/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading PyVCF-0.6.6.tar.gz (30 kB)
ERROR: Command errored out with exit status 1:
command: /home/myourshaw/.venv/dnanexus/bin/python3 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-nl16n6e2/pyvcf_56bd71449dd1463e8d4bbb431c3596b3/setup.py'"'"'; file='"'"'/tmp/pip-install-nl16n6e2/pyvcf_56bd71449dd1463e8d4bbb431c3596b3/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-1bgqn8hl
cwd: /tmp/pip-install-nl16n6e2/pyvcf_56bd71449dd1463e8d4bbb431c3596b3/
Complete output (1 lines):
error in PyVCF setup command: use_2to3 is invalid.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/f7/b5/0c1763caa7502b71b43ef486211230fb6bfe30568b01594859150d5b2339/PyVCF-0.6.6.tar.gz#sha256=d0517b0ebd41a4064aa4cc6545617597d84ef7772c96713c170f39b68a997186 (from https://pypi.org/simple/pyvcf/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading PyVCF-0.6.5.tar.gz (30 kB)
ERROR: Command errored out with exit status 1:
command: /home/myourshaw/.venv/dnanexus/bin/python3 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-nl16n6e2/pyvcf_8093a21b8da84ca2b66a98ab35277981/setup.py'"'"'; file='"'"'/tmp/pip-install-nl16n6e2/pyvcf_8093a21b8da84ca2b66a98ab35277981/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-fgevzwdl
cwd: /tmp/pip-install-nl16n6e2/pyvcf_8093a21b8da84ca2b66a98ab35277981/
Complete output (1 lines):
error in PyVCF setup command: use_2to3 is invalid.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/10/a7/f97d71cf4b0a22a2adc55564b3dab6bf1a90ef6592ad2db0c5b8a58c5e0a/PyVCF-0.6.5.tar.gz#sha256=458b012fe69842acd49d87913f1eb068696c01b03aea7c04d6b8e14f13872c13 (from https://pypi.org/simple/pyvcf/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading PyVCF-0.6.4.tar.gz (29 kB)
ERROR: Command errored out with exit status 1:
command: /home/myourshaw/.venv/dnanexus/bin/python3 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-nl16n6e2/pyvcf_29ece4726a9944eca31b0cc9eb5bb8f6/setup.py'"'"'; file='"'"'/tmp/pip-install-nl16n6e2/pyvcf_29ece4726a9944eca31b0cc9eb5bb8f6/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-_zv8aoj3
cwd: /tmp/pip-install-nl16n6e2/pyvcf_29ece4726a9944eca31b0cc9eb5bb8f6/
Complete output (1 lines):
error in PyVCF setup command: use_2to3 is invalid.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/30/db/fd30981c363499c9b51687b7d06e891937c3136073b5771b2e30c0453aae/PyVCF-0.6.4.tar.gz#sha256=10aef49ed2a4de7a64d51d92dd30441d350b24619f328d879cbd86611031b18a (from https://pypi.org/simple/pyvcf/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading PyVCF-0.6.3.tar.gz (27 kB)
ERROR: Command errored out with exit status 1:
command: /home/myourshaw/.venv/dnanexus/bin/python3 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-nl16n6e2/pyvcf_784cb7c529e64bf2b1b675cc63f94301/setup.py'"'"'; file='"'"'/tmp/pip-install-nl16n6e2/pyvcf_784cb7c529e64bf2b1b675cc63f94301/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-w_wig34k
cwd: /tmp/pip-install-nl16n6e2/pyvcf_784cb7c529e64bf2b1b675cc63f94301/
Complete output (1 lines):
error in PyVCF setup command: use_2to3 is invalid.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/38/3a/a3b7a9b36cd2d8aedbe1335887c50441b942cb3e990def4b327f1ee21147/PyVCF-0.6.3.tar.gz#sha256=44b6f753472b2f9b2c5e3f08959d1f6532076fcf83223f3797256ac7b8ede60d (from https://pypi.org/simple/pyvcf/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading PyVCF-0.6.2.tar.gz (26 kB)
ERROR: Command errored out with exit status 1:
command: /home/myourshaw/.venv/dnanexus/bin/python3 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-nl16n6e2/pyvcf_a3d3fb04fa3d411d8a5d56cd1b549b19/setup.py'"'"'; file='"'"'/tmp/pip-install-nl16n6e2/pyvcf_a3d3fb04fa3d411d8a5d56cd1b549b19/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-a46cmorm
cwd: /tmp/pip-install-nl16n6e2/pyvcf_a3d3fb04fa3d411d8a5d56cd1b549b19/
Complete output (1 lines):
error in PyVCF setup command: use_2to3 is invalid.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/73/4b/2bbb1ee971de3d6b516ba4dc152027488fe6f15fc396620881750a9b51d0/PyVCF-0.6.2.tar.gz#sha256=aebd8dc67ea92d307976ae73ed0add8d9e1b6c7e09343decfa960e0e597f28b1 (from https://pypi.org/simple/pyvcf/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading PyVCF-0.6.1.tar.gz (26 kB)
ERROR: Command errored out with exit status 1:
command: /home/myourshaw/.venv/dnanexus/bin/python3 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-nl16n6e2/pyvcf_17bed027b0914176be707cd31d1fc385/setup.py'"'"'; file='"'"'/tmp/pip-install-nl16n6e2/pyvcf_17bed027b0914176be707cd31d1fc385/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-bmf9e3i8
cwd: /tmp/pip-install-nl16n6e2/pyvcf_17bed027b0914176be707cd31d1fc385/
Complete output (1 lines):
error in PyVCF setup command: use_2to3 is invalid.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/6f/49/e46405959069b27ee605f7646e7ec7d5c220e981a11fa8a76f28bb5dee17/PyVCF-0.6.1.tar.gz#sha256=41e0369cc7852011f4fb277e2b5282439715d6edde2ee9cdde0e1262e78b2389 (from https://pypi.org/simple/pyvcf/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading PyVCF-0.6.0.tar.gz (27 kB)
ERROR: Command errored out with exit status 1:
command: /home/myourshaw/.venv/dnanexus/bin/python3 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-nl16n6e2/pyvcf_180b617c9d7f4fde9d97a7ef7aba3510/setup.py'"'"'; file='"'"'/tmp/pip-install-nl16n6e2/pyvcf_180b617c9d7f4fde9d97a7ef7aba3510/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-d0xo61ur
cwd: /tmp/pip-install-nl16n6e2/pyvcf_180b617c9d7f4fde9d97a7ef7aba3510/
Complete output (1 lines):
error in PyVCF setup command: use_2to3 is invalid.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/4e/ae/b43f6a7dca99957ebee1d0944213a6a1490595e04aa4ad95fb25c69dbcd9/PyVCF-0.6.0.tar.gz#sha256=d9ec3bbedb64fa35c2648a9c41fdefaedd3912ff597a436e073d27aeccf5de7c (from https://pypi.org/simple/pyvcf/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading PyVCF-0.5.0.tar.gz (23 kB)
ERROR: Command errored out with exit status 1:
command: /home/myourshaw/.venv/dnanexus/bin/python3 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-nl16n6e2/pyvcf_d4708667383a4805837b729c0e754e46/setup.py'"'"'; file='"'"'/tmp/pip-install-nl16n6e2/pyvcf_d4708667383a4805837b729c0e754e46/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-gq7makn7
cwd: /tmp/pip-install-nl16n6e2/pyvcf_d4708667383a4805837b729c0e754e46/
Complete output (1 lines):
error in PyVCF setup command: use_2to3 is invalid.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/db/4c/b2c4f3f1eba4913dc531e0b5d27a1219f3edd767007f1a02f753207e1647/PyVCF-0.5.0.tar.gz#sha256=51cc9ffea4f1e9ae2095d41abd371afe4581b4c7203094f7647e7a2a071e50c9 (from https://pypi.org/simple/pyvcf/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading PyVCF-0.4.6.tar.gz (19 kB)
ERROR: Command errored out with exit status 1:
command: /home/myourshaw/.venv/dnanexus/bin/python3 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-nl16n6e2/pyvcf_dbca7ea0a9d64b5388858d37f892526a/setup.py'"'"'; file='"'"'/tmp/pip-install-nl16n6e2/pyvcf_dbca7ea0a9d64b5388858d37f892526a/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-6rgxcqx6
cwd: /tmp/pip-install-nl16n6e2/pyvcf_dbca7ea0a9d64b5388858d37f892526a/
Complete output (1 lines):
error in PyVCF setup command: use_2to3 is invalid.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/ca/25/bfe4a71b1f65d0bcd3e7353c26a35fce513bd8c0f5e1dfce9d42d2f37c27/PyVCF-0.4.6.tar.gz#sha256=6e41ba239b2644664bf4c64a2638ca4870afb144ff5891a1fd37ad2adad79e40 (from https://pypi.org/simple/pyvcf/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading PyVCF-0.4.5.tar.gz (19 kB)
ERROR: Command errored out with exit status 1:
command: /home/myourshaw/.venv/dnanexus/bin/python3 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-nl16n6e2/pyvcf_d2e138b2cb9042b78f728691c5a10899/setup.py'"'"'; file='"'"'/tmp/pip-install-nl16n6e2/pyvcf_d2e138b2cb9042b78f728691c5a10899/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-5d5pey31
cwd: /tmp/pip-install-nl16n6e2/pyvcf_d2e138b2cb9042b78f728691c5a10899/
Complete output (1 lines):
error in PyVCF setup command: use_2to3 is invalid.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/8f/c4/e1c71b3e00d2c2a5149933558e088e3a42a27b94620f47f5b2cb861642a8/PyVCF-0.4.5.tar.gz#sha256=4c7367d3a55d7ba8c404241b12cbdf011b5fa7a95034a1c779489523292a2d47 (from https://pypi.org/simple/pyvcf/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading PyVCF-0.4.4.tar.gz (19 kB)
ERROR: Command errored out with exit status 1:
command: /home/myourshaw/.venv/dnanexus/bin/python3 -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-nl16n6e2/pyvcf_6cb5c5e7564741f39a6194069b28de6d/setup.py'"'"'; file='"'"'/tmp/pip-install-nl16n6e2/pyvcf_6cb5c5e7564741f39a6194069b28de6d/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-voul_7t5
cwd: /tmp/pip-install-nl16n6e2/pyvcf_6cb5c5e7564741f39a6194069b28de6d/
Complete output (1 lines):
error in PyVCF setup command: use_2to3 is invalid.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/e3/38/e1b52283c76ef5ef2fc4a5e005bfd308ff14be5483f09b2e5268bd06ae9d/PyVCF-0.4.4.tar.gz#sha256=4576d8a46958fc51a0c100ee0c8aa768e6d8a7fb84706a97a1fbdebd97f49e70 (from https://pypi.org/simple/pyvcf/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
Downloading PyVCF-0.4.3.tar.gz (17 kB)
Building wheels for collected packages: PyVCF
Building wheel for PyVCF (setup.py) ... done
Created wheel for PyVCF: filename=PyVCF-0.4.3-py3-none-any.whl size=16158 sha256=cfa327118633b62205e0d7e957d360c04caa64f9716e25bc3ec6d1e6055a6a97
Stored in directory: /home/myourshaw/.cache/pip/wheels/f9/3f/f2/4da50c1e0c57afb2b17589433e794cc9a3b688164a69e3b395
Successfully built PyVCF
Installing collected packages: PyVCF
Successfully installed PyVCF-0.4.3
`

@ChrisMoth
Copy link

In looking at some of the code, I sense it is Python2 still:

File "/home/mothcw/Downloads/PyVCF-master/vcf/parser.py", line 644, in Writer
counts = dict((v,k) for k,v in field_counts.iteritems())
AttributeError: 'dict' object has no attribute 'iteritems'

I hope the maintainers might move the entire thing to Python3 and call it Version 0.7.0

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