Ruby on rails 在任何源中都找不到activerecord-postgis-adapter-5.0.0
推到HerokuRuby on rails 在任何源中都找不到activerecord-postgis-adapter-5.0.0,ruby-on-rails,postgresql,heroku,activerecord,postgis,Ruby On Rails,Postgresql,Heroku,Activerecord,Postgis,推到Heroku时出错,在任何源中都找不到activerecord-postgis-adapter-5.0.0。 在开发和生产中使用PostGIS。 档案: 来源“” 谢谢你的建议。activerecord postgis适配器是否请求不需要的内容 堆栈溢出问题。通常会被要求输入更多的代码。现在无法发布,因为没有足够的详细信息。我不确定我应该添加什么,所以我将继续键入,直到错误消失。在过去,我已经能够把这个推给Heroku,但是postgis适配器还有其他问题,可能是最近的更新导致了这个问题。我
时出错,在任何源中都找不到activerecord-postgis-adapter-5.0.0
。
在开发和生产中使用PostGIS。
档案:
来源“”
谢谢你的建议。
activerecord postgis适配器
是否请求不需要的内容
堆栈溢出问题。通常会被要求输入更多的代码。现在无法发布,因为没有足够的详细信息。我不确定我应该添加什么,所以我将继续键入,直到错误消失。在过去,我已经能够把这个推给Heroku,但是postgis适配器还有其他问题,可能是最近的更新导致了这个问题。我不知道版本号是从哪里来的。档案的来源对我来说有点神秘
除其他事项外,我尝试了:
gem卸载activerecord postgis适配器
Select gem to uninstall:
1. activerecord-postgis-adapter-3.1.2
2. activerecord-postgis-adapter-4.0.2
3. activerecord-postgis-adapter-5.0.0
4. activerecord-postgis-adapter-5.0.1
5. All versions
我选择了选项5并重新运行
捆绑安装
Gemfile.lock
现在activerecord postgis适配器(4.0.4)
但是在Heroku push上仍然得到在任何源代码中都找不到activerecord-postgis-adapter-5.0.0
检查您的Gemfile.lock
对于该Gem,我猜您以前安装过它(如果它被选中,可能在另一个系统上)并锁定到5.0.0
RubyGems没有这个Gem的5.0.0版本,因此作者似乎删除了它
然而,Bundler永远不会自动更新您的gems(它在
Gemfile.lock
中跟踪版本),但您可以使用bundle update
或bundle update activerecord postgis adapter
告诉它这样做
请看我做了两个更改,但不确定哪一个是关键。我更改了gem'pg','~>0.18.4',删除了版本限制,从而安装了v
0.21.0
。我还在gem文件中将gem'rgeo geojson'
移动到上面的gem'activerecord postgis adapter'
。在bundle update
之后,最终得到了activerecord postgis adapter 4.0.4
,这不是最新版本,所以仍然很好奇这一切是如何工作的。我怀疑前一个变化是重要的。我将这些更改基于我正在开发的一个更新的相关应用程序,该应用程序确实上传到了Heroku activerecord postgis适配器(5.0.0)rgeo activerecord(~>5.1)
位于Gemfile.lock
中。我删除了该文件并运行了包更新
,但仍然显示相同的内容。我会试着去读这个链接,尽管它有点让我不知所措。那么,是否有其他gem需要这个特定版本?我尝试了bundle更新——保守的,但仍然在清单中使用activerecord postgis适配器5.0.0
。感谢您的快速回答,捆绑更新activerecord postgis适配器将在5.0.0中产生。我在Gemfile.lock(毫无疑问是no)中编辑了activerecord postgis适配器(5.0.0)
中的`(5.0.0)`,并在按下Heroku时,仍然出现错误在任何源代码中都找不到activerecord-postgis-adapter-5.0.0
我尝试过(格式化不起作用,以下是六行)gem卸载activerecord postgis适配器选择gem卸载:1。activerecord-postgis-adapter-3.1.2。activerecord-postgis-adapter-4.0.2 3。activerecord-postgis-adapter-5.0.0 4。activerecord-postgis-adapter-5.0.1 5。所有版本我都选择了选项5并重新运行bundle安装
Gemfile.lock
nowactiverecord postgis adapter(4.0.4)
但在Heroku push上仍然无法在任何源文件中找到activerecord-postgis-adapter-5.0.0
。这可能是另一个要求特定版本的Gem,通常他们只会说他们支持的主要版本。锁文件显示这种缩进的依赖关系,例如,activerecord(5.1.1)
要求activemodel
和activesupport
也正好在5.1.1,但是arel
是~>8.0
。如果当前活动的Gem需要一些实际不可用的东西,我想应该向他们报告这个bug。Heroku和任何其他平台都应该完全按照您推送的Gemfile.lock
所说的安装(这就是重点,不要意外更新和破坏东西)。
default: &default
adapter: postgis
encoding: unicode
pool: 5
Select gem to uninstall:
1. activerecord-postgis-adapter-3.1.2
2. activerecord-postgis-adapter-4.0.2
3. activerecord-postgis-adapter-5.0.0
4. activerecord-postgis-adapter-5.0.1
5. All versions