Project

General

Custom queries

Profile

Actions

Support #16004

closed

Fails to load plugins using deface

Added by Guido Günther almost 9 years ago. Updated almost 9 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
Rails
Target version:
-
Triaged:
Fixed in Releases:
Found in Releases:

Description

With current 'develop' HEAD (b96e021026cdcc6918c61d246dbf5c7baabfc1b4) if I use any plugin using deface (e.g. the
example plugin) I get

$ bundle exec bin/rails server
bundler: failed to load command: bin/rails (bin/rails)
LoadError: cannot load such file -- colorize
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/polyglot-0.3.5/lib/polyglot.rb:65:in `require'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/polyglot-0.3.5/lib/polyglot.rb:65:in `require'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:274:in `block in require'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:240:in `load_dependency'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:274:in `require'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/deface-1.0.2/lib/deface.rb:39:in `<top (required)>'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:274:in `require'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:274:in `block in require'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:240:in `load_dependency'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:274:in `require'
/var/scratch/src/foreman/foreman_/lib/foreman_foobar/engine.rb:1:in `<top (required)>'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:274:in `require'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:274:in `block in require'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:240:in `load_dependency'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/activesupport-4.2.6/lib/active_support/dependencies.rb:274:in `require'
/var/scratch/src/foreman/foreman_/lib/foreman_foobar.rb:1:in `<top (required)>'
/usr/lib/ruby/vendor_ruby/bundler/runtime.rb:86:in `require'
/usr/lib/ruby/vendor_ruby/bundler/runtime.rb:86:in `block (2 levels) in require'
/usr/lib/ruby/vendor_ruby/bundler/runtime.rb:81:in `each'
/usr/lib/ruby/vendor_ruby/bundler/runtime.rb:81:in `block in require'
/usr/lib/ruby/vendor_ruby/bundler/runtime.rb:70:in `each'
/usr/lib/ruby/vendor_ruby/bundler/runtime.rb:70:in `require'
/usr/lib/ruby/vendor_ruby/bundler.rb:102:in `require'
/var/scratch/src/foreman/foreman/config/application.rb:36:in `<top (required)>'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/railties-4.2.6/lib/rails/commands/commands_tasks.rb:78:in `require'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/railties-4.2.6/lib/rails/commands/commands_tasks.rb:78:in `block in server'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/railties-4.2.6/lib/rails/commands/commands_tasks.rb:75:in `tap'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/railties-4.2.6/lib/rails/commands/commands_tasks.rb:75:in `server'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/railties-4.2.6/lib/rails/commands/commands_tasks.rb:39:in `run_command!'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/railties-4.2.6/lib/rails/commands.rb:17:in `<top (required)>'
/var/scratch/src/foreman/foreman/bin/rails:9:in `require'
/var/scratch/src/foreman/foreman/bin/rails:9:in `<top (required)>'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/spring-1.7.2/lib/spring/client/rails.rb:28:in `load'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/spring-1.7.2/lib/spring/client/rails.rb:28:in `call'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/spring-1.7.2/lib/spring/client/command.rb:7:in `call'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/spring-1.7.2/lib/spring/client.rb:30:in `run'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/spring-1.7.2/bin/spring:49:in `<top (required)>'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/spring-1.7.2/lib/spring/binstub.rb:11:in `load'
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/spring-1.7.2/lib/spring/binstub.rb:11:in `<top (required)>'
/var/scratch/src/foreman/foreman/bin/spring:13:in `require'
/var/scratch/src/foreman/foreman/bin/spring:13:in `<top (required)>'
bin/rails:3:in `load'
bin/rails:3:in `<top (required)>'

Uncommenting the require 'deface' makes the server start again (but
one cant use any plugins). This used to work a couple of weeks ago.

My guess is that deface wants to print a warning but colorize is not
yet initialized. I've attaced my Gemfile.lock for reference. As a
plugin one can use [1]. Can't look into this in more detail atm so any
pointers would be welcome.

[1] https://github.com/agx/foreman_image_upload

Actions #1

Updated by Dominic Cleal almost 9 years ago

The attached Gemfile.lock isn't present, but I'd verify that colorize is being added to the bundle and installed (bundle show, bundle show colorize) as it's a runtime dep of deface. You could also try removing Gemfile.lock and reinstalling it, or upgrading Bundler.

Actions #2

Updated by Guido Günther almost 9 years ago

  • Status changed from New to Closed

Dominic Cleal wrote:

The attached Gemfile.lock isn't present, but I'd verify that colorize is being added to the bundle and installed (bundle show, bundle show colorize) as it's a runtime dep of deface. You could also try removing Gemfile.lock and reinstalling it, or upgrading Bundler.

You hit it

$ bundle  show colorize
The gem colorize has been deleted. It was installed at:
/var/scratch/src/foreman/foreman/.bundle/vendor/ruby/2.3.0/gems/colorize-0.8.1

No idea how this happened though (I sure did not delete it)

$ bundle exec gem uninstall colorize
$ bundle update

fixed it. Thanks a lot.

Actions #3

Updated by Dominic Cleal almost 9 years ago

  • Tracker changed from Bug to Support
  • Status changed from Closed to Resolved
Actions

Also available in: Atom PDF