Skip to content

Single invalid style filter disables all cosmetic filtering on the page #2170

Closed
@Yuki2718

Description

Prerequisites

I tried to reproduce the issue when...

  • uBO is the only extension
  • uBO with default lists/settings
  • using a new, unmodified browser profile

Description

As the title says. See Steps to reproduce.

A specific URL where the issue occurs

www.backcountry.com

Steps to Reproduce

  1. Add
www.backcountry.com##.chakra-portal
www.backcountry.com##body:style(overflow: auto !important;padding: var(--chakra-space-0 !important;)

to My filters - note the second rule lacks an close parenthesis for var but neither picker or assets viewer marks as invalid. Also enable EasyList Cookie to see the effect.

  1. Visit the page and see newsletter modal and cookie banner are displayed, which should not be the case and the logger shows according filters applied.
  2. If you add the close parenthesis (i.e. www.backcountry.com##body:style(overflow: auto !important;padding: var(--chakra-space-0) !important;)) everything works as expected1.

  1. The style filter acutally doesn't work on the page but it's not relevant here.

Expected behavior

uBO ignores the style filter and other elements are hidden.

Actual behavior

All cosmetic filters are not applied yet logged.

uBlock Origin version

1.43.0/1.43.1b3

Browser name and version

Firefox 102.0.1

Operating System and version

Windows 10

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingfixedissue has been addressed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions