我正在尝试通过 GitHub 在 Heroku 上部署我的机器人。
在 requirements.txt 中,我有“操作系统”。我尝试部署机器人,以便 Heroku 识别 Procfile。它给了我这个错误。
Collecting os (from -r /tmp/build_e656b8b6627c307b02ef77c47e6bb725/requirements.txt (line 3))
Could not find a version that satisfies the requirement os (from -r /tmp/build_e656b8b6627c307b02ef77c47e6bb725/requirements.txt (line 3)) (from versions: )
No matching distribution found for os (from -r /tmp/build_e656b8b6627c307b02ef77c47e6bb725/requirements.txt (line 3))
! Push rejected, failed to compile Python app.
! Push failed
如何解决?
最佳答案
您不需要在 requirements.txt 中包含 os
- 它是一个内置模块。只需将其删除即可。
关于python - 为什么Heroku找不到满足要求的 'os'版本?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/58465220/