The plugin provides 21 inspections for Python type annotation simplification and validation:
UnionWithNoneInspection—Union[X, None]→Optional[X]UnionWithObjectInspection—Union[X, object]→objectUnionWithOneChildToChildInspection—Union[X]→XRedundantOptionalInspection—Optional[Optional[X]]→Optional[X]AnyInUnionInspection—Union[X, Any]→AnyDuplicateTypesInUnionInspection—Union[int, int, str]→Union[int, str]RedundantUnionInspection—Union[int, bool]→intNestedUnionInspection—Union[Union[X, Y], Z]→Union[X, Y, Z]EmptyUnionInspection— detect invalidUnion[]
PipeSyntaxWithObjectInspection—X | object→objectPipeSyntaxWithAnyInspection—X | Any→AnyRedundantParenthesesInPipeUnionInspection—(X) | Y→X | YNestedPipeUnionInspection—(X | Y) | Z→X | Y | Z
ConvertUnionToModernSyntaxInspection—Union[X, Y]→X | YConvertOptionalToModernSyntaxInspection—Optional[X]→X | NoneConvertPipeToUnionInspection—X | Y→Union[X, Y]ConvertPipeNoneToOptionalInspection—X | None→Optional[X]DeprecatedTypingCollectionInspection—List[X]→list[X]ConvertToTypeStatementInspection—TypeAlias→typestatement
MissingOptionalInspection— detect= NonewithoutOptionalSimplifyCallableInspection—Callable[..., Any]→CallableRedundantGenericInspection— redundantGeneric[T]in classUnboundTypeVarInspection— TypeVar used only onceProtocolMethodAnnotationInspection— Protocol methods without annotations
- Add test infrastructure with IntelliJ test framework
- Write tests for all inspections and quick fixes
- Set up CI test coverage reporting
- Handle forward references in string annotations
- Add settings page for inspection configuration
- Allow choosing Python version target
- Option to prefer
Optional[X]vsX | None - Batch fix action for entire file/project
- Improve inspection descriptions with more examples
- Add "Learn more" links to PEP documentation
- Create plugin documentation website
- Extract strings to resource bundles
- Add Russian localization
- Add Chinese localization
- Integration with mypy error messages
- Integration with pyright suggestions
- Support for stub files (.pyi)
- Add type annotation intentions (not just inspections)
- Quick documentation for type patterns
- Type annotation completion suggestions
Contributions are welcome! See GitHub Issues for current tasks.