Skip to content

Preserve blank values when extending queries - #161

Open
muneikh wants to merge 1 commit into
python-hyper:mainfrom
muneikh:fix-extend-query-empty-values
Open

muneikh wants to merge 1 commit into
python-hyper:mainfrom
muneikh:fix-extend-query-empty-values

Conversation

@muneikh

@muneikh muneikh commented Oct 11, 2026

Copy link
Copy Markdown

Extending a URI query currently drops existing parameters with empty values because parse_qsl uses its default keep_blank_values=False. For example, extending a=&a=1 retains only a=1.

Keep blank values when parsing the original query. Three regression cases cover empty values, repeated parameters, valueless flags, and preserving the original builder.

Validation: all three regressions fail before the fix; all 2,917 tests pass with 100% source coverage. Black, isort and Flake8 pass. The configured Pyright type-completeness gate passes at 76.95% (75% required).

A valueless flag is retained and normalized to flag=, consistent with the builder’s query serialization.

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.

1 participant