Problems with mercurial repository.
Added by Paolo Andreuzza about 15 years ago
Hi,
I have some problems when i try to browse my mercurial repository.
Redmine version :0.8.5
Mercurial version : 1.3.1
OS : Windows XP
hg.exe folder is on path so it is always reacheble
Mercurial repository is on a local drive.
I usually use mongrel, but now I'm testing with WEBRick.
When I select the "Repository" tab I get these page on my browser:
NoMethodError in RepositoriesController#show undefined method `[]' for nil:NilClass RAILS_ROOT: C:/redmine lib/redmine/scm/adapters/mercurial_adapter.rb:47:in `hgversion_from_command_line' lib/redmine/scm/adapters/mercurial_adapter.rb:40:in `hgversion' lib/redmine/scm/adapters/mercurial_adapter.rb:33:in `client_version' lib/redmine/scm/adapters/mercurial_adapter.rb:51:in `template_path' lib/redmine/scm/adapters/mercurial_adapter.rb:108:in `revisions' lib/redmine/scm/adapters/mercurial_adapter.rb:72:in `info' lib/redmine/scm/adapters/abstract_adapter.rb:150:in `retrieve_root_url' lib/redmine/scm/adapters/abstract_adapter.rb:54:in `initialize' app/models/repository.rb:41:in `new' app/models/repository.rb:41:in `scm' app/models/repository/mercurial.rb:56:in `fetch_changesets' app/controllers/repositories_controller.rb:69:in `show' vendor/rails/activerecord/lib/active_record/associations/association_proxy.rb:173:in `send' vendor/rails/activerecord/lib/active_record/associations/association_proxy.rb:173:in `method_missing' vendor/rails/actionpack/lib/action_controller/base.rb:1166:in `send' vendor/rails/actionpack/lib/action_controller/base.rb:1166:in `perform_action_without_filters' vendor/rails/actionpack/lib/action_controller/filters.rb:579:in `call_filters' vendor/rails/actionpack/lib/action_controller/filters.rb:572:in `perform_action_without_benchmark' vendor/rails/actionpack/lib/action_controller/benchmarking.rb:68:in `perform_action_without_rescue' c:/ruby/lib/ruby/1.8/benchmark.rb:293:in `measure' vendor/rails/actionpack/lib/action_controller/benchmarking.rb:68:in `perform_action_without_rescue' vendor/rails/actionpack/lib/action_controller/rescue.rb:201:in `perform_action_without_caching' vendor/rails/actionpack/lib/action_controller/caching/sql_cache.rb:13:in `perform_action' vendor/rails/activerecord/lib/active_record/connection_adapters/abstract/query_cache.rb:33:in `cache' vendor/rails/activerecord/lib/active_record/query_cache.rb:8:in `cache' vendor/rails/actionpack/lib/action_controller/caching/sql_cache.rb:12:in `perform_action' vendor/rails/actionpack/lib/action_controller/base.rb:529:in `send' vendor/rails/actionpack/lib/action_controller/base.rb:529:in `process_without_filters' vendor/rails/actionpack/lib/action_controller/filters.rb:568:in `process_without_session_management_support' vendor/rails/actionpack/lib/action_controller/session_management.rb:130:in `process' vendor/rails/actionpack/lib/action_controller/base.rb:389:in `process' vendor/rails/actionpack/lib/action_controller/dispatcher.rb:149:in `handle_request' vendor/rails/actionpack/lib/action_controller/dispatcher.rb:107:in `dispatch' vendor/rails/actionpack/lib/action_controller/dispatcher.rb:104:in `synchronize' vendor/rails/actionpack/lib/action_controller/dispatcher.rb:104:in `dispatch' vendor/rails/actionpack/lib/action_controller/dispatcher.rb:120:in `dispatch_cgi' vendor/rails/actionpack/lib/action_controller/dispatcher.rb:35:in `dispatch' vendor/rails/railties/lib/webrick_server.rb:112:in `handle_dispatch' vendor/rails/railties/lib/webrick_server.rb:78:in `service' c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:104:in `service' c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:65:in `run' c:/ruby/lib/ruby/1.8/webrick/server.rb:173:in `start_thread' c:/ruby/lib/ruby/1.8/webrick/server.rb:162:in `start' c:/ruby/lib/ruby/1.8/webrick/server.rb:162:in `start_thread' c:/ruby/lib/ruby/1.8/webrick/server.rb:95:in `start' c:/ruby/lib/ruby/1.8/webrick/server.rb:92:in `each' c:/ruby/lib/ruby/1.8/webrick/server.rb:92:in `start' c:/ruby/lib/ruby/1.8/webrick/server.rb:23:in `start' c:/ruby/lib/ruby/1.8/webrick/server.rb:82:in `start' vendor/rails/railties/lib/webrick_server.rb:62:in `dispatch' vendor/rails/railties/lib/commands/servers/webrick.rb:66 c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require' vendor/rails/activesupport/lib/active_support/dependencies.rb:510:in `require' vendor/rails/activesupport/lib/active_support/dependencies.rb:355:in `new_constants_in' vendor/rails/activesupport/lib/active_support/dependencies.rb:510:in `require' vendor/rails/railties/lib/commands/server.rb:39 c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require' script/server:3 lib/redmine/scm/adapters/mercurial_adapter.rb:47:in `hgversion_from_command_line' lib/redmine/scm/adapters/mercurial_adapter.rb:40:in `hgversion' lib/redmine/scm/adapters/mercurial_adapter.rb:33:in `client_version' lib/redmine/scm/adapters/mercurial_adapter.rb:51:in `template_path' lib/redmine/scm/adapters/mercurial_adapter.rb:108:in `revisions' lib/redmine/scm/adapters/mercurial_adapter.rb:72:in `info' lib/redmine/scm/adapters/abstract_adapter.rb:150:in `retrieve_root_url' lib/redmine/scm/adapters/abstract_adapter.rb:54:in `initialize' app/models/repository.rb:41:in `new' app/models/repository.rb:41:in `scm' app/models/repository/mercurial.rb:56:in `fetch_changesets' vendor/rails/activerecord/lib/active_record/associations/association_proxy.rb:173:in `send' vendor/rails/activerecord/lib/active_record/associations/association_proxy.rb:173:in `method_missing' app/controllers/repositories_controller.rb:69:in `show' vendor/rails/actionpack/lib/action_controller/base.rb:1166:in `send' vendor/rails/actionpack/lib/action_controller/base.rb:1166:in `perform_action_without_filters' vendor/rails/actionpack/lib/action_controller/filters.rb:579:in `call_filters' vendor/rails/actionpack/lib/action_controller/filters.rb:572:in `perform_action_without_benchmark' vendor/rails/actionpack/lib/action_controller/benchmarking.rb:68:in `perform_action_without_rescue' c:/ruby/lib/ruby/1.8/benchmark.rb:293:in `measure' vendor/rails/actionpack/lib/action_controller/benchmarking.rb:68:in `perform_action_without_rescue' vendor/rails/actionpack/lib/action_controller/rescue.rb:201:in `perform_action_without_caching' vendor/rails/actionpack/lib/action_controller/caching/sql_cache.rb:13:in `perform_action' vendor/rails/activerecord/lib/active_record/connection_adapters/abstract/query_cache.rb:33:in `cache' vendor/rails/activerecord/lib/active_record/query_cache.rb:8:in `cache' vendor/rails/actionpack/lib/action_controller/caching/sql_cache.rb:12:in `perform_action' vendor/rails/actionpack/lib/action_controller/base.rb:529:in `send' vendor/rails/actionpack/lib/action_controller/base.rb:529:in `process_without_filters' vendor/rails/actionpack/lib/action_controller/filters.rb:568:in `process_without_session_management_support' vendor/rails/actionpack/lib/action_controller/session_management.rb:130:in `process' vendor/rails/actionpack/lib/action_controller/base.rb:389:in `process' vendor/rails/actionpack/lib/action_controller/dispatcher.rb:149:in `handle_request' vendor/rails/actionpack/lib/action_controller/dispatcher.rb:107:in `dispatch' vendor/rails/actionpack/lib/action_controller/dispatcher.rb:104:in `synchronize' vendor/rails/actionpack/lib/action_controller/dispatcher.rb:104:in `dispatch' vendor/rails/actionpack/lib/action_controller/dispatcher.rb:120:in `dispatch_cgi' vendor/rails/actionpack/lib/action_controller/dispatcher.rb:35:in `dispatch' vendor/rails/railties/lib/webrick_server.rb:112:in `handle_dispatch' vendor/rails/railties/lib/webrick_server.rb:78:in `service' c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:104:in `service' c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:65:in `run' c:/ruby/lib/ruby/1.8/webrick/server.rb:173:in `start_thread' c:/ruby/lib/ruby/1.8/webrick/server.rb:162:in `start' c:/ruby/lib/ruby/1.8/webrick/server.rb:162:in `start_thread' c:/ruby/lib/ruby/1.8/webrick/server.rb:95:in `start' c:/ruby/lib/ruby/1.8/webrick/server.rb:92:in `each' c:/ruby/lib/ruby/1.8/webrick/server.rb:92:in `start' c:/ruby/lib/ruby/1.8/webrick/server.rb:23:in `start' c:/ruby/lib/ruby/1.8/webrick/server.rb:82:in `start' vendor/rails/railties/lib/webrick_server.rb:62:in `dispatch' vendor/rails/railties/lib/commands/servers/webrick.rb:66 c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require' vendor/rails/activesupport/lib/active_support/dependencies.rb:510:in `require' vendor/rails/activesupport/lib/active_support/dependencies.rb:355:in `new_constants_in' vendor/rails/activesupport/lib/active_support/dependencies.rb:510:in `require' vendor/rails/railties/lib/commands/server.rb:39 c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require' c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require' script/server:3 Request Parameters: {"id"=>"xcvbdgme14"} --- :user_id: 1 flash: !map:ActionController::Flash::FlashHash {} Response Headers: {"cookie"=>[], "Cache-Control"=>"no-cache"}
Sorry for my english.
Thank you in advance.
P.
Replies (3)
RE: Problems with mercurial repository. - Added by Paolo Andreuzza about 15 years ago
Some more informations:
About your application's environment Ruby version 1.8.6 (i386-mswin32) RubyGems version 0.9.4 Rails version 2.1.2 Active Record version 2.1.2 Action Pack version 2.1.2 Active Resource version 2.1.2 Action Mailer version 2.1.2 Active Support version 2.1.2 Application root C:/redmine Environment production Database adapter mysql Database schema version 101
RE: Problems with mercurial repository. - Added by Yuya Nishihara about 15 years ago
Reproduced the problem.
It seems due to translated `hg --version` message.
Try to set LANG=C before running webrick like:
(on Linux)
$ LANG=C ruby script/server webrick -e production
(on Windows, maybe...)
> set LANG=C > ruby script/server webrick -e production
[SOLVED] RE: Problems with mercurial repository. - Added by Paolo Andreuzza about 15 years ago
Great!!! you got it!!
I've tryed on windows, it works!!
Thank you very much.
Paolo