Fix cookiestore defaults propagation#42418
Merged
TimvdLippe merged 1 commit intoservo:mainfrom Feb 7, 2026
Merged
Conversation
… underlying object Signed-off-by: Sebastian C <sebsebmc@gmail.com>
Taym95
reviewed
Feb 6, 2026
| @@ -1,6 +1,7 @@ | |||
| [change_eventhandler_for_already_expired.https.window.html] | |||
| expected: TIMEOUT | |||
Member
There was a problem hiding this comment.
usually FAIL better then TIMEOUT, do we knew why?
Contributor
Author
There was a problem hiding this comment.
Im not sure why they were failing before, but we currently don't implement the cookie change event so this should be timing out since we will never fire the event.
Contributor
Author
There was a problem hiding this comment.
I think before we weren't actually setting the expiry, and so the cookie was not getting deleted, which was a FAIL. Now the cookie is deleted but we don't fire the event.
sebsebmc
commented
Feb 7, 2026
| } | ||
| if let Some(expiry) = options.expires { | ||
| cookie.inner_mut().set_expires( | ||
| OffsetDateTime::from_unix_timestamp((*expiry / 1000.0) as i64).unwrap(), |
Contributor
Author
There was a problem hiding this comment.
Im not thrilled about this personally, just not sure how to best clean it up.
TimvdLippe
approved these changes
Feb 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Also fixes propagating expiry clamping to underlying cookie object. This matters when attempting to inspect expiry time from a retrieved cookie.
According to the WPT tests, setting max-age in a cookie string is supposed to be visible in the retrieved expiry.
Testing: cookiestore WPT tests cover this behavior