Defect #9465

Mercurial: can't browse named branch below Mercurial 1.5

Added by Toshi MARUYAMA about 3 years ago. Updated almost 3 years ago.

Status:ClosedStart date:2011-10-24
Priority:NormalDue date:
Assignee:Toshi MARUYAMA% Done:

0%

Category:SCM
Target version:1.2.2
Resolution:Fixed Affected version:1.2.1

Description

On Mercurial 1.5, when browse http://localhost/projects/test/repository/show?rev=default ,
500 error raises.

An error occurred when trying to access the repository: hg exited with non-zero status: 1

Associated revisions

Revision 7640
Added by Toshi MARUYAMA about 3 years ago

scm: mercurial: fix extension cmdtable on Mercurial 1.5 (#9465)

Before Mercurial revision 40c06bbf58be ,
following error raises.

Traceback (most recent call last):
  File "/WEB-DOWN/hg-repo/hg-crew/hg", line 27, in <module>
    mercurial.dispatch.run()
  File "/WEB-DOWN/hg-repo/hg-crew/mercurial/dispatch.py", line 16, in run
    sys.exit(dispatch(sys.argv[1:]))
  File "/WEB-DOWN/hg-repo/hg-crew/mercurial/dispatch.py", line 30, in dispatch
    return _runcatch(u, args)
  File "/WEB-DOWN/hg-repo/hg-crew/mercurial/dispatch.py", line 47, in _runcatch
    return _dispatch(ui, args)
  File "/WEB-DOWN/hg-repo/hg-crew/mercurial/dispatch.py", line 398, in _dispatch
    cmd, func, args, options, cmdoptions = _parse(lui, args)
  File "/WEB-DOWN/hg-repo/hg-crew/mercurial/dispatch.py", line 277, in _parse
    args = fancyopts.fancyopts(args, c, cmdoptions, True)
  File "/WEB-DOWN/hg-repo/hg-crew/mercurial/fancyopts.py", line 62, in fancyopts
    for short, name, default, comment in options:
ValueError: too many values to unpack

  1) Error:
test_nodes_in_branch(MercurialAdapterTest):
Redmine::Scm::Adapters::MercurialAdapter::HgCommandAborted: hg exited with non-zero status: 1
    lib/redmine/scm/adapters/mercurial_adapter.rb:306:in `hg'
    lib/redmine/scm/adapters/mercurial_adapter.rb:234:in `nodes_in_branch'
    test/unit/lib/redmine/scm/adapters/mercurial_adapter_test.rb:311:in `test_nodes_in_branch'
    test/unit/lib/redmine/scm/adapters/mercurial_adapter_test.rb:304:in `each'
    test/unit/lib/redmine/scm/adapters/mercurial_adapter_test.rb:304:in `test_nodes_in_branch'

Revision 7641
Added by Toshi MARUYAMA about 3 years ago

scm: mercurial: switch rev parameter of extension rhlog() if above Mercurial 1.6 or not (#9465)

On Mercurial 1.5, following error raises.

hg --config extensions.redminehelper=lib/redmine/scm/adapters/mercurial/redminehelper.py \
  --rhbranch default --from default --to 0

abort: unknown revision '"default"'!

Revision 7642
Added by Toshi MARUYAMA about 3 years ago

scm: mercurial: skip failing unit lib tests on below Mercurial 1.5 (#9465)

Tests of non ASCII nor alphabetic nor numeric named branch fails on below Mercurial 1.5.

Revision 7643
Added by Toshi MARUYAMA about 3 years ago

scm: mercurial: skip failing unit model tests on below Mercurial 1.5 (#9465)

Tests of non ASCII nor alphabetic nor numeric named branch fails on below Mercurial 1.5.

Revision 7650
Added by Toshi MARUYAMA about 3 years ago

scm: mercurial: drop supporting below Mercurial 1.1 (#9465)

On November 1st 2011, Mercurial 2.0 will be released.

On Mercurial 1.1.2, unit lib test fails with following error.

Traceback (most recent call last):
  File "/WEB-DOWN/hg-repo/hg-crew/hg", line 20, in <module>
    mercurial.dispatch.run()
  File "/WEB-DOWN/hg-repo/hg-crew/mercurial/dispatch.py", line 20, in run
    sys.exit(dispatch(sys.argv[1:]))
  File "/WEB-DOWN/hg-repo/hg-crew/mercurial/dispatch.py", line 29, in dispatch
    return _runcatch(u, args)
  File "/WEB-DOWN/hg-repo/hg-crew/mercurial/dispatch.py", line 45, in _runcatch
    return _dispatch(ui, args)
  File "/WEB-DOWN/hg-repo/hg-crew/mercurial/dispatch.py", line 367, in _dispatch
    ret = _runcommand(ui, options, cmd, d)
  File "/WEB-DOWN/hg-repo/hg-crew/mercurial/dispatch.py", line 416, in _runcommand
    return checkargs()
  File "/WEB-DOWN/hg-repo/hg-crew/mercurial/dispatch.py", line 376, in checkargs
    return cmdfunc()
  File "/WEB-DOWN/hg-repo/hg-crew/mercurial/dispatch.py", line 361, in <lambda>
    d = lambda: util.checksignature(func)(ui, *args, **cmdoptions)
  File "/WEB-DOWN/hg-repo/hg-crew/mercurial/util.py", line 715, in check
    return func(*args, **kwargs)
  File "/REDMINE-1/hg-workdir/redmine-bb-all/lib/redmine/scm/adapters/mercurial/redminehelper.py", line 149, in rhlog
    if hg.util.version() >= '1.6':
AttributeError: 'module' object has no attribute 'version'

  1) Error:
test_nodes_in_branch(MercurialAdapterTest):
Redmine::Scm::Adapters::MercurialAdapter::HgCommandAborted: hg exited with non-zero status: 1
    lib/redmine/scm/adapters/mercurial_adapter.rb:306:in `hg'
    lib/redmine/scm/adapters/mercurial_adapter.rb:234:in `nodes_in_branch'
    test/unit/lib/redmine/scm/adapters/mercurial_adapter_test.rb:311:in `test_nodes_in_branch'
    test/unit/lib/redmine/scm/adapters/mercurial_adapter_test.rb:304:in `each'
    test/unit/lib/redmine/scm/adapters/mercurial_adapter_test.rb:304:in `test_nodes_in_branch'

History

#1 Updated by Toshi MARUYAMA almost 3 years ago

  • Subject changed from Mercurial: can't browse named branch on Mercurial 1.5 to Mercurial: can't browse named branch below Mercurial 1.5

#2 Updated by Toshi MARUYAMA almost 3 years ago

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

Mercurial 2.0 will be released on November 1st 2011.

As r7650 comment, tests fails on Mercurial 1.1.2.
So, I drop support 1.1.

As r7642 and r7643 comment, tests of non ASCII nor alphabetic nor numeric named branch fails below Mercurial 1.5.

Also available in: Atom PDF