7

Github We have too many unwrap() calls in the codebase · Issue #301 · softprops/...

 3 years ago
source link: https://github.com/softprops/shiplift/issues/301
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

Copy link

Collaborator

matthiasbeyer commented yesterday

Doing a quick analysis:

grep -rni unwrap -c src/ | cut -d: -f 2 | awk '{sum+=$1} END {print sum}'

gives me a shocking 53. Of course some of those (probably the majority) is in tests, where it is (IMO) appropriate to unwrap right away, but a lot of them are not in tests (after a quick less on some files).

This is rather easy to tackle IMO, maybe even for a beginner (one unwrap fixed at a time in one PR even, I am happy to mentor!)


I'll mark this as good first issue and submit it to this-week-in-rust!


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK