GithubHelp home page GithubHelp logo

go mod depends on 1.12 about gziphandler HOT 11 CLOSED

nytimes avatar nytimes commented on September 25, 2024
go mod depends on 1.12

from gziphandler.

Comments (11)

jprobinson avatar jprobinson commented on September 25, 2024

Is the use of 1.12 negatively affecting you in some way?

It's in RC1 so it's the default version of Go internally to Google at this point, so should be fine to use in pipelines.

from gziphandler.

jared2501 avatar jared2501 commented on September 25, 2024

from gziphandler.

fsouza avatar fsouza commented on September 25, 2024

@jared2501 the version of go specified in go.mod is informative and doesn't actually do anything. It's used by Go to suggest that you may need to upgrade you version in case the module doesn't compile, but gziphandler doesn't actually require 1.12.

See https://tip.golang.org/doc/go1.12#modules

The go directive in a go.mod file now indicates the version of the language used by the files within that module. It will be set to the current release (go 1.12) if no existing version is present. If the go directive for a module specifies a version newer than the toolchain in use, the go command will attempt to build the packages regardless, and will note the mismatch only if that build fails.

from gziphandler.

jared2501 avatar jared2501 commented on September 25, 2024

Hmm I'm not seeing this on go 1.11:

✓ jnewman@Jareds-MacBook-Pro:~/dev/front-door | jn/gzip● $ CGO_ENABLED=0 GOOS=darwin go build -v -o build/darwin-amd64/front-door ./cmd/front-door
github.com/NYTimes/gziphandler
go build github.com/NYTimes/gziphandler: module requires Go 1.12
✕ jnewman@Jareds-MacBook-Pro:~/dev/front-door | jn/gzip● $ go version
go version go1.11.2 darwin/amd64

from gziphandler.

jared2501 avatar jared2501 commented on September 25, 2024

If you're not keen to downgrade the suggested version, no worries, I can use the replace direct and depend on my fork until go 1.12 comes out and then move over.

from gziphandler.

fsouza avatar fsouza commented on September 25, 2024

@jared2501 oh interesting. We can downgrade, but if the Go docs are telling the truth, the build is failing for some other reason and Go is trying to guess it's because of the language version? Is that code open source?

from gziphandler.

fsouza avatar fsouza commented on September 25, 2024

(and if I have to guess, I'd go with golang/go#29278, which will likely require you to upgrade to Go 1.11.4)

from gziphandler.

fsouza avatar fsouza commented on September 25, 2024

Reopening as we wait for more info.

from gziphandler.

jared2501 avatar jared2501 commented on September 25, 2024

Ah nice one @fsouza, that was it!

from gziphandler.

jared2501 avatar jared2501 commented on September 25, 2024

I upgraded to go 1.11.5, and could build v1.1.0 successfully

from gziphandler.

fsouza avatar fsouza commented on September 25, 2024

Cool, thanks for confirming! It sucks that go swallows the original error message though, so let's keep go 1.11 in the mod file for now and v1.1.1.

from gziphandler.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.