[PATCH 01 of 14 "] repoview: fix conditional around unserved changesets
Gregory Szorc
gregory.szorc at gmail.com
Tue Apr 16 06:43:08 EDT 2019
On Sat, Apr 13, 2019 at 5:49 PM Pierre-Yves David <
pierre-yves.david at ens-lyon.org> wrote:
> # HG changeset patch
> # User Pierre-Yves David <pierre-yves.david at octobus.net>
> # Date 1555181870 -7200
> # Sat Apr 13 20:57:50 2019 +0200
> # Node ID 5ce5915a48297de3f7464e8f149629799da5ca6f
> # Parent 2a3c0106ded9584938116ec2b1cbc7e21f13e1e1
> # EXP-Topic hgweb-obsolete
> # Available At https://bitbucket.org/octobus/mercurial-devel/
> # hg pull https://bitbucket.org/octobus/mercurial-devel/ -r
> 5ce5915a4829
> repoview: fix conditional around unserved changesets
>
Queued parts 1-3. I dropped the internal-phase requirement from part 2.
>
> The conditional could lead to wrong computation since we have more unserved
> changesets than just the "secret" phase.
>
> In addition, now that we have efficient caching of phased changesets, we
> don't
> need the conditional anymore.
>
> diff --git a/mercurial/repoview.py b/mercurial/repoview.py
> --- a/mercurial/repoview.py
> +++ b/mercurial/repoview.py
> @@ -93,8 +93,8 @@ def computeunserved(repo, visibilityexce
> assert not repo.changelog.filteredrevs
> # fast path in simple case to avoid impact of non optimised code
> hiddens = filterrevs(repo, 'visible')
> - if phases.hassecret(repo):
> - secrets = repo._phasecache.getrevset(repo,
> phases.remotehiddenphases)
> + secrets = repo._phasecache.getrevset(repo, phases.remotehiddenphases)
> + if secrets:
> return frozenset(hiddens | frozenset(secrets))
> else:
> return hiddens
> _______________________________________________
> Mercurial-devel mailing list
> Mercurial-devel at mercurial-scm.org
> https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.mercurial-scm.org/pipermail/mercurial-devel/attachments/20190416/fcab4ae1/attachment.html>
More information about the Mercurial-devel
mailing list