aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2019-09-18 08:52:01 -0400
committerNick Mathewson <nickm@torproject.org>2019-09-18 10:28:33 -0400
commitd1ffac3f8abbdd5b7d8e5955615821bff3ee3729 (patch)
tree4cd99440b90887a6e62556185189419b48c7f363 /scripts
parent25d55fa01ebc8d9bc8cd52672605636a9261ddf5 (diff)
downloadtor-d1ffac3f8abbdd5b7d8e5955615821bff3ee3729.tar.gz
tor-d1ffac3f8abbdd5b7d8e5955615821bff3ee3729.zip
practracker: An exception is "used" even when it is violated.
The purpose of tracking whether an exception is used is so that we can tell whether it is overbroad. This means that an _underbroad_ exception is still a used one. Fixes bug 31338.
Diffstat (limited to 'scripts')
-rw-r--r--scripts/maint/practracker/problem.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/scripts/maint/practracker/problem.py b/scripts/maint/practracker/problem.py
index 88e1044fb7..d21840a213 100644
--- a/scripts/maint/practracker/problem.py
+++ b/scripts/maint/practracker/problem.py
@@ -77,8 +77,10 @@ class ProblemVault(object):
# (e.g. we went from 4k LoC to 3k LoC), but we do warn if the
# situation worsened (e.g. we went from 60 includes to 80).
status = problem.is_worse_than(self.exceptions[problem.key()])
- if status == STATUS_OK:
- self.used_exception_for[problem.key()] = problem
+
+ # Remember that we used this exception, so that we can later
+ # determine whether the exception was overbroad.
+ self.used_exception_for[problem.key()] = problem
return status