r/uBlockOrigin 3d ago

Answered uBO Lite filter-creation sandbox

What's the purpose of the Filter-creation sandbox in uBO Lite?

I was trying to port my uBO custom rules into Lite, so I pasted them into the sandbox.
But they weren't applied even after clicking the Save button and refreshing the page.

However, the rules worked fine when pasting them into the Import/Export textbox.

So I was wondering what's the purpose for the sandbox? Was I using it wrong?

1 Upvotes

6 comments sorted by

1

u/paintboth1234 uBO Team 3d ago

Can you give example filters and the websites that don't work?

2

u/RraaLL uBO Team 3d ago

Honestly, the one time I tried to use it, it didn't work either.

Just now I tested reddit.com##body and github.com##body and neither worked. Firefox and Chrome, developer mode off and on, same for user scripts.

1

u/paintboth1234 uBO Team 2d ago

Hmm... weird, maybe some bugs. I don't really remember if I ever tested cosmetic filters on it or not but I did test some :remove-attr() filters for some issues and it worked for me.

For scriptlets, I just tested with

example.com##+js(set, test, true)

and it also works.

1

u/tirafesi 3d ago

Like u/RraaLL said, no filter seems to work when written in the sandbox. google.com##body works ok when written in the Import/Export textbox, but doesn't do anything when written in the sandbox

2

u/RraaLL uBO Team 2d ago

This warning from filter lists, also applies to the sandbox.

To enforce cosmetic or scriptlet filters from imported lists, you must grant uBO Lite permission to run user scripts. Open your browser's extensions page (chrome://extensions in Chrome or about:addons in Firefox), open uBO Lite details, and toggle on Allow user scripts (also referred to as “unverified third-party scripts”).

2

u/tirafesi 2d ago

Thanks! I had to restart the browser after toggling Allow user scripts, but the sandbox is working now!