StackStorm/st2

st2client could not be installed when setuptools>=50.0.0

Open

#5.036 aberto em 7 de set. de 2020

Ver no GitHub
 (9 comments) (0 reactions) (0 assignees)Python (740 forks)batch import
buggood first issuehelp wanted

Métricas do repositório

Stars
 (5.794 stars)
Métricas de merge de PR
 (Nenhuma PRs mesclada em 30d)

Description

SUMMARY

Provide a quick summary of your bug report.

STACKSTORM VERSION

not relevant

OS, environment, install method

not relevant

Steps to reproduce the problem

  1. run python image -> docker run --rm -it --entrypoint=sh python:3.7
  2. install setuptools>=50.0.0 pip install setuptools>=50.0.0
  3. try to install st2client in the container pip install st2client==3.2.0

however, when setuptools<50.0.0 was installed, st2client can be installed.

Expected Results

exceted st2client can be installed.

Actual Results

error occurs when installing

# pip install st2client==3.2.0
Collecting st2client==3.2.0
  Downloading st2client-3.2.0.tar.gz (104 kB)
     |████████████████████████████████| 104 kB 134 kB/s
    ERROR: Command errored out with exit status 1:
     command: /usr/local/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-f4z91qt3/st2client/setup.py'"'"'; __file__='"'"'/tmp/pip-install-f4z91qt3/st2client/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-o1xxfeb4
         cwd: /tmp/pip-install-f4z91qt3/st2client/
    Complete output (17 lines):
    /usr/local/lib/python3.7/site-packages/_distutils_hack/__init__.py:30: UserWarning: Setuptools is replacing distutils.
      warnings.warn("Setuptools is replacing distutils.")
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/pip-install-f4z91qt3/st2client/setup.py", line 63, in <module>
        'st2 = st2client.shell:main'
      File "/usr/local/lib/python3.7/site-packages/setuptools/__init__.py", line 152, in setup
        _install_setup_requires(attrs)
      File "/usr/local/lib/python3.7/site-packages/setuptools/__init__.py", line 145, in _install_setup_requires
        dist.parse_config_files(ignore_option_errors=True)
      File "/usr/local/lib/python3.7/site-packages/setuptools/dist.py", line 665, in parse_config_files
        self._parse_config_files(filenames=filenames)
      File "/usr/local/lib/python3.7/site-packages/setuptools/dist.py", line 572, in _parse_config_files
        filenames = self.find_config_files()
      File "/usr/local/lib/python3.7/site-packages/setuptools/_distutils/dist.py", line 353, in find_config_files
        sys_dir = os.path.dirname(sys.modules['distutils'].__file__)
    KeyError: 'distutils'
    ----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

Guia do colaborador