Defect #7969

Redmine dosn't work with sqlite3-ruby 1.3.3

Added by Daniel Bond over 6 years ago. Updated over 2 years ago.

Status:ClosedStart date:2011-03-23
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:Database
Target version:-
Resolution:Cant reproduce Affected version:

Description

I'm moving redmine (1.0.1) to a new server (ruby 1.8.7), when I installed sqlite3-ruby 1.3.3 on the new machine, redmine dosn't work correctly:

ArgumentError (comparison of Time with String failed):
app/models/setting.rb:152:in `<='
app/models/setting.rb:152:in `check_cache'
app/controllers/application_controller.rb:55:in `user_setup'
/usr/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
/usr/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
/usr/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:95:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `each'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:23:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:82:in `start'

the problem occurs because with sqlite3-ruby 1.3.3, "settings_updated_on = Setting.maximum(:updated_on)" is a String.

I installed sqlite3-ruby 1.2.4 and it worked fine again.

If this is a issue with sqlite3-ruby rather than redmine, I'd not be surprised, but I would imagine other users might face the same issue, and in that case might be worth noting somewhere.


Related issues

Related to Redmine - Feature #5638: Use Bundler (Gemfile) for gem management Closed 2010-06-02
Duplicated by Redmine - Defect #10506: Internal error after reinstalling redmin Closed

History

#1 Updated by Etienne Massip over 6 years ago

  • Category set to Database

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

  • Resolution set to Cant reproduce

I actually run tests with sqlite3 1.3.3 x86-mingw32 and don't have this issue.

>> Setting.maximum(:updated_on)
=> Sun Apr 03 18:25:29 +0200 2011
>> Setting.maximum(:updated_on).class
=> Time

#3 Updated by Yuya Nishihara over 6 years ago

the problem occurs because with sqlite3-ruby 1.3.3, "settings_updated_on = Setting.maximum(:updated_on)" is a String.

Do you have some incompatible plugins installed, by any chance? In my case, stuff_to_do_plugin produces this problem.

Try rake db:schema:dump to see if db/schema.rb gets broken. If it contains "Could not dump table ... because of following StandardError", remove suspected plugins until db/schema.rb becomes correct.

#4 Updated by Daniel Bond over 6 years ago

Do you have some incompatible plugins installed, by any chance? In my case, stuff_to_do_plugin produces this problem.

You are probably right. I did have the stuff_to_do_plugin installed, and that may well have been the root of the cause.

#5 Updated by Go MAEDA over 2 years ago

  • Status changed from New to Closed

Caused by a plugin, closing this issue.

Also available in: Atom PDF