[Webkit-unassigned] [Bug 202137] REGRESSION (Safari 13): IndexedDB asks user for gigabytes of storage, even though megabytes are actually used

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Sep 25 17:15:42 PDT 2019


https://bugs.webkit.org/show_bug.cgi?id=202137

--- Comment #2 from Sihui Liu <sihui_liu at apple.com> ---
(In reply to radexpl from comment #0)
> IndexedDB size calculations seem buggy, leading to very bad user experience.
> Our web app (4.nozbe.com) is based on LokiJS, which uses IndexedDB only as a
> storage mechanism -- and so it saves the entire LokiJS data object in just
> one IndexedDB row.
> 
> On a fairly large account, the database size can grow up too 100MB.
> 
> And yet, after a few database operations, Safari asks the user for >1GB of
> storage… after accepting, and a few database operations (each of which will
> save the new version of database to disk, but keeping below <100MB of size
> of both the database and WAL/SHL files), it will ask for 1.2GB… 1.4GB… every
> couple of minutes.
> 
> This is a regression in Safari 13 / Safari TP. The issue does not occur on
> Safari 12. I suspect this Webkit commit might be the cause of the issue:
> https://github.com/WebKit/webkit/commit/
> 36aa2f1a9d05d9efdcf41929c206e2dfdc6e6ded#diff-
> 714b919c798f296a141098072faac979
> 
> (originally posted as https://feedbackassistant.apple.com/feedback/7315350)
> 
> . . .
> 
> I extracted a repro demo here (the numbers are a little different, but basic
> principle is the same):
> 
> https://web.radexpl.now.sh/
> 
> 1. open in safari 13 / safari TP,
> 2. click "generate 10,000 records" a few times, open first item on the list,
> click "moderate", try with second item, click generate 10,000 items again —
> after a few of these actions (<30 seconds to reproduce), Safari will ask if
> it can increase db size to 1.2GB
> 3. click yes or refresh page - then check under
> `/Users/radex/Library/SafariTechnologyPreview/Databases/___IndexedDB/v1/
> https_web.radexpl.now.sh_0/` - database won't be actually larger than 250MB

Hi,

I just tried the steps above on Safari 13. I saw the "increase db size to 1.2GB", but only on when the database file sizes reach over or about 1GB. I noticed that the display of file size in Finder app may be delayed. If you were using Finder, can you try re-opening Finder probably a few seconds after you see the notification and confirm total database file size is much smaller than 1GB?

Thanks.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20190926/ab90910f/attachment.html>


More information about the webkit-unassigned mailing list