gpt4 book ai didi

ruby-on-rails - ruby on rails 5.1 错误与设计 gem

转载 作者:行者123 更新时间:2023-12-04 06:04:06 25 4
gpt4 key购买 nike

当我尝试运行时:'rails generate devise:install'

我得到以下信息:

`There was an error while trying to load the gem 'devise'.
Gem Load Error is: undefined method `alias_method_chain' for
ActionDispatch::Routing::RouteSet:Class
Did you mean? alias_method`

我的 gem 文件: 来源' https://rubygems.org '

gem 'devise'
gem 'rails', '~> 5.1.0'
gem 'sqlite3'
gem 'puma', '~> 3.7'
gem 'sass-rails', '~> 5.0'
gem 'uglifier', '>= 1.3.0'

gem 'coffee-rails', '~> 4.2'
gem 'turbolinks', '~> 5'
gem 'jbuilder', '~> 2.5'

group :development, :test do
gem 'byebug', platforms: [:mri, :mingw, :x64_mingw]
gem 'capybara', '~> 2.13.0'
gem 'selenium-webdriver'
end

group :development do
gem 'web-console', '>= 3.3.0'
gem 'listen', '>= 3.0.5', '< 3.2'
gem 'spring'
gem 'spring-watcher-listen', '~> 2.0.0'
end
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]

最佳答案

根据 https://github.com/plataformatec/devise/issues/4518 Devise 4.0 不适用于 Rails 5.1.0

下周会有一个新版本,同时在你的 Gemfile 中你可以使用:
gem “设计”,git:'https://github.com/plataformatec/devise.git'

关于ruby-on-rails - ruby on rails 5.1 错误与设计 gem ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43716882/

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