Defect #1292

error preview of new wiki page: Internal server error

Added by Luca Pireddu over 12 years ago. Updated over 12 years ago.

Status:ClosedStart date:2008-05-23
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:Wiki
Target version:-
Resolution:Fixed Affected version:

Description

I've created a new wiki page. I haven't saved it yet. When I click on "preview" Redmine produces an internal server error. I'm using HEAD. Here is the relevant log output:

Processing WikiController#preview (for 156.148.120.93 at 2008-05-23 11:59:02) [POST]
  Session ID: 76182564b0927e5bbf6ecf86fb74f26b
  Parameters: {"commit"=>"Save", "action"=>"preview", "id"=>"pgds", "controller"=>"wiki",
 "content"=>{"comments"=>"", "text"=>"h1. Modelling genealogy", "version"=>"0"}, 
 "page"=>"Modelling_genealogy"}

NoMethodError (undefined method `editable_by?' for nil:NilClass):
    /app/controllers/wiki_controller.rb:197:in `editable?'
    /app/controllers/wiki_controller.rb:165:in `preview'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:1158:in `send'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:1158:in `perform_action_without_filters'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/filters.rb:697:in `call_filters'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/filters.rb:689:in `perform_action_without_benchmark'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/benchmarking.rb:68:in `perform_action_without_rescue'
    /usr/lib/ruby/1.8/benchmark.rb:293:in `measure'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/benchmarking.rb:68:in `perform_action_without_rescue'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/rescue.rb:199:in `perform_action_without_caching'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/caching.rb:678:in `perform_action'
    /usr/lib/ruby/gems/1.8/gems/activerecord-2.0.2/lib/active_record/connection_adapters/abstract/query_cache.rb:33:in `cache'
    /usr/lib/ruby/gems/1.8/gems/activerecord-2.0.2/lib/active_record/query_cache.rb:8:in `cache'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/caching.rb:677:in `perform_action'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:524:in `send'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:524:in `process_without_filters'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/filters.rb:685:in `process_without_session_management_support'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/session_management.rb:123:in `process'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/base.rb:388:in `process'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:171:in `handle_request'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:115:in `dispatch'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:126:in `dispatch_cgi'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.0.2/lib/action_controller/dispatcher.rb:9:in `dispatch'
    /usr/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/fcgi_handler.rb:101:in `process_request'
    /usr/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/fcgi_handler.rb:149:in `with_signal_handler'
    /usr/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/fcgi_handler.rb:99:in `process_request'
    /usr/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/fcgi_handler.rb:77:in `process_each_request'
    /usr/lib/ruby/gems/1.8/gems/fcgi-0.8.7/lib/fcgi.rb:612:in `each_cgi'
    /usr/lib/ruby/gems/1.8/gems/fcgi-0.8.7/lib/fcgi.rb:609:in `each'
    /usr/lib/ruby/gems/1.8/gems/fcgi-0.8.7/lib/fcgi.rb:609:in `each_cgi'
    /usr/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/fcgi_handler.rb:76:in `process_each_request'
    /usr/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/fcgi_handler.rb:50:in `process!'
    /usr/lib/ruby/gems/1.8/gems/rails-2.0.2/lib/fcgi_handler.rb:24:in `process!'
    /public/dispatch.fcgi:24

Rendering /var/www/redmine/public/500.html (500 Internal Server Error)

Associated revisions

Revision 1445
Added by Jean-Philippe Lang over 12 years ago

Fixed: error when previewing a new wiki page (#1292) introduced in r1415.

History

#1 Updated by Tommy Jensen over 12 years ago

Please provide the version string for redmine, what database (and preferrably version) you are using, if this happens in every project, and last but not least if you have migrated from a earlier version.

Thanks.

#2 Updated by Luca Pireddu over 12 years ago

  • version: HEAD, revision 1444
  • database: PostgreSQL 8.2
  • migrated from earlier version: yes
  • every project: yes

#3 Updated by Tommy Jensen over 12 years ago

When you upgraded, did you do a rake db:migrate ,and restart the server (mongrel/webrick/..) afterwards?
And between which revisions/versions did this error occur?

#4 Updated by Luca Pireddu over 12 years ago

Migrated and restarted: yes.
Noticed noticed the problem in a previous revision, but I don't know which one. I updated to HEAD (r1444) this morning (23/5/2008) and the problem is still there.

#5 Updated by Jean-Philippe Lang over 12 years ago

  • Category set to Wiki
  • Status changed from New to Closed
  • Resolution set to Fixed

Fixed in r1445.

Also available in: Atom PDF