Im running python container with this command
docker run -p 8888:8888 --name jupyter_notebook -v /home/Data/jupyter_project/:/home/jovyan/work/jupyter_project jupyter/scipy-notebook .
When i tried to install my file requirements.txt on the project i got the error below.
Please who can help me to solve the problem.
ERROR: Command errored out with exit status 1:
command: /opt/conda/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-gei1w7ax/psycopg2_395c58e14f844125b95c77ccccec309d/setup.py'"'"'; __file__='"'"'/tmp/pip-install-gei1w7ax/psycopg2_395c58e14f844125b95c77ccccec309d/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-bkenr2u2
cwd: /tmp/pip-install-gei1w7ax/psycopg2_395c58e14f844125b95c77ccccec309d/
Complete output (14 lines):
running egg_info
creating /tmp/pip-pip-egg-info-bkenr2u2/psycopg2.egg-info
writing /tmp/pip-pip-egg-info-bkenr2u2/psycopg2.egg-info/PKG-INFO
writing dependency_links to /tmp/pip-pip-egg-info-bkenr2u2/psycopg2.egg-info/dependency_links.txt
writing top-level names to /tmp/pip-pip-egg-info-bkenr2u2/psycopg2.egg-info/top_level.txt
writing manifest file '/tmp/pip-pip-egg-info-bkenr2u2/psycopg2.egg-info/SOURCES.txt'
Error: pg_config executable not found.
Please add the directory containing pg_config to the PATH
or specify the full executable path with the option:
python setup.py build_ext --pg-config /path/to/pg_config build ...
or with the pg_config option in 'setup.cfg'.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/dd/47/000b405d73ca22980684fd7bd3318690cc03cfa3b2ae1c5b7fff8050b28a/psycopg2-2.7.3.2.tar.gz#sha256=5c3213be557d0468f9df8fe2487eaf2990d9799202c5ff5cb8d394d09fad9b2a (from https://pypi.org/simple/psycopg2/). 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 psycopg2==2.7.3.2 (from versions: 2.0.10, 2.0.11, 2.0.12, 2.0.13, 2.0.14, 2.2.0, 2.2.1, 2.2.2, 2.3.0, 2.3.1, 2.3.2, 2.4, 2.4.1, 2.4.2, 2.4.3, 2.4.4, 2.4.5, 2.4.6, 2.5, 2.5.1, 2.5.2, 2.5.3, 2.5.4, 2.5.5, 2.6, 2.6.1, 2.6.2, 2.7, 2.7.1, 2.7.2, 2.7.3, 2.7.3.1, 2.7.3.2, 2.7.4, 2.7.5, 2.7.6, 2.7.6.1, 2.7.7, 2.8, 2.8.1, 2.8.2, 2.8.3, 2.8.4, 2.8.5, 2.8.6, 2.9, 2.9.1)
ERROR: No matching distribution found for psycopg2==2.7.3.2
Note: you may need to restart the kernel to use updated packages.
edit
WARNING: Discarding https://files.pythonhosted.org/packages/19/79/35c7596bab4456f3610c12ec542a94d51c6781ced587d1d85127210b879b/psycopg2-2.0.10.tar.gz#sha256=e40cc04b43849085725076ae134bfef9e3b087f6dd7c964aeeb930e2f0bc14ab (from https://pypi.org/simple/psycopg2/). 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 psycopg2 (from versions: 2.0.10, 2.0.11, 2.0.12, 2.0.13, 2.0.14, 2.2.0, 2.2.1, 2.2.2, 2.3.0, 2.3.1, 2.3.2, 2.4, 2.4.1, 2.4.2, 2.4.3, 2.4.4, 2.4.5, 2.4.6, 2.5, 2.5.1, 2.5.2, 2.5.3, 2.5.4, 2.5.5, 2.6, 2.6.1, 2.6.2, 2.7, 2.7.1, 2.7.2, 2.7.3, 2.7.3.1, 2.7.3.2, 2.7.4, 2.7.5, 2.7.6, 2.7.6.1, 2.7.7, 2.8, 2.8.1, 2.8.2, 2.8.3, 2.8.4, 2.8.5, 2.8.6, 2.9, 2.9.1)
ERROR: No matching distribution found for psycopg2
Note: you may need to restart the kernel to use updated packages.```
Grateful
try installing this package instead of psycopg2 when using with docker.
pip install psycopg2-binary
Related
I have my website deployed in heroku which uses psycopg2 and when I upgrade version 2.8.6 --> 2.9.1 and greater then it throws an error that database connection isn't set to UTC.
And when I tried to install packages from my requirements.txt which consist psycopg2==2.8.6 (using python virtualenv in windows) then it throws following error
Using cached psycopg2-2.8.6.tar.gz (383 kB)
ERROR: Command errored out with exit status 1:
command: 'A:\Projects\django\tmp_env\Scripts\python.exe' -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\Amar K\\AppData\\Local\\Temp\\pip-install-ss0ajkyw\\psycopg2_60877ad816f94182b98212026f2b8d09\\setup.py'"'"'; __file__='"'"'C:\\Users\\Amar K\\AppData\\Local\\Temp\\pip-install-ss0ajkyw\\psycopg2_60877ad816f94182b98212026f2b8d09\\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 'C:\Users\Amar K\AppData\Local\Temp\pip-pip-egg-info-pwtcfhhf'
cwd: C:\Users\Amar K\AppData\Local\Temp\pip-install-ss0ajkyw\psycopg2_60877ad816f94182b98212026f2b8d09\
Complete output (23 lines):
running egg_info
creating C:\Users\Amar K\AppData\Local\Temp\pip-pip-egg-info-pwtcfhhf\psycopg2.egg-info
writing C:\Users\Amar K\AppData\Local\Temp\pip-pip-egg-info-pwtcfhhf\psycopg2.egg-info\PKG-INFO
writing dependency_links to C:\Users\Amar K\AppData\Local\Temp\pip-pip-egg-info-pwtcfhhf\psycopg2.egg-info\dependency_links.txt
writing top-level names to C:\Users\Amar K\AppData\Local\Temp\pip-pip-egg-info-pwtcfhhf\psycopg2.egg-info\top_level.txt
writing manifest file 'C:\Users\Amar K\AppData\Local\Temp\pip-pip-egg-info-pwtcfhhf\psycopg2.egg-info\SOURCES.txt'
Error: pg_config executable not found.
pg_config is required to build psycopg2 from source. Please add the directory
containing pg_config to the $PATH or specify the full executable path with the
option:
python setup.py build_ext --pg-config /path/to/pg_config build ...
For further information please check the 'doc/src/install.rst' file (also at
<https://www.psycopg.org/docs/install.html>).
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/fd/ae/98cb7a0cbb1d748ee547b058b14604bd0e9bf285a8e0cc5d148f8a8a952e/psycopg2-2.8.6.tar.gz#sha256=fb23f6c71107c37fd667cb4ea363ddeb936b348bbd6449278eb92c189699f543 (from https://pypi.org/simple/psycopg2/) (requires-python:>=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*). 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 psycopg2==2.8.6 (from versions: 2.0.10, 2.0.11, 2.0.12, 2.0.13, 2.0.14, 2.2.0, 2.2.1, 2.2.2, 2.3.0, 2.3.1, 2.3.2, 2.4, 2.4.1, 2.4.2, 2.4.3, 2.4.4, 2.4.5, 2.4.6, 2.5, 2.5.1, 2.5.2, 2.5.3, 2.5.4, 2.5.5, 2.6, 2.6.1, 2.6.2, 2.7, 2.7.1, 2.7.2, 2.7.3, 2.7.3.1, 2.7.3.2, 2.7.4, 2.7.5, 2.7.6, 2.7.6.1, 2.7.7, 2.8, 2.8.1, 2.8.2, 2.8.3, 2.8.4, 2.8.5, 2.8.6, 2.9, 2.9.1, 2.9.2, 2.9.3, 2.9.4, 2.9.5)ERROR: No matching distribution found for psycopg2==2.8.6
my requirements.txt
asgiref==3.3.4
autopep8==2.0.1
certifi==2020.12.5
cffi==1.15.1
chardet==3.0.4
charset-normalizer==2.0.12
click==8.0.1
cloudscraper==1.2.58
colorama==0.4.4
cryptography==3.4.7
defusedxml==0.7.1
diff-match-patch==20200713
dj-database-url==0.5.0
Django==3.0.7
django-environ==0.9.0
django-heroku==0.3.1
django-import-export==2.7.1
et-xmlfile==1.1.0
flake8==6.0.0
gingerit==0.8.2
googletrans==3.1.0a0
gunicorn==20.1.0
h11==0.9.0
h2==3.2.0
hpack==3.0.0
hstspreload==2020.12.22
httpcore==0.9.1
httpx==0.13.3
hyperframe==5.2.0
idna==2.10
joblib==1.1.1
language-tool-python==2.5.2
MarkupPy==1.14
mccabe==0.7.0
Naked==0.1.31
nltk==3.6.3
numpy==1.24.1
oauthlib==3.1.1
odfpy==1.4.1
openpyxl==3.0.10
Pillow==8.4.0
psycopg2==2.8.6
pybase64==1.2.0
pycodestyle==2.10.0
pycparser==2.20
pycryptodome==3.11.0
pyflakes==3.0.1
PyJWT==2.1.0
pyparsing==3.0.7
pytesseract==0.3.8
python3-openid==3.2.0
pytz==2021.1
PyYAML==6.0
rake-nltk==1.0.6
regex==2021.9.24
requests==2.27.1
requests-oauthlib==1.3.0
requests-toolbelt==0.9.1
rfc3986==1.4.0
scikit-learn==1.2.0
scipy==1.9.3
shellescape==3.8.1
six==1.16.0
sniffio==1.2.0
social-auth-app-django==4.0.0
social-auth-core==4.1.0
SpeechRecognition==3.8.1
sqlparse==0.4.1
tablib==3.3.0
threadpoolctl==3.0.0
tomli==2.0.1
tqdm==4.60.0
urllib3==1.25.11
whitenoise==5.2.0
xlrd==2.0.1
xlwt==1.3.0
I am trying to find solution for this problem that I have mentioned & I did not find solution for this anywhere(there is solution but only for linux os) or if there is then can u share a link.
I've been working on this over a week now, and the version problems just seem endless. I've downloaded a complex Django app, which has multiple install scripts. It is very complex.
I got an error that needed to be fixed by deleting Pipfile.lock, then I got some "missing module" errors and I manually did:
pip3 install importlib_metadata
pip3 install ConfigParser
but now I try:
pipenv lock
I get absolutely endless error messages, a small part of which looks like:
ERROR:pip.subprocessor:Command errored out with exit status 1:
command: /home/ec2-user/.local/share/virtualenvs/blueflow-c7ciKYpf/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pipenv-233zg4_c-build/psycopg2_a87c46885ac64bcd839843d942c021c6/setup.py'"'"'; __file__='"'"'/tmp/pipenv-233zg4_c-build/psycopg2_a87c46885ac64bcd839843d942c021c6/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'"'"'))' --no-user-cfg egg_info --egg-base /tmp/pip-pip-egg-info-t04x5e3y
cwd: /tmp/pipenv-233zg4_c-build/psycopg2_a87c46885ac64bcd839843d942c021c6/
Complete output (6 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pipenv-233zg4_c-build/psycopg2_a87c46885ac64bcd839843d942c021c6/setup.py", line 225
except Warning, w:
^
SyntaxError: invalid syntax
----------------------------------------
ERROR:pip.subprocessor:Command errored out with exit status 1:
command: /home/ec2-user/.local/share/virtualenvs/blueflow-c7ciKYpf/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pipenv-233zg4_c-build/psycopg2_4e8ce76ba6cc49a19dc4f3ec22a582aa/setup.py'"'"'; __file__='"'"'/tmp/pipenv-233zg4_c-build/psycopg2_4e8ce76ba6cc49a19dc4f3ec22a582aa/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'"'"'))' --no-user-cfg egg_info --egg-base /tmp/pip-pip-egg-info-liszsbkl
cwd: /tmp/pipenv-233zg4_c-build/psycopg2_4e8ce76ba6cc49a19dc4f3ec22a582aa/
Complete output (5 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pipenv-233zg4_c-build/psycopg2_4e8ce76ba6cc49a19dc4f3ec22a582aa/setup.py", line 50, in <module>
import ConfigParser
ModuleNotFoundError: No module named 'ConfigParser'
----------------------------------------
CRITICAL:pipenv.patched.notpip._internal.resolution.resolvelib.factory:Could not find a version that satisfies the requirement psycopg2 (from versions: 2.0.10, 2.0.11, 2.0.12, 2.0.13, 2.0.14, 2.2.0, 2.2.1, 2.2.2, 2.3.0, 2.3.1, 2.3.2, 2.4, 2.4.1, 2.4.2, 2.4.3, 2.4.4, 2.4.5, 2.4.6, 2.5, 2.5.1, 2.5.2, 2.5.3, 2.5.4, 2.5.5, 2.6, 2.6.1, 2.6.2, 2.7, 2.7.1, 2.7.2, 2.7.3, 2.7.3.1, 2.7.3.2, 2.7.4, 2.7.5, 2.7.6, 2.7.6.1, 2.7.7, 2.8, 2.8.1, 2.8.2, 2.8.3, 2.8.4, 2.8.5, 2.8.6, 2.9, 2.9.1, 2.9.2, 2.9.3)
[ResolutionFailure]: File "/usr/local/lib/python3.6/site-packages/pipenv/resolver.py", line 743, in _main
[ResolutionFailure]: resolve_packages(pre, clear, verbose, system, write, requirements_dir, packages, dev)
[ResolutionFailure]: File "/usr/local/lib/python3.6/site-packages/pipenv/resolver.py", line 711, in resolve_packages
[ResolutionFailure]: requirements_dir=requirements_dir,
[ResolutionFailure]: File "/usr/local/lib/python3.6/site-packages/pipenv/resolver.py", line 693, in resolve
[ResolutionFailure]: req_dir=requirements_dir
[ResolutionFailure]: File "/usr/local/lib/python3.6/site-packages/pipenv/utils.py", line 1385, in resolve_deps
[ResolutionFailure]: req_dir=req_dir,
[ResolutionFailure]: File "/usr/local/lib/python3.6/site-packages/pipenv/utils.py", line 1106, in actually_resolve_deps
[ResolutionFailure]: resolver.resolve()
[ResolutionFailure]: File "/usr/local/lib/python3.6/site-packages/pipenv/utils.py", line 884, in resolve
[ResolutionFailure]: raise ResolutionFailure(message=str(e))
[pipenv.exceptions.ResolutionFailure]: Warning: Your dependencies could not be resolved. You likely have a mismatch in your sub-dependencies.
You can use $ pipenv install --skip-lock to bypass this mechanism, then run $ pipenv graph to inspect the situation.
Hint: try $ pipenv lock --pre if it is a pre-release dependency.
ERROR: No matching distribution found for psycopg2
but the heart of it seems to be:
ERROR: No matching distribution found for psycopg2
I'm trying to figure out how to install this, but I'm also curious if anyone has some meta level comment that might help resolve all of these errors.
I should add, I can do this:
pip3 install psycopg2-binary
which succeeds, but then when I do this:
pipenv lock
I still get:
ERROR: No matching distribution found for psycopg2
I also see this line:
"Defaulting to user installation because normal site-packages is not writeable"
If I knew where the normal site-packages was, I would make it writeable, but I have no idea.
If I try:
pip3 install psycopg2
I get:
Error: pg_config executable not found.
And also:
WARNING: Discarding https://files.pythonhosted.org/packages/19/79/35c7596bab4456f3610c12ec542a94d51c6781ced587d1d85127210b879b/psycopg2-2.0.10.tar.gz#sha256=e40cc04b43849085725076ae134bfef9e3b087f6dd7c964aeeb930e2f0bc14ab (from https://pypi.org/simple/psycopg2/). 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 psycopg2 (from versions: 2.0.10, 2.0.11, 2.0.12, 2.0.13, 2.0.14, 2.2.0, 2.2.1, 2.2.2, 2.3.0, 2.3.1, 2.3.2, 2.4, 2.4.1, 2.4.2, 2.4.3, 2.4.4, 2.4.5, 2.4.6, 2.5, 2.5.1, 2.5.2, 2.5.3, 2.5.4, 2.5.5, 2.6, 2.6.1, 2.6.2, 2.7, 2.7.1, 2.7.2, 2.7.3, 2.7.3.1, 2.7.3.2, 2.7.4, 2.7.5, 2.7.6, 2.7.6.1, 2.7.7, 2.8, 2.8.1, 2.8.2, 2.8.3, 2.8.4, 2.8.5, 2.8.6, 2.9, 2.9.1, 2.9.2, 2.9.3)
ERROR: No matching distribution found for psycopg2
I cannot afford to spend another week on this. I wonder if there is some way to break through and get everything working. Is there truly no way to get Python to do more of the work of figuring out what dependencies need to be installed?
When I try to run the code provided in a paper, it has the following errors related to CVXPY:
(bayesrace) C:\Users\Lenovo\bayesrace>pip install -e .
Obtaining file:///C:/Users/Lenovo/bayesrace
Collecting pandas==1.0.3
Using cached pandas-1.0.3-cp36-cp36m-win_amd64.whl (8.7 MB)
Collecting cvxpy==1.0.15
Using cached cvxpy-1.0.15.tar.gz (915 kB)
ERROR: Command errored out with exit status 1:
command: 'D:\Anaconda\envs\bayesrace\python.exe' -c 'import io, os, sys, setuptools,
tokenize; sys.argv[0] = '"'"'C:\Users\Lenovo\AppData\Local\Temp\pip-install-hpu8en1_\cvxpy_9e73400b3c3d4e82b6ff31bd1122b730\setup.py'"'"';file='"'"'C:\Users\Lenovo\AppData\Local\Temp\pip-install-hpu8en1_\cvxpy_9e73400b3c3d4e82b6ff31bd1122b730\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 'C:\Users\Lenovo\AppData\Local\Temp\pip-pip-egg-info-hpjhbaju'cwd: C:\Users\Lenovo\AppData\Local\Temp\pip-install-hpu8en1_\cvxpy_9e73400b3c3d4e82b6ff31bd1122b730
Complete output (1 lines):
error in cvxpy setup command: use_2to3 is invalid.
WARNING: Discarding https://files.pythonhosted.org/packages/ab/6f/bcab45a432befe375f056ea31a7cc9c7468d07922768cb63c3dec5733afa/cvxpy-1.0.15.tar.gz#sha256=dff246a3fa03fe5c815f290825345a6ad5ff49df5e1882f123e632a4217bbcd1 (from https://pypi.org/simple/cvxpy/).
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 cvxpy==1.0.15 (from bayes-race) (from versions: 0.1, 0.2, 0.2.1, 0.2.2, 0.2.3, 0.2.4, 0.2.5, 0.2.6, 0.2.7, 0.2.9, 0.2.10, 0.2.11, 0.2.12, 0.2.13, 0.2.14, 0.2.15, 0.2.16, 0.2.17, 0.2.18, 0.2.19, 0.2.20, 0.2.21, 0.2.22, 0.2.23, 0.2.24, 0.2.25, 0.2.26, 0.2.27, 0.2.28, 0.3.0, 0.3.1, 0.3.3, 0.3.4, 0.3.5, 0.3.6, 0.3.7, 0.3.8, 0.3.9, 0.4.0, 0.4.1, 0.4.2, 0.4.3, 0.4.4, 0.4.5, 0.4.6, 0.4.8, 0.4.9, 0.4.10, 0.4.11, 1.0.2, 1.0.3, 1.0.4, 1.0.5, 1.0.6, 1.0.8, 1.0.9, 1.0.10, 1.0.11, 1.0.12, 1.0.13, 1.0.14, 1.0.15, 1.0.16, 1.0.17, 1.0.18, 1.0.19, 1.0.20, 1.0.21, 1.0.22, 1.0.23, 1.0.24, 1.0.25, 1.0.26, 1.0.27, 1.0.28, 1.0.29, 1.0.31, 1.1.0a0, 1.1.0a1, 1.1.0a2, 1.1.0a3, 1.1.0a4, 1.1.0, 1.1.1, 1.1.2, 1.1.3, 1.1.4, 1.1.5, 1.1.6, 1.1.7, 1.1.8, 1.1.9, 1.1.10, 1.1.11, 1.1.12, 1.1.13, 1.1.14, 1.1.15, 1.1.16, 1.1.17, 1.1.18)
ERROR: No matching distribution found for cvxpy==1.0.15
To Reproduce:
You can find the code for this paper here: https://github.com/jainachin/bayesrace
And I am running the code in the installation section on this page.
When I run the first 4 lines of code, it has no errors, the first 4 lines of code is:
conda create --name bayesrace python=3.6
conda activate bayesrace
git clone https://github.com/jainachin/bayesrace.git
cd bayesrace/
But when I try to run the 5th line of code, that is (pip install -e .), the above errors occurred.
You can also find the bugs/errors image here:
I am using Windows 11.
use_2to3 has been removed from setuptools 58.0 and newer.
However, newer versions (1.1+) of cvxpy don't use the flag.
Primarily, try using a newer version of cvxpy.
If that fails, downgrade your setuptools to a version less than 58.0.
I used pip to install Kivy 1.10.0 (Yes! I need this version, no more, no less). But when I run pip install kivy==1.10.0, I got this:
C:\Users\FlopffyGrape> pip install kivy==1.10.0
Collecting kivy==1.10.0
Using cached Kivy-1.10.0.tar.gz (24.3 MB)
Preparing metadata (setup.py) ... error
ERROR: Command errored out with exit status 1:
command: 'C:\Users\FlopffyGrape\AppData\Local\Programs\Python\Python39\python.exe' -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\FlopffyGrape\\AppData\\Local\\Temp\\pip-install-iiwz5ycz\\kivy_349a20b557a341848792819dc6f37ede\\setup.py'"'"'; __file__='"'"'C:\\Users\\FlopffyGrape\\AppData\\Local\\Temp\\pip-install-iiwz5ycz\\kivy_349a20b557a341848792819dc6f37ede\\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 'C:\Users\FlopffyGrape\AppData\Local\Temp\pip-pip-egg-info-fyg82ilx'
cwd: C:\Users\FlopffyGrape\AppData\Local\Temp\pip-install-iiwz5ycz\kivy_349a20b557a341848792819dc6f37ede\
Complete output (14 lines):
C:\Users\FlopffyGrape\AppData\Local\Temp\pip-install-iiwz5ycz\kivy_349a20b557a341848792819dc6f37ede\setup.py:69: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
MIN_CYTHON_VERSION = LooseVersion(MIN_CYTHON_STRING)
C:\Users\FlopffyGrape\AppData\Local\Temp\pip-install-iiwz5ycz\kivy_349a20b557a341848792819dc6f37ede\setup.py:71: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
MAX_CYTHON_VERSION = LooseVersion(MAX_CYTHON_STRING)
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\FlopffyGrape\AppData\Local\Temp\pip-install-iiwz5ycz\kivy_349a20b557a341848792819dc6f37ede\setup.py", line 219, in <module>
from Cython.Distutils import build_ext
ModuleNotFoundError: No module named 'Cython'
Using distutils
Cython is missing, it's required for compiling kivy !
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/8c/49/5c22589099f9b7fd106502ee6634a6675e634d7553fede141a7606e6a92d/Kivy-1.10.0.tar.gz#sha256=28c180fd5e4538858f0d2b3dde53c123d3a898d3ac7fba512bf3b83d0dfc248d (from https://pypi.org/simple/kivy/). 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 kivy==1.10.0 (from versions: 1.0.1a0, 1.0.2a0, 1.0.3a0, 1.0.4b0, 1.0.5, 1.0.6, 1.0.7, 1.0.8, 1.0.9, 1.1.0, 1.1.1, 1.2.0, 1.3.0, 1.4.0, 1.4.1, 1.5.0, 1.5.1, 1.6.0, 1.7.0, 1.7.1, 1.7.2, 1.8.0, 1.9.0, 1.9.1, 1.10.0, 1.10.1, 1.11.0rc1, 1.11.0rc2, 1.11.0, 1.11.1, 2.0.0rc1, 2.0.0rc2, 2.0.0rc3, 2.0.0rc4, 2.0.0)
ERROR: No matching distribution found for kivy==1.10.0
But Cython is already installed (The version is 0.29.26).
How can I solve this? (I'm using Window 10 and Python 3.9.1)
you should reinstall cython (pip install cython).
I have migrated my python project from 2.7 to 3.8. and I am trying to deploy using zappa.
But, as soon as it's starting updating Lambda function configs it hits this error.
Updating Lambda function configuration..
Oh no! An error occurred! :(
==============
Traceback (most recent call last):
File "/Users/leilakarimi/Projects/ATGWSams/venv/lib/python3.7/site-packages/zappa/cli.py", line 3422, in handle
sys.exit(cli.handle())
File "/Users/leilakarimi/Projects/ATGWSams/venv/lib/python3.7/site-packages/zappa/cli.py", line 588, in handle
self.dispatch_command(self.command, stage)
File "/Users/leilakarimi/Projects/ATGWSams/venv/lib/python3.7/site-packages/zappa/cli.py", line 644, in dispatch_command
self.vargs["docker_image_uri"],
File "/Users/leilakarimi/Projects/ATGWSams/venv/lib/python3.7/site-packages/zappa/cli.py", line 1194, in update
endpoint_configuration=self.endpoint_configuration,
File "/Users/leilakarimi/Projects/ATGWSams/venv/lib/python3.7/site-packages/zappa/core.py", line 2417, in create_stack_template
self.cf_template.add_description("Automatically generated with Zappa")
AttributeError: 'Template' object has no attribute 'add_description'
I found this question and tried to downgrade troposphere as suggested in this post but again I face a new error as below:
ERROR: Command errored out with exit status 1:
command: /Users/leilakarimi/Projects/ATGWSams/venv/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/2q/m5qvgtkj1872r4695zkbpln80000gn/T/pip-install-w9uojyvq/troposphere_527f0b9692da4c9ca1d6451190752408/setup.py'"'"'; __file__='"'"'/private/var/folders/2q/m5qvgtkj1872r4695zkbpln80000gn/T/pip-install-w9uojyvq/troposphere_527f0b9692da4c9ca1d6451190752408/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 /private/var/folders/2q/m5qvgtkj1872r4695zkbpln80000gn/T/pip-pip-egg-info-hguo5f3y
cwd: /private/var/folders/2q/m5qvgtkj1872r4695zkbpln80000gn/T/pip-install-w9uojyvq/troposphere_527f0b9692da4c9ca1d6451190752408/
Complete output (1 lines):
error in troposphere setup command: use_2to3 is invalid.
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/35/a1/cfb1f6b2f271213da05fd5c67cda0256d7d841ba0edbfa815ae517c6235d/troposphere-2.2.0.tar.gz#sha256=b2e322063e2278e7d69822943d230b683ce9a0438db8ad017f610d344998453d (from https://pypi.org/simple/troposphere/). 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 troposphere==2.7.1 (from versions: 0.1.2, 0.2.0, 0.3.0, 0.3.2, 0.3.3, 0.3.4, 0.4.0, 0.5.0, 0.6.0, 0.6.1, 0.6.2, 0.7.0, 0.7.1, 0.7.2, 1.0.0, 1.1.0, 1.1.1, 1.1.2, 1.2.0, 1.2.1, 1.2.2, 1.3.0, 1.4.0, 1.5.0, 1.6.0, 1.7.0, 1.8.0, 1.8.1, 1.8.2, 1.9.0, 1.9.1, 1.9.2, 1.9.3, 1.9.4, 1.9.5, 1.9.6, 2.0.0, 2.0.1, 2.0.2, 2.1.0, 2.1.1, 2.1.2, 2.2.0, 2.2.1, 2.2.2, 2.3.0, 2.3.1, 2.3.2, 2.3.3, 2.3.4, 2.4.0, 2.4.1, 2.4.2, 2.4.3, 2.4.4, 2.4.5, 2.4.6, 2.4.7, 2.4.8, 2.4.9, 2.5.0, 2.5.1, 2.5.2, 2.5.3, 2.6.0, 2.6.1, 2.6.2, 2.6.3, 2.6.4, 2.7.0, 2.7.1, 3.0.0, 3.0.1, 3.0.2, 3.0.3)
ERROR: No matching distribution found for troposphere==2.7.1
Any thoughts/help is much appreciated.
thanks
setuptools 58 broke support for use_2to3. Therefore, you should add setuptools<58 to your requirements file along with troposphere<3. If you still get the same issue, downgrade setuptools first and then install troposphere with the other requirements.
Related question: Error while downloading the requirements using pip install (setup command: use_2to3 is invalid.)
We have forked zappa and removed the pinned requirement for Werkzeug. Zappa project been restarted but they have been late to update. You can read how to do this at this blog