Closed alexedwards closed 5 years ago
Isn't it the fact that there is no go.mod file in this repository ?
I simply did not create it because this router has no dependencies, and I did not want to include in go.mod file packages I used for benchmarks. (not an issue anymore)
I think releasing major version v4.0.0 with a go.mod file should fix issue. Do you agree @alexedwards ?
Kind of!
I beleive that the +incompatible
tag isn't just because there's no go.mod file. Lot's of repositories don't have them, but will still pull through without the incompatible tag... so long as they are in v0 or v1. For example: https://github.com/bmizerany/pat.
My understanding is that the incompatible tag is appearing because Go knows that the gorouter repository is at v3.0.6, but the import path doesn't follow the convention of being github.com/vardius/gorouter/v3.
So if you're making a v4 release, then I think that initializing the go.mod file with go mod init github.com/vardius/gorouter/v4
should fix it.
I should have said in my first message, you've done really nice work on this package. I really like the design decisions you've made for the router and the documentation is excellent! : )
I created new release https://github.com/vardius/gorouter/releases/tag/v4.0.0,
which seems to work correctly now https://github.com/vardius/go-api-boilerplate/blob/05ee7ccd28718b542ec67665e768e2a2a35666ef/go.mod#L15
Since now import router as import "github.com/vardius/gorouter/v4"
. Please update your imports.
That works great now. Thanks for the fast fix :+1:
When pulling through
github.com/vardius/gorouter
as a dependency, mygo.mod
file has the+incompatible
tag:I think this is because the
gorouter
repository isn't following the module path conventions for v2+ repositories.