In main(), blocklist_instance is only assigned inside the branch where a blocklist.py is loaded, so when no blocklist file is present (the default) every matched article raises cannot access local variable 'blocklist_instance' and is skipped. Fix: initialize blocklist_instance = None before the if os.path.exists(blocklist_path) block (check_for_matches already treats blocklist=None as safe).
In
main(),blocklist_instanceis only assigned inside the branch where ablocklist.pyis loaded, so when no blocklist file is present (the default) every matched article raisescannot access local variable 'blocklist_instance'and is skipped. Fix: initializeblocklist_instance = Nonebefore theif os.path.exists(blocklist_path)block (check_for_matchesalready treatsblocklist=Noneas safe).