Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump beartype from 0.17.0 to 0.17.1 in /{{ cookiecutter.__project_name }} #252

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Feb 12, 2024

⚠️ Dependabot is rebasing this PR ⚠️

Rebasing might not happen immediately, so don't worry if this takes some time.

Note: if you make any changes to this PR yourself, they will take precedence over the rebase.


Bumps beartype from 0.17.0 to 0.17.1.

Release notes

Sourced from beartype's releases.

Beartype 0.17.1: Bully Maguire Bullies Bugs

Beartype 0.17.1 gently descends from the heavens on a golden dragon made of rainbows. "How can this be!?", the crowd exclaims. Verily, it is best not to ask questions:

pip install --upgrade beartype

This patch release comes courtesy these proud GitHub Sponsors, without whom @​leycec's cats would currently be eating grasshoppers:

Thanks so much, masters of fintech.

Who Let the Bugs Out?

This patch release adds explicit support for typing.NamedTuple subclasses under PEP 563 (i.e., from __future__ import annotations), resolving issue #318 kindly submitted by the cosmically rare-earth GitHub element @​kasium. For unknown reasons (which probably reduce to "Guido was tired that day."), the typing.NamedTuple superclass exhibits high strangeness.

Specifically, for each typing.NamedTuple subclass named {MuhTuple}, the typing.NamedTuple superclass dynamically generates a {MuhTuple}.__new__() dunder method whose:

  • __annotations__ dunder attribute wraps all stringified type hints inside typing.ForwardRef(...) objects. Why? No reason.
  • __module__ dunder attribute claims that method was defined in a fake module named named_{MuhTuple}. Why? Nobody knows.

For example:

from __future__ import annotations  # <-- PEP 563: it makes kittens cry
import typing
When you said this...
class MuhTuple(typing.NamedTuple):  # <-- very reasonable
muh_field: int                  # <-- makes sense, huh?
...what "typing.NamedTuple" heard you say was this:
class MuhTuple(typing.NamedTuple):
def new(cls, muh_field: ForwardRef('int')) -> None:  # <-- wut
self.muh_field = muh_field
MuhTuple.new.module = 'named_MuhTuple'  # <-- lolbro

Why does typing.NamedTuple do these sad things? Because it is crazy. This is the official answer. Cray classes gonna cray.

@​beartype now responds with a mountain of code that took us two weeks. Was that worth it? Probably not. Probably should have just implemented deep type-checking already. Instead, this is all we got.

Mo Money Means Mo Code

@​beartype 0.17.0 advised everybody to donate money to charitable causes. Instead, everybody donated more money to @​beartype. Reverse psychology surely is the path of righteousness.

These monocled code aristocrats graciously filled the money trough, which the cats are now sleeping on against our wishes:

... (truncated)

Commits
  • 1c51f3d Beartype 0.17.1 released.
  • 193f005 Beartypistry removal.
  • 2fda008 Forward reference proxy cache handling.
  • db7d538 PEP 563 + typing.NamedTuple x 10.
  • a7794bb PEP 563 + typing.NamedTuple x 9.
  • bebad05 Resolve documentation code typo.
  • 79db992 PEP 563 + typing.NamedTuple x 8.
  • 15b1d1f PEP 563 + typing.NamedTuple x 7.
  • 657a3b6 ReadTheDocs updating x 2.
  • 36df44d ReadTheDocs updating x 1.
  • 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 show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @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 dependabot bot added dependencies Pull requests that update a dependency file python Pull requests that update Python code labels Feb 12, 2024
github-actions[bot]
github-actions bot previously approved these changes Feb 12, 2024
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm approving this pull request because it includes a patch or minor update

Bumps [beartype](https://github.com/beartype/beartype) from 0.17.0 to 0.17.1.
- [Release notes](https://github.com/beartype/beartype/releases)
- [Changelog](https://github.com/beartype/beartype/blob/main/doc/RELEASE.rst)
- [Commits](beartype/beartype@v0.17.0...v0.17.1)

---
updated-dependencies:
- dependency-name: beartype
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot bot force-pushed the dependabot/pip/{{-cookiecutter.__project_name-}}/beartype-0.17.1 branch from 47015a3 to c8ccf99 Compare February 13, 2024 10:01
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm approving this pull request because it includes a patch or minor update

@github-actions github-actions bot merged commit cfde016 into main Feb 13, 2024
1 check passed
@dependabot dependabot bot deleted the dependabot/pip/{{-cookiecutter.__project_name-}}/beartype-0.17.1 branch February 13, 2024 10:01
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 python Pull requests that update Python code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

0 participants