If set, there will be debug message when a filter computation is triggered.
This is going to be useful to remove various filtering trigger and to test they
do not get reintroduced.
If set, there will be debug message when a filter computation is triggered.
This is going to be useful to remove various filtering trigger and to test they
do not get reintroduced.
Lint Skipped |
Unit Tests Skipped |
Path | Packages | |||
---|---|---|---|---|
M | mercurial/configitems.py (3 lines) | |||
M | mercurial/repoview.py (3 lines) |
Commit | Parents | Author | Summary | Date |
---|---|---|---|---|
21f11297daa3 | 040931e19f0c | Pierre-Yves David | Nov 16 2019, 11:32 PM |
) | ) | ||||
coreconfigitem( | coreconfigitem( | ||||
b'devel', b'debug.copies', default=False, | b'devel', b'debug.copies', default=False, | ||||
) | ) | ||||
coreconfigitem( | coreconfigitem( | ||||
b'devel', b'debug.extensions', default=False, | b'devel', b'debug.extensions', default=False, | ||||
) | ) | ||||
coreconfigitem( | coreconfigitem( | ||||
b'devel', b'debug.repo-filters', default=False, | |||||
) | |||||
coreconfigitem( | |||||
b'devel', b'debug.peer-request', default=False, | b'devel', b'debug.peer-request', default=False, | ||||
) | ) | ||||
coreconfigitem( | coreconfigitem( | ||||
b'devel', b'discovery.randomize', default=True, | b'devel', b'discovery.randomize', default=True, | ||||
) | ) | ||||
_registerdiffopts(section=b'diff') | _registerdiffopts(section=b'diff') | ||||
coreconfigitem( | coreconfigitem( | ||||
b'email', b'bcc', default=None, | b'email', b'bcc', default=None, |
def filterrevs(repo, filtername, visibilityexceptions=None): | def filterrevs(repo, filtername, visibilityexceptions=None): | ||||
"""returns set of filtered revision for this filter name | """returns set of filtered revision for this filter name | ||||
visibilityexceptions is a set of revs which must are exceptions for | visibilityexceptions is a set of revs which must are exceptions for | ||||
hidden-state and must be visible. They are dynamic and hence we should not | hidden-state and must be visible. They are dynamic and hence we should not | ||||
cache it's result""" | cache it's result""" | ||||
if filtername not in repo.filteredrevcache: | if filtername not in repo.filteredrevcache: | ||||
if repo.ui.configbool(b'devel', b'debug.repo-filters'): | |||||
msg = b'debug.filters: computing revision filter for "%s"\n' | |||||
repo.ui.debug(msg % filtername) | |||||
func = filtertable[filtername] | func = filtertable[filtername] | ||||
if visibilityexceptions: | if visibilityexceptions: | ||||
return func(repo.unfiltered, visibilityexceptions) | return func(repo.unfiltered, visibilityexceptions) | ||||
repo.filteredrevcache[filtername] = func(repo.unfiltered()) | repo.filteredrevcache[filtername] = func(repo.unfiltered()) | ||||
return repo.filteredrevcache[filtername] | return repo.filteredrevcache[filtername] | ||||
def wrapchangelog(unfichangelog, filteredrevs): | def wrapchangelog(unfichangelog, filteredrevs): |