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.
I happened to notice errors on my local machine when I would run
make generate
. I did a little digging and realize these were material errors that were happening in CI, too.If you look at this latest CI job from
main
, in the "Unit Test" step, you'll see output that repeats the following error message:On my laptop, I was seeing a different error:
Doh! This error should have caused the
make generate
target to halt and fail, but it did not. This pull request remedies that.There are two different issues afoot:
generate.sh
script would return success (zero exit code), even when the various commands it was running would fail. This is due to how the-exec
flag tofind
works. So I changed it to instead usexargs
, which will properly return a non-zero exit code if any of the processes it spawns fails.generate.sh
failing: thePATH
variable was not properly configured. So themake generate
target was building the dependencies but not making them available on thePATH
.Now that this is fixed, this also fixes the generated code produced by that step so that it corresponds to the correct version of
protoc-gen-go
(i.e. the version pinned ingo.mod
).