Skip to content

docs: note UUID-to-int coercion in with_query docs#1645

Open
r266-tech wants to merge 1 commit intoaio-libs:masterfrom
r266-tech:docs/uuid-query-params-note
Open

docs: note UUID-to-int coercion in with_query docs#1645
r266-tech wants to merge 1 commit intoaio-libs:masterfrom
r266-tech:docs/uuid-query-params-note

Conversation

@r266-tech
Copy link
Copy Markdown

Fixes #1458.

Types implementing __int__ (e.g. uuid.UUID) are converted to integers by the query parameter API because int is preferred over str for numeric coercion. This is expected behavior per maintainer feedback in #1458.

This PR adds a tip in the with_query documentation explaining the behavior and showing how to cast to str when the human-readable representation is needed. Includes a doctest for the example.

Types implementing __int__ (e.g. uuid.UUID) are converted to integers
by the query parameter API because int is preferred over str for numeric
coercion. Add a tip with a doctest showing how to cast to str to get
the human-readable representation.
@psf-chronographer psf-chronographer bot added the bot:chronographer:provided There is a change note present in this PR label Mar 23, 2026
@r266-tech r266-tech force-pushed the docs/uuid-query-params-note branch from 4197d36 to 2872181 Compare March 23, 2026 14:20
@codspeed-hq
Copy link
Copy Markdown

codspeed-hq bot commented Mar 23, 2026

Merging this PR will not alter performance

✅ 99 untouched benchmarks


Comparing r266-tech:docs/uuid-query-params-note (2872181) with master (148fc70)

Open in CodSpeed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bot:chronographer:provided There is a change note present in this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Convert an uuid.UUID variable into int when pass it in params

1 participant