summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Bruhin <me@the-compiler.org>2021-01-28 14:54:40 +0100
committerFlorian Bruhin <me@the-compiler.org>2021-01-28 15:57:42 +0100
commit215257cc7d28fbb51eaaf4d83c014887919e786a (patch)
treea9d02f498f3c846371631e9a2da6ce4a5427c688
parent240c5663844290767d8037bf70bd30a386fada40 (diff)
downloadqutebrowser-215257cc7d28fbb51eaaf4d83c014887919e786a.tar.gz
qutebrowser-215257cc7d28fbb51eaaf4d83c014887919e786a.zip
Ignore stale adblock.py component
It looks like some setups (and even packages, apparently?!) still ship adblock.py despite it not being a part of the release. This then causes a NoOptionError because adblock.py tries to access content.host_blocking which doesn't exist anymore. Likely this will resolve over time - but until that's the case, let's just explicitly block that component even if it exists. (cherry picked from commit f5a409aa9f0b59f3bbb3e23bcf84e4a05c829858)
-rw-r--r--qutebrowser/extensions/loader.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/qutebrowser/extensions/loader.py b/qutebrowser/extensions/loader.py
index 297f1b108..9b704c94d 100644
--- a/qutebrowser/extensions/loader.py
+++ b/qutebrowser/extensions/loader.py
@@ -108,6 +108,11 @@ def _walk_normal() -> Iterator[ExtensionInfo]:
onerror=_on_walk_error):
if ispkg:
continue
+ if name == 'qutebrowser.components.adblock':
+ # WORKAROUND for packaging issues where the old adblock.py file is still
+ # lingering around.
+ log.extensions.debug("Ignoring stale 'adblock' component")
+ continue
yield ExtensionInfo(name=name)