Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ref: Explicit reexport of types (backport to 1.x) #2913

Merged
merged 1 commit into from
Mar 27, 2024
Merged
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
2 changes: 2 additions & 0 deletions sentry_sdk/types.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,5 @@

if TYPE_CHECKING:
from sentry_sdk._types import Event, Hint # noqa: F401

__all__ = ["Event", "Hint"]

Check warning on line 16 in sentry_sdk/types.py

View check run for this annotation

Codecov / codecov/patch

sentry_sdk/types.py#L16

Added line #L16 was not covered by tests
Copy link
Contributor

@sentrivana sentrivana Mar 27, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it ok that this is behind TYPE_CHECKING? Not too deep into the topic but #2909 seems to suggest it shouldn't be?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR only fixes #2910. I opened #2914 to fix #2909, and in #2914, I have moved the __all__ out of the if TYPE_CHECKING guard

Loading