Upgrading mypy 0.701 to 0.710
Unknown0.701 → 0.710
Fetching 1 release from GitHub…0 / 1
UnknownUpgrade verdict
DepDelta is still reading the notes for this range, so breaking changes can't be ruled out yet.
In plain terms
- DepDelta is still reading the release notes in this range, so it can't rule out breaking changes yet.
- This page updates as the notes come in.
Must act Still reading release notes
DepDelta is still reading the release notes in this range. This updates as they come in.
Moves typed-ast 1.3.5 → 1.4.3. Your build may pick other versions.
API changes
Generated by DepDelta from published Python source. Not mixed with prose notes.
- changed:
class BuildManager(BuildManagerBase) → class BuildManager - changed:
constructor BuildManager(data_dir: str, search_paths: SearchPaths, ignore_prefix: str, source_set: BuildSourceSet, reports: Optional[Reports], options: Options, version_id: str, plugin: Plugin, plugins_snapshot: Dict[str, str], errors: Errors, flush_errors: Callable[[List[str], bool], None], fscache: FileSystemCache) -> None → constructor BuildManager(data_dir: str, search_paths: SearchPaths, ignore_prefix: str, source_set: BuildSourceSet, reports: Optional[Reports], options: Options, version_id: str, plugin: Plugin, plugins_snapshot: Dict[str, str], errors: Errors, flush_errors: Callable[[List[str], bool], None], fscache: FileSystemCache, stdout: TextIO, stderr: TextIO) -> None - changed:
function build(sources: List[BuildSource], options: Options, alt_lib_path: Optional[str]=…, flush_errors: Optional[Callable[[List[str], bool], None]]=…, fscache: Optional[FileSystemCache]=…) -> BuildResult → function build(sources: List[BuildSource], options: Options, alt_lib_path: Optional[str]=…, flush_errors: Optional[Callable[[List[str], bool], None]]=…, fscache: Optional[FileSystemCache]=…, stdout: Optional[TextIO]=…, stderr: Optional[TextIO]=…) -> BuildResult - changed:
function dispatch(sources: List[BuildSource], manager: BuildManager) -> Graph → function dispatch(sources: List[BuildSource], manager: BuildManager, stdout: TextIO) -> Graph - changed:
function dump_graph(graph: Graph) -> None → function dump_graph(graph: Graph, stdout: Optional[TextIO]=…) -> None - changed:
function load_plugins(options: Options, errors: Errors) -> Tuple[Plugin, Dict[str, str]] → function load_plugins(options: Options, errors: Errors, stdout: TextIO) -> Tuple[Plugin, Dict[str, str]] - changed:
function read_quickstart_file(options: Options) -> Optional[Dict[str, Tuple[float, int, str]]] → function read_quickstart_file(options: Options, stdout: TextIO) -> Optional[Dict[str, Tuple[float, int, str]]] - added:
field State.early_errors - added:
function log_configuration(manager: BuildManager) -> None - added:
method BuildManager.add_stats(**kwds: Any) -> None - added:
method BuildManager.log(*message: str) -> None - added:
method BuildManager.log_fine_grained(*message: str) -> None - added:
method BuildManager.trace(*message: str) -> None - added:
method BuildManager.verbosity() -> int - added:
method State.parse_inline_configuration(source: str) -> None
- removed:
method TypeChecker.warn(msg: str, context: Context) -> None - changed:
method TypeChecker.check_compatibility(name: str, base1: TypeInfo, base2: TypeInfo, ctx: Context) -> None → method TypeChecker.check_compatibility(name: str, base1: TypeInfo, base2: TypeInfo, ctx: TypeInfo) -> None - added:
function is_private(node_name: str) -> bool - added:
method TypeChecker.bind_and_map_method(sym: SymbolTableNode, typ: FunctionLike, sub_info: TypeInfo, super_info: TypeInfo) -> FunctionLike
- changed:
function all_same_types(types: Iterable[Type]) -> bool → function all_same_types(types: List[Type]) -> bool - changed:
method ExpressionChecker.accept(node: Expression, type_context: Optional[Type]=…, allow_none_return: bool=…, always_allow_any: bool=…, in_final_declaration: bool=…) -> Type → method ExpressionChecker.accept(node: Expression, type_context: Optional[Type]=…, allow_none_return: bool=…, always_allow_any: bool=…) -> Type - changed:
method ExpressionChecker.check_generator_or_comprehension(gen: GeneratorExpr, type_name: str, id_for_messages: str, additional_args: List[Type]=…) -> Type → method ExpressionChecker.check_generator_or_comprehension(gen: GeneratorExpr, type_name: str, id_for_messages: str, additional_args: Optional[List[Type]]=…) -> Type - changed:
method ExpressionChecker.dangerous_comparison(left: Type, right: Type) -> bool → method ExpressionChecker.dangerous_comparison(left: Type, right: Type, original_container: Optional[Type]=…) -> bool - added:
function custom_equality_method(typ: Type) -> bool - added:
function has_bytes_component(typ: Type) -> bool
- changed:
function analyze_none_member_access(name: str, typ: NoneTyp, mx: MemberContext) -> Type → function analyze_none_member_access(name: str, typ: NoneType, mx: MemberContext) -> Type - changed:
function type_object_type_from_function(init_or_new: FuncBase, info: TypeInfo, fallback: Instance) -> FunctionLike → function type_object_type_from_function(signature: FunctionLike, info: TypeInfo, def_info: TypeInfo, fallback: Instance) -> FunctionLike - added:
function is_valid_constructor(n: Optional[SymbolNode]) -> bool
- added:
function mypy_comments_to_config_map(line: str, template: Options) -> Tuple[Dict[str, str], List[str]] - added:
function parse_config_file(options: Options, filename: Optional[str], stdout: Optional[TextIO]=…, stderr: Optional[TextIO]=…) -> None - added:
function parse_mypy_comments(args: List[Tuple[int, str]], template: Options) -> Tuple[Dict[str, object], List[Tuple[int, str]]] - added:
function parse_section(prefix: str, template: Options, section: Mapping[str, str], stderr: TextIO=…) -> Tuple[Dict[str, object], Dict[str, str]] - added:
function parse_version(v: str) -> Tuple[int, int] - added:
function split_and_match_files(paths: str) -> List[str] - added:
function split_directive(s: str) -> Tuple[List[str], List[str]] - added:
variable MYPY - added:
variable config_types
- changed:
method ConstraintBuilderVisitor.visit_none_type(template: NoneTyp) -> List[Constraint] → method ConstraintBuilderVisitor.visit_none_type(template: NoneType) -> List[Constraint]
- removed:
class AugmentedHelpFormatter(argparse.RawDescriptionHelpFormatter) - removed:
class BadStatus(Exception) - removed:
constructor AugmentedHelpFormatter(prog: str) -> None - removed:
function action(subparser: argparse.ArgumentParser) -> Callable[[ActionFunction], ActionFunction] - removed:
function check_output(response: Dict[str, Any], verbose: bool, junit_xml: Optional[str], perf_stats_file: Optional[str]) -> None - removed:
function check_status(data: Dict[str, Any]) -> Tuple[int, str] - removed:
function console_entry() -> None - removed:
function do_check(args: argparse.Namespace) -> None - removed:
function do_daemon(args: argparse.Namespace) -> None - removed:
function do_hang(args: argparse.Namespace) -> None - removed:
function do_help(args: argparse.Namespace) -> None - removed:
function do_kill(args: argparse.Namespace) -> None - removed:
function do_recheck(args: argparse.Namespace) -> None - removed:
function do_restart(args: argparse.Namespace) -> None - removed:
function do_run(args: argparse.Namespace) -> None - removed:
function do_start(args: argparse.Namespace) -> None - removed:
function do_status(args: argparse.Namespace) -> None - removed:
function do_stop(args: argparse.Namespace) -> None - removed:
function do_suggest(args: argparse.Namespace) -> None - removed:
function fail(msg: str) -> None - removed:
function get_status(status_file: str) -> Tuple[int, str] - removed:
function is_running(status_file: str) -> bool - removed:
function main(argv: List[str]) -> None - removed:
function read_status(status_file: str) -> Dict[str, object] - removed:
function request(status_file: str, command: str, *, timeout: Optional[int]=…, **kwds: object) -> Dict[str, Any] - removed:
function restart_server(args: argparse.Namespace, allow_sources: bool=…) -> None - removed:
function show_stats(response: Mapping[str, object]) -> None - removed:
function start_server(args: argparse.Namespace, allow_sources: bool=…) -> None - removed:
function wait_for_server(status_file: str, timeout: float=…) -> None - removed:
variable ActionFunction - removed:
variable check_parser - removed:
variable daemon_parser - removed:
variable hang_parser - removed:
variable help_parser - removed:
variable kill_parser - removed:
variable p - removed:
variable parser - removed:
variable recheck_parser - removed:
variable restart_parser - removed:
variable run_parser - removed:
variable start_parser - removed:
variable status_parser - removed:
variable stop_parser - removed:
variable subparsers - removed:
variable suggest_parser
- added:
class AugmentedHelpFormatter(argparse.RawDescriptionHelpFormatter) - added:
class BadStatus(Exception) - added:
constructor AugmentedHelpFormatter(prog: str) -> None - added:
function action(subparser: argparse.ArgumentParser) -> Callable[[ActionFunction], ActionFunction] - added:
function check_output(response: Dict[str, Any], verbose: bool, junit_xml: Optional[str], perf_stats_file: Optional[str]) -> None - added:
function check_status(data: Dict[str, Any]) -> Tuple[int, str] - added:
function console_entry() -> None - added:
function do_check(args: argparse.Namespace) -> None - added:
function do_daemon(args: argparse.Namespace) -> None - added:
function do_hang(args: argparse.Namespace) -> None - added:
function do_help(args: argparse.Namespace) -> None - added:
function do_kill(args: argparse.Namespace) -> None - added:
function do_recheck(args: argparse.Namespace) -> None - added:
function do_restart(args: argparse.Namespace) -> None - added:
function do_run(args: argparse.Namespace) -> None - added:
function do_start(args: argparse.Namespace) -> None - added:
function do_status(args: argparse.Namespace) -> None - added:
function do_stop(args: argparse.Namespace) -> None - added:
function do_suggest(args: argparse.Namespace) -> None - added:
function fail(msg: str) -> None - added:
function get_status(status_file: str) -> Tuple[int, str] - added:
function is_running(status_file: str) -> bool - added:
function main(argv: List[str]) -> None - added:
function read_status(status_file: str) -> Dict[str, object] - added:
function request(status_file: str, command: str, *, timeout: Optional[int]=…, **kwds: object) -> Dict[str, Any] - added:
function restart_server(args: argparse.Namespace, allow_sources: bool=…) -> None - added:
function show_stats(response: Mapping[str, object]) -> None - added:
function start_server(args: argparse.Namespace, allow_sources: bool=…) -> None - added:
function wait_for_server(status_file: str, timeout: float=…) -> None - added:
variable ActionFunction - added:
variable check_parser - added:
variable daemon_parser - added:
variable hang_parser - added:
variable help_parser - added:
variable kill_parser - added:
variable p - added:
variable parser - added:
variable recheck_parser - added:
variable restart_parser - added:
variable run_parser - added:
variable start_parser - added:
variable status_parser - added:
variable stop_parser - added:
variable subparsers - added:
variable suggest_parser
- changed:
method Server.cmd_suggest(function: str, json: bool, callsites: bool) -> Dict[str, object] → method Server.cmd_suggest(function: str, callsites: bool, **kwargs: bool) -> Dict[str, object]
- changed:
method EraseTypeVisitor.visit_none_type(t: NoneTyp) -> Type → method EraseTypeVisitor.visit_none_type(t: NoneType) -> Type - added:
class LastKnownValueEraser(TypeTranslator) - added:
function remove_instance_last_known_values(t: Type) -> Type - added:
method LastKnownValueEraser.visit_instance(t: Instance) -> Type
- removed:
method Errors.generate_unused_ignore_notes(file: str) -> None - changed:
constructor ErrorInfo(import_ctx: List[Tuple[str, int]], file: str, module: Optional[str], typ: Optional[str], function_or_member: Optional[str], line: int, column: int, severity: str, message: str, blocker: bool, only_once: bool, origin: Optional[Tuple[str, int]]=…, target: Optional[str]=…) -> None → constructor ErrorInfo(import_ctx: List[Tuple[str, int]], file: str, module: Optional[str], typ: Optional[str], function_or_member: Optional[str], line: int, column: int, severity: str, message: str, blocker: bool, only_once: bool, origin: Optional[Tuple[str, int, int]]=…, target: Optional[str]=…) -> None - changed:
function report_internal_error(err: Exception, file: Optional[str], line: int, errors: Errors, options: Options) -> None → function report_internal_error(err: Exception, file: Optional[str], line: int, errors: Errors, options: Options, stdout: Optional[TextIO]=…, stderr: Optional[TextIO]=…) -> None - changed:
method Errors.report(line: int, column: Optional[int], message: str, blocker: bool=…, severity: str=…, file: Optional[str]=…, only_once: bool=…, origin_line: Optional[int]=…, offset: int=…) -> None → method Errors.report(line: int, column: Optional[int], message: str, blocker: bool=…, severity: str=…, file: Optional[str]=…, only_once: bool=…, origin_line: Optional[int]=…, offset: int=…, end_line: Optional[int]=…) -> None - added:
method Errors.generate_unused_ignore_errors(file: str) -> None
- changed:
method ExpandTypeVisitor.visit_none_type(t: NoneTyp) -> Type → method ExpandTypeVisitor.visit_none_type(t: NoneType) -> Type
- removed:
method ASTConverter.in_class() -> bool - changed:
method ASTConverter.fail(msg: str, line: int, column: int) -> None → method ASTConverter.fail(msg: str, line: int, column: int, blocker: bool=…) -> None - changed:
method ASTConverter.translate_stmt_list(l: Sequence[AST]) -> List[Statement] → method ASTConverter.translate_stmt_list(stmts: Sequence[ast3.stmt], ismodule: bool=…) -> List[Statement] - added:
method ASTConverter.get_lineno(node: Union[ast3.expr, ast3.stmt]) -> int - added:
method ASTConverter.in_method_scope() -> bool - added:
variable PY_MINOR_VERSION
- removed:
method ASTConverter.in_class() -> bool - changed:
method ASTConverter.fail(msg: str, line: int, column: int) -> None → method ASTConverter.fail(msg: str, line: int, column: int, blocker: bool=…) -> None - changed:
method ASTConverter.translate_stmt_list(l: Sequence[AST]) -> List[Statement] → method ASTConverter.translate_stmt_list(stmts: Sequence[ast27.stmt], module: bool=…) -> List[Statement] - added:
method ASTConverter.get_lineno(node: Union[ast27.expr, ast27.stmt]) -> int - added:
method ASTConverter.in_method_scope() -> bool
- changed:
method FileSystemCache.isfile_case(path: str) -> bool → method FileSystemCache.isfile_case(path: str, prefix: str) -> bool
- changed:
method TypeIndirectionVisitor.visit_none_type(t: types.NoneTyp) -> Set[str] → method TypeIndirectionVisitor.visit_none_type(t: types.NoneType) -> Set[str]
- changed:
method TypeJoinVisitor.visit_none_type(t: NoneTyp) -> Type → method TypeJoinVisitor.visit_none_type(t: NoneType) -> Type
- removed:
class SplitNamespace(argparse.Namespace) - removed:
constructor SplitNamespace(standard_namespace: object, alt_namespace: object, alt_prefix: str) -> None - removed:
function parse_config_file(options: Options, filename: Optional[str]) -> None - removed:
function parse_section(prefix: str, template: Options, section: Mapping[str, str]) -> Tuple[Dict[str, object], Dict[str, str]] - removed:
function parse_version(v: str) -> Tuple[int, int] - removed:
variable config_types - changed:
function fail(msg: str) -> None → function fail(msg: str, stderr: TextIO) -> None - changed:
function main(script_path: Optional[str], args: Optional[List[str]]=…) -> None → function main(script_path: Optional[str], stdout: TextIO, stderr: TextIO, args: Optional[List[str]]=…) -> None - changed:
function process_options(args: List[str], require_targets: bool=…, server_options: bool=…, fscache: Optional[FileSystemCache]=…, program: str=…, header: str=…) -> Tuple[List[BuildSource], Options] → function process_options(args: List[str], stdout: Optional[TextIO]=…, stderr: Optional[TextIO]=…, require_targets: bool=…, server_options: bool=…, fscache: Optional[FileSystemCache]=…, program: str=…, header: str=…) -> Tuple[List[BuildSource], Options]
- changed:
method TypeMeetVisitor.visit_none_type(t: NoneTyp) -> Type → method TypeMeetVisitor.visit_none_type(t: NoneType) -> Type
- added:
variable BAD_CONSTRUCTOR_TYPE - added:
variable INVALID_TYPE_RAW_ENUM_VALUE
- removed:
method MessageBuilder.warn(msg: str, context: Context, file: Optional[str]=…, origin: Optional[Context]=…) -> None - changed:
function format_string_list(s: Iterable[str]) -> str → function format_string_list(lst: List[str]) -> str - changed:
method MessageBuilder.argument_incompatible_with_supertype(arg_num: int, name: str, type_name: Optional[str], name_in_supertype: str, supertype: str, context: Context) -> None → method MessageBuilder.argument_incompatible_with_supertype(arg_num: int, name: str, type_name: Optional[str], name_in_supertype: str, arg_type_in_supertype: Type, supertype: str, context: Context) -> None - changed:
method MessageBuilder.need_annotation_for_var(node: SymbolNode, context: Context) -> None → method MessageBuilder.need_annotation_for_var(node: SymbolNode, context: Context, python_version: Optional[Tuple[int, int]]=…) -> None - changed:
method MessageBuilder.return_type_incompatible_with_supertype(name: str, name_in_supertype: str, supertype: str, context: Context) -> None → method MessageBuilder.return_type_incompatible_with_supertype(name: str, name_in_supertype: str, supertype: str, original: Type, override: Type, context: Context) -> None
- changed:
function highest_init_level(fscache: FileSystemCache, id: str, path: str) -> int → function highest_init_level(fscache: FileSystemCache, id: str, path: str, prefix: str) -> int - changed:
function verify_module(fscache: FileSystemCache, id: str, path: str) -> bool → function verify_module(fscache: FileSystemCache, id: str, path: str, prefix: str) -> bool
- removed:
class BuildManagerBase - removed:
constructor BuildManagerBase() -> None - removed:
method BuildManagerBase.add_stats(**kwds: Any) -> None - removed:
method BuildManagerBase.log(*message: str) -> None - removed:
method BuildManagerBase.log_fine_grained(*message: str) -> None - removed:
method BuildManagerBase.trace(*message: str) -> None - removed:
method BuildManagerBase.verbosity() -> int
- removed:
method NewSemanticAnalyzer.add_func_redefinition(names: SymbolTable, name: str, symbol: SymbolTableNode) -> None - removed:
method NewSemanticAnalyzer.add_func_to_symbol_table(func: Union[FuncDef, OverloadedFuncDef]) -> None - removed:
method NewSemanticAnalyzer.add_submodules_to_parent_modules(id: str, module_public: bool) -> None - removed:
method NewSemanticAnalyzer.analyze_function(defn: FuncItem) -> None - removed:
method NewSemanticAnalyzer.rebind_symbol_table_node(n: SymbolTableNode) -> Optional[SymbolTableNode] - removed:
method NewSemanticAnalyzer.setup_type_promotion(defn: ClassDef) -> None - removed:
variable TYPE_PROMOTIONS - removed:
variable TYPE_PROMOTIONS_PYTHON2 - removed:
variable TYPE_PROMOTIONS_PYTHON3 - changed:
method NewSemanticAnalyzer.add_symbol(name: str, node: SymbolNode, context: Optional[Context], module_public: bool=…, module_hidden: bool=…) -> bool → method NewSemanticAnalyzer.add_symbol(name: str, node: SymbolNode, context: Context, module_public: bool=…, module_hidden: bool=…, can_defer: bool=…) -> bool - changed:
method NewSemanticAnalyzer.add_symbol_table_node(name: str, symbol: SymbolTableNode, context: Optional[Context]=…) -> bool → method NewSemanticAnalyzer.add_symbol_table_node(name: str, symbol: SymbolTableNode, context: Optional[Context]=…, can_defer: bool=…) -> bool - changed:
method NewSemanticAnalyzer.anal_type(t: Type, *, tvar_scope: Optional[TypeVarScope]=…, allow_tuple_literal: bool=…, allow_unbound_tvars: bool=…, allow_placeholder: bool=…, report_invalid_types: bool=…, third_pass: bool=…) -> Optional[Type] → method NewSemanticAnalyzer.anal_type(typ: Type, *, tvar_scope: Optional[TypeVarScope]=…, allow_tuple_literal: bool=…, allow_unbound_tvars: bool=…, allow_placeholder: bool=…, report_invalid_types: bool=…, third_pass: bool=…) -> Optional[Type] - changed:
method NewSemanticAnalyzer.check_no_global(n: str, ctx: Context, is_overloaded_func: bool=…) -> None → method NewSemanticAnalyzer.check_no_global(name: str, ctx: Context, is_overloaded_func: bool=…) -> None - changed:
method NewSemanticAnalyzer.file_context(file_node: MypyFile, fnam: str, options: Options, active_type: Optional[TypeInfo], scope: Optional[Scope]=…) -> Iterator[None] → method NewSemanticAnalyzer.file_context(file_node: MypyFile, options: Options, active_type: Optional[TypeInfo]=…) -> Iterator[None] - changed:
method NewSemanticAnalyzer.qualified_name(n: str) -> str → method NewSemanticAnalyzer.qualified_name(name: str) -> str - changed:
method NewSemanticAnalyzer.refresh_partial(node: Union[MypyFile, FuncDef, OverloadedFuncDef], patches: List[Tuple[int, Callable[[], None]]], final_iteration: bool) -> None → method NewSemanticAnalyzer.refresh_partial(node: Union[MypyFile, FuncDef, OverloadedFuncDef], patches: List[Tuple[int, Callable[[], None]]], final_iteration: bool, file_node: MypyFile, options: Options, active_type: Optional[TypeInfo]=…) -> None - changed:
method NewSemanticAnalyzer.type_analyzer(*, tvar_scope: Optional[TypeVarScope]=…, allow_tuple_literal: bool=…, allow_unbound_tvars: bool=…, allow_placeholder: bool=…, report_invalid_types: bool=…, third_pass: bool=…) -> TypeAnalyser → method NewSemanticAnalyzer.type_analyzer(*, tvar_scope: Optional[TypeVarScope]=…, allow_tuple_literal: bool=…, allow_unbound_tvars: bool=…, allow_placeholder: bool=…, report_invalid_types: bool=…) -> TypeAnalyser - added:
field NewSemanticAnalyzer.deferred - added:
field NewSemanticAnalyzer.incomplete - added:
field NewSemanticAnalyzer.missing_names - added:
field NewSemanticAnalyzer.patches - added:
field NewSemanticAnalyzer.statement - added:
function dummy_context() -> Context - added:
function is_same_symbol(a: Optional[SymbolNode], b: Optional[SymbolNode]) -> bool - added:
function is_same_var_from_getattr(n1: Optional[SymbolNode], n2: Optional[SymbolNode]) -> bool - added:
function is_valid_replacement(old: SymbolTableNode, new: SymbolTableNode) -> bool - added:
method NewSemanticAnalyzer.add_function_to_symbol_table(func: Union[FuncDef, OverloadedFuncDef]) -> None - added:
method NewSemanticAnalyzer.add_redefinition(names: SymbolTable, name: str, symbol: SymbolTableNode) -> None - added:
method NewSemanticAnalyzer.already_defined(name: str, ctx: Context, original_ctx: Optional[Union[SymbolTableNode, SymbolNode]], noun: str) -> None - added:
method NewSemanticAnalyzer.analyze_func_def(defn: FuncDef) -> None - added:
method NewSemanticAnalyzer.analyze_function_body(defn: FuncItem) -> None - added:
method NewSemanticAnalyzer.analyze_overloaded_func_def(defn: OverloadedFuncDef) -> None - added:
method NewSemanticAnalyzer.attribute_already_defined(name: str, ctx: Context, original_ctx: Optional[Union[SymbolTableNode, SymbolNode]]=…) -> None - added:
method NewSemanticAnalyzer.bind_name_expr(expr: NameExpr, sym: SymbolTableNode) -> None - added:
method NewSemanticAnalyzer.cannot_resolve_name(name: str, kind: str, ctx: Context) -> None - added:
method NewSemanticAnalyzer.get_module_symbol(node: MypyFile, name: str) -> Optional[SymbolTableNode] - added:
method NewSemanticAnalyzer.implicit_symbol(sym: SymbolTableNode, name: str, parts: List[str], source_type: AnyType) -> SymbolTableNode - added:
method NewSemanticAnalyzer.is_active_symbol_in_class_body(node: Optional[SymbolNode]) -> bool - added:
method NewSemanticAnalyzer.is_defined_in_current_module(fullname: Optional[str]) -> bool - added:
method NewSemanticAnalyzer.is_missing_module(module: str) -> bool - added:
variable TYPES_FOR_UNIMPORTED_HINTS
- added:
function add_type_promotion(info: TypeInfo, module_names: SymbolTable, options: Options) -> None - added:
variable MYPY - added:
variable TYPE_PROMOTIONS - added:
variable TYPE_PROMOTIONS_PYTHON2 - added:
variable TYPE_PROMOTIONS_PYTHON3
- removed:
function process_selected_targets(state: State, nodes: List[FineGrainedDeferredNode], graph: Graph, strip_patches: List[Callable[[], None]]) -> None - added:
function restore_saved_attrs(saved_attrs: SavedAttributes) -> None - added:
function semantic_analysis_for_targets(state: State, nodes: List[FineGrainedDeferredNode], graph: Graph, saved_attrs: SavedAttributes) -> None
- removed:
class ReachabilityAnalyzer(TraverserVisitor) - removed:
method ReachabilityAnalyzer.visit_assignment_stmt(s: AssignmentStmt) -> None - removed:
method ReachabilityAnalyzer.visit_block(b: Block) -> None - removed:
method ReachabilityAnalyzer.visit_expression_stmt(s: ExpressionStmt) -> None - removed:
method ReachabilityAnalyzer.visit_file(file: MypyFile, fnam: str, mod_id: str, options: Options) -> None - removed:
method ReachabilityAnalyzer.visit_for_stmt(s: ForStmt) -> None - removed:
method ReachabilityAnalyzer.visit_if_stmt(s: IfStmt) -> None - removed:
method ReachabilityAnalyzer.visit_import(node: Import) -> None - removed:
method ReachabilityAnalyzer.visit_import_all(node: ImportAll) -> None - removed:
method ReachabilityAnalyzer.visit_import_from(node: ImportFrom) -> None - removed:
method ReachabilityAnalyzer.visit_return_stmt(s: ReturnStmt) -> None - added:
class SemanticAnalyzerPreAnalysis(TraverserVisitor) - added:
method SemanticAnalyzerPreAnalysis.visit_assignment_stmt(s: AssignmentStmt) -> None - added:
method SemanticAnalyzerPreAnalysis.visit_block(b: Block) -> None - added:
method SemanticAnalyzerPreAnalysis.visit_class_def(node: ClassDef) -> None - added:
method SemanticAnalyzerPreAnalysis.visit_expression_stmt(s: ExpressionStmt) -> None - added:
method SemanticAnalyzerPreAnalysis.visit_file(file: MypyFile, fnam: str, mod_id: str, options: Options) -> None - added:
method SemanticAnalyzerPreAnalysis.visit_for_stmt(s: ForStmt) -> None - added:
method SemanticAnalyzerPreAnalysis.visit_func_def(node: FuncDef) -> None - added:
method SemanticAnalyzerPreAnalysis.visit_if_stmt(s: IfStmt) -> None - added:
method SemanticAnalyzerPreAnalysis.visit_import(node: Import) -> None - added:
method SemanticAnalyzerPreAnalysis.visit_import_all(node: ImportAll) -> None - added:
method SemanticAnalyzerPreAnalysis.visit_import_from(node: ImportFrom) -> None - added:
method SemanticAnalyzerPreAnalysis.visit_return_stmt(s: ReturnStmt) -> None
- removed:
class SemanticAnalyzerPass3(TraverserVisitor, SemanticAnalyzerCoreInterface) - removed:
constructor SemanticAnalyzerPass3(modules: Dict[str, MypyFile], errors: Errors, sem: NewSemanticAnalyzer) -> None - removed:
method SemanticAnalyzerPass3.analyze(type: Optional[Type], node: Node, warn: bool=…) -> None - removed:
method SemanticAnalyzerPass3.analyze_symbol_table(names: SymbolTable) -> None - removed:
method SemanticAnalyzerPass3.analyze_types(types: List[Type], node: Node) -> None - removed:
method SemanticAnalyzerPass3.builtin_type(name: str, args: Optional[List[Type]]=…) -> Instance - removed:
method SemanticAnalyzerPass3.check_for_omitted_generics(typ: Type) -> None - removed:
method SemanticAnalyzerPass3.fail(msg: str, ctx: Context, serious: bool=…, *, blocker: bool=…) -> None - removed:
method SemanticAnalyzerPass3.fail_blocker(msg: str, ctx: Context) -> None - removed:
method SemanticAnalyzerPass3.lookup_fully_qualified(fullname: str) -> SymbolTableNode - removed:
method SemanticAnalyzerPass3.lookup_qualified(name: str, ctx: Context, suppress_errors: bool=…) -> Optional[SymbolTableNode] - removed:
method SemanticAnalyzerPass3.make_type_analyzer(indicator: Dict[str, bool]) -> TypeAnalyserPass3 - removed:
method SemanticAnalyzerPass3.note(msg: str, ctx: Context) -> None - removed:
method SemanticAnalyzerPass3.visit_assignment_stmt(s: AssignmentStmt) -> None - removed:
method SemanticAnalyzerPass3.visit_class_def(tdef: ClassDef) -> None - removed:
method SemanticAnalyzerPass3.visit_decorator(dec: Decorator) -> None - removed:
method SemanticAnalyzerPass3.visit_file(file_node: MypyFile, fnam: str, options: Options, patches: List[Tuple[int, Callable[[], None]]]) -> None
- changed:
method SemanticAnalyzerInterface.add_symbol(name: str, node: SymbolNode, context: Optional[Context], module_public: bool=…, module_hidden: bool=…) -> bool → method SemanticAnalyzerInterface.add_symbol(name: str, node: SymbolNode, context: Context, module_public: bool=…, module_hidden: bool=…, can_defer: bool=…) -> bool - changed:
method SemanticAnalyzerInterface.anal_type(t: Type, *, tvar_scope: Optional[TypeVarScope]=…, allow_tuple_literal: bool=…, allow_unbound_tvars: bool=…, report_invalid_types: bool=…, third_pass: bool=…) -> Optional[Type] → method SemanticAnalyzerInterface.anal_type(t: Type, *, tvar_scope: Optional[TypeVarScope]=…, allow_tuple_literal: bool=…, allow_unbound_tvars: bool=…, report_invalid_types: bool=…) -> Optional[Type]
- changed:
constructor TypeArgumentAnalyzer(errors: Errors) -> None → constructor TypeArgumentAnalyzer(errors: Errors, options: Options, is_typeshed_file: bool) -> None - added:
method TypeArgumentAnalyzer.visit_any(t: AnyType) -> None
- removed:
class TypeAnalyserPass3(TypeVisitor[None]) - removed:
constructor TypeAnalyserPass3(api: SemanticAnalyzerCoreInterface, plugin: Plugin, options: Options, is_typeshed_stub: bool, indicator: Dict[str, bool], patches: List[Tuple[int, Callable[[], None]]]) -> None - removed:
method TypeAnalyserPass3.anal_type(tp: UnboundType) -> Type - removed:
method TypeAnalyserPass3.visit_any(t: AnyType) -> None - removed:
method TypeAnalyserPass3.visit_callable_type(t: CallableType) -> None - removed:
method TypeAnalyserPass3.visit_deleted_type(t: DeletedType) -> None - removed:
method TypeAnalyserPass3.visit_forwardref_type(t: ForwardRef) -> None - removed:
method TypeAnalyserPass3.visit_instance(t: Instance) -> None - removed:
method TypeAnalyserPass3.visit_literal_type(t: LiteralType) -> None - removed:
method TypeAnalyserPass3.visit_none_type(t: NoneTyp) -> None - removed:
method TypeAnalyserPass3.visit_overloaded(t: Overloaded) -> None - removed:
method TypeAnalyserPass3.visit_partial_type(t: PartialType) -> None - removed:
method TypeAnalyserPass3.visit_star_type(t: StarType) -> None - removed:
method TypeAnalyserPass3.visit_tuple_type(t: TupleType) -> None - removed:
method TypeAnalyserPass3.visit_type_list(t: TypeList) -> None - removed:
method TypeAnalyserPass3.visit_type_type(t: TypeType) -> None - removed:
method TypeAnalyserPass3.visit_type_var(t: TypeVarType) -> None - removed:
method TypeAnalyserPass3.visit_typeddict_type(t: TypedDictType) -> None - removed:
method TypeAnalyserPass3.visit_unbound_type(t: UnboundType) -> None - removed:
method TypeAnalyserPass3.visit_uninhabited_type(t: UninhabitedType) -> None - removed:
method TypeAnalyserPass3.visit_union_type(t: UnionType) -> None - changed:
constructor TypeAnalyser(api: SemanticAnalyzerCoreInterface, tvar_scope: Optional[TypeVarScope], plugin: Plugin, options: Options, is_typeshed_stub: bool, *, defining_alias: bool=…, allow_tuple_literal: bool=…, allow_unnormalized: bool=…, allow_unbound_tvars: bool=…, allow_placeholder: bool=…, report_invalid_types: bool=…, third_pass: bool=…) -> None → constructor TypeAnalyser(api: SemanticAnalyzerCoreInterface, tvar_scope: TypeVarScope, plugin: Plugin, options: Options, is_typeshed_stub: bool, *, defining_alias: bool=…, allow_tuple_literal: bool=…, allow_unnormalized: bool=…, allow_unbound_tvars: bool=…, allow_placeholder: bool=…, report_invalid_types: bool=…) -> None - changed:
method TypeAnalyser.analyze_unbound_type_without_type_info(t: UnboundType, sym: SymbolTableNode) -> Type → method TypeAnalyser.analyze_unbound_type_without_type_info(t: UnboundType, sym: SymbolTableNode, defining_literal: bool) -> Type - changed:
method TypeAnalyser.visit_none_type(t: NoneTyp) -> Type → method TypeAnalyser.visit_none_type(t: NoneType) -> Type - changed:
method TypeAnalyser.visit_unbound_type(t: UnboundType) -> Type → method TypeAnalyser.visit_unbound_type(t: UnboundType, defining_literal: bool=…) -> Type - changed:
method TypeAnalyser.visit_unbound_type_nonoptional(t: UnboundType) -> Type → method TypeAnalyser.visit_unbound_type_nonoptional(t: UnboundType, defining_literal: bool) -> Type - added:
method TypeAnalyser.cannot_resolve_type(t: UnboundType) -> None
- removed:
field WithStmt.target_type - changed:
constructor PlaceholderNode(fullname: str, node: Node, becomes_typeinfo: bool=…) -> None → constructor PlaceholderNode(fullname: str, node: Node, line: int, *, becomes_typeinfo: bool=…) -> None - changed:
method Argument.set_line(target: Union[Context, int], column: Optional[int]=…) -> None → method Argument.set_line(target: Union[Context, int], column: Optional[int]=…, end_line: Optional[int]=…) -> None - changed:
method Context.set_line(target: Union[Context, int], column: Optional[int]=…) -> None → method Context.set_line(target: Union[Context, int], column: Optional[int]=…, end_line: Optional[int]=…) -> None - changed:
method FuncItem.set_line(target: Union[Context, int], column: Optional[int]=…) -> None → method FuncItem.set_line(target: Union[Context, int], column: Optional[int]=…, end_line: Optional[int]=…) -> None - added:
field WithStmt.analyzed_types - added:
field WithStmt.unanalyzed_type - added:
variable RUNTIME_PROTOCOL_DECOS
- added:
method SemanticAnalyzerPluginInterface.final_iteration() -> bool
- added:
method DataclassTransformer.reset_init_only_vars(info: TypeInfo, attributes: List[DataclassAttribute]) -> None
- added:
function enum_name_callback(ctx: mypy.plugin.AttributeContext) -> Type - added:
function enum_value_callback(ctx: mypy.plugin.AttributeContext) -> Type - added:
variable ENUM_NAME_ACCESS - added:
variable ENUM_PREFIXES - added:
variable ENUM_VALUE_ACCESS - added:
variable MYPY
- removed:
method VariableRenameVisitor.enter_with_or_try() -> None - removed:
method VariableRenameVisitor.leave_with_or_try() -> None - added:
method VariableRenameVisitor.enter_try() -> None - added:
method VariableRenameVisitor.leave_try() -> None
- changed:
method SameTypeVisitor.visit_none_type(left: NoneTyp) -> bool → method SameTypeVisitor.visit_none_type(left: NoneType) -> bool
- added:
method SemanticAnalyzerPass2.already_defined(name: str, ctx: Context, original_ctx: Optional[Union[SymbolTableNode, SymbolNode]], noun: str) -> None - added:
method SemanticAnalyzerPass2.attribute_already_defined(name: str, ctx: Context, original_ctx: Optional[Union[SymbolTableNode, SymbolNode]]=…) -> None - added:
property SemanticAnalyzerPass2.final_iteration -> bool - added:
variable TYPES_FOR_UNIMPORTED_HINTS
- changed:
method SnapshotTypeVisitor.visit_none_type(typ: NoneTyp) -> SnapshotItem → method SnapshotTypeVisitor.visit_none_type(typ: NoneType) -> SnapshotItem
- changed:
method TypeReplaceVisitor.visit_none_type(typ: NoneTyp) -> None → method TypeReplaceVisitor.visit_none_type(typ: NoneType) -> None
- added:
method NodeStripVisitor.visit_with_stmt(node: WithStmt) -> None
- removed:
method NodeStripVisitor.prepare_implicit_var_patches(node: ClassDef) -> None - changed:
constructor NodeStripVisitor() -> None → constructor NodeStripVisitor(saved_class_attrs: SavedAttributes) -> None - changed:
function strip_target_new(node: Union[MypyFile, FuncDef, OverloadedFuncDef]) -> List[Callable[[], None]] → function strip_target_new(node: Union[MypyFile, FuncDef, OverloadedFuncDef], saved_attrs: SavedAttributes) -> None - added:
method NodeStripVisitor.save_implicit_attributes(node: ClassDef) -> None - added:
variable SavedAttributes
- changed:
method TypeTriggersVisitor.visit_none_type(typ: NoneTyp) -> List[str] → method TypeTriggersVisitor.visit_none_type(typ: NoneType) -> List[str]
- removed:
function module_prefix(modules: Iterable[str], target: str) -> Optional[str] - removed:
function split_target(modules: Iterable[str], target: str) -> Optional[Tuple[str, str]]
- added:
class SplitNamespace(argparse.Namespace) - added:
constructor SplitNamespace(standard_namespace: object, alt_namespace: object, alt_prefix: str) -> None
- added:
function get_original_any(t: AnyType) -> AnyType - added:
function is_special_form_any(t: AnyType) -> bool
- removed:
class ReturnSeeker(mypy.traverser.TraverserVisitor) - removed:
constructor ReturnSeeker() -> None - removed:
function has_return_statement(fdef: FuncBase) -> bool - removed:
method ReturnSeeker.visit_return_stmt(o: ReturnStmt) -> None - changed:
method AnnotationPrinter.visit_none_type(t: NoneTyp) -> str → method AnnotationPrinter.visit_none_type(t: NoneType) -> str
- changed:
function is_c_property_readonly(prop: object) -> bool → function is_c_property_readonly(prop: Any) -> bool
- changed:
function report_missing(mod: str) -> None → function report_missing(mod: str, message: Optional[str]=…) -> None - added:
constructor CantImport(module: str, message: str)
- changed:
method ProperSubtypeVisitor.visit_none_type(left: NoneTyp) -> bool → method ProperSubtypeVisitor.visit_none_type(left: NoneType) -> bool - changed:
method SubtypeVisitor.visit_none_type(left: NoneTyp) -> bool → method SubtypeVisitor.visit_none_type(left: NoneType) -> bool
- removed:
function format_callable(is_method: bool, typ: CallableType) -> str - removed:
function format_type(typ: Type) -> str - changed:
constructor SuggestionEngine(fgmanager: FineGrainedBuildManager) → constructor SuggestionEngine(fgmanager: FineGrainedBuildManager, json: bool, no_errors: bool=…, no_any: bool=…) -> None - changed:
method SuggestionEngine.find_best(func: FuncDef, guesses: List[CallableType]) -> CallableType → method SuggestionEngine.find_best(func: FuncDef, guesses: List[CallableType]) -> Tuple[CallableType, int] - changed:
method SuggestionEngine.suggest(function: str, give_json: bool) -> str → method SuggestionEngine.suggest(function: str) -> str - added:
class TypeFormatter(TypeStrVisitor) - added:
constructor TypeFormatter(module: Optional[str], graph: Graph) -> None - added:
function callable_has_any(t: CallableType) -> int - added:
method SuggestionEngine.filter_options(guesses: List[CallableType]) -> List[CallableType] - added:
method SuggestionEngine.format_callable(cur_module: Optional[str], is_method: bool, typ: CallableType) -> str - added:
method SuggestionEngine.format_type(cur_module: Optional[str], typ: Type) -> str - added:
method TypeFormatter.visit_instance(t: Instance) -> str - added:
method TypeFormatter.visit_tuple_type(t: TupleType) -> str
- added:
class ReturnSeeker(TraverserVisitor) - added:
constructor ReturnSeeker() -> None - added:
function has_return_statement(fdef: FuncBase) -> bool - added:
method ReturnSeeker.visit_return_stmt(o: ReturnStmt) -> None
- changed:
method TypeQuery.visit_none_type(t: NoneTyp) -> T → method TypeQuery.visit_none_type(t: NoneType) -> T - changed:
method TypeTranslator.visit_none_type(t: NoneTyp) -> Type → method TypeTranslator.visit_none_type(t: NoneType) -> Type - changed:
method TypeVisitor.visit_none_type(t: NoneTyp) -> T → method TypeVisitor.visit_none_type(t: NoneType) -> T
- changed:
method TypeAnalyser.analyze_unbound_type_without_type_info(t: UnboundType, sym: SymbolTableNode) -> Type → method TypeAnalyser.analyze_unbound_type_without_type_info(t: UnboundType, sym: SymbolTableNode, defining_literal: bool) -> Type - changed:
method TypeAnalyser.visit_none_type(t: NoneTyp) -> Type → method TypeAnalyser.visit_none_type(t: NoneType) -> Type - changed:
method TypeAnalyser.visit_unbound_type(t: UnboundType) -> Type → method TypeAnalyser.visit_unbound_type(t: UnboundType, defining_literal: bool=…) -> Type - changed:
method TypeAnalyser.visit_unbound_type_nonoptional(t: UnboundType) -> Type → method TypeAnalyser.visit_unbound_type_nonoptional(t: UnboundType, defining_literal: bool) -> Type - changed:
method TypeAnalyserPass3.visit_none_type(t: NoneTyp) -> None → method TypeAnalyserPass3.visit_none_type(t: NoneType) -> None
- removed:
class NoneTyp(Type) - removed:
constructor NoneTyp(line: int=…, column: int=…) -> None - removed:
method NoneTyp.accept(visitor: TypeVisitor[T]) -> T - removed:
method NoneTyp.can_be_true_default() -> bool - removed:
method NoneTyp.serialize() -> JsonDict - removed:
static method NoneTyp.deserialize(data: JsonDict) -> NoneTyp - changed:
constructor Instance(typ: mypy.nodes.TypeInfo, args: List[Type], line: int=…, column: int=…, erased: bool=…, final_value: Optional[LiteralType]=…) -> None → constructor Instance(typ: mypy.nodes.TypeInfo, args: List[Type], line: int=…, column: int=…, erased: bool=…, last_known_value: Optional[LiteralType]=…) -> None - changed:
constructor TypeType(item: Bogus[Union[Instance, AnyType, TypeVarType, TupleType, NoneTyp, CallableType]], *, line: int=…, column: int=…) -> None → constructor TypeType(item: Bogus[Union[Instance, AnyType, TypeVarType, TupleType, NoneType, CallableType]], *, line: int=…, column: int=…) -> None - changed:
method Instance.copy_modified(*, args: Bogus[List[Type]]=…, final_value: Bogus[Optional[LiteralType]]=…) -> Instance → method Instance.copy_modified(*, args: Bogus[List[Type]]=…, last_known_value: Bogus[Optional[LiteralType]]=…) -> Instance - changed:
method TypeStrVisitor.visit_none_type(t: NoneTyp) -> str → method TypeStrVisitor.visit_none_type(t: NoneType) -> str - added:
class NoneType(Type) - added:
constructor NoneType(line: int=…, column: int=…) -> None - added:
method LiteralType.is_enum_literal() -> bool - added:
method NoneType.accept(visitor: TypeVisitor[T]) -> T - added:
method NoneType.can_be_true_default() -> bool - added:
method NoneType.serialize() -> JsonDict - added:
method UnboundType.copy_modified(args: Bogus[Optional[List[Type]]]=…) -> UnboundType - added:
static method NoneType.deserialize(data: JsonDict) -> NoneType - added:
variable NoneTyp - added:
variable TPDICT_FB_NAMES - added:
variable TPDICT_NAMES
- changed:
method TypeTraverserVisitor.visit_none_type(t: NoneTyp) -> None → method TypeTraverserVisitor.visit_none_type(t: NoneType) -> None
- added:
function get_mypy_comments(source: str) -> List[Tuple[int, str]] - added:
function get_unique_redefinition_name(name: str, existing: Container[str]) -> str - added:
function module_prefix(modules: Iterable[str], target: str) -> Optional[str] - added:
function split_target(modules: Iterable[str], target: str) -> Optional[Tuple[str, str]]