Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix go.mod for Go 1.13 #258

Merged
merged 2 commits into from Aug 2, 2019
Merged

Fix go.mod for Go 1.13 #258

merged 2 commits into from Aug 2, 2019

Conversation

tie
Copy link
Contributor

@tie tie commented Aug 2, 2019

This PR fixes the timestamp in dependency version.

I’ve also pinned github.com/golang/glog module version (that’s what go mod tidy does anyway).


The go.mod in this project does not work with go1.13 (checked out at golang/go@2d6ee6e89a). The project depends on google.golang.org/genproto@v0.0.0-20170818100345-ee236bd376b0, but the timestamp is invalid. It should be 20170818010345 instead. See googleapis/go-genproto@ee236bd

Steps to reproduce:

# Check our Go version.
% go version
go version go1.13-2d6ee6e89a darwin/amd64

# Clean local module cache.
% go clean -modcache

# Don’t use the modules proxy.
% go env -w GOPROXY=direct

% go mod tidy
go: google.golang.org/genproto@v0.0.0-20170818100345-ee236bd376b0: invalid pseudo-version: does not match version-control timestamp (2017-08-18T01:03:45Z)

Note that the those steps won’t cause an error with go1.12. Running go1.13 mod tidy after go1.12 mod tidy succeeds, so we have to clean the mod cache. Moreover, the [broken] module version is cached in the default GOPROXY=https://proxy.golang.org so we have to disable that too.

@tie tie mentioned this pull request Aug 2, 2019
go.mod Outdated Show resolved Hide resolved
go mod tidy pulls in glog indirect dependency from grpc logger package.
protoreflect does not use grpclog/glogger, so it's ok to omit glog from go.mod.
Copy link
Owner

@jhump jhump left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the patch!

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.

None yet

2 participants