[PATCH 07 of 12] phases: marked content of a changegroup as published

Matt Mackall mpm at selenic.com
Tue Oct 18 13:57:43 CDT 2011


On Tue, 2011-10-18 at 19:27 +0200, pierre-yves.david at logilab.fr wrote:
> # HG changeset patch
> # User Pierre-Yves David <pierre-yves.david at logilab.fr>
> # Date 1318956406 -7200
> # Node ID f4981dc4b9e9b559864f5cffa19b90479ba5bdb9
> # Parent  568b9dfebb7e9224d5b0f0fe9628f54fb30aca16
> phases: marked content of a changegroup as published
> 
> diff --git a/mercurial/localrepo.py b/mercurial/localrepo.py
> --- a/mercurial/localrepo.py
> +++ b/mercurial/localrepo.py
> @@ -1942,10 +1942,13 @@ class localrepository(repo.repository):
>                  p = lambda: cl.writepending() and self.root or ""
>                  self.hook('pretxnchangegroup', throw=True,
>                            node=hex(cl.node(clstart)), source=srctype,
>                            url=url, pending=p)
>  
> +            added = [cl.node(r) for r in xrange(clstart, clend)]
> +            if phases.moveboundary(self, 0, added):
> +                phases.writeheads(self)

This is not how we usually flush data. See what happens on lock release
in localrepo. There are issues here with rollback/abort to consider.

-- 
Mathematics is the supreme nostalgia of our time.




More information about the Mercurial-devel mailing list