Project

General

Profile

Plugin 404 Errors

Added by Shad Storhaug over 11 years ago

I have been tinkering all day, but can't seem to get any plugin to work in Redmine. I am using the BitNami Redmine Stack (2.1.2) on Windows.

I managed to get 2 plugins to install, but after installation I am still having problems getting the urls of the new plugin to load.

I installed the 2.x port of the stuff-to-do-plugin from https://github.com/Rumega/redmine-stuff-to-do-plugin, ran the migrations, and restarted both Thin services. Now I am able to see the plugin under Administration > Plugins, and I also see the link to "Stuff to do" in the upper left. However, when I click either link, I get a 404 error.

Here are the contents of the log for each link:

ActionController::RoutingError (uninitialized constant StuffToDoController):
activesupport (3.2.8) lib/active_support/inflector/methods.rb:219:in `constantize'
activesupport (3.2.8) lib/active_support/inflector/methods.rb:218:in `each'
activesupport (3.2.8) lib/active_support/inflector/methods.rb:218:in `constantize'
actionpack (3.2.8) lib/action_dispatch/routing/route_set.rb:69:in `controller_reference'
actionpack (3.2.8) lib/action_dispatch/routing/route_set.rb:54:in `controller'
actionpack (3.2.8) lib/action_dispatch/routing/route_set.rb:32:in `call'
journey (1.0.4) lib/journey/router.rb:68:in `call'
journey (1.0.4) lib/journey/router.rb:56:in `each'
journey (1.0.4) lib/journey/router.rb:56:in `call'
actionpack (3.2.8) lib/action_dispatch/routing/route_set.rb:600:in `call'
rack-openid (1.3.1) lib/rack/openid.rb:98:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/best_standards_support.rb:17:in `call'
rack (1.4.1) lib/rack/etag.rb:23:in `call'
rack (1.4.1) lib/rack/conditionalget.rb:25:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/head.rb:14:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/params_parser.rb:21:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/flash.rb:242:in `call'
rack (1.4.1) lib/rack/session/abstract/id.rb:205:in `context'
rack (1.4.1) lib/rack/session/abstract/id.rb:200:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/cookies.rb:339:in `call'
activerecord (3.2.8) lib/active_record/query_cache.rb:64:in `call'
activerecord (3.2.8) lib/active_record/connection_adapters/abstract/connection_pool.rb:473:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/callbacks.rb:28:in `call'
activesupport (3.2.8) lib/active_support/callbacks.rb:405:in `_run__625342628__call__4__callbacks'
activesupport (3.2.8) lib/active_support/callbacks.rb:405:in `send'
activesupport (3.2.8) lib/active_support/callbacks.rb:405:in `__run_callback'
activesupport (3.2.8) lib/active_support/callbacks.rb:385:in `_run_call_callbacks'
activesupport (3.2.8) lib/active_support/callbacks.rb:81:in `send'
activesupport (3.2.8) lib/active_support/callbacks.rb:81:in `run_callbacks'
actionpack (3.2.8) lib/action_dispatch/middleware/callbacks.rb:27:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/remote_ip.rb:31:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/debug_exceptions.rb:16:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/show_exceptions.rb:56:in `call'
railties (3.2.8) lib/rails/rack/logger.rb:26:in `call_app'
railties (3.2.8) lib/rails/rack/logger.rb:16:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/request_id.rb:22:in `call'
rack (1.4.1) lib/rack/methodoverride.rb:21:in `call'
rack (1.4.1) lib/rack/runtime.rb:17:in `call'
activesupport (3.2.8) lib/active_support/cache/strategy/local_cache.rb:72:in `call'
rack (1.4.1) lib/rack/lock.rb:15:in `call'
actionpack (3.2.8) lib/action_dispatch/middleware/static.rb:62:in `call'
rack-cache (1.2) lib/rack/cache/context.rb:136:in `forward'
rack-cache (1.2) lib/rack/cache/context.rb:245:in `fetch'
rack-cache (1.2) lib/rack/cache/context.rb:185:in `lookup'
rack-cache (1.2) lib/rack/cache/context.rb:66:in `call!'
rack-cache (1.2) lib/rack/cache/context.rb:51:in `call'
railties (3.2.8) lib/rails/engine.rb:479:in `call'
railties (3.2.8) lib/rails/application.rb:223:in `call'
railties (3.2.8) lib/rails/railtie/configurable.rb:30:in `send'
railties (3.2.8) lib/rails/railtie/configurable.rb:30:in `method_missing'
thin (1.3.1) lib/thin/connection.rb:80:in `pre_process'
thin (1.3.1) lib/thin/connection.rb:78:in `catch'
thin (1.3.1) lib/thin/connection.rb:78:in `pre_process'
thin (1.3.1) lib/thin/connection.rb:53:in `process'
thin (1.3.1) lib/thin/connection.rb:38:in `receive_data'
eventmachine-1.0.0.rc.4-x86 (mingw32) lib/eventmachine.rb:187:in `run_machine'
eventmachine-1.0.0.rc.4-x86 (mingw32) lib/eventmachine.rb:187:in `run'
thin (1.3.1) lib/thin/backends/base.rb:61:in `start'
thin (1.3.1) lib/thin/server.rb:159:in `start'
thin (1.3.1) lib/thin/controllers/controller.rb:86:in `start'
thin (1.3.1) lib/thin/runner.rb:185:in `send'
thin (1.3.1) lib/thin/runner.rb:185:in `run_command'
thin (1.3.1) lib/thin/runner.rb:151:in `run!'
thin (1.3.1) bin/thin:6
bin/thin:16:in `load'
bin/thin:16

Started GET "/settings/plugin/stuff_to_do_plugin" for 127.0.0.1 at Wed Nov 14 03:30:03 -0800 2012
Processing by SettingsController#plugin as HTML
Parameters: {"id"=>"stuff_to_do_plugin"}
Current user: nightowl888 (id=1)
Rendered settings/plugin.html.erb within layouts/admin (0.0ms)
Missing template, responding with 404
Rendered common/error.html.erb within layouts/base (0.0ms)
Completed 404 Not Found in 47ms (Views: 15.6ms | ActiveRecord: 0.0ms)

I am a noob when it comes to ruby on rails, so if there is anything else required to figure this out, please be specific with your request (and keep in mind I am on Windows!)


Replies (8)

RE: Plugin 404 Errors - Added by Mohsin Hijazee over 11 years ago

Exaclty same is the issue with me but I am trying to develop a plugin instead of installing one. Not sure if that's the issue with latest redmine 2.1.2 release or what.

I tried something that didn't work for me but may be it works for you, do this:

in config/application.rb find this line:

# Only load the plugins named here, in the order given (default is alphabetical).
# :all can be used as a placeholder for all plugins not explicitly named.
# config.plugins = [:exception_notification, :ssl_requirement, :all]

Uncomment this line and let me know if it works.

RE: Plugin 404 Errors - Added by Shad Storhaug over 11 years ago

Moshin,

Thanks for the advice. I was hopeful because it was something I hadn't attempted yet, but unfortunately it did not change the result. I get the same errors as before.

I am guessing that the error indicates that the Ruby parser is not picking up the file that contains the StuffToDoController class, so it cannot resolve the reference. I tried temporarily setting the Thin Windows service user to Administrator to rule out a Windows permission issue, but it didn't make any difference.

Note also that I have tried the Web Platform Installer version of Redmine as outlined here: http://www.helicontech.com/articles/installing-redmine-on-windows-in-production/

Although that it is a significantly different setup (running directly in IIS instead of using Thin under a windows service), this plugin won't load in that environment either.

I guess I could try setting up another virtual environment with a different (but still > 2.x) version of Redmine and see if I can get plugins to work. So far, I haven't been able to get a single plugin to function in 2.1.2 on Windows.

RE: Plugin 404 Errors - Added by Mohsin Hijazee over 11 years ago

Really strange, my setup is on Ubuntu and neither I am getting any plugin loaded. The issue is the same - Controllers aren't loaded by the Redmine core.

RE: Plugin 404 Errors - Added by Shad Storhaug over 11 years ago

Well, being that it doesn't seem to matter which version of Ruby (I have tried 1.8 and 1.9) or which OS is used, this is looking more like it might be a problem with Redmine itself.

I found a forum post while trying to find a fix, which seems to confirm that plugins (or more specifically, links in the top menu to a plugin controller) will work in version 2.0.3.
http://www.redmine.org/boards/2/topics/32065

I also took a look at the change logs and found 2 issues that dealt with plugins.

#11533 (fixed in version 2.0.4)
#11945 (fixed in version 2.1.1)

So, it looks like testing with version 2.0.3 will determine whether this is a configuration problem or a problem with Redmine. If it is a problem with Redmine, testing with either 2.0.4 or 2.1.0 will narrow down which of these versions it first appeared in (and possibly which fix caused it).

RE: Plugin 404 Errors - Added by Shad Storhaug over 11 years ago

Moshin,

Were you able to get this working? I am about ready to give up using plugins with Redmine because I can't seem to get any of them to work. I tried upgrading to 2.1.4, but no such luck.

Unfortunately, old Bitnami stacks are only available upon request and I haven't had the time to mess with it.

RE: Plugin 404 Errors - Added by Patrick Cummins almost 11 years ago

Did any of you get this working?

I'm running Redmine 2.1.6 and the latest 'stuff to do' plugin from the same source. I'm getting the same error.

RE: Plugin 404 Errors - Added by Stephen Curran over 10 years ago

I'm running Redmine 2.3.2.stable and got this plugin running using the files from https://github.com/Rumega/redmine-stuff-to-do-plugin. I had some initial issues with getting the plugin to install at all (migrate didn't perform the database migration), and then with the 404 errors. Here's what I did:

  • Moved the plugin from the vendor/plugins directory to the plugins directory.
  • Renamed the cloned folder from redmine-stuff-to-do-plugin to stuff_to_do_plugin
  • Ran the plugins migration task
  • Restarted redmine

I can now log in and do not get the 404 errors on either the config screen, nor the top menu stuff_to_do link.

RE: Plugin 404 Errors - Added by Daniel Albuschat about 10 years ago

Thanks Stephen Curran, renaming the folder helped for me, too!

    (1-8/8)