ChrisCrossCrash / ChrisCrossCrash/c3-http-request

Add lazily-populated Response.headers_dict

Open
#2 0 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
GDScript
Stars
5
Forks
0
PR merge metrics
No merged PRs in 30d

Description

Add a `headers_dict` member mirroring the lazy pattern of `text`/`json`, so callers don't hand-parse the `headers: PackedStringArray`.

Design decisions to settle:

- **Case:** lowercase keys for predictable case-insensitive lookup (HTTP header names are case-insensitive; the engine's `get_response_headers_as_dictionary()` keeps server casing, which is a footgun).
- **Duplicates:** a `Dictionary` can't hold repeated headers like `Set-Cookie`; decide on join behavior and document that the raw `headers` array stays the source of truth for repeated headers.

Additive and non-breaking.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.