Project

General

Profile

Defect #1425

when I open the code review page in project ,it occured 500 error

Added by Steven Wong over 4 years ago. Updated about 4 years ago.

Status:
解決(Resolved)
Priority:
通常(Normal)
Assignee:
Target version:
-
Start date:
08/15/2016
Due date:
% Done:

100%

Estimated time:

Description

my environment is

Environment:
  Redmine version                3.3.0.stable.15736
  Ruby version                   2.2.4-p230 (2015-12-16) [x86_64-linux]
  Rails version                  4.2.7.1
  Environment                    production
  Database adapter               Mysql2

error logs as follows

Started GET "/projects/uth_testteam/code_review/index" for 192.168.60.238 at 2016-08-15 16:32:08 +0800
Processing by CodeReviewController#index as HTML
  Parameters: {"id"=>"uth_testteam"}
  Current user: hui.wang (id=8)
Completed 500 Internal Server Error in 44ms (ActiveRecord: 32.7ms)
  Rendered /usr/local/rvm/gems/ruby-2.2.4@newgemset/gems/exception_notification-4.2.1/lib/exception_notifier/views/exception_notifier/_request.text.erb (0.3ms)
  Rendered /usr/local/rvm/gems/ruby-2.2.4@newgemset/gems/exception_notification-4.2.1/lib/exception_notifier/views/exception_notifier/_title.text.erb (0.2ms)
  Rendered /usr/local/rvm/gems/ruby-2.2.4@newgemset/gems/exception_notification-4.2.1/lib/exception_notifier/views/exception_notifier/_session.text.erb (0.6ms)
  Rendered /usr/local/rvm/gems/ruby-2.2.4@newgemset/gems/exception_notification-4.2.1/lib/exception_notifier/views/exception_notifier/_title.text.erb (0.1ms)
  Rendered /usr/local/rvm/gems/ruby-2.2.4@newgemset/gems/exception_notification-4.2.1/lib/exception_notifier/views/exception_notifier/_environment.text.erb (2.1ms)
  Rendered /usr/local/rvm/gems/ruby-2.2.4@newgemset/gems/exception_notification-4.2.1/lib/exception_notifier/views/exception_notifier/_title.text.erb (0.1ms)
  Rendered /usr/local/rvm/gems/ruby-2.2.4@newgemset/gems/exception_notification-4.2.1/lib/exception_notifier/views/exception_notifier/_backtrace.text.erb (0.1ms)
  Rendered /usr/local/rvm/gems/ruby-2.2.4@newgemset/gems/exception_notification-4.2.1/lib/exception_notifier/views/exception_notifier/_title.text.erb (0.1ms)
  Rendered /usr/local/rvm/gems/ruby-2.2.4@newgemset/gems/exception_notification-4.2.1/lib/exception_notifier/views/exception_notifier/exception_notification.text.erb (11.4ms)

ActiveRecord::StatementInvalid (Mysql2::Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ':conditions=>["project_id = ? and issue_id is NOT NULL", 2]}) FROM `code_reviews' at line 1: SELECT COUNT({:conditions=>["project_id = ? and issue_id is NOT NULL", 2]}) FROM `code_reviews`):
  plugins/redmine_code_review/app/controllers/code_review_controller.rb:39:in `index'
  lib/redmine/sudo_mode.rb:63:in `sudo_mode'

Also available in: Atom PDF