0

I have developed a small package in my quest of studying Python that can be found here wanikani-notifier.

It has been some months now since I last pushed something to the repository but I recently came across a bug I wanted to fix. After a quick fix and a push, the "test" action that runs tox to validate my code now fails unexpectedly during the init phase. I had obviously never encountered such an issue before.

  Collecting python-pushsafer==0.4
  Downloading python-pushsafer-0.4.tar.gz (15 kB)
    ERROR: Command errored out with exit status 1:
     command: /home/runner/work/wanikani_notifier/wanikani_notifier/.tox/py/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-v6gorqgy/python-pushsafer_78e09e214b904de69a76a25ec309e37b/setup.py'"'"'; __file__='"'"'/tmp/pip-install-v6gorqgy/python-pushsafer_78e09e214b904de69a76a25ec309e37b/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-xkyrxe9m
         cwd: /tmp/pip-install-v6gorqgy/python-pushsafer_78e09e214b904de69a76a25ec309e37b/
    Complete output (1 lines):
    error in python-pushsafer setup command: use_2to3 is invalid.

I gathered this "use_2to3" error is related to the version of setuptools. However, I have not updated the version in my requirements file and it still points to 57.4.0.

Is there something I have configured wrong? How can I tackle this?

The full log can be found hereafter:

GLOB sdist-make: /home/runner/work/wanikani_notifier/wanikani_notifier/setup.py
py create: /home/runner/work/wanikani_notifier/wanikani_notifier/.tox/py
py installdeps: -r/home/runner/work/wanikani_notifier/wanikani_notifier/requirements/test.txt
ERROR: invocation failed (exit code 1), logfile: /home/runner/work/wanikani_notifier/wanikani_notifier/.tox/py/log/py-1.log
================================== log start ===================================
Requirement already satisfied: pip in ./.tox/py/lib/python3.8/site-packages (from -r /home/runner/work/wanikani_notifier/wanikani_notifier/requirements/prod.txt (line 1)) (21.2.4)
Collecting setuptools==57.4.0
  Downloading setuptools-57.4.0-py3-none-any.whl (819 kB)
Collecting Click==7.0
  Downloading Click-7.0-py2.py3-none-any.whl (81 kB)
Collecting urllib3==1.26.6
  Downloading urllib3-1.26.6-py2.py3-none-any.whl (138 kB)
Collecting wanikani-api==0.5.1
  Downloading wanikani_api-0.5.1-py2.py3-none-any.whl (13 kB)
Collecting python-pushsafer==0.4
  Downloading python-pushsafer-0.4.tar.gz (15 kB)
    ERROR: Command errored out with exit status 1:
     command: /home/runner/work/wanikani_notifier/wanikani_notifier/.tox/py/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-v6gorqgy/python-pushsafer_78e09e214b904de69a76a25ec309e37b/setup.py'"'"'; __file__='"'"'/tmp/pip-install-v6gorqgy/python-pushsafer_78e09e214b904de69a76a25ec309e37b/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-xkyrxe9m
         cwd: /tmp/pip-install-v6gorqgy/python-pushsafer_78e09e214b904de69a76a25ec309e37b/
    Complete output (1 lines):
    error in python-pushsafer setup command: use_2to3 is invalid.
    ----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/e7/f0/951014efae1637e78962194519b60aeb8f7997427d4313217fb224f62036/python-pushsafer-0.4.tar.gz#sha256=229534a58ba9921cc99991dd4a889ca4f4b39ec82df52b4b034db8287e8d2fc2 (from https://pypi.org/simple/python-pushsafer/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
ERROR: Could not find a version that satisfies the requirement python-pushsafer==0.4 (from versions: 0.2, 0.3, 0.4)
ERROR: No matching distribution found for python-pushsafer==0.4

=================================== log end ====================================
ERROR: could not install deps [-r/home/runner/work/wanikani_notifier/wanikani_notifier/requirements/test.txt]; v = InvocationError('/home/runner/work/wanikani_notifier/wanikani_notifier/.tox/py/bin/python -m pip install -r/home/runner/work/wanikani_notifier/wanikani_notifier/requirements/test.txt', 1)
___________________________________ summary ____________________________________
ERROR:   py: could not install deps [-r/home/runner/work/wanikani_notifier/wanikani_notifier/requirements/test.txt]; v = InvocationError('/home/runner/work/wanikani_notifier/wanikani_notifier/.tox/py/bin/python -m pip install -r/home/runner/work/wanikani_notifier/wanikani_notifier/requirements/test.txt', 1)
Error: Process completed with exit code 1.
  • https://stackoverflow.com/search?tab=newest&q=%22use_2to3%22 – phd Oct 03 '21 at 19:53
  • This package fails to install via pip python-pushsafer-0.4.tar.gz. The issue is not related to tox, but to that package. – Yeti Oct 03 '21 at 22:02

0 Answers0