Uploaded image for project: 'SonarQube'
  1. SonarQube
  2. SONAR-6132

Dashboard is failing on removed components

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.1
    • Component/s: None
    • Labels:
      None

      Description

      When displaying dashboard on a removed file, a 500 error is returned.

      Steps to reproduce :

      • Analyse a project
      • Delete a file
      • Display the dashboard using the id or the key of the removed component

      Here are the logs :

      2015.01.30 09:26:04 ERROR web[o.s.s.ui.JRubyFacade]  Fail to render: http://localhost:9050/dashboard/index/6?did=1
      undefined method `parent' for nil:NilClass
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/app/controllers/dashboard_controller.rb:36:in `index'
      	org/jruby/RubyKernel.java:2223:in `send'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/base.rb:1333:in `perform_action'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/filters.rb:617:in `call_filters'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/filters.rb:610:in `perform_action_with_filters'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/benchmarking.rb:68:in `perform_action_with_benchmark'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activesupport-2.3.15/lib/active_support/core_ext/benchmark.rb:17:in `ms'
      	jar:file:/Users/julienlancelot/Dev/Utils/sonarqube-5.0/lib/server/jruby-complete-1.7.9.jar!/META-INF/jruby.home/lib/ruby/1.8/benchmark.rb:308:in `realtime'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activesupport-2.3.15/lib/active_support/core_ext/benchmark.rb:17:in `ms'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/benchmarking.rb:68:in `perform_action_with_benchmark'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/rescue.rb:160:in `perform_action_with_rescue'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/flash.rb:151:in `perform_action_with_flash'
      	org/jruby/RubyKernel.java:2223:in `send'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/base.rb:532:in `process'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/filters.rb:606:in `process_with_filters'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/base.rb:391:in `process'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/base.rb:386:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/routing/route_set.rb:450:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/dispatcher.rb:87:in `dispatch'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/dispatcher.rb:121:in `_call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/dispatcher.rb:130:in `build_middleware_stack'
      	org/jruby/RubyProc.java:290:in `call'
      	org/jruby/RubyProc.java:224:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/query_cache.rb:29:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/connection_adapters/abstract/query_cache.rb:34:in `cache'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/query_cache.rb:9:in `cache'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/query_cache.rb:28:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/connection_adapters/abstract/connection_pool.rb:361:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/string_coercion.rb:25:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/head.rb:9:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/methodoverride.rb:24:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/params_parser.rb:15:in `call'
      	file:/Users/julienlancelot/Dev/Utils/sonarqube-5.0/lib/server/jruby-rack-1.1.13.2.jar!/jruby/rack/session_store.rb:70:in `context'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/session/abstract/id.rb:58:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/failsafe.rb:26:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/dispatcher.rb:106:in `call'
      	file:/Users/julienlancelot/Dev/Utils/sonarqube-5.0/lib/server/jruby-rack-1.1.13.2.jar!/rack/adapter/rails.rb:34:in `serve_rails'
      	file:/Users/julienlancelot/Dev/Utils/sonarqube-5.0/lib/server/jruby-rack-1.1.13.2.jar!/rack/adapter/rails.rb:39:in `call'
      	file:/Users/julienlancelot/Dev/Utils/sonarqube-5.0/lib/server/jruby-rack-1.1.13.2.jar!/rack/handler/servlet.rb:22:in `call'
      
      2015.01.30 09:26:04 ERROR web[o.s.s.ui.JRubyFacade]  Fail to render: http://localhost:9050/dashboard/index/6?did=1
      Can only render or redirect once per action
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/base.rb:891:in `render'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/benchmarking.rb:51:in `render_with_benchmark'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activesupport-2.3.15/lib/active_support/core_ext/benchmark.rb:17:in `ms'
      	jar:file:/Users/julienlancelot/Dev/Utils/sonarqube-5.0/lib/server/jruby-complete-1.7.9.jar!/META-INF/jruby.home/lib/ruby/1.8/benchmark.rb:308:in `realtime'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activesupport-2.3.15/lib/active_support/core_ext/benchmark.rb:17:in `ms'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/benchmarking.rb:51:in `render_with_benchmark'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/app/controllers/application_controller.rb:215:in `render_error'
      	org/jruby/RubyMethod.java:128:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activesupport-2.3.15/lib/active_support/rescuable.rb:73:in `rescue_with_handler'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/rescue.rb:73:in `rescue_action'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/rescue.rb:162:in `perform_action_with_rescue'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/flash.rb:151:in `perform_action_with_flash'
      	org/jruby/RubyKernel.java:2223:in `send'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/base.rb:532:in `process'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/filters.rb:606:in `process_with_filters'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/base.rb:391:in `process'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/base.rb:386:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/routing/route_set.rb:450:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/dispatcher.rb:87:in `dispatch'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/dispatcher.rb:121:in `_call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/dispatcher.rb:130:in `build_middleware_stack'
      	org/jruby/RubyProc.java:290:in `call'
      	org/jruby/RubyProc.java:224:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/query_cache.rb:29:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/connection_adapters/abstract/query_cache.rb:34:in `cache'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/query_cache.rb:9:in `cache'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/query_cache.rb:28:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/activerecord-2.3.15/lib/active_record/connection_adapters/abstract/connection_pool.rb:361:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/string_coercion.rb:25:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/head.rb:9:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/methodoverride.rb:24:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/params_parser.rb:15:in `call'
      	file:/Users/julienlancelot/Dev/Utils/sonarqube-5.0/lib/server/jruby-rack-1.1.13.2.jar!/jruby/rack/session_store.rb:70:in `context'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/rack-1.1.6/lib/rack/session/abstract/id.rb:58:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/failsafe.rb:26:in `call'
      	/Users/julienlancelot/Dev/Utils/sonarqube-5.0/web/WEB-INF/gems/gems/actionpack-2.3.15/lib/action_controller/dispatcher.rb:106:in `call'
      	file:/Users/julienlancelot/Dev/Utils/sonarqube-5.0/lib/server/jruby-rack-1.1.13.2.jar!/rack/adapter/rails.rb:34:in `serve_rails'
      	file:/Users/julienlancelot/Dev/Utils/sonarqube-5.0/lib/server/jruby-rack-1.1.13.2.jar!/rack/adapter/rails.rb:39:in `call'
      	file:/Users/julienlancelot/Dev/Utils/sonarqube-5.0/lib/server/jruby-rack-1.1.13.2.jar!/rack/handler/servlet.rb:22:in `call'
      

        Attachments

          Activity

            People

            Assignee:
            julien.lancelot Julien Lancelot
            Reporter:
            julien.lancelot Julien Lancelot
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Due:
              Created:
              Updated:
              Resolved: