haru / redmine_code_review

70 stars 29 forks source link

Internal error occurred when click code review link #17

Open nop0x0000 opened 5 years ago

nop0x0000 commented 5 years ago

Internal error occurred when click code review link

Environment:
  Redmine version                4.0.3.stable
  Ruby version                   2.6.2-p47 (2019-03-13) [x86_64-linux]
  Rails version                  5.2.2.1
  Environment                    production
  Database adapter               PostgreSQL
  Mailer queue                   ActiveJob::QueueAdapters::AsyncAdapter
  Mailer delivery                smtp
SCM:
  Subversion                     1.9.5
  Mercurial                      4.0
  Bazaar                         2.8.0
  Git                            2.11.0
  Filesystem                     
  GitMirror                      2.11.0
Redmine plugins:
  redmine_absolute_dates         0.0.4
  redmine_code_review            1.0.0
  redmine_dmsf                   2.0.0
  redmine_git_mirror             0.8.0
  redmine_issue_templates        0.3.3
  redmine_japanese_help          0.0.1
  redmine_wysiwyg_editor         0.3.5

Steps to Reproduce

  1. Create a code review.
  2. Click Code reviews tab in the project.
  3. Click issue number link.
  4. Click "Code review:" link.
  5. Showed Internal error page.

Logs

redmine_1     | I, [2019-06-06T02:08:40.288711 #1]  INFO -- : Started GET "/projects/hello-world/code_review/show?review_id=2" for 172.19.0.2 at 2019-06-06 02:08:40 +0000
redmine_1     | I, [2019-06-06T02:08:40.289804 #1]  INFO -- : Processing by CodeReviewController#show as HTML
redmine_1     | I, [2019-06-06T02:08:40.289867 #1]  INFO -- :   Parameters: {"review_id"=>"2", "id"=>"hello-world"}
redmine_1     | I, [2019-06-06T02:08:40.357694 #1]  INFO -- :   Current user: m.kudo (id=44)
redmine_1     | I, [2019-06-06T02:08:40.383526 #1]  INFO -- : Completed 500 Internal Server Error in 94ms (ActiveRecord: 71.4ms)
redmine_1     | F, [2019-06-06T02:08:40.384217 #1] FATAL -- :
redmine_1     | F, [2019-06-06T02:08:40.384254 #1] FATAL -- : ActionController::UrlGenerationError (No route matches {:action=>"diff", :controller=>"repositories", :id=>#<Project id: 22, name: "Hello-World", description: "開発支援サーバの使い方を練習するためのプロジェクトです。", homepage: "", is_public: true, parent_id: nil, created_on: "2019-06-05 00:21:08", updated_on: "2019-06-05 09:41:22", identifier: "hello-world", status: 1, lft: 5, rgt: 6, inherit_members: false, default_version_id: nil, default_assigned_to_id: nil, dmsf_description: nil, dmsf_notification: false, dmsf_act_as_attachable: 1>, :path=>[[".", ""]], :repository_id=>nil, :rev=>"850948d73fce1ddbffaf8f010efd1253be3e8b0a"}):
redmine_1     | F, [2019-06-06T02:08:40.384275 #1] FATAL -- :
redmine_1     | F, [2019-06-06T02:08:40.384302 #1] FATAL -- : plugins/redmine_code_review/app/controllers/code_review_controller.rb:259:in `show'
redmine_1     | lib/redmine/sudo_mode.rb:63:in `sudo_mode'
redmine_1     | plugins/redmine_dmsf/lib/redmine_dmsf/webdav/custom_middleware.rb:68:in `call'

I'm Japanese. Let me apologize for my poor English.

parmalatinter commented 4 years ago

I fixed that issue by following steps.

  1. Replace 'config/routes.rb' to following file. https://github.com/haru/redmine_code_review/pull/18/commits/292883494ecfa94f993597d226b750af3da7ad29#diff-21497849d8f00507c9c8dcaf6288b136L1
  2. Exec commands. bundle exec rake tmp:cache:clear bundle exec rake assets:clobber RAILS_ENV=production bundle exec rake assets:precompile RAILS_ENV=production
  3. Restart Redmine.
zyg1014 commented 4 years ago

I fixed that issue by following steps.

  1. Replace 'config/routes.rb' to following file. 2928834#diff-21497849d8f00507c9c8dcaf6288b136L1
  2. Exec commands. bundle exec rake tmp:cache:clear bundle exec rake assets:clobber RAILS_ENV=production bundle exec rake assets:precompile RAILS_ENV=production
  3. Restart Redmine.

Not fixed on 4.0.1

Environment: Redmine version 4.0.1.stable Ruby version 2.4.5-p335 (2018-10-18) [i386-mingw32] Rails version 5.2.2 Environment production Database adapter Mysql2 Mailer queue ActiveJob::QueueAdapters::AsyncAdapter Mailer delivery smtp SCM: Subversion 1.10.3 Filesystem
Redmine plugins: redmine_code_review 1.0.0