[PATCH STABLE V2] update: allow update to existing branches with invalid names (issue3710)

Kevin Bullock kbullock+mercurial at ringworld.org
Wed Nov 28 12:33:44 CST 2012


On Nov 28, 2012, at 12:31 PM, Pierre-Yves David wrote:

> On Wed, Nov 28, 2012 at 08:22:26PM +0200, Idan Kamara wrote:
>> On Wed, Nov 28, 2012 at 3:21 PM, Tim Henigan <tim.henigan at gmail.com> wrote:
>>> 
>>> # HG changeset patch
>>> # User Tim Henigan <tim.henigan at gmail.com>
>>> # Date 1354024055 18000
>>> # Branch stable
>>> # Node ID 15c51486a402299c61ef009b7587afbb152d2c54
>>> # Parent  54cedee86e5126188b0dcfbd7015bcdca7f6c2e2
>>> update: allow update to existing branches with invalid names (issue3710)
>>> 
>>> Starting with 361ab1e2086f, users are no longer able to update a
>>> working copy to a branch named with a "bad" character (such as ':').
>>> 
>>> Prior to v2.4, it was possible to create branch names using "bad"
>>> characters, so this breaks backwards compatibility.
>>> 
>>> Mercurial must allow users to update to existing branches with bad
>>> names.  However, it should continue to prevent the creation of new
>>> branches with bad names.
>>> 
>>> A test was added to confirm that 'hg update' works as expected. The
>>> test uses a bundled repo that was created with an earlier version of
>>> Mercurial.
>> 
>> You could perhaps use inilne Python to do this test more easily:
>> 
>>>>> from mercurial import hg, ui
>>>>> r = hg.repository(ui.ui())
>>>>> r.dirstate.setbranch('a:b')
> 
> I'm not sure we care about the internal here. What matter is to not
> regresse on hg update. Isn't it?


I agree, I'd rather have the external test for this.

pacem in terris / мир / शान्ति / ‎‫سَلاَم‬ / 平和
Kevin R. Bullock

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://selenic.com/pipermail/mercurial-devel/attachments/20121128/cdbd2d3c/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 195 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://selenic.com/pipermail/mercurial-devel/attachments/20121128/cdbd2d3c/attachment.pgp>


More information about the Mercurial-devel mailing list