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

setup.py: install fails with 'setuptools >= 58.0' #17

Closed
stanislavlevin opened this issue Sep 16, 2021 · 2 comments
Closed

setup.py: install fails with 'setuptools >= 58.0' #17

stanislavlevin opened this issue Sep 16, 2021 · 2 comments

Comments

@stanislavlevin
Copy link

This project has the option use_2to3 in setup.py, which support has been removed in setuptools since version 58.0.0 https://setuptools.readthedocs.io/en/latest/history.html#v58-0-0:

2086: Removed support for 2to3 during builds. Projects should port to a unified codebase or pin to an older version of Setuptools using PEP 518 build-requires.

The build fails with:

  • /usr/bin/python3 setup.py build
    /usr/lib64/python3/site-packages/setuptools/dist.py:718: UserWarning: Usage of dash-separated 'upload-dir' will not be supported in future versions. Please use the underscore name 'upload_dir' instead
    warnings.warn(
    error in parse_type setup command: use_2to3 is invalid.

According to docs https://docs.python.org/3/library/2to3.html#module-lib2to3 the whole lib2to3 is

Deprecated since version 3.10: Python 3.9 will switch to a PEG parser (see PEP 617), and Python 3.10 may include new language syntax that is not parsable by lib2to3’s LL(1) parser. The lib2to3 module may be removed from the standard library in a future Python version. Consider third-party alternatives such as LibCST or parso.

@jenisys
Copy link
Owner

jenisys commented Jan 18, 2022

FIXED.
INTEGRATED INTO: v0.6.0

@jenisys
Copy link
Owner

jenisys commented Jan 19, 2022

AFFECTED PLATFORMS:

  • Linux

HOW TO REPEAT:

$ pip install -U setuptools
$ pip install --no-binary :all: --force-reinstall parse-type
...
Complete output (1 lines):
  error in parse-type setup command: use_2to3 is invalid.

WORK-AROUND UNTIL FIXED:

$ pip install 'setuptools<58.0'
$ pip install --no-binary :all: --force-reinstall parse-type
...
Successfully installed parse-type-x.x.x ...

@jenisys jenisys changed the title build fails against setuptools 58+ setup.py: install fails with 'setuptools >= 58.0' Jan 19, 2022
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