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

ImportError: cannot import name 'Feature' from 'setuptools' #120

Closed
fengweiyuan opened this issue Jan 6, 2021 · 4 comments
Closed

ImportError: cannot import name 'Feature' from 'setuptools' #120

fengweiyuan opened this issue Jan 6, 2021 · 4 comments
Assignees
Labels
python Pull requests that update Python code review Tagged for review.

Comments

@fengweiyuan
Copy link

ERROR: Command errored out with exit status 1:
 command: /Users/fwy/env/ksdb/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/p3/88pf4865713bvhx1g0qq07980000gn/T/pip-install-n_c6hrko/markupsafe_f7a88688051645a9b3bb18103afea1ba/setup.py'"'"'; __file__='"'"'/private/var/folders/p3/88pf4865713bvhx1g0qq07980000gn/T/pip-install-n_c6hrko/markupsafe_f7a88688051645a9b3bb18103afea1ba/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 /private/var/folders/p3/88pf4865713bvhx1g0qq07980000gn/T/pip-pip-egg-info-mabo4a6b
     cwd: /private/var/folders/p3/88pf4865713bvhx1g0qq07980000gn/T/pip-install-n_c6hrko/markupsafe_f7a88688051645a9b3bb18103afea1ba/
Complete output (5 lines):
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/private/var/folders/p3/88pf4865713bvhx1g0qq07980000gn/T/pip-install-n_c6hrko/markupsafe_f7a88688051645a9b3bb18103afea1ba/setup.py", line 6, in <module>
    from setuptools import setup, Extension, Feature
ImportError: cannot import name 'Feature' from 'setuptools' (/Users/fwy/env/ksdb/lib/python3.8/site-packages/setuptools/__init__.py)
----------------------------------------

ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

@priithaamer
Copy link

Temporary workaround was to install

pip3 install setuptools==45

@dougch
Copy link

dougch commented May 4, 2021

bumping MarkupSafe to version 1.1 in requirements.txt also works, PR?

@pashminacameron
Copy link

Same here, MarkupSafe=1.1 works.
I also needed to pip install python-magic-bin==0.4.14 for a successful server start (got a ImportError: failed to find libmagic. Check your installation upon using python run.py).

Working environment.yml:

name: flame-env
channels:
  - defaults
dependencies:
  - pip<20.3
  - python==3.7.7
  - pip:
    - cachetools==3.0.0
    - click==6.7
    - Flask==1.0
    - itsdangerous==0.24
    - Jinja2==2.10
    - MarkupSafe==1.1.0
    - protobuf==3.6.1
    - python-magic==0.4.15
    - six==1.12.0
    - Werkzeug==0.15.3
    - nflxprofile==1.4.1
    - python-magic-bin==0.4.14

@spiermar spiermar self-assigned this Oct 14, 2021
@spiermar spiermar added review Tagged for review. python Pull requests that update Python code labels Oct 14, 2021
@spiermar
Copy link
Contributor

Fixed on 44506f9.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
python Pull requests that update Python code review Tagged for review.
Projects
None yet
Development

No branches or pull requests

5 participants