You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@skywalking.apache.org by GitBox <gi...@apache.org> on 2021/01/20 12:27:42 UTC
[GitHub] [skywalking-satellite] kezhenxu94 opened a new pull request #18: Include go.sum|go.mod in CI consistency
kezhenxu94 opened a new pull request #18:
URL: https://github.com/apache/skywalking-satellite/pull/18
go.sum|go.mod need to be checked too @EvanLjp , see https://github.com/apache/skywalking-satellite/pull/16#discussion_r560815717
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [skywalking-satellite] EvanLjp edited a comment on pull request #18: Include go.sum|go.mod in CI consistency
Posted by GitBox <gi...@apache.org>.
EvanLjp edited a comment on pull request #18:
URL: https://github.com/apache/skywalking-satellite/pull/18#issuecomment-763579830
But in the history cases, the `go mod tidy` is not stable in the different machines to add `// indirect`
how about following way?
```
check: clean
$(OUT_DIR)/$(BINARY)-$(VERSION)-$(OSNAME)-$(ARCH) docs
$(GO) mod tidy &> /dev/null
@if ! git status -s | grep -v '// indirect'; then \
echo "Following files are not consistent with CI:"; \
git status -s | grep -v '// indirect'; \
exit 1; \
fi
```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [skywalking-satellite] wu-sheng merged pull request #18: Include go.sum|go.mod in CI consistency check
Posted by GitBox <gi...@apache.org>.
wu-sheng merged pull request #18:
URL: https://github.com/apache/skywalking-satellite/pull/18
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [skywalking-satellite] kezhenxu94 commented on pull request #18: Include go.sum|go.mod in CI consistency
Posted by GitBox <gi...@apache.org>.
kezhenxu94 commented on pull request #18:
URL: https://github.com/apache/skywalking-satellite/pull/18#issuecomment-764448130
According to [the doc](https://github.com/golang/go/wiki/Modules#why-does-go-mod-tidy-record-indirect-and-test-dependencies-in-my-gomod), `go mod tidy` should be consistent in all platforms:
> go mod tidy also ensures your current go.mod reflects the dependency requirements for all possible combinations of OS, architecture, and build tags (as described here). In contrast, other commands like go build and go test only update go.mod to provide the packages imported by the requested packages under the current GOOS, GOARCH, and build tags (which is one reason go mod tidy might add requirements that were not added by go build or similar).
I checked your issue in #10 , which is caused by the `packr` tool because it used `GO111MODULE=on` so that it modifies the `go.{mod,sum}` always when no `packr2` is installed (this happens on GitHub Action, but not on your local machine unless you remove `$(go env GOPATH)/bin/packr2`), we don't use it and thus I remove it here.
Another problem is that you had `$(GO) mod tidy &> /dev/null`, causing the `go mod tidy` to run at background and the following command `git status -s` will detect nothing because `go mod tidy` has not finished yet (mostly because it cause some time), see [here](https://github.com/apache/skywalking-satellite/runs/1740240310) for the problem that was never detected before because of this .
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [skywalking-satellite] EvanLjp commented on pull request #18: Include go.sum|go.mod in CI consistency
Posted by GitBox <gi...@apache.org>.
EvanLjp commented on pull request #18:
URL: https://github.com/apache/skywalking-satellite/pull/18#issuecomment-763579830
But in the history cases, the `go mod tidy` is not stable in the different machines to add `// indirect`
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [skywalking-satellite] kezhenxu94 commented on pull request #18: Include go.sum|go.mod in CI consistency
Posted by GitBox <gi...@apache.org>.
kezhenxu94 commented on pull request #18:
URL: https://github.com/apache/skywalking-satellite/pull/18#issuecomment-764448130
According to [the doc](https://github.com/golang/go/wiki/Modules#why-does-go-mod-tidy-record-indirect-and-test-dependencies-in-my-gomod), `go mod tidy` should be consistent in all platforms:
> go mod tidy also ensures your current go.mod reflects the dependency requirements for all possible combinations of OS, architecture, and build tags (as described here). In contrast, other commands like go build and go test only update go.mod to provide the packages imported by the requested packages under the current GOOS, GOARCH, and build tags (which is one reason go mod tidy might add requirements that were not added by go build or similar).
I checked your issue in #10 , which is caused by the `packr` tool because it used `GO111MODULE=on` so that it modifies the `go.{mod,sum}` always when no `packr2` is installed (this happens on GitHub Action, but not on your local machine unless you remove `$(go env GOPATH)/bin/packr2`), we don't use it and thus I remove it here.
Another problem is that you had `$(GO) mod tidy &> /dev/null`, causing the `go mod tidy` to run at background and the following command `git status -s` will detect nothing because `go mod tidy` has not finished yet (mostly because it cause some time), see [here](https://github.com/apache/skywalking-satellite/runs/1740240310) for the problem that was never detected before because of this .
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [skywalking-satellite] wu-sheng merged pull request #18: Include go.sum|go.mod in CI consistency check
Posted by GitBox <gi...@apache.org>.
wu-sheng merged pull request #18:
URL: https://github.com/apache/skywalking-satellite/pull/18
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org