Actions
Defect #23055
closedError with Fetch commits with Mercurial repository when log has invalid char
Start date:
Due date:
% Done:
0%
Estimated time:
Resolution:
Fixed
Affected version:
Description
Error with Fetch commits automatically with mercurial repository
When I add a mercurial repository, redmine start to scan and add to Mysql. This take several minutes. When redmine finish to index .Redmine show a error page. In production.log show this message. It happen with a huge repository about 70335 commits
production.log
Started GET "/projects/iset/repository" for 192.168.1.164 at 2016-06-13 10:56:04 +0000 Processing by RepositoriesController#show as HTML Parameters: {"id"=>"iset"} Current user: admin (id=1) Completed 500 Internal Server Error in 2039ms (ActiveRecord: 4.8ms) NoMethodError (undefined method `[]' for nil:NilClass): lib/redmine/scm/adapters/mercurial_adapter.rb:194:in `each_revision' app/models/repository/mercurial.rb:187:in `block in fetch_changesets' app/models/repository/mercurial.rb:186:in `step' app/models/repository/mercurial.rb:186:in `fetch_changesets' app/controllers/repositories_controller.rb:114:in `show' lib/redmine/sudo_mode.rb:63:in `sudo_mode'
If you exec a manual auto_fetch to refresh data with rake -f Rakefile RAIL_ENV=production redmine:fetch_changesets --trace
Console shows:
/usr/local/bundle/gems/htmlentities-4.3.1/lib/htmlentities/mappings/expanded.rb:465: warning: duplicated key at line 466 ignored: "inodot" ** Invoke redmine:fetch_changesets (first_time) ** Invoke environment (first_time) ** Execute environment ** Execute redmine:fetch_changesets rake aborted! NoMethodError: undefined method `[]' for nil:NilClass /usr/src/redmine/lib/redmine/scm/adapters/mercurial_adapter.rb:194:in `each_revision' /usr/src/redmine/app/models/repository/mercurial.rb:187:in `block in fetch_changesets' /usr/src/redmine/app/models/repository/mercurial.rb:186:in `step' /usr/src/redmine/app/models/repository/mercurial.rb:186:in `fetch_changesets' /usr/src/redmine/app/models/repository.rb:344:in `block (2 levels) in fetch_changesets' /usr/local/bundle/gems/activerecord-4.2.5/lib/active_record/relation/delegation.rb:46:in `each' /usr/local/bundle/gems/activerecord-4.2.5/lib/active_record/relation/delegation.rb:46:in `each' /usr/src/redmine/app/models/repository.rb:342:in `block in fetch_changesets' /usr/local/bundle/gems/activerecord-4.2.5/lib/active_record/relation/delegation.rb:46:in `each' /usr/local/bundle/gems/activerecord-4.2.5/lib/active_record/relation/delegation.rb:46:in `each' /usr/src/redmine/app/models/repository.rb:341:in `fetch_changesets' /usr/src/redmine/lib/tasks/redmine.rake:47:in `block (2 levels) in <top (required)>' /usr/local/bundle/gems/rake-10.5.0/lib/rake/task.rb:240:in `call' /usr/local/bundle/gems/rake-10.5.0/lib/rake/task.rb:240:in `block in execute' /usr/local/bundle/gems/rake-10.5.0/lib/rake/task.rb:235:in `each' /usr/local/bundle/gems/rake-10.5.0/lib/rake/task.rb:235:in `execute' /usr/local/bundle/gems/rake-10.5.0/lib/rake/task.rb:179:in `block in invoke_with_call_chain' /usr/local/lib/ruby/2.2.0/monitor.rb:211:in `mon_synchronize' /usr/local/bundle/gems/rake-10.5.0/lib/rake/task.rb:172:in `invoke_with_call_chain' /usr/local/bundle/gems/rake-10.5.0/lib/rake/task.rb:165:in `invoke' /usr/local/bundle/gems/rake-10.5.0/lib/rake/application.rb:150:in `invoke_task' /usr/local/bundle/gems/rake-10.5.0/lib/rake/application.rb:106:in `block (2 levels) in top_level' /usr/local/bundle/gems/rake-10.5.0/lib/rake/application.rb:106:in `each' /usr/local/bundle/gems/rake-10.5.0/lib/rake/application.rb:106:in `block in top_level' /usr/local/bundle/gems/rake-10.5.0/lib/rake/application.rb:115:in `run_with_threads' /usr/local/bundle/gems/rake-10.5.0/lib/rake/application.rb:100:in `top_level' /usr/local/bundle/gems/rake-10.5.0/lib/rake/application.rb:78:in `block in run' /usr/local/bundle/gems/rake-10.5.0/lib/rake/application.rb:176:in `standard_exception_handling' /usr/local/bundle/gems/rake-10.5.0/lib/rake/application.rb:75:in `run' /usr/local/bundle/gems/rake-10.5.0/bin/rake:33:in `<top (required)>' /usr/local/bundle/bin/rake:16:in `load' /usr/local/bundle/bin/rake:16:in `<main>' Tasks: TOP => redmine:fetch_changesets
Redmine version 3.1.3.stable Ruby version 2.2.4-p230 (2015-12-16) [x86_64-linux-gnu] Rails version 4.2.5 Environment production Database adapter Mysql2 SCM: Subversion 1.8.13 Mercurial 3.1.2 Git 2.1.4 Bazaar 2.7.0 Filesystem Redmine plugins: no plugin installed
Files
Actions