Skip to content

Add request/response context to parseJson option#849

Merged
sholladay merged 1 commit intomainfrom
parse-context
Mar 26, 2026
Merged

Add request/response context to parseJson option#849
sholladay merged 1 commit intomainfrom
parse-context

Conversation

@sindresorhus
Copy link
Copy Markdown
Owner

Fixes #605

@sindresorhus sindresorhus requested a review from sholladay March 26, 2026 06:46
@sindresorhus
Copy link
Copy Markdown
Owner Author

options is intentionally left out. request and response already provide what you need for logging and conditional parsing. options is problematic because it can be stale (it's a snapshot from creation time, not reflecting runtime state after retries/hooks).

@sholladay sholladay merged commit 3713ce8 into main Mar 26, 2026
6 checks passed
@sholladay sholladay deleted the parse-context branch March 26, 2026 14:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Allow for logging network errors and JSON parse errors

2 participants