Bug 3950 - rebase cannot handle a bookmark named "bisect"
Summary: rebase cannot handle a bookmark named "bisect"
Status: RESOLVED FIXED
Alias: None
Product: Mercurial
Classification: Unclassified
Component: rebase (show other bugs)
Version: 2.6
Hardware: All All
: normal bug
Assignee: Bugzilla
URL:
Keywords: easy
Depends on:
Blocks:
 
Reported: 2013-05-29 17:04 UTC by Bryan O'Sullivan
Modified: 2013-11-07 17:47 UTC (History)
5 users (show)

See Also:
Python Version: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Bryan O'Sullivan 2013-05-29 17:04 UTC
$ hg rebase -r bisect -d foo 
hg: parse error: can't use bisect here
Comment 1 Nikolaj Sjujskij 2013-05-29 17:06 UTC
I suppose it interferes with revset.
Comment 2 Matt Mackall 2013-05-29 17:31 UTC
Should work, should not interfere with revsets.

Compare:

hg bookmark bisect
hg log -r bisect  <- succeed, interpreted as non-revset when revset fails
hg log -r 'bisect^' <- fails, not a valid non-revset either
hg log -r '"bisect"^' <- quoted, not treated as a function

The problem is here:

http://www.selenic.com/hg/file/1bef6f99a12d/hgext/rebase.py#l188

This treats the incoming revision argument as a known-valid revset, rather than a possible-revset-or-bare-rev-that-the-user-gave-us.

Notably, the very next stanza does this right, by passing the arg through scmutil.revrange first.
Comment 3 HG Bot 2013-09-03 17:00 UTC
Fixed by http://selenic.com/repo/hg/rev/5528c31c629c
Bryan O'Sullivan <bryano@fb.com>
rebase: handle bookmarks matching revset function names (issue3950)

We handled these correctly with all rev-specifying options except,
somehow, -r/--rev.

(please test the fix)
Comment 4 HG Bot 2013-09-03 17:00 UTC
Fixed by http://selenic.com/repo/hg/rev/14ec82594f47
Bryan O'Sullivan <bryano@fb.com>
rebase: handle bookmarks matching revset function names (issue3950)

We handled these correctly with all rev-specifying options except,
somehow, -r/--rev.

(please test the fix)