alexbevi / redmine_knowledgebase

A knowledgebase plugin for Redmine
453 stars 197 forks source link

Error: LoadError: cannot load such file -- redmine_acts_as_taggable_on/initialize #273

Closed Josuefdz closed 9 years ago

Josuefdz commented 9 years ago

I just installed a clean version of Redmine 2.6.2.0 over windows. After the install I'm able to view Redmine and navigate with no problem. I then go ahead and install the redmine_knowledgebase plugin, I then execute:

rake redmine:plugins:migrate RAILS_ENV=production --trace

This is the result I get:

(in D:/Redmine/apps/redmine/htdocs) * Invoke redmine:plugins:migrate (first_time) * Invoke environment (first_time) \ Execute environment rake aborted! LoadError: cannot load such file -- redmine_acts_as_taggable_on/initialize D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:251:in require' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:251:inblock in require' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:236:in load_dependency' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:251:inrequire' D:/Redmine/apps/redmine/htdocs/plugins/redmine_knowledgebase/init.rb:2:in <top(required)>' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:251:inrequire' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:251:in block in require' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:236:inload_dependency' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:251:in require' D:/Redmine/apps/redmine/htdocs/lib/redmine/plugin.rb:150:inblock in load' D:/Redmine/apps/redmine/htdocs/lib/redmine/plugin.rb:141:in each' D:/Redmine/apps/redmine/htdocs/lib/redmine/plugin.rb:141:inload' D:/Redmine/apps/redmine/htdocs/config/initializers/30-redmine.rb:19:in <top (required)>' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:245:inload' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:245:in block in load' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:236:inload_dependency' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:245:in load' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/railties-3.2.21/lib/rails/engine.rb:593:inblock (2 levels) in class:Engine' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/railties-3.2.21/lib/rails/engine.rb:592:in each' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/railties-3.2.21/lib/rails/engine.rb:592:inblock in class:Engine' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/railties-3.2.21/lib/rails/initializable.rb:30:in instance_exec' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/railties-3.2.21/lib/rails/initializable.rb:30:inrun' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/railties-3.2.21/lib/rails/initializable.rb:55:in block in run_initializers' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/railties-3.2.21/lib/rails/initializable.rb:54:ineach' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/railties-3.2.21/lib/rails/initializable.rb:54:in run_initializers' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/railties-3.2.21/lib/rails/application.rb:136:ininitialize!' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/railties-3.2.21/lib/rails/railtie/configurable.rb:30:in method_missing' D:/Redmine/apps/redmine/htdocs/config/environment.rb:14:in<top (required)>' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:251:in require' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:251:inblock in require' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:236:in load_dependency' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/activesupport-3.2.21/lib/active_support/dependencies.rb:251:inrequire' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/railties-3.2.21/lib/rails/application.rb:103:in require_environment!' D:/Redmine/apps/redmine/htdocs/vendor/bundle/ruby/2.0.0/gems/railties-3.2.21/lib/rails/application.rb:305:inblock (2 levels) in initialize_tasks' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/task.rb:240:in call' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/task.rb:240:inblock in execute' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/task.rb:235:in each' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/task.rb:235:inexecute' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/task.rb:179:in block in invoke_with_call_chain' D:/Redmine/ruby/lib/ruby/2.0.0/monitor.rb:211:inmon_synchronize' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/task.rb:172:in invoke_with_call_chain' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/task.rb:201:inblock in invoke_prerequisites' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/task.rb:199:in each' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/task.rb:199:ininvoke_prerequisites' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/task.rb:178:in block in invoke_with_call_chain' D:/Redmine/ruby/lib/ruby/2.0.0/monitor.rb:211:inmon_synchronize' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/task.rb:172:in invoke_with_call_chain' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/task.rb:165:ininvoke' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:150:in invoke_task' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:106:inblock (2 levels) in top_level' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:106:in each' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:106:inblock in top_level' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:115:in run_with_threads' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:100:intop_level' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:78:in block in run' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:176:instandard_exception_handling' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/lib/rake/application.rb:75:in run' D:/Redmine/ruby/lib/ruby/gems/2.0.0/gems/rake-10.4.2/bin/rake:33:in<top (required)>' D:/Redmine/ruby/bin/rake:23:in load' D:/Redmine/ruby/bin/rake:23:in

' Tasks: TOP => redmine:plugins:migrate => environment

Any ideas as to why I'm getting the error "cannot load such file -- redmine_acts_as_taggable_on/initialize", I've already installed the gem, here's a list of all the gems installed:

* LOCAL GEMS *

actionmailer (4.2.0) actionpack (4.2.0) actionview (4.2.0) activejob (4.2.0) activemodel (4.2.0) activerecord (4.2.0) activesupport (4.2.0) acts-as-taggable-on (2.4.1) arel (6.0.0) aws-sdk (1.8.3.1) bigdecimal (1.2.0) binding_of_caller (0.7.2) builder (3.1.4) bundler (1.7.0) byebug (3.5.1) coffee-rails (4.1.0) coffee-script (2.2.0) coffee-script-source (1.6.2) columnize (0.9.0) crack (0.3.1) daemons (1.1.8) debug_inspector (0.0.2) debugger-linecache (1.2.0) diff-lcs (1.1.3) erubis (2.7.0) eventmachine (1.0.2 x86-mingw32, 1.0.0) execjs (1.4.0) globalid (0.3.0) hike (1.2.3) hoe (3.0.6) httparty (0.8.3) i18n (0.7.0) io-console (0.4.2) jbuilder (2.0.7) jquery-rails (3.0.4) json (1.8.1, 1.7.7) loofah (2.0.1) mail (2.5.4) mime-types (1.23) mini_magick (3.4) mini_portile (0.6.0) minitest (5.3.3, 4.3.2) multi_json (1.3.6) multi_xml (0.5.1) mysql2 (0.3.16 x86-mingw32, 0.2.18) nokogiri (1.6.5 x86-mingw32) pg (0.18.0.pre20141117110243 x86-mingw32) polyglot (0.3.3) psych (2.0.0) rack (1.6.0) rack-test (0.6.2) rails (4.2.0) rails-deprecated_sanitizer (1.0.3) rails-dom-testing (1.0.5) rails-html-sanitizer (1.0.1) railties (4.2.0) rake (10.4.2, 0.9.6) rake-compiler (0.8.1) rdoc (4.0.0) redmine_acts_as_taggable_on (1.0.0) rmagick (2.13.4 x86-mingw32) rspec (2.11.0) rspec-core (2.11.1) rspec-expectations (2.11.2) rspec-mocks (2.11.1) rvm (1.11.3.5) sass (3.2.9) sass-rails (5.0.1) sdoc (0.4.0) slop (3.6.0) spring (1.2.0) sprockets (2.10.0, 2.2.1) sprockets-rails (2.0.1) sqlite3 (1.3.8 x86-mingw32) sqlite3-ruby (1.3.2 x86-mingw32) subexec (0.2.2) test-unit (2.0.0.0) thin (1.6.1 x86-mingw32, 1.5.1) thor (0.18.1) thread_safe (0.3.4) tilt (1.4.1) treetop (1.4.14) turbolinks (1.2.0) tzinfo (1.1.0) tzinfo-data (1.2014.2) uglifier (2.1.1) uuidtools (2.1.3) web-console (2.0.0) ya2yaml (0.31)

Here's my environment details:

RubyGems Environment:

  • RUBYGEMS VERSION: 2.0.14
  • RUBY VERSION: 2.0.0 (2014-10-27 patchlevel 594) [i386-mingw32]
  • INSTALLATION DIRECTORY: D:/Redmine/ruby/lib/ruby/gems/2.0.0
  • RUBY EXECUTABLE: D:/Redmine/ruby/bin/ruby.exe
  • EXECUTABLE DIRECTORY: D:/Redmine/ruby/bin
  • RUBYGEMS PLATFORMS:
    • ruby
    • x86-mingw32
  • GEM PATHS:
    • D:/Redmine/ruby/lib/ruby/gems/2.0.0
  • GEM CONFIGURATION:
    • :update_sources => true
    • :verbose => true
    • :backtrace => false
    • :bulk_threshold => 1000
  • REMOTE SOURCES:
alexbevi commented 9 years ago

Just curious if you're still having this problem.

Also, after you added the plugin, did you remember to rerun the bundle via bundle install?

Josuefdz commented 9 years ago

I thought I had already run bundle install, but it seems that I was missing that step.

So here's what I did:

Executed bundle install but it returned an error

D:\Redmine\apps\redmine\htdocs\bin>bundle install DL is deprecated, please use Fiddle You are trying to install in deployment mode after changing your Gemfile. Run bundle install elsewhere and add the updated Gemfile.lock to version control.

If this is a development machine, remove the Gemfile freeze by running bundle install --no-deployment.

You have added to the Gemfile:

  • redmine_acts_as_taggable_on (~> 1.0)
  • ya2yaml

So I then executed bundle install --no-deployment and this is what it return

D:\Redmine\apps\redmine\htdocs\bin>bundle install --no-deployment DL is deprecated, please use Fiddle Fetching gem metadata from https://rubygems.org/......... Resolving dependencies... Using rake 10.4.2 Installing i18n 0.6.11 Installing multi_json 1.10.1 Installing activesupport 3.2.21 Installing builder 3.0.4 Installing activemodel 3.2.21 Using erubis 2.7.0 Installing journey 1.0.4 Installing rack 1.4.5 Installing rack-cache 1.2 Installing rack-test 0.6.3 Using hike 1.2.3 Using tilt 1.4.1 Installing sprockets 2.2.3 Installing actionpack 3.2.21 Installing mime-types 1.25.1 Installing polyglot 0.3.5 Installing treetop 1.4.15 Using mail 2.5.4 Installing actionmailer 3.2.21 Installing arel 3.0.3 Installing tzinfo 0.3.43 Installing activerecord 3.2.21 Installing activeresource 3.2.21 Using bundler 1.7.0 Installing rack-ssl 1.3.4 Installing json 1.8.2 Installing rdoc 3.12.2 Installing thor 0.19.1 Installing railties 3.2.21 Installing rails 3.2.21 Using acts-as-taggable-on 2.4.1 Installing coderay 1.1.0 Installing daemons 1.1.9 Installing eventmachine 1.0.3 Installing jquery-rails 3.1.2 Installing mysql2 0.3.11 Installing net-ldap 0.3.1 Installing ruby-openid 2.3.0 Installing rack-openid 1.4.2 Installing rbpdf 1.18.5 Installing redcarpet 2.3.0 Using redmine_acts_as_taggable_on 1.0.0 Installing request_store 1.0.5 Using rmagick 2.13.4 Using thin 1.6.1 Using ya2yaml 0.31 Updating files in vendor/cache

  • acts-as-taggable-on-2.4.1.gem
  • redmine_acts_as_taggable_on-1.0.0.gem
    • ya2yaml-0.31.gem Your bundle is complete! Gems in the groups development, test and sqlite were not installed. Use bundle show [gemname] to see where a bundled gem is installed. Post-install message from rdoc: Depending on your version of ruby, you may need to install ruby rdoc/ri data:

<= 1.8.6 : unsupported = 1.8.7 : gem install rdoc-data; rdoc-data --install = 1.9.1 : gem install rdoc-data; rdoc-data --install

= 1.9.2 : nothing to do! Yay!

After that, I executed rake redmine:plugins:migrate RAILS_ENV=production and the plugin was installed successfully.

alexbevi commented 9 years ago

Thanks for getting back to me @Josuefdz. I'm closing the issue as it seems like it's not a bug :)

laoshaw commented 7 years ago

I have the same issue on debian 9 though, a fresh redmine installation, and this is the first plugin I added, run 'bundle install' just fine, but

debian:/usr/share/redmine/lib$ sudo rake redmine:plugins:migrate NAME=redmine_knowledgebase
(in /usr/share/redmine)
rake aborted!
LoadError: cannot load such file -- redmine_acts_as_taggable_on/initialize
/usr/share/redmine/lib/plugins/redmine_knowledgebase/init.rb:2:in `block in <top (required)>'
/usr/share/redmine/config/initializers/00-core_plugins.rb:12:in `eval'
/usr/share/redmine/config/initializers/00-core_plugins.rb:12:in `block in <top (required)>'
/usr/share/redmine/config/initializers/00-core_plugins.rb:2:in `each'
/usr/share/redmine/config/initializers/00-core_plugins.rb:2:in `<top (required)>'
/usr/share/redmine/config/environment.rb:14:in `<top (required)>'
Tasks: TOP => redmine:plugins:migrate => environment
(See full trace by running task with --trace)