[Bug 4075] New: abort: unknown revision during outgoing/push when there are no changes and hidden changesets are present

mercurial-bugs at selenic.com mercurial-bugs at selenic.com
Wed Oct 30 13:24:43 CDT 2013


http://bz.selenic.com/show_bug.cgi?id=4075

          Priority: normal
            Bug ID: 4075
                CC: mercurial-devel at selenic.com
          Assignee: bugzilla at selenic.com
           Summary: abort: unknown revision during outgoing/push when
                    there are no changes and hidden changesets are present
          Severity: bug
    Classification: Unclassified
                OS: All
          Reporter: gregory.szorc at gmail.com
          Hardware: All
            Status: UNCONFIRMED
           Version: 2.8-rc
         Component: Mercurial
           Product: Mercurial

I don't have STR, but I believe I stumbled across a legit bug in obsolescence
support.

I am running `hg out` on a repository that has many hidden and obsolete
changesets created through a combination of `hg amend` and `hg rebase`. To my
surprise, this command exists with "abort: unknown revision X" where X is a
full hex identifier.

$ hg out collab
comparing with ssh://hgssh@hg.gregoryszorc.com/gecko-collab
searching for changes
abort: unknown revision 'd097ca031e604879dfc231f793f060326e39738b'!

The changeset does exist (although it is hidden):

$ hg --hidden log -r d097ca031e604879dfc231f793f060326e39738b

changeset:   168351:d097ca031e60
parent:      168282:855da6d8a327
user:        Gregory Szorc <gps at mozilla.com>
date:        Thu Oct 17 13:56:29 2013 -0700
summary:     Bug 927837 - Capture AC_OUTPUT and AC_HEADER_OUPUT dependencies to
config.status

The changeset exists in phaseroots:

$ grep d097ca031e604879dfc231f793f060326e39738b .hg/store/phaseroots
1 d097ca031e604879dfc231f793f060326e39738b

The changeset is referenced is obsolescence data. Relevant entries from
debugobs:

d097ca031e604879dfc231f793f060326e39738b
73d712058d54e9d2ca726ad19798c99e6cd4f8ee 0 {'date': '1382114351 25200', 'user':
'Gregory Szorc <gps at mozilla.com>'}
3d712058d54e9d2ca726ad19798c99e6cd4f8ee
637445b2db1dc9eeca8337631b78304da56f5958 0 {'date': '1382120061 25200', 'user':
'Gregory Szorc <gps at mozilla.com>'}
061def54a965a408f2047789a1bd17a1302f1ac1
637445b2db1dc9eeca8337631b78304da56f5958 0 {'date': '1382120061 25200', 'user':
'Gregory Szorc <gps at mozilla.com>'}
af084eeb83ed3049aff9dadf727a81dd20d4967a
637445b2db1dc9eeca8337631b78304da56f5958 0 {'date': '1382120061 25200', 'user':
'Gregory Szorc <gps at mozilla.com>'}
1830d8c761e10fff9a1fc06453dfa805c9a041df
637445b2db1dc9eeca8337631b78304da56f5958 0 {'date': '1382120061 25200', 'user':
'Gregory Szorc <gps at mozilla.com>'}
67406180143801f0ec820834c38850ff699d106b
637445b2db1dc9eeca8337631b78304da56f5958 0 {'date': '1382120061 25200', 'user':
'Gregory Szorc <gps at mozilla.com>'}
4d58f088ead8d97b08c2485e9ea322a5931feffd
637445b2db1dc9eeca8337631b78304da56f5958 0 {'date': '1382120061 25200', 'user':
'Gregory Szorc <gps at mozilla.com>'}
637445b2db1dc9eeca8337631b78304da56f5958
311d4fffb7f7c424fdc58d153f0e21e84b80daa0 0 {'date': '1382120687 25200', 'user':
'Gregory Szorc <gps at mozilla.com>'}
311d4fffb7f7c424fdc58d153f0e21e84b80daa0
9656c165741cd0f885ca94b2be451fc88d8e4c2e 0 {'date': '1382389683 25200', 'user':
'Gregory Szorc <gps at mozilla.com>'}
9656c165741cd0f885ca94b2be451fc88d8e4c2e
f4532b46fa534375513f84d7e6f37a357ed3d5bc 0 {'date': '1382487539 25200', 'user':
'Gregory Szorc <gps at mozilla.com>'}
f4532b46fa534375513f84d7e6f37a357ed3d5bc
78d0ea6b71225d32c69699262eb0abff93037a9d 0 {'date': '1382544888 25200', 'user':
'Gregory Szorc <gps at mozilla.com>'}
78d0ea6b71225d32c69699262eb0abff93037a9d
2f7eddb9c146cfba405076daa7a34e3819ec9e32 0 {'date': '1382561846 25200', 'user':
'Gregory Szorc <gps at mozilla.com>'}
<and this goes on for a while>

>From the following traceback, I /think/ this is a bug in the special case where
there are no outgoing changesets.

$ hg --debug --traceback out collab
comparing with ssh://hgssh@hg.gregoryszorc.com/gecko-collab
running ssh hgssh at hg.gregoryszorc.com 'hg -R gecko-collab serve --stdio'
sending hello command
sending between command
remote: 145
remote: capabilities: lookup changegroupsubset branchmap pushkey known
getbundle unbundlehash batch stream unbundle=HG10GZ,HG10BZ,HG10UN
httpheader=1024
remote: 1
query 1; heads
sending batch command
searching for changes
taking initial sample
searching: 2 queries
query 2; still undecided: 29, sample size is: 29
sending known command
2 total queries
Traceback (most recent call last):
  File
"/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/dispatch.py", line
133, in _runcatch
    return _dispatch(req)
  File
"/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/dispatch.py", line
806, in _dispatch
    cmdpats, cmdoptions)
  File
"/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/dispatch.py", line
585, in runcommand
    ret = _runcommand(ui, options, cmd, d)
  File
"/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/extensions.py",
line 196, in wrap
    return wrapper(origfn, *args, **kwargs)
  File "/Users/gps/src/hg/env/lib/python2.7/site-packages/hgext/pager.py", line
138, in pagecmd
    return orig(ui, options, cmd, cmdfunc)
  File
"/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/extensions.py",
line 196, in wrap
    return wrapper(origfn, *args, **kwargs)
  File "/Users/gps/src/hg/env/lib/python2.7/site-packages/hgext/color.py", line
419, in colorcmd
    return orig(ui_, opts, cmd, cmdfunc)
  File
"/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/dispatch.py", line
897, in _runcommand
    return checkargs()
  File
"/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/dispatch.py", line
868, in checkargs
    return cmdfunc()
  File
"/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/dispatch.py", line
803, in <lambda>
    d = lambda: util.checksignature(func)(ui, *args, **cmdoptions)
  File "/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/util.py",
line 512, in check
    return func(*args, **kwargs)
  File
"/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/extensions.py",
line 151, in wrap
    util.checksignature(origfn), *args, **kwargs)
  File "/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/util.py",
line 512, in check
    return func(*args, **kwargs)
  File "/Users/gps/src/hg/env/lib/python2.7/site-packages/hgext/mq.py", line
3376, in mqcommand
    return orig(ui, repo, *args, **kwargs)
  File "/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/util.py",
line 512, in check
    return func(*args, **kwargs)
  File
"/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/commands.py", line
4345, in outgoing
    return hg.outgoing(ui, repo, dest, opts)
  File "/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/hg.py",
line 578, in outgoing
    o = _outgoing(ui, repo, dest, opts)
  File "/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/hg.py",
line 563, in _outgoing
    scmutil.nochangesfound(repo.ui, repo, outgoing.excluded)
  File
"/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/scmutil.py", line
33, in nochangesfound
    ctx = repo[n]
  File
"/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/localrepo.py",
line 405, in __getitem__
    return context.changectx(self, changeid)
  File
"/Users/gps/src/hg/env/lib/python2.7/site-packages/mercurial/context.py", line
301, in __init__
    _("unknown revision '%s'") % changeid)
RepoLookupError: unknown revision 'd097ca031e604879dfc231f793f060326e39738b'
abort: unknown revision 'd097ca031e604879dfc231f793f060326e39738b'!

I can reproduce the abort on `hg out` with current tip (1d7a36ff2615). If this
is a repository corruption issue, that occurred while using 2.7.2.

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


More information about the Mercurial-devel mailing list