[Bug 6117] New: rebase.experimental.inmemory stack traces when a rebase includes moving all files out of a subdir

mercurial-bugs at mercurial-scm.org mercurial-bugs at mercurial-scm.org
Wed Apr 10 06:27:31 EDT 2019


https://bz.mercurial-scm.org/show_bug.cgi?id=6117

            Bug ID: 6117
           Summary: rebase.experimental.inmemory stack traces when a
                    rebase includes moving all files out of a subdir
           Product: Mercurial
           Version: 4.8.1
          Hardware: PC
                OS: Linux
            Status: UNCONFIRMED
          Severity: bug
          Priority: wish
         Component: rebase
          Assignee: bugzilla at mercurial-scm.org
          Reporter: jordigh at octave.org
                CC: mercurial-devel at mercurial-scm.org

Here is the repro:

$ hg init lol
$ cd lol
$ touch omg
$ hg addr
adding omg
$ hg ci -m omg
$ mkdir wtf
$ cd wtf
$ touch brb bbq
$ hg addr
adding wtf/bbq
adding wtf/brb
$ hg ci -m brbbbq
$ cd ..
$ touch g2g
$ hg addr
adding g2g
$ hg ci -m g2g
$ hg up .^
0 files updated, 0 files merged, 1 files removed, 0 files unresolved
$ hg mv wtf/* .
$ hg ci -m 'move one dir up'
created new head
$ hg log -G -T '{rev}: {desc} ({files})\n'
◍  3: move one dir up (bbq brb wtf/bbq wtf/brb)
│
│ ○  2: g2g (g2g)
│╱
○  1: brbbbq (wtf/bbq wtf/brb)
│
○  0: omg (omg)

$ hg rebase --config rebase.experimental.inmemory=True -b 3 -d 2

This produces the following stack trace:

rebasing 3:e8046fd155fa "move one dir up" (tip)
** unknown exception encountered, please report by visiting
** https://mercurial-scm.org/wiki/BugTracker
** Python 2.7.13 (default, Sep 26 2018, 18:42:22) [GCC 6.3.0 20170516]
** Mercurial Distributed SCM (version 4.8.2)
** Extensions loaded: convert, strip, record, churn, purge, rebase, highlight,
patchbomb, histedit, largefiles, shelve, show, absorb, beautifygraph, censor,
evolve
** ProgrammingError: markcopied() called on clean context
Traceback (most recent call last):
  File "/home/jordi/.local/bin/hg", line 43, in <module>
    dispatch.run()
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/dispatch.py",
line 96, in run
    status = dispatch(req)
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/dispatch.py",
line 220, in dispatch
    ret = _runcatch(req) or 0
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/dispatch.py",
line 363, in _runcatch
    return _callcatch(ui, _runcatchfunc)
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/dispatch.py",
line 371, in _callcatch
    return scmutil.callcatch(ui, func)
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/scmutil.py",
line 166, in callcatch
    return func()
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/dispatch.py",
line 354, in _runcatchfunc
    return _dispatch(req)
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/dispatch.py",
line 994, in _dispatch
    cmdpats, cmdoptions)
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/dispatch.py",
line 737, in runcommand
    ret = _runcommand(ui, options, cmd, d)
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/dispatch.py",
line 1003, in _runcommand
    return cmdfunc()
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/dispatch.py",
line 991, in <lambda>
    d = lambda: util.checksignature(func)(ui, *args, **strcmdopt)
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/util.py", line
1644, in check
    return func(*args, **kwargs)
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/util.py", line
1644, in check
    return func(*args, **kwargs)
  File
"/home/jordi/.local/lib/python2.7/site-packages/hgext/largefiles/overrides.py",
line 911, in overriderebase
    return orig(ui, repo, **opts)
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/util.py", line
1644, in check
    return func(*args, **kwargs)
  File "/home/jordi/.local/lib/python2.7/site-packages/hgext/rebase.py", line
864, in rebase
    return _dorebase(ui, repo, action, opts, inmemory=inmemory)
  File "/home/jordi/.local/lib/python2.7/site-packages/hgext/rebase.py", line
918, in _dorebase
    return _origrebase(ui, repo, action, opts, rbsrt, inmemory=inmemory)
  File "/home/jordi/.local/lib/python2.7/site-packages/hgext/rebase.py", line
987, in _origrebase
    rbsrt._performrebase(tr)
  File "/home/jordi/.local/lib/python2.7/site-packages/hgext/rebase.py", line
458, in _performrebase
    self._rebasenode(tr, rev, allowdivergence, progress)
  File "/home/jordi/.local/lib/python2.7/site-packages/hgext/rebase.py", line
549, in _rebasenode
    dest, wctx=self.wctx)
  File "/home/jordi/.local/lib/python2.7/site-packages/hgext/rebase.py", line
1219, in rebasenode
    copies.duplicatecopies(repo, wctx, rev, p1rev, skiprev=dest)
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/copies.py",
line 923, in duplicatecopies
    wctx[dst].markcopied(src)
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/context.py",
line 2047, in markcopied
    self._parent.markcopied(self._path, origin)
  File "/home/jordi/.local/lib/python2.7/site-packages/mercurial/context.py",
line 1790, in markcopied
    raise error.ProgrammingError('markcopied() called on clean context')
mercurial.error.ProgrammingError: markcopied() called on clean context

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Mercurial-devel mailing list