adblockparser
adblockparser copied to clipboard
Easylist no longer supported?
I can't get any of the easylists to work at all?
>>> with open('fanboy_social_general_block.txt', 'rb') as f:
... raw_rules = f.read().decode('utf8').splitlines()
>>> rules = AdblockRules(raw_rules)
>>> rules.should_block("http://www.facebook.com")
False
>>> with open('easylist.txt', 'rb') as f:
... raw_rules = f.read().decode('utf8').splitlines()
>>> rules = AdblockRules(raw_rules)
>>> rules.should_block("http://ads.example.com")
False
Any ideas? Are they no longer compatible?
@gonedjur
Have you tried passing the third-party
argument in options?
>>> from adblockparser import AdblockRules
>>> AdblockRules(['||example.com^$third-party']).should_block('example.com')
False
>>> AdblockRules(['||example.com^$third-party']).should_block('example.com', {'third-party': True})
True
I am facing the same problem. Every input returns false despite passing the third-party option in AdblockRules(). @gonedjur Please let me know if you were able to resolve this.