CCleaner breaks Firefox's service workers

I reported this to support back on March 2020, and I was quite disappointed to see the issue being dismissed. Now, it's almost December, and the issue is still present.

Using the latest CCleaner version (5.74.8198 at the time of writing) along with the latest Firefox (83.0), and the following options, ALL the registered service workers become invalid after running CCleaner; the next time one visits a site which had registered a SW, the page will be blank. After a couple of reloads and/or waiting for a while, the SW will be re-registered and everything will work until the next time one runs CCleaner.

This is easily reproducible on Twitter or Gmail sites which register a service worker.

The workaround is to uncheck cookies cleaning or disable service workers in Firefox

dom.serviceWorkers.enabled

Now, this is 100% reproducible on at least 8 machines with the same settings, so it's definitely a bug in CCleaner. It'd be nice if CCleaner finally fixed the issue.

I attached a video demonstrating the issue.

2020-11-30_09-12-21.png

That is not a bug.

It is the itended behaviour and is what CCleaner is supposed to do unless you specifically tell it not to.

It's 100% reproducible because it is supposed to be like that.

CCleaner is supposed to clear cookies.

If you want CCleaner to leave the cookies for your particular service worker(s), or any other cookies, alone then you have to tell it not to clean them.

Not everybody wants the same cookies to be saved and so it is made easy for the individual user to set what Custom Clean will leave alone.

For instance most people will want the service worker cookies removing, you don't want that so you have the option to tell CCleaner to leave them alone.

You have already found (and noted above) that if you tell CCleaner not to clear any Firefox cookies then it will leave them alone.

You can go further than that though and tell CCleaner to 'Keep' specific cookies, which will then leave them alone while clearing the rest.

That way you can tell it to leave the cookies for the service workers alone while cleaning any other cookies.

See 'Option 2' of this article for how to do that:

https://www.ccleaner.com/docs/ccleaner/ccleaner-settings/choosing-which-cookies-to-keep

Read also the section 'Not sure which cookies to keep' about the 'Intelligent cookie scan' which could help if you are not sure which cookies you need to keep.

I don't think you understand the issue.

Clearing cookies, should NOT break SW.

Yes, but it is telling that unticking Firefox cookies in CCleaner stops the problem from happening.

That tends to indicate that those particular SWs are relying on cookies in some way.

From what you say then not cleaning any Firefox cookies at all works.


So I'd still check if making certain cookies an exception in CCleaner will solve it, of course the problem there is identfying which particular cookies to keep.

Of course it could be something that Firefox has changed, when Mozilla separted the Startup caches from the General caches and started saving them to a different location a month or so ago it caused issues for a while.

Your issue has been flagged up to the CCleaner staff to be investigated.

JFYI: Firefox seems to handle this in the same way. If you enable "Delete cookies and site data when Firefox is closed", Service Workers will not work either.

21 minutes ago, APMichael said:
<div class="ipsQuote_contents">
	<p>
		JFYI: Firefox seems to handle this in the same way. If you enable "Delete cookies and site data when Firefox is closed", Service Workers will not work either.
	</p>
</div>

Works for me here.

Some facts, AFAICT:

1. this issue wasn't present up until March (can't recall the exact Firefox version since it's been so many months)

2. Chromium-based browsers do not have this issue

3. Firefox's own option to delete data on exit, or manually deleting the data, does NOT break Service Workers for me

So, from the looks of it, it does seem something CCleaner is doing is wrong, and as much as I've tried to escalate this in the past, doesn't seem to get the proper attention.

1 hour ago, XhmikosR said:
<div class="ipsQuote_contents">
	<p>
		Works for me here. ...
	</p>
</div>

Strange, since the bug report is still open: https://bugzilla.mozilla.org/show_bug.cgi?id=1413615

But never mind, if the problem exists only since a few versions, then the CCleaner developers should have a look.

3 hours ago, XhmikosR said:
<div class="ipsQuote_contents ipsClearfix" data-gramm="false">
	<p>
		Works for me here.
	</p>

	<p>
		Some facts, AFAICT:
	</p>

	<p>
		1. this issue wasn't present up until March (can't recall the exact Firefox version since it's been so many months)
	</p>

	<p>
		2. Chromium-based browsers do not have this issue
	</p>

	<p>
		3. Firefox's own option to delete data on exit, or manually deleting the data, does NOT break Service Workers for me
	</p>

	<p>
		 
	</p>

	<p>
		So, from the looks of it, it does seem something CCleaner is doing is wrong, and as much as I've tried to escalate this in the past, doesn't seem to get the proper attention.
	</p>
</div>

Hello XhmikosR,

We've sent this to our devs to investigate and as soon as he will hear back from them we will let you know more about your situation.

@Andrei CCleaner any news about this?