Filter combining inconsistency between blockers #1728
Replies: 9 comments 13 replies
-
Actually this one issue was linked from wiki: #453 it's about comma-separated procedurals, not only |
Beta Was this translation helpful? Give feedback.
This comment has been hidden.
This comment has been hidden.
This comment has been hidden.
This comment has been hidden.
-
AG follows CSS selectors semantics here. I don't fully understand why uBO & ABP opted to do it differently. On a side note, does it really make sense to support commas in CSS selectors? Combining different selectors may save some time, but it hurts our attempts to automate the detection of obsolete selectors. |
Beta Was this translation helpful? Give feedback.
-
Very useful where multiple elements are to be styled with one common style or get removed or something similar where all elements are subjected to one singular action.
No, procedural filters cannot be combined with plain selectors like that in uBO. |
Beta Was this translation helpful? Give feedback.
-
The rule I brought forward was made by a certain uBO user (not @uBlock-user :D) who suggested me to combine two procedural filters that way. I didn't add that rule to the Finnish Easylist because I luckily happened to be aware of this syntax interpretation difference. Also, I don't usually like to combine rules (with the exception of style injection or if rules are targeting visually the same element). But someone else filterlist maintainer who uses uBO or ABP, could add a rule like that and it could cause breakages to AG users. The rule I gave in the opening, would hide legit articles on |
Beta Was this translation helpful? Give feedback.
-
I recall being involved in a discussion about this a couple months ago, though I can no longer remember where it occured. I find the uBO+ABP approach to be very convenient, as some of my opt-in cultural filterlists would not have been realistically possible to maintain without The filesize of this specific list would've possibly doubled with AdGuard's approach, though I'm short on time to do fine calculations about it this afternoon. |
Beta Was this translation helpful? Give feedback.
-
@krystian3w It's better to rewrite Sep'21 idea of FB Sponsored in |
Beta Was this translation helpful? Give feedback.
-
This may changed a few logic with now pure CSS filters: #2480 so better check how works own lists where is not added long time ago Demo to checks: https://jsfiddle.net/wvcnz8Lk/ https://output.jsbin.com/tedikod |
Beta Was this translation helpful? Give feedback.
-
I have noticed that there is an inconsistency between blockers when combining filters with a comma (and there's a procedural operator involved).
Adblock Plus, Adguard and uBlock Origin treat filters like this differently:
iltalehti.fi#?#main div[class="card "], main .half-article:-abp-contains(Kaupallinen yhteistyö)
ABP & uBO way to interpret:
iltalehti.fi#?#main div[class="card "]:-abp-contains(Kaupallinen yhteistyö)
iltalehti.fi#?#main .half-article:-abp-contains(Kaupallinen yhteistyö)
AG way to interpret:
iltalehti.fi#?#main div[class="card "]
iltalehti.fi#?#main .half-article:-abp-contains(Kaupallinen yhteistyö)
I'm not aware of any common place to discuss stuff like this so I'm opening an issue report here, and I'll tag representatives from each "section": @gorhill @ameshkov @WebReflection
What I'm trying to say is that could you consider doing some alignment/agreeing together how rules like that should be interpret so that it's interpret in the same way in all blockers? For those who try to maintain cross-blocker compatible filterlists, inconsistencies in interpretation are not a good thing.
Page where I tested filter interpretation:
https://www.iltalehti.fi/raha
Beta Was this translation helpful? Give feedback.
All reactions