NoMethodError: undefined method `true?' for Additionals:Module
lifedanceman opened this issue · 8 comments
Hi!
I get an error when do migrate steps on redmine_git_hosting. All gems are installed successfully.
bundle exec rake redmine:plugins:migrate RAILS_ENV=production NAME=additionals
W, [2022-01-26T13:31:46.915302 #3525] WARN -- : Creating scope :system. Overwriting existing method Enumeration.system. W, [2022-01-26T13:31:47.534116 #3525] WARN -- : Creating scope :sorted. Overwriting existing method User.sorted. W, [2022-01-26T13:31:47.602537 #3525] WARN -- : Creating scope :sorted. Overwriting existing method Group.sorted. W, [2022-01-26T13:31:47.975049 #3525] WARN -- : Creating scope :visible. Overwriting existing method Principal.visible. W, [2022-01-26T13:31:53.312679 #3525] WARN -- : DEPRECATION WARNING: Using a dynamic :action segment in a route is deprecated and will be removed in Rails 6.0. (called from instance_eval at /usr/src/redmine/config/routes.rb:395) W, [2022-01-26T13:31:53.315547 #3525] WARN -- : DEPRECATION WARNING: Using a dynamic :action segment in a route is deprecated and will be removed in Rails 6.0. (called from instance_eval at /usr/src/redmine/config/routes.rb:395)
bundle exec rake redmine:plugins:migrate RAILS_ENV=production NAME=redmine_git_hosting --trace
`** Invoke redmine:plugins:migrate (first_time)
** Invoke environment (first_time)
** Execute environment
W, [2022-01-26T13:33:11.957425 #3527] WARN -- : Creating scope :system. Overwriting existing method Enumeration.system.
W, [2022-01-26T13:33:12.577682 #3527] WARN -- : Creating scope :sorted. Overwriting existing method User.sorted.
W, [2022-01-26T13:33:12.647966 #3527] WARN -- : Creating scope :sorted. Overwriting existing method Group.sorted.
W, [2022-01-26T13:33:13.054020 #3527] WARN -- : Creating scope :visible. Overwriting existing method Principal.visible.
W, [2022-01-26T13:33:18.776369 #3527] WARN -- : DEPRECATION WARNING: Using a dynamic :action segment in a route is deprecated and will be removed in Rails 6.0. (called from instance_eval at /usr/src/redmine/config/routes.rb:395)
W, [2022-01-26T13:33:18.779330 #3527] WARN -- : DEPRECATION WARNING: Using a dynamic :action segment in a route is deprecated and will be removed in Rails 6.0. (called from instance_eval at /usr/src/redmine/config/routes.rb:395)
** Execute redmine:plugins:migrate
I, [2022-01-26T13:33:19.352909 #3527] INFO -- : Migrating to MigrateParameters (20130807223227)
== 20130807223227 MigrateParameters: migrating ================================
rake aborted!
StandardError: An error has occurred, all later migrations canceled:
undefined method true?' for Additionals:Module /usr/src/redmine/plugins/redmine_git_hosting/db/migrate/20130807223227_migrate_parameters.rb:160:in
block in up'
/usr/src/redmine/plugins/redmine_git_hosting/db/migrate/20130807223227_migrate_parameters.rb:67:in each' /usr/src/redmine/plugins/redmine_git_hosting/db/migrate/20130807223227_migrate_parameters.rb:67:in
up'
/usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:817:in exec_migration' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:798:in
block (2 levels) in migrate'
/usr/local/lib/ruby/2.7.0/benchmark.rb:293:in measure' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:797:in
block in migrate'
/usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/connection_adapters/abstract/connection_pool.rb:416:in with_connection' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:796:in
migrate'
/usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:977:in migrate' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1292:in
block in execute_migration_in_transaction'
/usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1345:in ddl_transaction' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1291:in
execute_migration_in_transaction'
/usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1263:in block in migrate_without_lock' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1262:in
each'
/usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1262:in migrate_without_lock' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1210:in
block in migrate'
/usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1363:in with_advisory_lock' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1210:in
migrate'
/usr/src/redmine/lib/redmine/plugin.rb:542:in up' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1011:in
migrate'
/usr/src/redmine/lib/redmine/plugin.rb:574:in migrate_plugin' /usr/src/redmine/lib/redmine/plugin.rb:515:in
migrate'
/usr/src/redmine/lib/redmine/plugin.rb:526:in migrate' /usr/src/redmine/lib/tasks/redmine.rake:135:in
block (3 levels) in <top (required)>'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/task.rb:281:in block in execute' /usr/local/bundle/gems/rake-13.0.6/lib/rake/task.rb:281:in
each'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/task.rb:281:in execute' /usr/local/bundle/gems/rake-13.0.6/lib/rake/task.rb:219:in
block in invoke_with_call_chain'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/task.rb:199:in synchronize' /usr/local/bundle/gems/rake-13.0.6/lib/rake/task.rb:199:in
invoke_with_call_chain'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/task.rb:188:in invoke' /usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:160:in
invoke_task'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:116:in block (2 levels) in top_level' /usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:116:in
each'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:116:in block in top_level' /usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:125:in
run_with_threads'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:110:in top_level' /usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:83:in
block in run'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:186:in standard_exception_handling' /usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:80:in
run'
/usr/local/bundle/gems/rake-13.0.6/exe/rake:27:in <top (required)>' /usr/local/bundle/bin/rake:23:in
load'
/usr/local/bundle/bin/rake:23:in <top (required)>' /usr/local/lib/ruby/2.7.0/bundler/cli/exec.rb:63:in
load'
/usr/local/lib/ruby/2.7.0/bundler/cli/exec.rb:63:in kernel_load' /usr/local/lib/ruby/2.7.0/bundler/cli/exec.rb:28:in
run'
/usr/local/lib/ruby/2.7.0/bundler/cli.rb:476:in exec' /usr/local/lib/ruby/2.7.0/bundler/vendor/thor/lib/thor/command.rb:27:in
run'
/usr/local/lib/ruby/2.7.0/bundler/vendor/thor/lib/thor/invocation.rb:127:in invoke_command' /usr/local/lib/ruby/2.7.0/bundler/vendor/thor/lib/thor.rb:399:in
dispatch'
/usr/local/lib/ruby/2.7.0/bundler/cli.rb:30:in dispatch' /usr/local/lib/ruby/2.7.0/bundler/vendor/thor/lib/thor/base.rb:476:in
start'
/usr/local/lib/ruby/2.7.0/bundler/cli.rb:24:in start' /usr/local/lib/ruby/gems/2.7.0/gems/bundler-2.1.4/libexec/bundle:46:in
block in <top (required)>'
/usr/local/lib/ruby/2.7.0/bundler/friendly_errors.rb:123:in with_friendly_errors' /usr/local/lib/ruby/gems/2.7.0/gems/bundler-2.1.4/libexec/bundle:34:in
<top (required)>'
/usr/local/bin/bundle:23:in load' /usr/local/bin/bundle:23:in
Caused by:
NoMethodError: undefined method true?' for Additionals:Module /usr/src/redmine/plugins/redmine_git_hosting/db/migrate/20130807223227_migrate_parameters.rb:160:in
block in up'
/usr/src/redmine/plugins/redmine_git_hosting/db/migrate/20130807223227_migrate_parameters.rb:67:in each' /usr/src/redmine/plugins/redmine_git_hosting/db/migrate/20130807223227_migrate_parameters.rb:67:in
up'
/usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:817:in exec_migration' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:798:in
block (2 levels) in migrate'
/usr/local/lib/ruby/2.7.0/benchmark.rb:293:in measure' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:797:in
block in migrate'
/usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/connection_adapters/abstract/connection_pool.rb:416:in with_connection' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:796:in
migrate'
/usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:977:in migrate' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1292:in
block in execute_migration_in_transaction'
/usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1345:in ddl_transaction' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1291:in
execute_migration_in_transaction'
/usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1263:in block in migrate_without_lock' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1262:in
each'
/usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1262:in migrate_without_lock' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1210:in
block in migrate'
/usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1363:in with_advisory_lock' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1210:in
migrate'
/usr/src/redmine/lib/redmine/plugin.rb:542:in up' /usr/local/bundle/gems/activerecord-5.2.6/lib/active_record/migration.rb:1011:in
migrate'
/usr/src/redmine/lib/redmine/plugin.rb:574:in migrate_plugin' /usr/src/redmine/lib/redmine/plugin.rb:515:in
migrate'
/usr/src/redmine/lib/redmine/plugin.rb:526:in migrate' /usr/src/redmine/lib/tasks/redmine.rake:135:in
block (3 levels) in <top (required)>'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/task.rb:281:in block in execute' /usr/local/bundle/gems/rake-13.0.6/lib/rake/task.rb:281:in
each'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/task.rb:281:in execute' /usr/local/bundle/gems/rake-13.0.6/lib/rake/task.rb:219:in
block in invoke_with_call_chain'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/task.rb:199:in synchronize' /usr/local/bundle/gems/rake-13.0.6/lib/rake/task.rb:199:in
invoke_with_call_chain'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/task.rb:188:in invoke' /usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:160:in
invoke_task'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:116:in block (2 levels) in top_level' /usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:116:in
each'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:116:in block in top_level' /usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:125:in
run_with_threads'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:110:in top_level' /usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:83:in
block in run'
/usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:186:in standard_exception_handling' /usr/local/bundle/gems/rake-13.0.6/lib/rake/application.rb:80:in
run'
/usr/local/bundle/gems/rake-13.0.6/exe/rake:27:in <top (required)>' /usr/local/bundle/bin/rake:23:in
load'
/usr/local/bundle/bin/rake:23:in <top (required)>' /usr/local/lib/ruby/2.7.0/bundler/cli/exec.rb:63:in
load'
/usr/local/lib/ruby/2.7.0/bundler/cli/exec.rb:63:in kernel_load' /usr/local/lib/ruby/2.7.0/bundler/cli/exec.rb:28:in
run'
/usr/local/lib/ruby/2.7.0/bundler/cli.rb:476:in exec' /usr/local/lib/ruby/2.7.0/bundler/vendor/thor/lib/thor/command.rb:27:in
run'
/usr/local/lib/ruby/2.7.0/bundler/vendor/thor/lib/thor/invocation.rb:127:in invoke_command' /usr/local/lib/ruby/2.7.0/bundler/vendor/thor/lib/thor.rb:399:in
dispatch'
/usr/local/lib/ruby/2.7.0/bundler/cli.rb:30:in dispatch' /usr/local/lib/ruby/2.7.0/bundler/vendor/thor/lib/thor/base.rb:476:in
start'
/usr/local/lib/ruby/2.7.0/bundler/cli.rb:24:in start' /usr/local/lib/ruby/gems/2.7.0/gems/bundler-2.1.4/libexec/bundle:46:in
block in <top (required)>'
/usr/local/lib/ruby/2.7.0/bundler/friendly_errors.rb:123:in with_friendly_errors' /usr/local/lib/ruby/gems/2.7.0/gems/bundler-2.1.4/libexec/bundle:34:in
<top (required)>'
/usr/local/bin/bundle:23:in load' /usr/local/bin/bundle:23:in
Tasks: TOP => redmine:plugins:migrate`
platform: docker
version: 4.2.3.stable
additionals_version: stable (last commit 625a375e2c46e7b8eb5ea0edc7758204812457ab)
redmine_git_hosting_version: 5.0.0 (c7ab92b (HEAD, tag: 5.0.0))
Do you use latest stable additionals plugin with latest redmine-git-hosting master? Looks like you use an old version.
Yes. I installed the latest (I think:)) version(commit in the massage above) of additionals plugin using this instructions.
Now. I tried to install everything from the beginning and it's all successfully done. What could be the reason?
I think, you did not had the latest version of redmine_git_hosting on your first try. If you did not had commit c5484d4, this would be cause your error message.
Maybe the first time I installed from master brunch. Now I installed from stable one and it's all successfully done. Anyway thanks for the help!
I have the same problem. Checked out latest additionals and redmine_git_hosting 5.0.0
redmine_git_hosting:
commit c7ab92b (HEAD, tag: 5.0.0)
Date: Thu Dec 24 23:40:25 2020 +0900
5.0.0
additionals:
commit 389938075fbafa510205e2ea634fb534c557850e (HEAD -> main, origin/main, origin/HEAD, stable)
Author: Alexander Meindl alex@alphanodes.com
Date: Mon Feb 7 07:21:10 2022 +0100
replace master with main in doc
As I wrote above, you have to use latest redmine_git_hosting and not tagged version 5.0.0.