Replace not x in y with x not in y
Recipe ID
org.openrewrite.python.cleanup.ReplaceNotInTestArtifactopenrewrite-migrate-pythonReplace not x in y with x not in y. The not in operator is clearer than negating an in test. A chained comparison such as not a in b in c is left alone.
Single recipepythonE713cleanupruffProprietary
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.ReplaceNotInTestIf 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