Skip to content

Bump flake8-annotations from 2.4.1 to 2.6.0#58

Closed
dependabot-preview[bot] wants to merge 1 commit intomasterfrom
dependabot/pip/flake8-annotations-2.6.0
Closed

Bump flake8-annotations from 2.4.1 to 2.6.0#58
dependabot-preview[bot] wants to merge 1 commit intomasterfrom
dependabot/pip/flake8-annotations-2.6.0

Conversation

@dependabot-preview
Copy link
Contributor

Bumps flake8-annotations from 2.4.1 to 2.6.0.

Release notes

Sourced from flake8-annotations's releases.

Release v2.6.0

Changelog

[v2.6.0]

Added

  • #98 Add --dispatch-decorators to support suppression of all errors from functions decorated by decorators such as functools.singledispatch and functools.singledispatchmethod.
  • #99 Add --overload-decorators to support generic aliasing of the typing.overload decorator.

Fixed

  • #106 Fix incorrect parsing of multiline docstrings with less than two lines of content, causing incorrect line numbers for yielded errors in Python versions prior to 3.8

Additional Details

Generic Functions

Per #98, the functools.singledispatch and functools.singledispatchmethod decorators transform a function into a single-dispatch generic function.

For example:

import functools
@functools.singledispatch
def foo(a):
print(a)
@foo.register
def _(a: list) -> None:
for idx, thing in enumerate(a):
print(idx, thing)

Is correctly annotated but would previously yield linting errors for foo. In the spirit of the purpose of these decorators, linting errors are now suppressed for functions decorated with these decorators. The --dispatch-decorators configuration option has been added, which specifies a comma-separated list of decorators to be considered as dispatch decorators.

Decorators are matched based on their attribute name. For example, "singledispatch" will match any of the following:

  • import functools; @functools.singledispatch
  • import functools as fnctls; @fnctls.singledispatch
  • from functools import singledispatch; @singledispatch

By default, linting errors are suppressed for functions decorated by singledispatch or singledispatchmethod.

typing.overload decorator aliasing

Per #99, handling of the typing.overload has been made generic, removing the caveat from the initial implementation. The --overload-decorators configuration option has been added, which specifies a comma-separated list of decorators to be considered as typing.overload decorators.

Decorators are now matched based on their attribute name. For example, "overload" will match any of the following:

  • import typing; @typing.overload
  • import typing as t; @t.overload
  • from typing import overload; @overload

By default, linting errors are suppressed for functions decorated by overload, which should be a transparent change from v2.4 (#97).

Release v2.5.0

Changelog

... (truncated)

Changelog

Sourced from flake8-annotations's changelog.

[v2.6.0]

Added

  • #98 Add --dispatch-decorators to support suppression of all errors from functions decorated by decorators such as functools.singledispatch and functools.singledispatchmethod.
  • #99 Add --overload-decorators to support generic aliasing of the typing.overload decorator.

Fixed

  • #106 Fix incorrect parsing of multiline docstrings with less than two lines of content, causing incorrect line numbers for yielded errors in Python versions prior to 3.8

[v2.5.0]

Added

  • #103 Add --allow-untyped-nested to suppress all errors from dynamically typted nested functions. A function is considered dynamically typed if it does not contain any type hints.
Commits
  • 9058f8f Release v2.6.0
  • 1b72427 Fix bug in colon seeker for multiline docstrings in Py < 3.8
  • 94d61fc Add tests for contentless multiline docstrings
  • bd024db Adjust classifier return type annotation
  • d94e4a9 README & Classifier tweaks
  • c2d54f5 Misc type annotations cleanup
  • 4c416ba Slot Argument and Function objects
  • 777932b Add support for callable dispatch & overload decorators
  • ce4bfc8 Bump ver
  • b5888a4 Add dispatch decorator tests
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
  • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
  • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
  • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
  • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language
  • @dependabot badge me will comment on this PR with code to add a "Dependabot enabled" badge to your readme

Additionally, you can set the following in your Dependabot dashboard:

  • Update frequency (including time of day and day of week)
  • Pull request limits (per update run and/or open at any time)
  • Out-of-range updates (receive only lockfile updates, if desired)
  • Security updates (receive only security updates, if desired)

Bumps [flake8-annotations](https://github.com/sco1/flake8-annotations) from 2.4.1 to 2.6.0.
- [Release notes](https://github.com/sco1/flake8-annotations/releases)
- [Changelog](https://github.com/sco1/flake8-annotations/blob/master/CHANGELOG.md)
- [Commits](sco1/flake8-annotations@2.4.1...v2.6.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
@dependabot-preview dependabot-preview bot added the dependencies Pull requests that update a dependency file label Mar 8, 2021
@dependabot-preview
Copy link
Contributor Author

Superseded by #60.

@dependabot-preview dependabot-preview bot deleted the dependabot/pip/flake8-annotations-2.6.0 branch March 17, 2021 03:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants