Не удалось развернуть Google App Engine. Не найдено подходящего распределения для pywin32 == xxx - PullRequest
2 голосов
/ 04 апреля 2020

Я запустил gcloud app deploy для моего Django приложения, но в конце журнала сборки произошла ошибка со следующими ошибками:

Step #1 - "builder": Collecting pywin32==227 (from -r requirements.txt (line 63))
Step #1 - "builder": 
Step #1 - "builder": INFO     `pip_download_wheels` had stderr output:
Step #1 - "builder":   ERROR: Could not find a version that satisfies the requirement pywin32==227 (from -r requirements.txt (line 63)) (from versions: none)
Step #1 - "builder": ERROR: No matching distribution found for pywin32==227 (from -r requirements.txt (line 63))
Step #1 - "builder": 
Step #1 - "builder": ERROR    error: `pip_download_wheels` returned code: 1
Step #1 - "builder": INFO     pip_download_wheels took 13 seconds
Step #1 - "builder": INFO     build process for FTL image took 18 seconds
Step #1 - "builder": INFO     full build took 18 seconds
Step #1 - "builder": ERROR    `pip_download_wheels` had stderr output:
Step #1 - "builder":   ERROR: Could not find a version that satisfies the requirement pywin32==227 (from -r requirements.txt (line 63)) (from versions: none)
Step #1 - "builder": ERROR: No matching distribution found for pywin32==227 (from -r requirements.txt (line 63))
Step #1 - "builder": 
Step #1 - "builder": error: `pip_download_wheels` returned code: 1
Step #1 - "builder": Traceback (most recent call last):
Step #1 - "builder":   File "/usr/lib/python2.7/runpy.py", line 174, in _run_module_as_main
Step #1 - "builder":     "__main__", fname, loader, pkg_name)
Step #1 - "builder":   File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
Step #1 - "builder":     exec code in run_globals
Step #1 - "builder":   File "/usr/local/bin/ftl.par/__main__.py", line 65, in <module>
Step #1 - "builder":   File "/usr/local/bin/ftl.par/__main__.py", line 57, in main
Step #1 - "builder":   File "/usr/local/bin/ftl.par/__main__/ftl/common/ftl_error.py", line 58, in UserErrorHandler
Step #1 - "builder": IOError: [Errno 2] No such file or directory: '""/output'
Finished Step #1 - "builder"
ERROR
ERROR: build step 1 "gcr.io/gae-runtimes/python37_app_builder:python37_20200223_3_7_6_RC00" failed: step exited with non-zero status: 1

Для справки, мой файл require.txt включен ниже:

aioredis==1.3.1
asgiref==3.2.3
astroid==2.3.3
async-timeout==3.0.1
attrs==19.3.0
autobahn==20.1.3
Automat==0.8.0
certifi==2019.11.28
cffi==1.13.2
channels==2.4.0
channels-redis==2.4.1
chardet==3.0.4
Click==7.0
colorama==0.4.3
constantly==15.1.0
cryptography==2.8
daphne==2.4.1
dash==1.8.0
dash-core-components==1.7.0
dash-html-components==1.0.2
dash-renderer==1.2.3
dash-table==4.6.0
Django==3.0.2
django-crispy-forms==1.9.0
django-extensions==2.2.8
django-plotly-dash==1.1.5
django-redis==4.11.0
djangorestframework==3.11.0
docker==4.1.0
dpd-components==0.1.0
Flask==1.1.1
Flask-Compress==1.4.0
future==0.18.2
gunicorn==20.0.4
hiredis==1.0.1
hyperlink==19.0.0
idna==2.8
incremental==17.5.0
isort==4.3.21
itsdangerous==1.1.0
Jinja2==2.11.0
lazy-object-proxy==1.4.3
MarkupSafe==1.1.1
mccabe==0.6.1
msgpack==0.6.2
numpy==1.18.1
pandas==1.0.1
Pillow==7.0.0
plotly==4.5.0
psycopg2==2.8.4
psycopg2-binary==2.8.4
pyasn1==0.4.8
pyasn1-modules==0.2.8
pycparser==2.19
PyHamcrest==2.0.0
pylint==2.4.4
pylint-django==2.0.14
pylint-plugin-utils==0.6
pyOpenSSL==19.1.0
pypiwin32==223
python-dateutil==2.8.1
pytz==2019.3
pywin32==227
redis==3.3.11
requests==2.22.0
retrying==1.3.3
scipy==1.4.1
service-identity==18.1.0
simplejson==3.17.0
six==1.14.0
sqlparse==0.3.0
Twisted==19.10.0
txaio==20.1.1
typed-ast==1.4.1
urllib3==1.25.8
websocket-client==0.57.0
Werkzeug==0.16.1
wincertstore==0.2
wrapt==1.11.2
xlrd==1.2.0
zope.interface==4.7.1

Я пытался понизиться до версии pywin32 до 223, когда была предоставлена ​​большая поддержка python 3.7 в соответствии с их журналом изменений на GitHub, но каждая повторная попытка выявила идентичные ошибки журнала сборки с версией подставил.

Я не совсем уверен, что именно не так. Почему GCP не может найти подходящий дистрибутив?

Также, возможно, связанный с этим вопрос, почему в трассировке до финальной ошибки IOError указан файл runpy.py в каталоге python2 .7? Я указал время выполнения python как 3.7 в своем app.yaml, а также написал все с учетом python3 ...

Любая помощь приветствуется, и извините, если я упускаю что-то действительно очевидное Вот. Вот уже пару часов я ломаю голову, но безрезультатно: (

1 Ответ

4 голосов
/ 04 апреля 2020

Пакет pywin32 публикует только встроенные дистрибутивы для платформы Windows (обратите внимание на все win* имена файлов здесь ).

Вы не сможете установить его в App Engine, потому что базовая платформа - Linux, а не Windows.

...