D1285: repoview: add a new attribute _visibilityexceptions and related API
yuja (Yuya Nishihara)
phabricator at mercurial-scm.org
Fri Dec 8 11:12:15 EST 2017
yuja added a comment.
> I have spend a lot of time on this and I am unable to make this work without making it class attribute because to calculate filterrevs, unfilteredrepo is passed and I lose the reference to the object on which I initially stored the visibilityexceptions. If I call `repo.filtered(filtername)`, I am getting a new object with empty visibilityexception set.
How long should the visibilityexception be preserved?
The safest one is to bind it to a temporary filteredrepo object, so that new `.filtered()`
object won't see it.
We could attach it to `unfi`, but in which case, we have to be careful to not leak
the current visibilityexception to the subsequent sessions. A `repo` object may
live longer than a single command/request session in hgweb or command server.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D1285
To: pulkit, #hg-reviewers, quark, yuja
Cc: yuja, lothiraldan, quark, mercurial-devel
More information about the Mercurial-devel
mailing list