Page MenuHomePhabricator

DismissableSiteNotice: Notice should still be hidden on the current page even if saving cookie fails
Closed, ResolvedPublic

Description

Right now I am unable to dismiss SiteNotices on any Wikipedia projects because my local storage has been completely filled up by MediaWikiModuleStore.

When I click [dismiss], JS throws the following exception:
[Exception... "Persistent storage maximum size reached" code: "1014" nsresult: "0x805303f6 (NS_ERROR_DOM_QUOTA_REACHED)" location: "<unknown>"] { code=1014, message="Persistent storage maximum size reached", result=2152924150, more...}

Being able to dismiss SiteNotices is important. It should either use cookies by default or fall back to using cookies when local storage is unavailable.


Version: unspecified
Severity: major
See Also:
https://bugzilla.wikimedia.org/show_bug.cgi?id=64721

Details

Reference
bz64716

Event Timeline

bzimport raised the priority of this task from to Normal.Nov 22 2014, 3:23 AM
bzimport set Reference to bz64716.
bzimport added a subscriber: Unknown Object (MLST).
kaldari created this task.May 1 2014, 8:46 PM

Looks like DismissableSiteNotice actually uses $.cookie to save the dismiss state. I have no idea why that would fail if local storage is full. Strange.

Change 130972 had a related patch set uploaded by Kaldari:
Make sure notice can be dismissed regardless of whether cookie is set

https://gerrit.wikimedia.org/r/130972

Change 130973 had a related patch set uploaded by Ori.livneh:
Make localStorage use resilient

https://gerrit.wikimedia.org/r/130973

Change 130972 merged by jenkins-bot:
Make sure notice can be dismissed even if setting cookie throws

https://gerrit.wikimedia.org/r/130972

Change 130973 merged by jenkins-bot:
Make localStorage use resilient

https://gerrit.wikimedia.org/r/130973

  • Bug 64737 has been marked as a duplicate of this bug. ***