Use is not instead of not ... is
Recipe ID
org.openrewrite.python.cleanup.ReplaceNotIsTestArtifactopenrewrite-migrate-pythonReplace not x is y with x is not y. The is not operator is clearer than negating an is test. A chained comparison such as not a is b is c is left alone.
Single recipepythoncleanupE714ruffProprietary
Usage
This recipe has no required configuration options. You’ll need the Moderne CLI configured before running the command below.
mod run . --recipe org.openrewrite.python.cleanup.ReplaceNotIsTestIf the recipe isn’t available locally, install it with:
mod config recipes pip install openrewrite-migrate-python
mod config recipes jar install org.openrewrite.recipe:rewrite-migrate-python:RELEASE
mod config recipes jar install org.openrewrite:rewrite-python:RELEASE