FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-123968: Fix lower bound for `python -m random --float` by andersk · Pull Request #123971 · python/cpython · GitHub

/ cpython Public

gh-123968: Fix lower bound for python -m random --float - #123971

Merged
hugovk merged 1 commit into
python:mainfrom
andersk:random-float
Sep 12, 2024
Merged

gh-123968: Fix lower bound for python -m random --float#123971
hugovk merged 1 commit into
python:mainfrom
andersk:random-float

Conversation

andersk commented Sep 11, 2024
edited
Loading

Copy link
Copy Markdown
Contributor

python -m random --float N incorrectly used a range between 1 and N of length N - 1. Fix it to use a range between 0 and N of length N, as originally specified in #118131, and as everyone will expect.

`python -m random --float N` incorrectly used a range between 1 and N
of length N - 1.  Fix it to use a range between 0 and N of length N,
as originally specified in python#118131, and as everyone will expect.

Fixes python#123968.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
Eclips4 requested review from hugovk and removed request for rhettinger September 11, 2024 19:55
Eclips4 added the needs backport to 3.13 bugs and security fixes label Sep 12, 2024
hugovk merged commit a362c41 into python:main Sep 12, 2024

Copy link
Copy Markdown

Thanks @andersk for the PR, and @hugovk for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13.
🐍🍒⛏🤖

hugovk commented Sep 12, 2024

Copy link
Copy Markdown
Member

Thanks!

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Sep 12, 2024
…onGH-123971)

(cherry picked from commit a362c41)

Co-authored-by: Anders Kaseorg <andersk@mit.edu>

bedevere-app Bot commented Sep 12, 2024

Copy link
Copy Markdown

GH-124009 is a backport of this pull request to the 3.13 branch.

bedevere-app Bot removed the needs backport to 3.13 bugs and security fixes label Sep 12, 2024
andersk deleted the random-float branch September 16, 2024 21:44
Yhg1s pushed a commit that referenced this pull request Sep 23, 2024
…123971) (#124009)

gh-123968: Fix lower bound for `python -m random --float` (GH-123971)
(cherry picked from commit a362c41)

Co-authored-by: Anders Kaseorg <andersk@mit.edu>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL