Loading changes/bug24953 0 → 100644 +4 −0 Original line number Diff line number Diff line o Minor bugfixes (fallback scripts): - In updateFallbackDirs.py, call the filter file a "fallback list" instead of a "whitelist" in check_existing mode. Fixes bug 24953; bugfix on 0.3.0.3-alpha. scripts/maint/updateFallbackDirs.py +10 −5 Original line number Diff line number Diff line Loading @@ -1594,7 +1594,7 @@ class CandidateList(dict): """ Apply the fallback whitelist_obj to this fallback list, passing exact to is_in_whitelist(). """ excluded_count = 0 logging.debug('Applying whitelist') logging.debug('Applying fallback list') # parse the whitelist whitelist = self.load_relaylist(whitelist_obj) filtered_fallbacks = [] Loading @@ -1609,14 +1609,18 @@ class CandidateList(dict): else: # exclude excluded_count += 1 log_excluded('Excluding %s: not in whitelist.', log_excluded('Excluding %s: not in fallback list.', f._fpr) self.fallbacks = filtered_fallbacks return excluded_count @staticmethod def summarise_filters(initial_count, excluded_count): return '/* Whitelist excluded %d of %d candidates. */'%( def summarise_filters(initial_count, excluded_count, check_existing): list_type = 'Whitelist' if check_existing: list_type = 'Fallback list' return '/* %s excluded %d of %d candidates. */'%(list_type, excluded_count, initial_count) # calculate each fallback's measured bandwidth based on the median Loading Loading @@ -2284,7 +2288,8 @@ def list_fallbacks(whitelist, exact=False): # instead, there will be an info-level log during the eligibility check. initial_count = len(candidates.fallbacks) excluded_count = candidates.apply_filter_lists(whitelist, exact=exact) print candidates.summarise_filters(initial_count, excluded_count) print candidates.summarise_filters(initial_count, excluded_count, whitelist['check_existing']) eligible_count = len(candidates.fallbacks) # calculate the measured bandwidth of each relay, Loading Loading
changes/bug24953 0 → 100644 +4 −0 Original line number Diff line number Diff line o Minor bugfixes (fallback scripts): - In updateFallbackDirs.py, call the filter file a "fallback list" instead of a "whitelist" in check_existing mode. Fixes bug 24953; bugfix on 0.3.0.3-alpha.
scripts/maint/updateFallbackDirs.py +10 −5 Original line number Diff line number Diff line Loading @@ -1594,7 +1594,7 @@ class CandidateList(dict): """ Apply the fallback whitelist_obj to this fallback list, passing exact to is_in_whitelist(). """ excluded_count = 0 logging.debug('Applying whitelist') logging.debug('Applying fallback list') # parse the whitelist whitelist = self.load_relaylist(whitelist_obj) filtered_fallbacks = [] Loading @@ -1609,14 +1609,18 @@ class CandidateList(dict): else: # exclude excluded_count += 1 log_excluded('Excluding %s: not in whitelist.', log_excluded('Excluding %s: not in fallback list.', f._fpr) self.fallbacks = filtered_fallbacks return excluded_count @staticmethod def summarise_filters(initial_count, excluded_count): return '/* Whitelist excluded %d of %d candidates. */'%( def summarise_filters(initial_count, excluded_count, check_existing): list_type = 'Whitelist' if check_existing: list_type = 'Fallback list' return '/* %s excluded %d of %d candidates. */'%(list_type, excluded_count, initial_count) # calculate each fallback's measured bandwidth based on the median Loading Loading @@ -2284,7 +2288,8 @@ def list_fallbacks(whitelist, exact=False): # instead, there will be an info-level log during the eligibility check. initial_count = len(candidates.fallbacks) excluded_count = candidates.apply_filter_lists(whitelist, exact=exact) print candidates.summarise_filters(initial_count, excluded_count) print candidates.summarise_filters(initial_count, excluded_count, whitelist['check_existing']) eligible_count = len(candidates.fallbacks) # calculate the measured bandwidth of each relay, Loading