Project

General

Profile

Bug #8510

gettext_i18n_rails 1.x causes "cannot load such file -- gettext/tools/task" in production

Added by Dominic Cleal over 5 years ago. Updated almost 2 years ago.

Status:
Closed
Priority:
Urgent
Assignee:
Category:
Packaging
Target version:
Difficulty:
Triaged:
Bugzilla link:
Fixed in Releases:
Found in Releases:

Description

[root@foreman ~]# foreman-rake plugins --trace
rake aborted!
cannot load such file -- gettext/tools/task
/opt/rh/ruby193/root/usr/share/rubygems/rubygems/custom_require.rb:36:in `require'
/opt/rh/ruby193/root/usr/share/rubygems/rubygems/custom_require.rb:36:in `require'
/opt/rh/ruby193/root/usr/share/gems/gems/activesupport-3.2.8/lib/active_support/dependencies.rb:251:in `block in require'
/opt/rh/ruby193/root/usr/share/gems/gems/activesupport-3.2.8/lib/active_support/dependencies.rb:236:in `load_dependency'
/opt/rh/ruby193/root/usr/share/gems/gems/activesupport-3.2.8/lib/active_support/dependencies.rb:251:in `require'
/opt/rh/ruby193/root/usr/share/gems/gems/gettext_i18n_rails-1.0.5/lib/gettext_i18n_rails/tasks.rb:1:in `<top (required)>'
/opt/rh/ruby193/root/usr/share/rubygems/rubygems/custom_require.rb:36:in `require'
/opt/rh/ruby193/root/usr/share/rubygems/rubygems/custom_require.rb:36:in `require'
/opt/rh/ruby193/root/usr/share/gems/gems/activesupport-3.2.8/lib/active_support/dependencies.rb:251:in `block in require'
/opt/rh/ruby193/root/usr/share/gems/gems/activesupport-3.2.8/lib/active_support/dependencies.rb:236:in `load_dependency'
/opt/rh/ruby193/root/usr/share/gems/gems/activesupport-3.2.8/lib/active_support/dependencies.rb:251:in `require'
/usr/share/foreman/lib/tasks/gettext.rake:3:in `<top (required)>'

This also causes db:migrate etc to fail.

Previously the gem only lazily loaded gettext when the rake tasks were executed, but now it's happening when the tasks are loaded, due to https://github.com/grosser/gettext_i18n_rails/commit/d1b02f734f9e0c96de50d1a58e8170ce6ec457ac


Related issues

Related to Foreman - Refactor #7233: Revert Ruby 1.8 specificsClosed2014-08-22

Associated revisions

Revision 86ed8e1a (diff)
Added by Dominic Cleal over 5 years ago

fixes #8510 - ignore gettext load failures in production without it

gettext is only used when loading gettext_i18n_rails 1.x rake tasks, so it's
only marked as a development dependency. In production we won't have it, but
still ship this .rake file, so permit loading to fail.

History

#1 Updated by Dominic Cleal over 5 years ago

#2 Updated by The Foreman Bot over 5 years ago

  • Status changed from Assigned to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/1980 added
  • Pull request deleted ()

#3 Updated by Dominic Cleal over 5 years ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100

#4 Updated by Dominic Cleal over 5 years ago

  • Legacy Backlogs Release (now unused) set to 28

Also available in: Atom PDF