Skip to content

fix: crypto/rand.Read can't fail#71

Merged
mccutchen merged 1 commit intomainfrom
crypto/rand-can't-fail
Oct 27, 2025
Merged

fix: crypto/rand.Read can't fail#71
mccutchen merged 1 commit intomainfrom
crypto/rand-can't-fail

Conversation

@mccutchen
Copy link
Owner

Per the package docs:

Read calls io.ReadFull on Reader and crashes the program irrecoverably
if an error is returned. The default Reader uses operating system APIs
that are documented to never return an error on all but legacy Linux
systems.

Per its docs[1]:

> Read calls io.ReadFull on Reader and crashes the program irrecoverably
> if an error is returned. The default Reader uses operating system APIs
> that are documented to never return an error on all but legacy Linux
> systems.

[1]: https://pkg.go.dev/crypto/rand#Read
@github-actions
Copy link

🔥 Run benchmarks comparing 2cdfb2a against main:

gh workflow run bench.yaml -f pr_number=71

Note: this comment will update with each new commit.

@mccutchen mccutchen enabled auto-merge (squash) October 27, 2025 16:41
@codecov
Copy link

codecov bot commented Oct 27, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.04%. Comparing base (91b0005) to head (2cdfb2a).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #71      +/-   ##
==========================================
+ Coverage   98.11%   99.04%   +0.93%     
==========================================
  Files           2        2              
  Lines         425      421       -4     
==========================================
  Hits          417      417              
+ Misses          4        2       -2     
+ Partials        4        2       -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@mccutchen mccutchen merged commit 322a83a into main Oct 27, 2025
13 checks passed
@mccutchen mccutchen deleted the crypto/rand-can't-fail branch October 27, 2025 16:42
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.

1 participant