Large codebases and libraries need time to refactor code that might be legacy or automatically generated.

Rapidly turning a warning into a hard error can break environments. A longer warning period ensures developers see the notice without their builds immediately failing.

For most developers, this is rarely the intended result. Usually, someone using ~ on a boolean actually wants the logical NOT ( not True ), which correctly returns False . Because of this common point of confusion, the Python steering committee decided to deprecate bitwise inversion on booleans to encourage clearer coding practices. What’s New in Issue #122982?

Contact us today
If you're a federal employee and feel you've been the victim of unlawful discrimination involving MSPB claims or EEO claims, our experienced federal employment attorneys stand ready to fight on your behalf. Give us a call today at (404) 724-0000 or fill out the form below and we'll be sure to follow up in a timely manner.
Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.

122982 May 2026

Large codebases and libraries need time to refactor code that might be legacy or automatically generated.

Rapidly turning a warning into a hard error can break environments. A longer warning period ensures developers see the notice without their builds immediately failing. 122982

For most developers, this is rarely the intended result. Usually, someone using ~ on a boolean actually wants the logical NOT ( not True ), which correctly returns False . Because of this common point of confusion, the Python steering committee decided to deprecate bitwise inversion on booleans to encourage clearer coding practices. What’s New in Issue #122982? Large codebases and libraries need time to refactor