Skip to content

Releases: KotlinIsland/basedmypy

2.9.1

08 Jan 23:44
Compare
Choose a tag to compare

based on mypy 1.14.1

Fixes

  • typings for functools.cache and operator.attrgetter

2.9.0

01 Jan 17:46
Compare
Choose a tag to compare

based on mypy 1.14.0

Added

  • collections.User* should have __repr__

Fixes

  • cache modules that only have baseline errors

v2.8.1

10 Dec 15:52
Compare
Choose a tag to compare

based on mypy 1.13.0

Fixes

  • stubtest: the __bool__ method of function parameter defaults will no longer be unnecessarily evaluated. Contribution by @jorenham

2.8.0

03 Dec 07:58
Compare
Choose a tag to compare

based on mypy 1.13.0

Added

  • ban variance on TypeVar definitions (#817)
  • enforce TypeVar constraints on type applications (#817)

Fixes

  • check type args on type aliases (#817)
  • cache modules that only have baseline errors
  • fix dmypy in vscode

Docs

  • correct error code documentation regarding defaults

2.7.0

31 Oct 21:58
Compare
Choose a tag to compare

based on mypy 1.13.0

Added

  • typed functools.wraps correctly
  • typed builtins.ellipsis/types.EllipsisType correctly
  • disable bytearray and memoryview promotions by default
  • support typing.type_check_only
  • support default values on type parameters
  • support based type notation in type alias statements
  • support basedtyping.FunctionType

Fixes

  • fixed crash with re plugin
  • fixed crash with Intersection cache
  • fixed definition of types.NoneType

Enhancements

  • fixed default configuration in the docs

2.6.0

18 Aug 13:47
Compare
Choose a tag to compare

based on mypy 1.11.1

Added

  • Any parameter _ will be inferred as object (#687)
  • work_not_properly_function_names made available to per module configuration (#699)
  • Support BASEDMYPY_TYPE_CHECKING (#702)
  • Enable stub mode within TYPE_CHECKING branches (#702)
  • Infer from overloads - add default value in impl (#697)
  • Warn for missing returns with explicit Any return types (#715)

Fixes

  • positional arguments on overloads break super (#697)
  • positional arguments on overloads duplicate unions (#697)
  • fix intersection type aliases (#716)

2.5.0

21 Jun 02:04
Compare
Choose a tag to compare

based on mypy 1.10

Added

  • Callable syntax ((int) -> str) (#619)
  • FunctionType syntax (def (int) -> str) (#619)

Fixes

  • Callable is no longer types.FunctionType (#619)

2.4.0

16 Jan 04:48
Compare
Choose a tag to compare

Based on mypy 1.8.0

2.3.0

08 Dec 12:13
Compare
Choose a tag to compare

Based on mypy 1.7.1

Added

  • f-string format specs are checked (#543)
  • Narrow type on initial assignment (#547)
  • Annotations in function bodies are not analyzed as evaluated (#564)
  • Invalid casts show an error (#573)
  • Argument names are validated for subtypes (#562)
  • Type-guards narrow in the negative (#553)
  • Conditional types for asymmetric type-guards (#553)
  • Static conditions report an error (#553)
  • Regex groups are special-cased (#531)
  • f-strings will show an error if the value doesn't define a stringification (#565)

Enhancements

  • Show 'narrowed from' in reveal_type (#550)
  • --color-output is enabled by default (#531)
  • --ide will disable color-output (#531)
  • Output lines won't wrap if not connected to a terminal (#531)

Fixes

  • Render star args in error messages properly (#551)
  • The first argument to cast is analyzed as evaluated (#564)
  • Decorated functions that return None correctly warn when used (#572)
  • Some impossible type-guards were not reporting an error (#553)

2.2.1

14 Oct 03:04
Compare
Choose a tag to compare

Fixes a regression with the default config regarding explicit-override