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

Update golang.org/x/net -> v0.15.0 #459

Merged
merged 1 commit into from
Oct 5, 2023

Conversation

jcconnell
Copy link
Contributor

Update golang.org/x/net from v0.12.0 -> v0.15.0 to address https://security.snyk.io/vuln/SNYK-GOLANG-GOLANGORGXNETHTML-5816820

@mna
Copy link
Member

mna commented Oct 5, 2023

Thank you. It's important to understand, though, that the go.mod file of goquery does not define what the applications using goquery will use. That is, the fact that goquery's go.mod does not use the latest version of a dependency does not prevent in any way applications using goquery from updating to the latest dependency (as long as that dependency is version-compatible, of course):

$ go mod init
go: creating new go.mod: module myapp

$ go get github.com/PuerkitoBio/goquery@latest
go: added github.com/PuerkitoBio/goquery v1.8.1
go: added github.com/andybalholm/cascadia v1.3.1
go: added golang.org/x/net v0.7.0

$ go get -u
go: upgraded github.com/andybalholm/cascadia v1.3.1 => v1.3.2
go: upgraded golang.org/x/net v0.7.0 => v0.15.0

$ cat go.mod
module myapp

go 1.21.1

require github.com/PuerkitoBio/goquery v1.8.1

require (
	github.com/andybalholm/cascadia v1.3.2 // indirect
	golang.org/x/net v0.15.0 // indirect
)

$ go build .

$ go version -m myapp 
myapp: go1.21.1
	path	.../myapp
	mod	.../myapp	(devel)	
	dep	github.com/PuerkitoBio/goquery	v1.8.1	h1:uQxhNlArOIdbrH1tr0UXwdVFgDcZDrZVdcpygAcwmWM=
	dep	github.com/andybalholm/cascadia	v1.3.2	h1:3Xi6Dw5lHF15JtdcmAHD3i1+T8plmv7BQ/nsViSLyss=
	dep	golang.org/x/net	v0.15.0	h1:ugBLEUaxABaB5AJqW9enI0ACdci2RUd4eP51NTBvuJ8=
	build	-buildmode=exe
	build	-compiler=gc
	build	CGO_ENABLED=1
	build	CGO_CFLAGS=
	build	CGO_CPPFLAGS=
	build	CGO_CXXFLAGS=
	build	CGO_LDFLAGS=
	build	GOARCH=amd64
	build	GOOS=linux
	build	GOAMD64=v1

@mna mna merged commit 2f635a8 into PuerkitoBio:master Oct 5, 2023
6 checks passed
@jcconnell
Copy link
Contributor Author

Thank you for pointing this out - I was not aware. Good to know!

@mna
Copy link
Member

mna commented Oct 5, 2023

No problem, yeah it's not something that is widely known or understood about Go modules.

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.

2 participants