go mod update dependencies and leave local - go

I have a package that uses some local packages
module mycompany.com/clientname/server
go 1.14
require (
github.com/lib/pq v1.7.0
github.com/99designs/gqlgen v0.11.3
github.com/vektah/gqlparser/v2 v2.0.1
golang.org/x/oauth2 v0.0.0-20200107190931-bf48bf16ab8d
mycompany.com/clientname/models v0.0.0-00010101000000-000000000000
mycompany.com/common/utils v0.0.0-00010101000000-000000000000
)
replace mycompany.com/common/utils => ../../common/utils
replace mycompany.com/clientname/models => ../models
the mycompany.com domain doesn't serve the package, it is just a fictional path (and I use it in my gopath ~/go/src/mycompany.com/...)
the problem is that when I run go get -u all, I want the 'valid' packages to be updated (like the github.com/lib/pq or github.com/99designs/gqlgen), but to leave the local (fictional) packages as they are.
but go get -u all just prints out the new versions, then prints the errors on the local packages and then doesn't change go.mod.
go: google.golang.org/grpc upgrade => v1.30.0
go: go.opencensus.io upgrade => v0.22.4
go: github.com/mattn/go-runewidth upgrade => v0.0.9
go: github.com/gogs/chardet upgrade => v0.0.0-20191104214054-4b6791f73a28
go: golang.org/x/text upgrade => v0.3.3
go: github.com/mitchellh/mapstructure upgrade => v1.3.2
go get all: unrecognized import path "mycompany.com/clientname/models": reading https://mycompany.com/clientname/models?go-get=1: 404 Not Found
go get all: unrecognized import path "mycompany.com/common/utils": reading https://mycompany.com/common/utils?go-get=1: 404 Not Found

The error from go get -u was a bug in the go command, fixed in the upcoming Go 1.16 release. See https://golang.org/issue/32567 for detail.
(That said, ideally you should be hosting the modules in version control and using GOPRIVATE=mycompany.com instead of slotting things in locally via replace directives.)

Related

Deploying Go app on Google Cloud 'missing go.sum entry'

I'm trying to deploy a simple API on Google Cloud using Go 1.19
> go version
go version go1.19.2 windows/amd64
I'm following this documentation as a template to deploy my app. But the deploy fails.
Updating service [default]...failed.
ERROR: (gcloud.app.deploy) Error Response: [9] Cloud build xxx status: FAILURE
go: github.com/go-redis/redis/v9#v9.0.0-rc.1 requires
github.com/onsi/ginkgo#v1.16.5: missing go.sum entry; to add it:
go mod download github.com/onsi/ginkgo
Cloud build log:
Running "go build -o /layers/google.go.build/bin/main . (GOCACHE=/layers/google.go.build/gocache)"
go: github.com/go-redis/redis/v9#v9.0.0-rc.1 requires
github.com/onsi/ginkgo#v1.16.5: missing go.sum entry; to add it:
go mod download github.com/onsi/ginkgo
Done "go build -o /layers/google.go.build/bin/main . (GOCACHE=/lay..." (7.516802ms)
Failure: (ID: 721b15b4) go: github.com/go-redis/redis/v9#v9.0.0-rc.1 requires
github.com/onsi/ginkgo#v1.16.5: missing go.sum entry; to add it:
go mod download github.com/onsi/ginkgo
--------------------------------------------------------------------------------
Running "mv -f /builder/outputs/output-5577006791947779410 /builder/outputs/output"
Done "mv -f /builder/outputs/output-5577006791947779410 /builder/o..." (3.938721ms)
ERROR: failed to build: exit status 1
Running the suggested go mod download github.com/onsi/ginkgo does not solve anything.
Also tried go mod tidy as suggested in another posts but same results. Also tried with vendor folder, but nothing again.
This is my app.yaml
runtime: go116
go.mod
module notams/anac
go 1.19
require (
github.com/go-redis/redis/v9 v9.0.0-rc.1
github.com/gorilla/mux v1.8.0
github.com/joho/godotenv v1.4.0
golang.org/x/exp v0.0.0-20221019170559-20944726eadf
)
require (
github.com/cespare/xxhash/v2 v2.1.2 // indirect
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f // indirect
)
go.sum
github.com/cespare/xxhash/v2 v2.1.2 h1:YRXhKfTDauu4ajMg1TPgFO5jnlC2HCbmLXMcTG5cbYE=
github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f h1:lO4WD4F/rVNCu3HqELle0jiPLLBs70cWOduZpkS1E78=
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f/go.mod h1:cuUVRXasLTGF7a8hSLbxyZXjz+1KgoB3wDUb6vlszIc=
github.com/fsnotify/fsnotify v1.4.9 h1:hsms1Qyu0jgnwNXIxa+/V/PDsU6CfLf6CNO8H7IWoS4=
github.com/go-redis/redis/v9 v9.0.0-rc.1 h1:/+bS+yeUnanqAbuD3QwlejzQZ+4eqgfUtFTG4b+QnXs=
github.com/go-redis/redis/v9 v9.0.0-rc.1/go.mod h1:8et+z03j0l8N+DvsVnclzjf3Dl/pFHgRk+2Ct1qw66A=
github.com/google/go-cmp v0.5.8 h1:e6P7q2lk1O+qJJb4BtCQXlK8vWEO8V1ZeuEdJNOqZyg=
github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI=
github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So=
github.com/joho/godotenv v1.4.0 h1:3l4+N6zfMWnkbPEXKng2o2/MR5mSwTrBih4ZEkkz1lg=
github.com/joho/godotenv v1.4.0/go.mod h1:f4LDr5Voq0i2e/R5DDNOoa2zzDfwtkZa6DnEwAbqwq4=
github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE=
github.com/onsi/ginkgo v1.16.5 h1:8xi0RTUf59SOSfEtZMvwTvXYMzG4gV23XVHOZiXNtnE=
github.com/onsi/gomega v1.21.1 h1:OB/euWYIExnPBohllTicTHmGTrMaqJ67nIu80j0/uEM=
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
github.com/stretchr/testify v1.8.0 h1:pSgiaMZlXftHpm5L7V1+rVB+AZJydKsMxsQBIJw4PKk=
golang.org/x/exp v0.0.0-20221019170559-20944726eadf h1:nFVjjKDgNY37+ZSYCJmtYf7tOlfQswHqplG2eosjOMg=
golang.org/x/exp v0.0.0-20221019170559-20944726eadf/go.mod h1:cyybsKvd6eL0RnXn6p/Grxp8F5bW7iYuBgsNCOHpMYE=
golang.org/x/net v0.0.0-20220722155237-a158d28d115b h1:PxfKdU9lEEDYjdIzOtC4qFWgkU2rGHdKlKowJSMN9h0=
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f h1:v4INt8xihDGvnrfjMDVXGxw9wrfxYyCjk0KbXjhR55s=
golang.org/x/text v0.3.7 h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk=
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ=
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
EDIT 1: Already tried to change runtime: go and to runtime: go119 but those are not supported and return "invalid go runtime".
To anyone who might have this problem, I just deployed the app on Cloud Run instead of App Engine and everything runs smoothly. I was not able to deploy it on App Engine and i think that the only way to do so is adapting the code and modules to the latest runtime version available for GCP (currently Go 1.16).

Installing a Go tool from github and facing installation errors

I want to install this tool from github : https://github.com/ethicalhackingplayground/ssrf-tool
I am using the cmd : go install github.com/ethicalhackingplayground/ssrf-tool#latest
Output :
go: finding module for package github.com/projectdiscovery/gologger
go: finding module for package github.com/briandowns/spinner
go: finding module for package github.com/logrusorgru/aurora
go: found github.com/briandowns/spinner in github.com/briandowns/spinner v1.18.1
go: found github.com/logrusorgru/aurora in github.com/logrusorgru/aurora v2.0.3+incompatible
go: found github.com/projectdiscovery/gologger in github.com/projectdiscovery/gologger v1.1.4
# github.com/ethicalhackingplayground/ssrf-tool
..\..\..\go\pkg\mod\github.com\ethicalhackingplayground\ssrf-tool#v0.0.0-20200901082948-7f3cffc3c7bb\ssrftool.go:34:2: undefined: gologger.Printf
..\..\..\go\pkg\mod\github.com\ethicalhackingplayground\ssrf-tool#v0.0.0-20200901082948-7f3cffc3c7bb\ssrftool.go:35:2: undefined: gologger.Infof
..\..\..\go\pkg\mod\github.com\ethicalhackingplayground\ssrf-tool#v0.0.0-20200901082948-7f3cffc3c7bb\ssrftool.go:36:2: undefined: gologger.Infof
I am super new to golang, go installation is fine in my system because other tools from github are working fine.
If some changes are required in the code of this tool, please suggest so.
This sources created without go module support and an old version of gologger, here is a workaround:
Clone repository git clone git#github.com:ethicalhackingplayground/ssrf-tool.git
cd ssrf-tool create go.mod file with content:
module github.com/ethicalhackingplayground/ssrf-tool
go 1.17
require (
github.com/briandowns/spinner v1.18.1
github.com/logrusorgru/aurora v2.0.3+incompatible
github.com/projectdiscovery/gologger v1.0.1
)
require (
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/fatih/color v1.7.0 // indirect
github.com/mattn/go-colorable v0.1.2 // indirect
github.com/mattn/go-isatty v0.0.8 // indirect
golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223 // indirect
)
download deps go mod download
Build executable go build .
./ssrf-tool --help
Profit.
Here is the repo with the problem fixed.
go install github.com/R0X4R/ssrf-tool#latest
or
git clone https://github.com/R0X4R/ssrf-tool.git
cd ssrf-tool
go build ssrftool.go && mv ssrftool /usr/bin/

How to Import KFServing Client Package in Golang

We are using KFServing in our kubernetes cluster. The project provides InferenceService struct and clientset in the folder pkg/.
How to import these packages under pkg/client? My code is as below:
package main
import (
"fmt"
kfs
"github.com/kubeflow/kfserving/pkg/client/clientset/versioned"
)
func main() {
var clientset *kfs.Cientset
clientset = kfs.NewForConfig(nil)
fmt.Println(clientset)
}
Try go mod tidy i got (I need dev on specified version v0.5.1):
main imports
github.com/kubeflow/kfserving/pkg/client/clientset/versioned
imports
k8s.io/client-go/discovery imports
github.com/googleapis/gnostic/OpenAPIv2:
module github.com/googleapis/gnostic#latest found (v0.5.5),
but does not contain package
github.com/googleapis/gnostic/OpenAPIv2
main imports
github.com/kubeflow/kfserving/pkg/client/clientset/versioned
imports
...
Try compiling these code i got:
a lot of errors .....
After go get github.com/kubeflow/kfserving I got:
Then I changed the go.mod and reconfiged the kfseving version from v0.6.0 to v0.5.1 and then recompile these code, still got below error:
go build .
go: github.com/kubeflow/kfserving#v0.5.1: missing go.sum entry; to add it:
go mod download github.com/kubeflow/kfserving
contens of go.mod:
module main
go 1.16
require github.com/kubeflow/kfserving v0.5.1 // indirect
UPDATE
for kfserving v0.4.0 everything works well
Looking at the kfserving go.mod file at v0.5.1, I see a big block of replace directives. By design, replace directives “only apply in the main module's go.mod file and are ignored in other modules”, so it looks like kfserving has some technical debt here that they're passing on to you.
I started with an empty go.mod file and pasted in those replace directives. Then:
$ go get -d github.com/kubeflow/kfserving/pkg/client/clientset/versioned#v0.5.1
go get: added github.com/PuerkitoBio/purell v1.1.1
…
go get: added sigs.k8s.io/yaml v1.2.0
The .go source file needed a few fixes for typos and mismatched types. I fudged it to:
package main
import (
"fmt"
kfs "github.com/kubeflow/kfserving/pkg/client/clientset/versioned"
)
func main() {
var clientset *kfs.Clientset
clientset = kfs.NewForConfigOrDie(nil)
fmt.Println(clientset)
}
and then go build . succeeds:
$ go build -o /dev/null .
Now I'll run go mod tidy to clean up the go.mod and go.sum files:
$ go mod tidy
go: downloading github.com/stretchr/testify v1.5.1
…
go: downloading github.com/jmespath/go-jmespath v0.3.0
But wait! I've still got all of the technical debt from kfserving/go.mod — without any comments explaining the choice of versions! — and I'm passing that technical debt on to any downstream users. Let's see if I can improve the situation while I'm here.
Go 1.16 handles the exclude directive a lot better than previous Go versions did, so maybe I can use a couple of targeted exclude directives instead of the (rather large) replace hammer.
I'll start by committing the fixes so far. (If nothing else, I want to be able to git diff the requirements to see what has changed.)
$ git add *.go go.mod go.sum
$ git commit -m 'fixed kfserving build'
[main fd93b1d] fixed kfserving build
3 files changed, 1643 insertions(+), 2 deletions(-)
create mode 100644 go.sum
I notice that all of the replace directives apply to k8s.io paths, so I'll list the current versions of those paths to see what needs to be fixed:
$ go list -m k8s.io/...
k8s.io/api v0.19.2 => k8s.io/api v0.19.2
k8s.io/apiextensions-apiserver v0.19.2 => k8s.io/apiextensions-apiserver v0.19.2
k8s.io/apimachinery v0.19.2 => k8s.io/apimachinery v0.19.2
k8s.io/apiserver v0.19.2 => k8s.io/apiserver v0.19.2
k8s.io/client-go v11.0.1-0.20190805182717-6502b5e7b1b5+incompatible => k8s.io/client-go v0.19.2
k8s.io/cloud-provider v0.19.2 => k8s.io/cloud-provider v0.19.2
k8s.io/code-generator v0.19.2 => k8s.io/code-generator v0.19.2
k8s.io/component-base v0.19.2 => k8s.io/component-base v0.19.2
k8s.io/csi-translation-lib v0.19.2 => k8s.io/csi-translation-lib v0.19.2
k8s.io/gengo v0.0.0-20200428234225-8167cfdcfc14
k8s.io/klog v1.0.0 => k8s.io/klog v1.0.0
k8s.io/klog/v2 v2.2.0
k8s.io/kube-openapi v0.0.0-20200805222855-6aeccd4b50c6
k8s.io/legacy-cloud-providers v0.17.4 => k8s.io/legacy-cloud-providers v0.19.2
k8s.io/test-infra v0.0.0-20200803112140-d8aa4e063646 => k8s.io/test-infra v0.0.0-20200803112140-d8aa4e063646
k8s.io/utils v0.0.0-20200912215256-4140de9c8800 => k8s.io/utils v0.0.0-20200324210504-a9aa75ae1b89
Most of those look fine, but there are three mismatched versions:
k8s.io/client-go v11.0.1-0.20190805182717-6502b5e7b1b5+incompatible => k8s.io/client-go v0.19.2
…
k8s.io/legacy-cloud-providers v0.17.4 => k8s.io/legacy-cloud-providers v0.19.2
…
k8s.io/utils v0.0.0-20200912215256-4140de9c8800 => k8s.io/utils v0.0.0-20200324210504-a9aa75ae1b89
legacy-cloud-providers just needs an upgrade, so that should be easy enough to fix with go get — but it's not relevant to this package anyway so I can just let it float to whatever version it ends up at. I'll cut down the replace directives to just the two remaining modules and see how far I get:
replace (
k8s.io/client-go => k8s.io/client-go v0.19.2
k8s.io/utils => k8s.io/utils v0.0.0-20200324210504-a9aa75ae1b89
)
Now:
$ go mod tidy
$ go build -o /dev/null .
Ok, so the build is still good — I've made incremental progress, so I'll lock that in:
$ git add go.mod go.sum
$ git commit -m 'go.mod: remove irrelevant replacements'
[main cdbc1db] go.mod: remove irrelevant replacements
3 files changed, 456 insertions(+), 43 deletions(-)
rewrite go.mod (85%)
create mode 100755 m
Now let's try notching out the bad client-go versions with exclude directives:
$ go mod edit -exclude=k8s.io/client-go#v11.0.1-0.20190805182717-6502b5e7b1b5+incompatible
$ go list -m k8s.io/client-go
k8s.io/client-go v9.0.0+incompatible => k8s.io/client-go v0.19.2
$ go mod edit -exclude=k8s.io/client-go#v9.0.0+incompatible
$ go list -m k8s.io/client-go
k8s.io/client-go v0.19.2 => k8s.io/client-go v0.19.2
Now I'm at the client-go version I needed, so I can drop that replace directive:
$ go mod edit -dropreplace=k8s.io/client-go
$ go mod tidy
$ go build -o /dev/null .
And again lock it in:
$ git add go.mod go.sum
$ git commit -m 'go.mod: use exclude instead of replace to notch out unwanted client-go versions'
[main de69965] go.mod: use exclude instead of replace to notch out unwanted client-go versions
2 files changed, 21 insertions(+), 3 deletions(-)
Now let's see what's going on with this k8s.io/utils replacement. I suspect that it isn't really needed — the version will be upgraded a bit, but I'm betting it won't break the build. And, indeed, it seems to be fine:
$ go list -m k8s.io/utils
k8s.io/utils v0.0.0-20200912215256-4140de9c8800 => k8s.io/utils v0.0.0-20200324210504-a9aa75ae1b89
$ go mod edit -dropreplace=k8s.io/utils
$ go mod tidy
$ go build -o /dev/null .
$ go list -m k8s.io/utils
k8s.io/utils v0.0.0-20200912215256-4140de9c8800
So now I've successfully reduced that big nest of replace directives from kfserving to just a couple of exclude directives targeted retracted versions of k8s.io/client-go. Here's my whole go.mod file at the end of this process:
module example.com/m
go 1.16
exclude (
k8s.io/client-go v11.0.1-0.20190805182717-6502b5e7b1b5+incompatible
k8s.io/client-go v9.0.0+incompatible
)
require github.com/kubeflow/kfserving v0.5.1
This seems like a module cache issue cause that package appears to be there for v0.5.1. Do the following:
Clean the modcache go clean --modcache
Get the module the nice way via go get github.com/kubeflow/kfserving#v0.5.1
Run go mod tidy
Update
With the extra output I can see you you have an import error from a dependent module.
github.com/kubeflow/kfserving/pkg/client/clientset/versioned
imports
k8s.io/client-go/discovery imports
github.com/googleapis/gnostic/OpenAPIv2:
So version v0.5.1 imports k8s.io/client-go/discovery which imports github.com/googleapis/gnostic/OpenAPIv2 which no longer exists in the current release (but it is there is older releases). So it looks like you would need to fix the import version in client-go to avoid this issue.

What to do when `go list` doesn't show the newest version of a package?

go list -m -versions gopkg.in/urfave/cli.v1 gives me the following version listing, that has 1.20.0 as the newest version:
gopkg.in/urfave/cli.v1 v1.0.0 v1.1.0 v1.2.0 v1.3.0 v1.3.1 v1.4.0 v1.4.1 v1.5.0 v1.6.0 v1.7.0 v1.7.1 v1.8.0 v1.9.0 v1.10.0 v1.10.1 v1.10.2 v1.11.0 v1.11.1 v1.12.0 v1.13.0 v1.14.0 v1.15.0 v1.16.0 v1.16.1 v1.17.0 v1.17.1 v1.18.0 v1.18.1 v1.19.0 v1.19.1 v1.20.0
However, according gopkg.in, 1.22.4 should be the newest version. 1.22.4 is also the newest release on the package's GitHub repo.
How should I go troubleshooting this problem? Seems like it could be a cache issue.
For background info: the repository originally had dep-based dependency listing (Gopkg.toml), that had version 1.20. I prefer modules, so I initialised go.mod by go mod init $REPO_URL. I later pulled the latest commits from the repo, which had the package version updated to 1.22. I tried re-creating go.mod; it first indicated a problem at that step:
go: converting Gopkg.lock: stat gopkg.in/urfave/cli.v1#v1.22.0: gopkg.in/urfave/cli.v1#v1.22.0: invalid version: go.mod has non-....v1 module path "github.com/urfave/cli" at revision v1.22.0
In the end, I ended up with code that expects version 1.22, but the tools fetch the version 1.20 which isn't forwards compatible, so it doesn't compile.
There is nothing you can do to fix it. The package is broken, so the package author/maintainer needs to fix it.
In short, the project has an invalid go.mod file, which was apparently added after v1.20.0 was released--which is why up to that version is available.
The go.mod file refers to "github.com/urfave/cli", but the package is imported as "gopkg.in/urfave/cli.v1". The go.mod file needs to be updated to reflect the proper import path.
As a work-around, it might work to import the package as "github.com/urfave/cli", but this will break many packages that have "sub" packages that refer to the alternate import path. I'd say it's worth a try in this case, though.

go.mod has post-v2 module path at revision v2.0.0

I have a rest api I built in Go with gin that has been working for months now on my local machine running 1.12.1. I decided it was going to a docker deploy so I started building with 1.12.6 when I started see errors during module retrieval. I went back to my local machine, ran running 1.12.1 and ran go clean -modcache, now the error is there as well. I've tried regenerating multiple times even editing the go.sum file to different versions of gofight but I'm lost and run out of ideas.
The output w/error:
go: github.com/appleboy/gofight#v2.0.0+incompatible: go.mod has post-v2 module path "github.com/appleboy/gofight/v2" at revision v2.0.0
go: error loading module requirements
go.mod
module go-hybrid-alert
go 1.12
require (
cloud.google.com/go v0.37.0
firebase.google.com/go v3.6.0+incompatible
github.com/Luzifer/go-openssl v2.0.0+incompatible
github.com/PuerkitoBio/goquery v1.5.0
github.com/antchfx/htmlquery v1.0.0 // indirect
github.com/antchfx/xmlquery v1.0.0 // indirect
github.com/antchfx/xpath v0.0.0-20190129040759-c8489ed3251e // indirect
github.com/appleboy/gin-jwt v0.0.0-20190216100112-ca1084e5d5a2
github.com/gin-contrib/sse v0.0.0-20190301062529-5545eab6dad3 // indirect
github.com/gin-gonic/gin v1.3.0
github.com/go-redis/redis v6.15.2+incompatible
github.com/gobwas/glob v0.2.3 // indirect
github.com/gocolly/colly v1.2.0
github.com/kennygrant/sanitize v1.2.4 // indirect
github.com/kisielk/godepgraph v0.0.0-20181003180210-9a9a3d47fba3 // indirect
github.com/levigross/grequests v0.0.0-20190130132859-37c80f76a0da // indirect
github.com/mattn/go-isatty v0.0.7 // indirect
github.com/mitchellh/mapstructure v1.1.2
github.com/saintfish/chardet v0.0.0-20120816061221-3af4cd4741ca // indirect
github.com/temoto/robotstxt v0.0.0-20180810133444-97ee4a9ee6ea // indirect
github.com/ugorji/go/codec v0.0.0-20190316083543-95c34d148dff // indirect
golang.org/x/crypto v0.0.0-20190313024323-a1f597ede03a
golang.org/x/net v0.0.0-20190313220215-9f648a60d977
google.golang.org/api v0.2.0
gopkg.in/dgrijalva/jwt-go.v3 v3.2.0 // indirect
gopkg.in/go-playground/validator.v8 v8.18.2 // indirect
)
go.sum (the line for the module in question, posting the whole thing exceeds SO post length)
github.com/appleboy/gofight v2.0.0+incompatible/go.mod h1:H/tvof1oZHnZdlBd+AeODZGkk1C+D2na0NXr0iXuZHA=
I've also tried adjusting the go 1.12 statement in go.mod for the specific subversions I'm attempting to build with but that had no effect.
What does this error mean? How can I fix it?
A number of packages were outdated, the main fix was to run the new install command for gin-jwt, go get github.com/appleboy/gin-jwt/v2
Ultimately though I just nuked my go.mod and go.sum and did a fresh sync in Goland IDE. Everything is working on 1.12+

Resources