Opened on 04/21/2016 at 12:33:02 PM

Closed on 04/21/2016 at 06:07:47 PM

Last modified on 04/22/2016 at 12:08:49 AM

#3964 closed defect (fixed)

Console errors when using CSS property filters

Reported by: Ross Assignee: trev
Priority: P1 Milestone: Adblock-Plus-2.7.3-for-Firefox
Module: Adblock-Plus-for-Firefox Keywords:
Cc: Blocked By:
Blocking: Platform: Firefox
Ready: yes Confidential: no
Tester: Ross Verified working: yes
Review URL(s):

Description (last modified by trev)



Reproduced with:
Firefox 44 / 45 / Windows 8

How to reproduce

  1. Launch Firefox open the Firefox console (CTRL+SHIFT+J).
  2. Install the latest ABP dev build.
  3. Add custom filter:[-abp-properties='width: 64px;']
  4. Navigate to
  5. Refresh the page several times.
  6. Observe the logo is sometimes hidden but often not.
  7. Observe errors in console related to CSS property filters.

Observed behaviour

The initial behaviour of the filter looks correct and hides the logo. But after refreshing the page the filter no longer seems to apply to the page and several errors are printed into the console:

InvalidAccessError: A parameter or an operation is not supported by the underlying object cssProperties.js 79:0
(This error also appears with a source of "<unknown>".

Expected behaviour

Errors to not occur when using CSS property filters.


CSS properties content script expects to run when all the stylesheets are already loaded. We are currently running it on DOMContentLoaded event in Firefox however, so there is chance that it will access a stylesheet that isn't loaded yet and trigger the exception above.

What to change

Run the content script from load event handler, not DOMContentLoaded.

Attachments (0)

Change History (5)

comment:1 Changed on 04/21/2016 at 12:54:48 PM by trev

  • Description modified (diff)
  • Owner set to trev
  • Priority changed from Unknown to P1
  • Ready set

comment:2 Changed on 04/21/2016 at 12:57:54 PM by trev

  • Review URL(s) modified (diff)
  • Status changed from new to reviewing

comment:3 Changed on 04/21/2016 at 06:07:08 PM by abpbot

A commit referencing this issue has landed:

comment:4 Changed on 04/21/2016 at 06:07:47 PM by trev

  • Milestone set to Adblock-Plus-2.7.3-for-Firefox
  • Resolution set to fixed
  • Status changed from reviewing to closed

comment:5 Changed on 04/22/2016 at 12:08:49 AM by Ross

  • Tester changed from Unknown to Ross
  • Verified working set

CSS property filters now work as expected and no longer cause errors shown the console.

Firefox 45 / Windows 8

Add Comment

Modify Ticket

Change Properties
as closed .
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from trev.
Note: See TracTickets for help on using tickets.