Closed Bug 1383029 Opened 7 years ago Closed 6 years ago

IndexedDB and Promises do not work together in Firefox

Categories

(Core :: Storage: IndexedDB, defect, P3)

56 Branch
defect

Tracking

()

RESOLVED FIXED

People

(Reporter: robertknight, Unassigned)

References

Details

(Keywords: DevAdvocacy)

Attachments

(1 file)

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_5) AppleWebKit/603.2.4 (KHTML, like Gecko) Version/10.1.1 Safari/603.2.4

Steps to reproduce:

1. Load the HTML test case from this Gist in Firefox: https://gist.github.com/robertknight/462d16b46a438ab67e29301861f5d55f
2. Check console output

The test case performs a series of read-modify-write actions using IndexedDB operations. To make the code easier to follow, IDB requests are converted to Promises and async + await is used to make the code flow look synchronous. The use of Promises with IDB requests works fine in other browsers (Chrome, Safari) but not Firefox.


Actual results:

A "Test failed" message appears followed by details of a `DOMException` error.


Expected results:

The test should output "Final value 10". Each time the page is reloaded, the count should increment by 10.

This works correctly in Safari 10 and Chrome.
Component: Untriaged → DOM: IndexedDB
Product: Firefox → Core
(In reply to robertknight from comment #1)
> Seems like this is related to
> https://bugzilla.mozilla.org/show_bug.cgi?id=1193394 and possibly
> https://bugzilla.mozilla.org/show_bug.cgi?id=1325975

You are right!
Status: UNCONFIRMED → NEW
Depends on: 1193394
Ever confirmed: true
Priority: -- → P3
I can see bug 1193394 is finally fixed and the test case here passes, on the latest Nightly. Please reopen if this is not completely fixed.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: