Defect #4970

Crash while deleting in-use enumeration

Added by Emmanuel Bastien over 7 years ago. Updated about 6 years ago.

Status:ClosedStart date:2010-03-02
Priority:LowDue date:
Assignee:-% Done:

0%

Category:Administration
Target version:0.9.4
Resolution:Fixed Affected version:0.9.3

Description

So far, the problem only happens when running with "RAILS_ENV=development".
I get the following stack while deleting a priority still assigned to at least one issue:

TypeError (can't dump anonymous class Class):
/opt/ruby-enterprise-1.8.7/lib/ruby/1.8/yaml/rubytypes.rb:6:in `to_yaml'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/connection_adapters/abstract/quoting.rb:31:in `quote'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/connection_adapters/mysql_adapter.rb:236:in `quote'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/base.rb:2392:in `quote_bound_value'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/base.rb:2352:in `replace_bind_variables'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/base.rb:2352:in `gsub'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/base.rb:2352:in `replace_bind_variables'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/base.rb:2341:in `sanitize_sql_array'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/base.rb:2230:in `sanitize_sql'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/base.rb:1494:in `merge_conditions'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/base.rb:1492:in `each'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/base.rb:1492:in `merge_conditions'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/base.rb:1804:in `add_conditions!'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/base.rb:1687:in `construct_finder_sql'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/base.rb:1548:in `find_every'
/opt/redmine-0.9.3/vendor/rails/activerecord/lib/active_record/base.rb:615:in `find'
/opt/redmine-0.9.3/app/controllers/enumerations_controller.rb:84:in `destroy'

Associated revisions

Revision 3524
Added by Jean-Philippe Lang over 7 years ago

Fixed: error while deleting an in-use enumeration (#4970).

History

#1 Updated by Jean-Philippe Lang over 7 years ago

  • Status changed from New to Resolved
  • Target version set to 0.9.4
  • Resolution set to Fixed

Fixed in r3524.

It was raised when running test/functional/enumerations_controller.rb but not when running all functional tests with rake test:functionals. Very strange... Anyway, the code was firing a deprecation warning, so it has to be fixed.
Thanks for pointing it out.

#2 Updated by Jean-Philippe Lang over 7 years ago

  • Subject changed from Crash while deleting in-use priority and RAILS_ENV=development to Crash while deleting in-use enumeration

#3 Updated by Jean-Philippe Lang over 7 years ago

  • Status changed from Resolved to Closed

#4 Updated by Geoffrey Larue about 6 years ago

SPAM

Also available in: Atom PDF