Content
Issue upgrading to 5.0.11
Added by Fabian Schwarz almost 9 years ago
Hi,
tried to update my manual installation of OpenProject to 5.0.11 today. Unfortunately got this error on migrating the database:
[openproject
projekt openproject]$ RAILS_ENV=“production” bundle exec rake db:migrate
rake aborted!
NoMethodError: undefined method `map’ for “\x04\b[\aI\”\ade\x06:\x06ETI\\aen\x06;\x00T
/home/openproject/openproject/config/initializers/30-redmine.rb:37:in `<top (required)>’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/activesupport-4.2.5.1/lib/active_support/dependencies.rb:268:in `load’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/activesupport-4.2.5.1/lib/active_support/dependencies.rb:268:in `block in load’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/activesupport-4.2.5.1/lib/active_support/dependencies.rb:240:in `load_dependency’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/activesupport-4.2.5.1/lib/active_support/dependencies.rb:268:in `load’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/engine.rb:652:in `block in load_config_initializer’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/activesupport-4.2.5.1/lib/active_support/notifications.rb:166:in `instrument’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/engine.rb:651:in `load_config_initializer’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/engine.rb:616:in `block (2 levels) in class:Engine’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/engine.rb:615:in `each’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/engine.rb:615:in `block in class:Engine’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/initializable.rb:30:in `instance_exec’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/initializable.rb:30:in `run’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/initializable.rb:55:in `block in run_initializers’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/initializable.rb:44:in `each’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/initializable.rb:44:in `tsort_each_child’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/initializable.rb:54:in `run_initializers’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/application.rb:352:in `initialize!’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/railtie.rb:194:in `public_send’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/railtie.rb:194:in `method_missing’
/home/openproject/openproject/config/environment.rb:34:in `<top (required)>’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/activesupport-4.2.5.1/lib/active_support/dependencies.rb:274:in `require’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/activesupport-4.2.5.1/lib/active_support/dependencies.rb:274:in `block in require’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/activesupport-4.2.5.1/lib/active_support/dependencies.rb:240:in `load_dependency’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/activesupport-4.2.5.1/lib/active_support/dependencies.rb:274:in `require’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/application.rb:328:in `require_environment!’
/home/openproject/openproject/vendor/cache/ruby/2.1.0/gems/railties-4.2.5.1/lib/rails/application.rb:457:in `block in run_tasks_blocks’
Tasks: TOP => db:migrate => environment
(See full trace by running task with —trace)@
Does anyone know how to solve this?
Many Thanks
Humppa
Replies (8)
Hey Fabian,
from what version did you try to migrate? The error stems from this line and appears to be connected to the available settings.
Could you connect to the database manually and show the actual value of that setting with
SELECT * FROM settings WHERE name = 'available_languages';
?It should be a YAML-serialized string that contains one or more language codes.
Best,
Oliver
Hi,
I’m using OpenProject 4.2.9 with PostgreSQL.
Here’s the output of the query:
`"id"|"name"|"value"|"updated_on"
24|"available_languages"|"---
"|"2016-01-29 07:28:06.338311"`
Best Regards
Fabian
Hi Fabian,
that looks alright.
Do you use the postgresql adapter with
encoding: unicode
set (inconfig/database.yml
) ?Best,
Oliver
Hi Oliver,
current value is
encoding: utf8
. Shall I switch it?Best regards
Fabian
unicode is only an alias for utf8 , so that should both be fine.
From which version do you try to upgrade?
I’m using OpenProject 4.2.9
Thanks. I’m looking into your issue since it’s probably the same problem as in https://community.openproject.org/topics/5393?r=5835
Hi Fabian,
I believe I found the underlying issue: The Rails caching is still from 4.2 and seems to be incompatible
See this message for more information: https://community.openproject.org/topics/5393?r=5850#message-5850
Best,
Oliver