Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion httpx/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,4 +102,9 @@ def main() -> None: # type: ignore
__locals = locals()
for __name in __all__:
if not __name.startswith("__"):
setattr(__locals[__name], "__module__", "httpx") # noqa
try:
setattr(__locals[__name], "__module__", "httpx") # noqa
except AttributeError: # pragma: no cover
# typing.Union instances are immutable in Python 3.14+,
# so don't fail if writing to "__module__" fails
continue # pragma: no cover