Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash in 0.38 when viewing requests in "waiting_classification" state #5846

Closed
laurentS opened this issue Aug 3, 2020 · 2 comments
Closed

Comments

@laurentS
Copy link
Contributor

laurentS commented Aug 3, 2020

We seem to have hit a bug at madada.fr after upgrading to 0.38 (from 0.34 over the weekend, so I'm not 100% sure at which point the error happened, although I suspect 0.38).

The bug seems to happen when viewing a request that is in waiting_classification state, as a logged in user. If not logged in, I can view the request. Likewise, requests in other states seem to be displayed correctly.

I have checked the modified templates vs our customised ones, and can't see any overlap, so I don't think this is the issue. The ones listed in the backtrace below are not in our custom theme either.

The error message looks like this:

An ActionView::Template::Error occurred in request#show:

  undefined method `classifications_url' for #<#<Class:0x00005616b27d5540>:0x00007ff29efaab70>
Did you mean?  classification_label
  app/views/request/_describe_state.html.erb:3:in `_app_views_request__describe_state_html_erb___4340668194622414316_70340011378520'

and backtrace:

  app/views/request/_describe_state.html.erb:3:in `_app_views_request__describe_state_html_erb___4340668194622414316_70340011378520'
  app/views/request/show.html.erb:17:in `_app_views_request_show_html_erb__3285365887382993526_70340001304780'
  app/controllers/request_controller.rb:125:in `block (3 levels) in show'
  app/controllers/request_controller.rb:124:in `block in show'
  lib/alaveteli_localization.rb:43:in `with_locale'
  app/controllers/request_controller.rb:75:in `show'
  app/controllers/application_controller.rb:116:in `record_memory'
  lib/strip_empty_sessions.rb:15:in `call'

Did I miss anything in the upgrade process, or is this an actual bug?

@laurentS laurentS changed the title Crash in 0.38 when viewing requests in "to be sorted" state Crash in 0.38 when viewing requests in "waiting_classification" state Aug 3, 2020
@gbp
Copy link
Member

gbp commented Aug 3, 2020

I think okfnfr/dada-core#32 is the issue here.

@laurentS
Copy link
Contributor Author

laurentS commented Aug 3, 2020

Indeed, thanks @gbp and sorry for the noise. I patched config/routes.rb (our template, to be specific) to match the changes that happened for each version between 0.33 and 0.38, and it seems to be working fine now.

@laurentS laurentS closed this as completed Aug 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants