首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >Pipfile.lock已过期

Pipfile.lock已过期
EN

Stack Overflow用户
提问于 2018-03-24 10:00:06
回答 10查看 31K关注 0票数 32

我正在尝试将一个大型的django项目部署到heroku。我安装了Heroku CLI,登录,创建了一个应用程序,然后运行:

git push heroku master

我已经设置了一个管道文件和requirements.txt。我添加了一个runtime.txt来指定我需要Python2.7。这也在Pipfile中。这是我从推送到heroku得到的:

代码语言:javascript
运行
复制
$ git push heroku master
Counting objects: 12159, done.
Delta compression using up to 2 threads.
Compressing objects: 100% (4853/4853), done.
Writing objects: 100% (12159/12159), 20.94 MiB | 1.82 MiB/s, done.
Total 12159 (delta 6859), reused 12036 (delta 6751)
remote: Compressing source files... done.
remote: Building source:
remote: 
remote: -----> Python app detected
remote: -----> Installing python-3.6.4
remote: -----> Installing pip
remote: -----> Installing dependencies with Pipenv 11.8.2…
remote:        Your Pipfile.lock (3b2ba9) is out of date. Expected: (83a5b4).
remote:        Aborting deploy.
remote:  !     Push rejected, failed to compile Python app.
remote: 
remote:  !     Push failed
remote: Verifying deploy....
remote: 
remote: !   Push rejected to camp-infinity.
remote: 
To https://git.heroku.com/camp-infinity.git
 ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'https://git.heroku.com/camp-infinity.git'

由于某种原因,它试图安装Python3,而且它也不喜欢我的Pipfile.lock文件。我尝试删除它,并使用pipenv install重新生成它,但这并没有改变任何事情。

EN

Stack Overflow用户

发布于 2021-01-23 06:25:15

如果已经创建了Pipfile,请将其删除,然后再次按deploy。它应该会重新安装你的依赖项。这就是对我有效的方法。

票数 3
EN
查看全部 10 条回答
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/49460486

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档