Avatar for the withastro user
withastro
astro
BlogDocsChangelog

Performance History

Latest Results

feat: export AstroComponentLogger type (#17313) Co-authored-by: Emanuele Stoppa <my.burning@gmail.com> Co-authored-by: Armand Philippot <git@armand.philippot.eu>
main
2 hours ago
chore: add changeset for error page cookie merge fix
sanjibani:fix/issue-17329-error-page-cookies
5 hours ago
fix(astro): merge new response cookies into original AstroCookies for error pages When Astro renders a custom error page (404.astro / 500.astro), any cookies set on the error page via Astro.cookies.set() never reached the final response. If the original page also set a cookie, the error page's cookies vanished entirely. Root cause in mergeResponses: - The merged response's headers were built by appending every header from originalResponse.headers (including any set-cookie entries) into a fresh newHeaders Headers object, then skipping any header name from newResponse.headers that was already in the seen set. set-cookie matches that seen set the moment the original response contributed its own set-cookie entries, so newResponse's set-cookie entries were silently dropped. - The new cookies were appended to originalResponse.headers via originalResponse.headers.append('set-cookie', cookieValue), but the merged response was built from newHeaders, which is a separate Headers object copied from the originals before the append. The append went to a Headers object no one else held a reference to. Repro from #17329: original page sets sid=abc then throws, 500.astro sets flash=boom. Observed final Set-Cookie: ["sid=abc; Path=/"] Expected: ["sid=abc; Path=/", "flash=boom; Path=/"] Fix: when both responses carry an AstroCookies instance, call originalCookies.merge(newCookies) to fold the new entries into the original AstroCookies object, then attachCookiesToResponse below emits the combined set on the merged response. Appending to originalResponse.headers is removed because it never reached the merged response. Behavior is unchanged when only one response carries cookies. Closes #17329
sanjibani:fix/issue-17329-error-page-cookies
7 hours ago
Merge branch 'main' into triagebot/fix-17241
triagebot/fix-17241
14 hours ago
Merge branch 'main' into triagebot/fix-13604
triagebot/fix-13604
24 hours ago

Latest Branches

CodSpeed Performance Gauge
0%
fix(astro): merge new response cookies into original AstroCookies for error pages (#17329)#17337
5 hours ago
4dba9d0
sanjibani:fix/issue-17329-error-page-cookies
CodSpeed Performance Gauge
0%
6 hours ago
efb2ec9
feat/data-store-backend-abstraction
CodSpeed Performance Gauge
-1%
© 2026 CodSpeed Technology
Home Terms Privacy Docs