Skip to content

3.11 random.randrange: fix typo: non-integral -> non-integer #106975

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

Closed
hugovk opened this issue Jul 21, 2023 · 1 comment
Closed

3.11 random.randrange: fix typo: non-integral -> non-integer #106975

hugovk opened this issue Jul 21, 2023 · 1 comment
Labels
docs Documentation in the Doc dir easy

Comments

@hugovk
Copy link
Member

hugovk commented Jul 21, 2023

Documentation

Similar to #106973, https://docs.python.org/3.11/library/random.html?highlight=randrange#random.randrange says:

Deprecated since version 3.10: The automatic conversion of non-integer types to equivalent integers is deprecated. Currently randrange(10.0) is losslessly converted to randrange(10). In the future, this will raise a TypeError.

Deprecated since version 3.10: The exception raised for non-integral values such as randrange(10.5) or randrange('10') will be changed from ValueError to TypeError.

non-integral should be non-integer.

This fix should be made to the 3.11 branch, because the text has been remove from main/3.12.

Linked PRs

@bedevere-bot
Copy link

GH-106985 is a backport of this pull request to the 3.11 branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation in the Doc dir easy
Projects
None yet
Development

No branches or pull requests

2 participants