[issue2364] Crash during update when working directory contains files of target version

Thomas Arendsen Hein bugs at mercurial.selenic.com
Mon Sep 6 14:41:04 CDT 2010

New submission from Thomas Arendsen Hein <thomas at intevation.de>:

Crash when updating to an older version when the working directory already
contains files of that version.

To reproduce:
- clone of current crew repository, checkout of any recent revision should
work, 74f54b7775f2 (current tip) definitely does

$ hg revert -r 288dda59233c templates
$ hg co 288dda59233c
** unknown exception encountered, details follow
** report bug details to http://mercurial.selenic.com/bts/
** or mercurial at selenic.com
** Python 2.5.2 (r252:60911, Jan 24 2010, 14:53:14) [GCC 4.3.2]
** Mercurial Distributed SCM (version 1.6.3+19-581066a319e5)
** Extensions loaded: 
Traceback (most recent call last):
  File "/home/thomas/bin/hg-tah", line 19, in <module>
  File "/home/thomas/hg/repos/tah/mercurial/dispatch.py", line 16, in run
  File "/home/thomas/hg/repos/tah/mercurial/dispatch.py", line 34, in dispatch
    return _runcatch(u, args)
  File "/home/thomas/hg/repos/tah/mercurial/dispatch.py", line 54, in _runcatch
    return _dispatch(ui, args)
  File "/home/thomas/hg/repos/tah/mercurial/dispatch.py", line 494, in _dispatch
    cmdpats, cmdoptions)
  File "/home/thomas/hg/repos/tah/mercurial/dispatch.py", line 355, in
    ret = _runcommand(ui, options, cmd, d)
  File "/home/thomas/hg/repos/tah/mercurial/dispatch.py", line 545, in
    return checkargs()
  File "/home/thomas/hg/repos/tah/mercurial/dispatch.py", line 499, in checkargs
    return cmdfunc()
  File "/home/thomas/hg/repos/tah/mercurial/dispatch.py", line 492, in <lambda>
    d = lambda: util.checksignature(func)(ui, *args, **cmdoptions)
  File "/home/thomas/hg/repos/tah/mercurial/util.py", line 420, in check
    return func(*args, **kwargs)
  File "/home/thomas/hg/repos/tah/mercurial/commands.py", line 3851, in update
    return hg.update(repo, rev)
  File "/home/thomas/hg/repos/tah/mercurial/hg.py", line 381, in update
    stats = mergemod.update(repo, node, False, False, None)
  File "/home/thomas/hg/repos/tah/mercurial/merge.py", line 521, in update
    stats = applyupdates(repo, action, wc, p2, pa)
  File "/home/thomas/hg/repos/tah/mercurial/merge.py", line 274, in applyupdates
    fca = fcl.parents()[0]
IndexError: list index out of range

messages: 13564
nosy: ThomasAH
priority: bug
status: unread
title: Crash during update when working directory contains files of target version
topic: merge

Mercurial issue tracker <bugs at mercurial.selenic.com>

More information about the Mercurial-devel mailing list