Re-enable CookieStore API
Categories
(Core :: Networking: Cookies, task, P2)
Tracking
()
People
(Reporter: edgul, Assigned: baku)
References
(Blocks 1 open bug)
Details
(Keywords: dev-doc-complete, webcompat:platform-bug, Whiteboard: [necko-triaged])
Attachments
(1 file)
The CookieStore API was disabled temporarily.
This bug will re-enable it.
| Assignee | ||
Updated•1 year ago
|
| Assignee | ||
Comment 1•1 year ago
|
||
Updated•1 year ago
|
Comment 3•1 year ago
|
||
Backed out for causing failures at test_serviceworker_interfaces.html.
Backout link: https://hg-edge.mozilla.org/integration/autoland/rev/514fd2961000a68d328d1e75d6946e20167556f7
Failure log: https://treeherder.mozilla.org/logviewer?job_id=504507159&repo=autoland&lineNumber=2430
Updated•1 year ago
|
| Assignee | ||
Updated•1 year ago
|
Comment 6•1 year ago
|
||
Backed out for causing mochitest failures in /test_interfaces_secureContext.html
- Backout link
- Push with failures
- Failure Log
- Failure line: TEST-UNEXPECTED-FAIL | dom/tests/mochitest/general/test_interfaces_secureContext.html | If this is failing: DANGER, are you sure you want to expose the new interface CookieStoreManager to all webpages as a property on 'window'? Do not make a change to this file without a review from a DOM peer for that specific change!!! (or a JS peer for changes to ecmaGlobals)
| Assignee | ||
Updated•1 year ago
|
Comment 8•1 year ago
|
||
| bugherder | ||
Comment 9•1 year ago
|
||
:baku want to add a release note back for this?
This was the wording used when it was added to the Fx136 release notes before it was later disabled.
Added support for the CookieStore API, an asynchronous cookie API for scripts running in HTML documents and service workers.
Are any changes needed to the wording?
Comment 10•1 year ago
|
||
I'd say the wording should now be something like "The CookieStore API got re-enabled. It provides methods for getting and setting cookies asynchronously from either a page or a service worker." (reflecting the wording on MDN).
I am also wondering whether it is worth mentioning that circumstance in the browser compat data, as well, meaning it was enabled in 136.0, then disabled in 136.0.2 and got re-enabled now for 140. Hamish, what do you think?
Sebastian
Comment 12•1 year ago
|
||
FWIW Donal wording is great. There is no need to mention the re-enabling because this history is not visible/relevant to external developers (exposed and undone in same release)
Comment 13•1 year ago
|
||
Thanks, added to the Fx140 nightly release notes, please allow 30 minutes for the site to update.
Keeping the relnote-firefox flag as ? to keep it on the radar for inclusion in the final Fx140 release notes.
Comment 14•11 months ago
|
||
FF140 MDN docs work for this can be tracked in https://github.com/mdn/content/issues/39612
Updated•11 months ago
|
Comment 15•11 months ago
•
|
||
OK, just found out from the compat data that this also supports:
CookieStoreManagerExtendableCookieChangeEventServiceWorkerGlobalScopecookiechangeeventServiceWorkerRegistration.cookies
Added in https://bugzilla.mozilla.org/show_bug.cgi?id=1947894 which was not tagged as needing docs (though they seem OK anyway)
-
Did anything else major change in the API from when it was implemented in https://bugzilla.mozilla.org/show_bug.cgi?id=1475599
For example, when we did docs for that issue, it was stated that Firefox has chosen to only return
nameandvaluefrom get and in change events. Is this still the case? -
Docs for
ExtendableCookieChangeEventindicate that this event is fired withtype = changedfor new cookies that are not immediately deleted, and withtype = deletedfor cookies that are deleted. There is also a note:A cookie that is replaced due to the insertion of another cookie with the same name, domain, and path, is ignored and does not trigger a change event.
Is that all correct? I.e. a new cookie is referred to as "changed" but you can't actually change a cookie - if you do so you are replacing it, and so the event is not fired?
| Assignee | ||
Comment 16•11 months ago
|
||
All looks right except the 'partitioned' property. That is not part of the spec.
- Did anything else major change in the API from when it was implemented in https://bugzilla.mozilla.org/show_bug.cgi?id=1475599
No. We just included the SW support (bug 1947894). The documentation is correct.
For example, when we did docs for that issue, it was stated that Firefox has chosen to only return
nameandvaluefrom get and in change events. Is this still the case?
Yes it is.
A cookie that is replaced due to the insertion of another cookie with the same name, domain, and path, is ignored and does not trigger a change event.
No. This is false. Any cookie change generates an event. This line needs to be updated.
Updated•11 months ago
|
Comment 17•11 months ago
|
||
I've marked this as complete because I've finished most of the work (waiting for reviews).
ExtendableCookieChangeEvent
All looks right except the 'partitioned' property. That is not part of the spec.
According to the linked spec the thing that has the properties is a CookieListItem, and in that partitioned does appear.
It is according to the linked spec: https://wicg.github.io/cookie-store/#dictdef-cookielistitem
Updated•11 months ago
|
Description
•