Content
You are here:
work_package view raises ActionController::RoutingError in 4.0.1
Added by Jangho Seo almost 10 years ago
Hello.
I recently upgraded from OpenProject 3.0.14 to OpenProject 4.0.1.
Unfortunately https://example.com/projects/management/work_packages gives me “Unable to retrieve query from URL” message (“management” is the project identifier)
and log file says:
Started GET "/api/experimental/projects/management/work_packages?page=1&per_page=10" for 147.x.x.x at 2014-11-15 10:12:48 +0900 Processing by Api::Experimental::WorkPackagesController#index as JSON Parameters: {"page"=>"1", "per_page"=>"10", "project_id"=>"management"} Completed 404 Not Found in 56.7ms ActionController::RoutingError (No route matches {:action=>"update", :controller=>"api/experimental/queries", :layout=>nil, :id=>#<Query id: nil, project_id: 3, name: "_", filters: [#<Queries::WorkPackages::Filter:0x007f4b8cf35118 @field=:status_id, @operator="o", @values=[""], @validation_context=nil, @errors=#<ActiveModel::Errors:0x007f4b8ca92868 @base=#<Queries::WorkPackages::Filter:0x007f4b8cf35118 ...>, @messages={}>>], user_id: 0, column_names: nil, sort_criteria: [], group_by: nil, is_public: true, display_sums: nil>}): app/controllers/api/experimental/concerns/query_loading.rb:85:in `block in allowed_links_on_query' app/controllers/api/experimental/concerns/query_loading.rb:75:in `tap' app/controllers/api/experimental/concerns/query_loading.rb:75:in `allowed_links_on_query' app/controllers/api/experimental/work_packages_controller.rb:178:in `query_as_json' app/controllers/api/experimental/work_packages_controller.rb:153:in `set_work_packages_meta_data' app/controllers/api/experimental/work_packages_controller.rb:139:in `current_work_packages' app/controllers/api/experimental/work_packages_controller.rb:52:in `index'
I am using nginx and passenger to deploy my OpenProject service, through manual installation driven by ruby-2.1.4.
Thanks.
Replies (5)
Hi, I experience the same problem when using the branch
release/4.0
, containing release v4.0.4, ordev
with Ruby 2.1.4 and the Passenger Apache module.Were you able to solve this?
Unfortunately, no.
I had to purge the old one and reinstall OpenProject, and migrate the necessary data manually :(
I believe this problem is due to the broken database schema, but I don’t have any accurate solution.
Sorry for not being much help :(
And I think #17928 means something :)
Having the exact same issue with v4.1.3. Going slightly insane here since try as i may, ruby is not my language and debugging this is incredibly frustrating. Close to giving up after 2 days of wasted time. With a clean install everything works perfectly. As soon as i try to migrate from older data, the error shows up.
Why would it not find action “update” inside the queries_controller.rb. I see it, it’s there. What database value can possibly affect routing? I changed the hostname in the settings table to the correct value.
Noob’s fix for the above problem:
Just comment out the code inside the Api::Experimental::Concerns::QueryLoading::allowed_links_on_query method. Let it return an empty {}. You’re not really losing anything since saved queries are not working anyway.