Some code structures are not conducive to static typing · Issue #386 · getsentry/sentry-python · GitHub
Skip to content

Some code structures are not conducive to static typing #386

Description

@bluetech

This package now declares that it includes typings so I tried to whitelist it in one of my projects. Unfortunately I got various errors like error: Module has no attribute "push_scope" for sentry_sdk.push_scope().

I haven't tried it but I suspect that dynamic code structures like

are too hard for mypy to understand. I was wondering if you'd be willing to forgo these (nice) shortcuts in order to help mypy. I'll be happy to send a PR if so.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions