Let the one-rev check pass a lockfile with no git sources - #26
Merged
Conversation
grep exits 1 when it matches nothing, and set -o pipefail turns that into a failed check. So the moment the last git dependency went away, the script that exists to police git dependencies started failing on the best possible lockfile, and it went red on master. The success message said "one rev per git source" either way, which would have read as a pass of a check that never ran. It now says "no git sources" when there are none.
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
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
one-revis red onmaster. It is not a dependency problem: the check itselffails when there is nothing to check.
grepexits 1 when it matches nothing, and the script runs underset -euo pipefail, so an empty match fails the whole script. Taking the lastgit dependency out of
Cargo.lock(#25) is therefore what broke it. The scriptthat exists to police git dependencies now fails on the best possible lockfile.
The success message was also unconditional — it printed "one rev per git
source" whether or not any git source existed, which reads as a pass of a check
that never ran. It says "no git sources" in that case now.
Verified
master)The duplicate-detection path is untouched; only the empty case and the final
message changed.