Content
You are here:
Error after upgrading from 13.x to 14.x: NameError: uninitialized constant Cron::CronJob (NameError)
Added by Chris Croome 4 months ago
Hi
I have just upgraded a OpenProject server from version 13.4.2 to 14.3.0 and have this error when running openproject configure
:
I, [2024-08-01T15:13:47.293273 #13095] INFO -- : Increasing database pool size to 17 to match max threads
rake aborted!
NameError: uninitialized constant Cron::CronJob (NameError)
::Cron::CronJob.register! ::Cron::ClearOldMergeRequestsJob
^^^^^^^^^
/opt/openproject/vendor/bundle/ruby/3.3.0/bundler/gems/openproject-gitlab-integration-7ae05eb72034/lib/open_project/gitlab_integration/engine.rb:105:in `block in <class:Engine>'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/activesupport-7.1.3.4/lib/active_support/callbacks.rb:448:in `instance_exec'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/activesupport-7.1.3.4/lib/active_support/callbacks.rb:448:in `block in make_lambda'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/activesupport-7.1.3.4/lib/active_support/callbacks.rb:202:in `block (2 levels) in halting'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/activesupport-7.1.3.4/lib/active_support/callbacks.rb:707:in `block (2 levels) in default_terminator'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/activesupport-7.1.3.4/lib/active_support/callbacks.rb:706:in `catch'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/activesupport-7.1.3.4/lib/active_support/callbacks.rb:706:in `block in default_terminator'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/activesupport-7.1.3.4/lib/active_support/callbacks.rb:203:in `block in halting'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/activesupport-7.1.3.4/lib/active_support/callbacks.rb:598:in `block in invoke_before'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/activesupport-7.1.3.4/lib/active_support/callbacks.rb:598:in `each'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/activesupport-7.1.3.4/lib/active_support/callbacks.rb:598:in `invoke_before'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/activesupport-7.1.3.4/lib/active_support/callbacks.rb:109:in `run_callbacks'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/activesupport-7.1.3.4/lib/active_support/reloader.rb:96:in `prepare!'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/railties-7.1.3.4/lib/rails/application/finisher.rb:74:in `block in <module:Finisher>'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/railties-7.1.3.4/lib/rails/initializable.rb:32:in `instance_exec'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/railties-7.1.3.4/lib/rails/initializable.rb:32:in `run'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/railties-7.1.3.4/lib/rails/initializable.rb:61:in `block in run_initializers'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/railties-7.1.3.4/lib/rails/initializable.rb:60:in `run_initializers'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/railties-7.1.3.4/lib/rails/application.rb:426:in `initialize!'
/opt/openproject/config/environment.rb:33:in `<top (required)>'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/zeitwerk-2.6.16/lib/zeitwerk/kernel.rb:34:in `require'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/railties-7.1.3.4/lib/rails/application.rb:402:in `require_environment!'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/railties-7.1.3.4/lib/rails/application.rb:588:in `block in run_tasks_blocks'
/opt/openproject/vendor/bundle/ruby/3.3.0/gems/rake-13.2.1/exe/rake:27:in `<top (required)>'
/opt/openproject/bin/bundle:110:in `load'
/opt/openproject/bin/bundle:110:in `<main>'
Tasks: TOP => db:migrate => db:load_config => environment
(See full trace by running task with --trace)
Has anyone else come across this before?
Does anyone have any suggestions regarding what I might be able to to do to debug / fix this issue?
Thanks!
Chris
Replies (3)
Some more detail in case it helps anyone debug this:
Remove the old GitLab integration following these steps.
Run
openproject configure --trace
this returns:Incidently the same results are returned when the steps to remove the GitLab plugin are not followed:
Incidently this is on a Debian Bookworm server with this version:
And the output from
openproject logs
is: