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

Use environment variable TYPEGUARD_DISABLE to disable typeguard. #475

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

tage64
Copy link

@tage64 tage64 commented Jul 31, 2024

Changes

Setting the environment variable TYPEGUARD_DISABLE disables Typeguard and has the same effect as running Python with the -O flag.

I wanted to compile my Python program with Nuitka which removes the source code so that the inspect module doesn't work. However, I did not want to disable all assertians with the -O flag.

Checklist

  • You've added tests (in tests/) added which would fail without your patch
  • You've updated the documentation (in docs/, in case of behavior changes or new
    features)
  • You've added a new changelog entry (in docs/versionhistory.rst).

@coveralls
Copy link

Coverage Status

coverage: 94.458% (-0.05%) from 94.511%
when pulling 859a611 on tage64:master
into b6a7e43 on agronholm:master.

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.

3 participants