gpt4 book ai didi

ModuleNotFoundError: No module named 'django' (deploying on Heroku)(ModuleNotFoundError:没有名为‘Django’的模块(在Heroku上部署))

转载 作者:bug小助手 更新时间:2023-10-26 19:54:11 25 4
gpt4 key购买 nike



I ran into an error when running the command: heroku run python manage.py migrate. When I run it it raises en error: ModuleNotFoundError: No module named 'django'.
My app runs fine locally. Django is installed.

在运行命令时,我遇到了一个错误:Heroku run pythonManage.py Migrate。当我运行它时,它会出现错误:ModuleNotFoundError:没有名为‘Django’的模块。我的应用在本地运行得很好。Django已安装。


I tried to search the internet but I see the answers for the errors with the module "django-heroku", not just "django". If anyone has any suggestions, I would be grateful!

我试着在互联网上搜索,但我找到了错误的答案,模块是“Django-Heroku”,而不仅仅是“Django”。如果任何人有任何建议,我将不胜感激!


更多回答

What you have installed locally is irrelevant. Have you declared the dependency? Are you using a requirements.txt file or a Pipfile? Whichever, please edit it into your question as a code block.

您在本地安装的内容无关紧要。您声明依赖关系了吗?您使用的是Requirements.txt文件还是管道文件?无论哪一种,请将其作为代码块编辑到您的问题中。

优秀答案推荐
更多回答

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com