You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Consolidate the two cookie parsers parseCookie and parseCookieHeader #24501
parseCookie (used by filterCookies for event cookie records) and parseCookieHeader (used by httpHeadersToSpanAttributes for span attributes) have several differences:
Nameless segments: filterCookies('opaque-blob; theme=dark', true) returns {theme: 'dark'} and drops the blob silently. The span attribute shows ['[Filtered]', 'theme=dark'].
Set-Cookie attributes: filterCookies('sid=1; Max-Age=3600; Path=/', true) returns {sid: '[Filtered]', 'Max-Age': '3600', Path: '/'}. Max-Age and Path are metadata, not cookies. parseCookieHeader strips them.
Only parseCookie URL-decodes values and strips quotes.
One parser returning ordered [name, value][] pairs, with a Set-Cookie mode, could work at both call sites. filterCookies.test.ts has two it.fails tests pinning the intended Set-Cookie behavior -> those need to be flipped when fixed.
Activity
linear-code commentedon Sep 18, 2026
JS-3720
Consolidate cookie parsers into parseCookiePairs
Consolidate cookie parsers into parseCookiePairs
Consolidate cookie parsers into parseCookiePairs
ref(core): Consolidate cookie parsing into one parser (getsentry#24536)
github-actions commentedon Sep 23, 2026
A PR closing this issue has just been released 🚀
This issue was referenced by PR #24536, which was included in the 11.0.0 release.