[PATCH 4 of 5 REVIEW] phases: mark content pushed as public in local repo on push
Pierre-Yves David
pierre-yves.david at logilab.fr
Fri Oct 21 11:43:40 CDT 2011
On Fri, Oct 21, 2011 at 10:39:58AM -0500, Matt Mackall wrote:
> > + # no need to compute outg ancestor. All node in outg have either:
> > + # - parents in outg
> > + # - parents in common
> > + # - nullid parent
> > + from itertools import chain
>
> Ugh, no, not itertools. And demandloading means you never do imports
> like this.
>
> > + rset = repo.set('heads(%ln)', chain(common, outg))
>
> I really can't see why this is an improvement on my proposal? What does
> this do that
>
> repo.set('heads(%ln or %ln)', common, outg)
>
> doesn't do except require itertools?
>
> > + futureheads = [ctx.node() for ctx in rset]
> > + return cg, remoteheads, futureheads
GRmlm… I mixed my diff after a mutt crash and sent the wrong version. The
version with chain is here because
repo.set('heads(%ln or %ln)', common, outg) does not work when common is empty.
I'm started working a fix for revset but I'll probably need your help.
(yes using a if common: conditional will do the trick too)
sorry for noise with the wrong version
I decided futureheads will contains nodes instead of context because
remoteheads contains node. I tried to be consistent until it's too annoying
--
Pierre-Yves David
http://www.logilab.fr/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://selenic.com/pipermail/mercurial-devel/attachments/20111021/5c5730ff/attachment.pgp>
More information about the Mercurial-devel
mailing list