diff --git "a/top_repo_data.csv" "b/top_repo_data.csv" new file mode 100644--- /dev/null +++ "b/top_repo_data.csv" @@ -0,0 +1,66273 @@ +Unnamed: 0,id,type,created_at,repo,repo_url,action,title,labels,body,index,text_combine,label,text,binary_label +41279,5346072400.0,IssuesEvent,2017-02-17 18:40:55,golang/go,https://api.github.com/repos/golang/go,opened,x/tools/go/loader: tests are too brittle,Testing,"The x/tools/go/loader tests have a history of breaking whenever something in the standard library +changes. + +Or breaking when testing Go 1.6 vs Go 1.7 vs Go 1.8 vs Go tip, etc. + +I think it's time to rethink those tests to not be a maintenance burden. + +(Latest example: https://go-review.googlesource.com/c/37148/) + +/cc @ianlancetaylor ",1.0,"x/tools/go/loader: tests are too brittle - The x/tools/go/loader tests have a history of breaking whenever something in the standard library +changes. + +Or breaking when testing Go 1.6 vs Go 1.7 vs Go 1.8 vs Go tip, etc. + +I think it's time to rethink those tests to not be a maintenance burden. + +(Latest example: https://go-review.googlesource.com/c/37148/) + +/cc @ianlancetaylor ",0,x tools go loader tests are too brittle the x tools go loader tests have a history of breaking whenever something in the standard library changes or breaking when testing go vs go vs go vs go tip etc i think it s time to rethink those tests to not be a maintenance burden latest example cc ianlancetaylor ,0 +24974,5115265922.0,IssuesEvent,2017-01-06 21:14:43,golang/go,https://api.github.com/repos/golang/go,closed,doc: define the first class ports,Documentation NeedsFix,"build.golang.org links to ""First Class Ports"": + +https://github.com/golang/go/wiki/PortingPolicy + +But that doesn't say which ports are the first class ones. + +Further, the checkbox on https://build.golang.org to show only first class ports seems to only filter by GOOS, not (GOOS,GOARCH), so it shows things like linux-mips64le and linux-ppc64 as being first class, which I don't think is true. We don't even have linux-ppc64 big-endian builders at the moment. + +Let's clarify. +",1.0,"doc: define the first class ports - build.golang.org links to ""First Class Ports"": + +https://github.com/golang/go/wiki/PortingPolicy + +But that doesn't say which ports are the first class ones. + +Further, the checkbox on https://build.golang.org to show only first class ports seems to only filter by GOOS, not (GOOS,GOARCH), so it shows things like linux-mips64le and linux-ppc64 as being first class, which I don't think is true. We don't even have linux-ppc64 big-endian builders at the moment. + +Let's clarify. +",1,doc define the first class ports build golang org links to first class ports but that doesn t say which ports are the first class ones further the checkbox on to show only first class ports seems to only filter by goos not goos goarch so it shows things like linux and linux as being first class which i don t think is true we don t even have linux big endian builders at the moment let s clarify ,1 +370260,25895992671.0,IssuesEvent,2022-12-14 22:31:04,golang/go,https://api.github.com/repos/golang/go,closed,spec: Document rules for recursive type and other self-referential decls,Documentation,"
The spec says "An interface type T may not embed itself or any interface type that +embeds T, recursively.", but nothing like this is mentioned for structs. + +(A struct containing itself would obviously need infty memory, but the spec should +probably still explicitly mention that these are illegal while a struct containing a +pointer to itself is fine+",1.0,"spec: Document rules for recursive type and other self-referential decls -
The spec says "An interface type T may not embed itself or any interface type that +embeds T, recursively.", but nothing like this is mentioned for structs. + +(A struct containing itself would obviously need infty memory, but the spec should +probably still explicitly mention that these are illegal while a struct containing a +pointer to itself is fine+",1,spec document rules for recursive type and other self referential decls the spec says quot an interface type t may not embed itself or any interface type that embeds t recursively quot but nothing like this is mentioned for structs a struct containing itself would obviously need infty memory but the spec should probably still explicitly mention that these are illegal while a struct containing a pointer to itself is fine ,1 +145587,11699464127.0,IssuesEvent,2020-03-06 15:41:12,golang/go,https://api.github.com/repos/golang/go,closed,x/text/unicode/norm: TestLinking consistently failing on multiple builders,NeedsInvestigation Testing,"See previously #32843. + +`TestLinking` appears to be failing consistently on the following builders: +* `linux-arm` (https://build.golang.org/log/367d5667c1ab0411c469fb3ff70496dec84e41e0) + ``` + normalize_test.go:937: tables appear not to be dropped: 1945437 - 1941429 = 4008 + ``` +* `linux-arm64-packet` (https://build.golang.org/log/a52ea14003e838e42ca1cd2b4082435838e79631) + ``` + normalize_test.go:937: tables appear not to be dropped: 2095708 - 2091220 = 4488 + ``` +* `linux-ppc64le-buildlet` (https://build.golang.org/log/6c896381e8a1c82f113eb45978ff309dd893513e) + ``` + normalize_test.go:937: tables appear not to be dropped: 2098114 - 2093534 = 4580 + ``` +* `linux-ppc64le-power9osu` (https://build.golang.org/log/8b01ed9d81fbc80df42ad31a20de438c946f9ec0) + ``` + normalize_test.go:937: tables appear not to be dropped: 2098114 - 2093534 = 4580 + ``` + +The failures are all similar, but the reported numbers vary by platform. + +If a test failure on these platforms is expected, the test should be skipped.",1.0,"x/text/unicode/norm: TestLinking consistently failing on multiple builders - See previously #32843. + +`TestLinking` appears to be failing consistently on the following builders: +* `linux-arm` (https://build.golang.org/log/367d5667c1ab0411c469fb3ff70496dec84e41e0) + ``` + normalize_test.go:937: tables appear not to be dropped: 1945437 - 1941429 = 4008 + ``` +* `linux-arm64-packet` (https://build.golang.org/log/a52ea14003e838e42ca1cd2b4082435838e79631) + ``` + normalize_test.go:937: tables appear not to be dropped: 2095708 - 2091220 = 4488 + ``` +* `linux-ppc64le-buildlet` (https://build.golang.org/log/6c896381e8a1c82f113eb45978ff309dd893513e) + ``` + normalize_test.go:937: tables appear not to be dropped: 2098114 - 2093534 = 4580 + ``` +* `linux-ppc64le-power9osu` (https://build.golang.org/log/8b01ed9d81fbc80df42ad31a20de438c946f9ec0) + ``` + normalize_test.go:937: tables appear not to be dropped: 2098114 - 2093534 = 4580 + ``` + +The failures are all similar, but the reported numbers vary by platform. + +If a test failure on these platforms is expected, the test should be skipped.",0,x text unicode norm testlinking consistently failing on multiple builders see previously testlinking appears to be failing consistently on the following builders linux arm normalize test go tables appear not to be dropped linux packet normalize test go tables appear not to be dropped linux buildlet normalize test go tables appear not to be dropped linux normalize test go tables appear not to be dropped the failures are all similar but the reported numbers vary by platform if a test failure on these platforms is expected the test should be skipped ,0 +276135,20970537493.0,IssuesEvent,2022-03-28 10:56:25,golang/go,https://api.github.com/repos/golang/go,closed,net/netip: inconsistent terminology for IPv4-mapped IPv6 addresses in documentation,Documentation help wanted NeedsFix," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.18 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What did you do? + +Read https://pkg.go.dev/net/netip@go1.18 + +### What did you expect to see? + +A consistent name for IPv4 addresses wrapped in IPv6 addresses. + +### What did you see instead? + +Many different names or phrases have appeared in the documentation, and they seem to refer to the same thing: + +- IPv4-mapped IPv6 address +- IP4-mapped IPv6 address +- IPv6-mapped IPv4 address +- v6-mapped form +- v6-mapped IPv6 address +- v6-mapped IPv4 IP + + + +",1.0,"net/netip: inconsistent terminology for IPv4-mapped IPv6 addresses in documentation - + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.18 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What did you do? + +Read https://pkg.go.dev/net/netip@go1.18 + +### What did you expect to see? + +A consistent name for IPv4 addresses wrapped in IPv6 addresses. + +### What did you see instead? + +Many different names or phrases have appeared in the documentation, and they seem to refer to the same thing: + +- IPv4-mapped IPv6 address +- IP4-mapped IPv6 address +- IPv6-mapped IPv4 address +- v6-mapped form +- v6-mapped IPv6 address +- v6-mapped IPv4 IP + + + +",1,net netip inconsistent terminology for mapped addresses in documentation please answer these questions before submitting your issue thanks what version of go are you using go version go version go version linux does this issue reproduce with the latest release yes what did you do read what did you expect to see a consistent name for addresses wrapped in addresses what did you see instead many different names or phrases have appeared in the documentation and they seem to refer to the same thing mapped address mapped address mapped address mapped form mapped address mapped ip ,1 +141113,12957747957.0,IssuesEvent,2020-07-20 10:12:20,golang/go,https://api.github.com/repos/golang/go,closed,x/xerrors: clarify documentation around stack frames ,Documentation NeedsInvestigation,"The docs for the `x/xerrors` package currently state + +``` +Most of the functions and types in this package will be incorporated into the standard library's errors package in Go 1.13; the behavior of this package's Errorf function will be incorporated into the standard library's fmt.Errorf. +``` + +This is not accurate. `fmt.Errorf` does _not_ provide the stack-trace functionality of `xerrors.Errorf`. Accordingly, I would suggest changing this docstring to + +``` +Most of the functions and types in this package have been incorporated into the standard library's errors package in Go 1.13. However, if you wish to retain the stack trace functionality of `xerrors.Errorf`, you will need to keep using this package. +```",1.0,"x/xerrors: clarify documentation around stack frames - The docs for the `x/xerrors` package currently state + +``` +Most of the functions and types in this package will be incorporated into the standard library's errors package in Go 1.13; the behavior of this package's Errorf function will be incorporated into the standard library's fmt.Errorf. +``` + +This is not accurate. `fmt.Errorf` does _not_ provide the stack-trace functionality of `xerrors.Errorf`. Accordingly, I would suggest changing this docstring to + +``` +Most of the functions and types in this package have been incorporated into the standard library's errors package in Go 1.13. However, if you wish to retain the stack trace functionality of `xerrors.Errorf`, you will need to keep using this package. +```",1,x xerrors clarify documentation around stack frames the docs for the x xerrors package currently state most of the functions and types in this package will be incorporated into the standard library s errors package in go the behavior of this package s errorf function will be incorporated into the standard library s fmt errorf this is not accurate fmt errorf does not provide the stack trace functionality of xerrors errorf accordingly i would suggest changing this docstring to most of the functions and types in this package have been incorporated into the standard library s errors package in go however if you wish to retain the stack trace functionality of xerrors errorf you will need to keep using this package ,1 +11043,3454719393.0,IssuesEvent,2015-12-17 17:00:15,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: document 'go generate' flags -n -v -x,Documentation,"Looking at https://tip.golang.org/cmd/go/#hdr-Generate_Go_files_by_processing_source right now: + +> Usage: +> +> ``` +> go generate [-run regexp] [file.go... | packages] +> ``` + +However, at the bottom it mentions: + +> It also accepts the standard build flags -v, -n, and -x. The -v flag prints the names of packages and files as they are processed. The -n flag prints commands that would be executed. The -x flag prints commands as they are executed. + +The usage line should be updated to mention those additional flags: + +```diff +-go generate [-run regexp] [file.go... | packages] ++go generate [-v] [-n] [-x] [-run regexp] [file.go... | packages] +``` + +Other commands have their usage complete and do not skip -n and -x flags that are available, for example: + +``` +go clean [-i] [-r] [-n] [-x] [build flags] [packages] +go fmt [-n] [-x] [packages] +go tool [-n] command [args...] +go vet [-n] [-x] [build flags] [packages] +go get [-d] [-f] [-fix] [-insecure] [-t] [-u] [build flags] [packages] +``` + +It seems -v is never included even if available, so maybe it's most consistent to do: + +``` +go generate [-n] [-x] [-run regexp] [file.go... | packages] +```",1.0,"cmd/go: document 'go generate' flags -n -v -x - Looking at https://tip.golang.org/cmd/go/#hdr-Generate_Go_files_by_processing_source right now: + +> Usage: +> +> ``` +> go generate [-run regexp] [file.go... | packages] +> ``` + +However, at the bottom it mentions: + +> It also accepts the standard build flags -v, -n, and -x. The -v flag prints the names of packages and files as they are processed. The -n flag prints commands that would be executed. The -x flag prints commands as they are executed. + +The usage line should be updated to mention those additional flags: + +```diff +-go generate [-run regexp] [file.go... | packages] ++go generate [-v] [-n] [-x] [-run regexp] [file.go... | packages] +``` + +Other commands have their usage complete and do not skip -n and -x flags that are available, for example: + +``` +go clean [-i] [-r] [-n] [-x] [build flags] [packages] +go fmt [-n] [-x] [packages] +go tool [-n] command [args...] +go vet [-n] [-x] [build flags] [packages] +go get [-d] [-f] [-fix] [-insecure] [-t] [-u] [build flags] [packages] +``` + +It seems -v is never included even if available, so maybe it's most consistent to do: + +``` +go generate [-n] [-x] [-run regexp] [file.go... | packages] +```",1,cmd go document go generate flags n v x looking at right now usage go generate however at the bottom it mentions it also accepts the standard build flags v n and x the v flag prints the names of packages and files as they are processed the n flag prints commands that would be executed the x flag prints commands as they are executed the usage line should be updated to mention those additional flags diff go generate go generate other commands have their usage complete and do not skip n and x flags that are available for example go clean go fmt go tool command go vet go get it seems v is never included even if available so maybe it s most consistent to do go generate ,1 +14384,3833096687.0,IssuesEvent,2016-04-01 00:49:00,golang/go,https://api.github.com/repos/golang/go,closed,"net/http: documentation of ""func (*Client) Do"" doesn't state clearly when to close response.Body",Documentation,"by **fish@freigeist.org**: + +
The documentation for Do()[1] says: + +"When err is nil, resp always contains a non-nil resp.Body." + +But it doesn't specify the behaviour if error is non-nil: +Do I need to close the Body if err is NOT nil? + + + + + + +--- +[1] https://godoc.org/net/http#Client.Do",1.0,"net/http: documentation of ""func (*Client) Do"" doesn't state clearly when to close response.Body - by **fish@freigeist.org**: + +
The documentation for Do()[1] says: + +"When err is nil, resp always contains a non-nil resp.Body." + +But it doesn't specify the behaviour if error is non-nil: +Do I need to close the Body if err is NOT nil? + + + + + + +--- +[1] https://godoc.org/net/http#Client.Do",1,net http documentation of func client do doesn t state clearly when to close response body by fish freigeist org the documentation for do says quot when err is nil resp always contains a non nil resp body quot but it doesn t specify the behaviour if error is non nil do i need to close the body if err is not nil a href ,1 +193106,15367368212.0,IssuesEvent,2021-03-02 03:08:44,golang/go,https://api.github.com/repos/golang/go,closed,x/website:https://golang.org/doc/code,Documentation NeedsFix help wanted,"Using https://golang.org/doc/code and Go 1.16. + +The part where you use `go install` does not automatically download the remote package. What you see is in the document is: + +``` +$ go install example.com/user/hello +go: finding module for package github.com/google/go-cmp/cmp +go: downloading github.com/google/go-cmp v0.4.0 +go: found github.com/google/go-cmp/cmp in github.com/google/go-cmp v0.4.0 +``` + +What I got was: + +``` +$ go install example.com/user/hello +hello.go:7:2: no required module provides package github.com/google/go-cmp/cmp; to add it: + go get github.com/google/go-cmp/cmp +``` + +After running `go get github.com/google/go-cmp/cmp`, rerunning produces: + +``` +$ go install example.com/user/hello +$ +``` + +If I am correct, I am happy to update the document. If I am wrong, happy to learn why! +",1.0,"x/website:https://golang.org/doc/code - Using https://golang.org/doc/code and Go 1.16. + +The part where you use `go install` does not automatically download the remote package. What you see is in the document is: + +``` +$ go install example.com/user/hello +go: finding module for package github.com/google/go-cmp/cmp +go: downloading github.com/google/go-cmp v0.4.0 +go: found github.com/google/go-cmp/cmp in github.com/google/go-cmp v0.4.0 +``` + +What I got was: + +``` +$ go install example.com/user/hello +hello.go:7:2: no required module provides package github.com/google/go-cmp/cmp; to add it: + go get github.com/google/go-cmp/cmp +``` + +After running `go get github.com/google/go-cmp/cmp`, rerunning produces: + +``` +$ go install example.com/user/hello +$ +``` + +If I am correct, I am happy to update the document. If I am wrong, happy to learn why! +",1,x website using and go the part where you use go install does not automatically download the remote package what you see is in the document is go install example com user hello go finding module for package github com google go cmp cmp go downloading github com google go cmp go found github com google go cmp cmp in github com google go cmp what i got was go install example com user hello hello go no required module provides package github com google go cmp cmp to add it go get github com google go cmp cmp after running go get github com google go cmp cmp rerunning produces go install example com user hello if i am correct i am happy to update the document if i am wrong happy to learn why ,1 +94525,10826081538.0,IssuesEvent,2019-11-09 20:08:48,golang/go,https://api.github.com/repos/golang/go,closed,crypto/tls: add an example for using VerifyPeerCertificate to customize verification logic,Documentation NeedsFix,"A number of proposals to add knobs to tls.Config were closed by providing a way to achieve the same result with InsecureSkipVerify and VerifyPeerCertificate. There should be a basic example that replicates the standard verification logic, so users can edit if needed.",1.0,"crypto/tls: add an example for using VerifyPeerCertificate to customize verification logic - A number of proposals to add knobs to tls.Config were closed by providing a way to achieve the same result with InsecureSkipVerify and VerifyPeerCertificate. There should be a basic example that replicates the standard verification logic, so users can edit if needed.",1,crypto tls add an example for using verifypeercertificate to customize verification logic a number of proposals to add knobs to tls config were closed by providing a way to achieve the same result with insecureskipverify and verifypeercertificate there should be a basic example that replicates the standard verification logic so users can edit if needed ,1 +28503,13726351203.0,IssuesEvent,2020-10-03 23:13:32,golang/go,https://api.github.com/repos/golang/go,opened,cmd/compile: introduce masked memeq,Performance,"This is an idea to experiment with. I don't know whether it'll yield enough fruit to be worth the added code. + +Consider this type: + +``` +type T struct { + x uint64 + b bool +} +``` + +Arrays of `T` require generated alg routines. This is because x has a required alignment of 8, so there's a 7 byte gap between Ts in the array, so we can't use one big memeq call. + +We could, however, introduce a masked memeq, to which the compiler passes not only the length of the memory to compare but also a repeating mask, probably of a fixed size. For T, the mask would be something like `1111111110000000` (nine 1s, seven 0s). When comparing memory the routine would load bytes from memory, mask out some of the bytes, and then do the comparison. This is the kind of thing that SIMD instructions excel at on many platforms. + +This would also work for structs containing blank fields (fields named _). + +This could also work for hash routines: Mask out bytes before feeding them to the regular hash routine. + +We could also use this as the first step in other alg routines. For example, `[8]string`'s equality function could start by calling memeqmask with a size of 8*8*2 (on 64 bit systems) and a mask of `1111111100000000` (eight 1s, eight 0s), to compare all the lengths. Then it could do its second loop to compare all the contents. + +cc @martisch @randall77 +",True,"cmd/compile: introduce masked memeq - This is an idea to experiment with. I don't know whether it'll yield enough fruit to be worth the added code. + +Consider this type: + +``` +type T struct { + x uint64 + b bool +} +``` + +Arrays of `T` require generated alg routines. This is because x has a required alignment of 8, so there's a 7 byte gap between Ts in the array, so we can't use one big memeq call. + +We could, however, introduce a masked memeq, to which the compiler passes not only the length of the memory to compare but also a repeating mask, probably of a fixed size. For T, the mask would be something like `1111111110000000` (nine 1s, seven 0s). When comparing memory the routine would load bytes from memory, mask out some of the bytes, and then do the comparison. This is the kind of thing that SIMD instructions excel at on many platforms. + +This would also work for structs containing blank fields (fields named _). + +This could also work for hash routines: Mask out bytes before feeding them to the regular hash routine. + +We could also use this as the first step in other alg routines. For example, `[8]string`'s equality function could start by calling memeqmask with a size of 8*8*2 (on 64 bit systems) and a mask of `1111111100000000` (eight 1s, eight 0s), to compare all the lengths. Then it could do its second loop to compare all the contents. + +cc @martisch @randall77 +",0,cmd compile introduce masked memeq this is an idea to experiment with i don t know whether it ll yield enough fruit to be worth the added code consider this type type t struct x b bool arrays of t require generated alg routines this is because x has a required alignment of so there s a byte gap between ts in the array so we can t use one big memeq call we could however introduce a masked memeq to which the compiler passes not only the length of the memory to compare but also a repeating mask probably of a fixed size for t the mask would be something like nine seven when comparing memory the routine would load bytes from memory mask out some of the bytes and then do the comparison this is the kind of thing that simd instructions excel at on many platforms this would also work for structs containing blank fields fields named this could also work for hash routines mask out bytes before feeding them to the regular hash routine we could also use this as the first step in other alg routines for example string s equality function could start by calling memeqmask with a size of on bit systems and a mask of eight eight to compare all the lengths then it could do its second loop to compare all the contents cc martisch ,0 +211419,16444338085.0,IssuesEvent,2021-05-20 17:41:36,golang/go,https://api.github.com/repos/golang/go,closed,doc/go1.17: document os changes for Go 1.17,Documentation NeedsInvestigation help wanted release-blocker,"As of filing this issue, the [Go 1.17 draft release notes](https://tip.golang.org/doc/go1.17) contained the following HTML: + +
+ TODO: https://golang.org/cl/268020: avoid allocation in File.WriteString +
++ TODO: https://golang.org/cl/268020: avoid allocation in File.WriteString +
++$ go version +go version go1.13rc1 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN=""/home/leighmcculloch/local/bin"" +GOCACHE=""/home/leighmcculloch/.cache/go-build"" +GOENV=""/home/leighmcculloch/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/leighmcculloch/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/home/leighmcculloch/local/bin/go/1.13rc1"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/home/leighmcculloch/local/bin/go/1.13rc1/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/leighmcculloch/devel/test/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build749101513=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.13rc1 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN=""/home/leighmcculloch/local/bin"" +GOCACHE=""/home/leighmcculloch/.cache/go-build"" +GOENV=""/home/leighmcculloch/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/leighmcculloch/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/home/leighmcculloch/local/bin/go/1.13rc1"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/home/leighmcculloch/local/bin/go/1.13rc1/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/leighmcculloch/devel/test/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build749101513=/tmp/go-build -gno-record-gcc-switches"" +
+go version go1.13 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+go env +GO111MODULE=""on"" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/tschinke/Library/Caches/go-build"" +GOENV=""/Users/tschinke/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/tschinke/go"" +GOPRIVATE="""" +GOPROXY=""direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/tschinke/repos/wdy_ausbildung/trainiety/app/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/bv/6rt5ck194ls704dz9p4c0hlh0000gn/T/go-build951955169=/tmp/go-build -gno-record-gcc-switches -fno-common"" + + +
+go version go1.13 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+go env +GO111MODULE=""on"" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/tschinke/Library/Caches/go-build"" +GOENV=""/Users/tschinke/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/tschinke/go"" +GOPRIVATE="""" +GOPROXY=""direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/tschinke/repos/wdy_ausbildung/trainiety/app/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/bv/6rt5ck194ls704dz9p4c0hlh0000gn/T/go-build951955169=/tmp/go-build -gno-record-gcc-switches -fno-common"" + + +
+$ go version +go version go1.13.4 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN=""/Users/steele/go/bin"" +GOCACHE=""/Users/steele/Library/Caches/go-build"" +GOENV=""/Users/steele/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/steele/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/steele/conversion-service/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/m7/ks10ly_j20g2tphn554wvdcm0000gn/T/go-build947817871=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
+$ go version +go version go1.13.4 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN=""/Users/steele/go/bin"" +GOCACHE=""/Users/steele/Library/Caches/go-build"" +GOENV=""/Users/steele/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/steele/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/steele/conversion-service/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/m7/ks10ly_j20g2tphn554wvdcm0000gn/T/go-build947817871=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
http://play.golang.org/p/YfvMjcI7b5 + + +Errors from that code are unhelpful, and the documentation for +* http://golang.org/pkg/text/template/#New +* http://golang.org/pkg/text/template/#Template.ParseFiles + + +No mention is made in the docs that when using .New() and then .ParseFiles(), the +orginal temaplte's name needs to tbe the same as the base name of the first file.",1.0,"text/template: improve documentation for creating templates - by **Shifter1**: + +
http://play.golang.org/p/YfvMjcI7b5 + + +Errors from that code are unhelpful, and the documentation for +* http://golang.org/pkg/text/template/#New +* http://golang.org/pkg/text/template/#Template.ParseFiles + + +No mention is made in the docs that when using .New() and then .ParseFiles(), the +orginal temaplte's name needs to tbe the same as the base name of the first file.",1,text template improve documentation for creating templates by a href errors from that code are unhelpful and the documentation for a href a href no mention is made in the docs that when using new and then parsefiles the orginal temaplte s name needs to tbe the same as the base name of the first file ,1 +42459,22616125151.0,IssuesEvent,2022-06-29 22:20:37,golang/go,https://api.github.com/repos/golang/go,closed,go/token: AddFile induces heavy contention in parallel parsing [freeze exception],Performance NeedsFix release-blocker,"https://go-review.googlesource.com/c/go/+/411909 reduces two sources of contention in parser-heavy workloads: FileSet.AddFile allocates memory in the middle of an otherwise tiny critical section, and FileSet.Pos uses a mutex to guard a cache, turning read-only operations into exclusive locks. Both are major sources of contention in gopls. + +I'd like to include the fix in the next release. + + +@golang/release @gri @findleyr ",True,"go/token: AddFile induces heavy contention in parallel parsing [freeze exception] - https://go-review.googlesource.com/c/go/+/411909 reduces two sources of contention in parser-heavy workloads: FileSet.AddFile allocates memory in the middle of an otherwise tiny critical section, and FileSet.Pos uses a mutex to guard a cache, turning read-only operations into exclusive locks. Both are major sources of contention in gopls. + +I'd like to include the fix in the next release. + + +@golang/release @gri @findleyr ",0,go token addfile induces heavy contention in parallel parsing reduces two sources of contention in parser heavy workloads fileset addfile allocates memory in the middle of an otherwise tiny critical section and fileset pos uses a mutex to guard a cache turning read only operations into exclusive locks both are major sources of contention in gopls i d like to include the fix in the next release golang release gri findleyr ,0 +52348,7759306146.0,IssuesEvent,2018-05-31 22:49:05,golang/go,https://api.github.com/repos/golang/go,closed,doc: archive/zip: *Writer.Close wording,Documentation NeedsInvestigation,"The documentation for *Writer.Close states: + +> Close finishes writing the zip file by writing the central directory. It does not (and cannot) close the underlying writer. + +The ""(and cannot)"" seems unnecessary, and differs from the docs of other Close methods in the standard library.",1.0,"doc: archive/zip: *Writer.Close wording - The documentation for *Writer.Close states: + +> Close finishes writing the zip file by writing the central directory. It does not (and cannot) close the underlying writer. + +The ""(and cannot)"" seems unnecessary, and differs from the docs of other Close methods in the standard library.",1,doc archive zip writer close wording the documentation for writer close states close finishes writing the zip file by writing the central directory it does not and cannot close the underlying writer the and cannot seems unnecessary and differs from the docs of other close methods in the standard library ,1 +263631,19956732239.0,IssuesEvent,2022-01-28 00:45:22,golang/go,https://api.github.com/repos/golang/go,closed,x/website: Effective Go needs to have a preamble re: generics,Documentation NeedsFix release-blocker,"[Effective Go](https://go.dev/doc/effective_go) needs to be updated with a preamble/disclaimer as it was not written with generics in mind. + +cc: @robpike ",1.0,"x/website: Effective Go needs to have a preamble re: generics - [Effective Go](https://go.dev/doc/effective_go) needs to be updated with a preamble/disclaimer as it was not written with generics in mind. + +cc: @robpike ",1,x website effective go needs to have a preamble re generics needs to be updated with a preamble disclaimer as it was not written with generics in mind cc robpike ,1 +28246,5444462009.0,IssuesEvent,2017-03-07 02:53:38,golang/go,https://api.github.com/repos/golang/go,closed,encoding/base64: document that padchar cannot be multi-byte,Documentation,"### What version of Go are you using (`go version`)? +Go 1.8 + +### What did you expect to see? +Looking at encoding/base64 we see that WithPadding accepts a rune: +https://golang.org/pkg/encoding/base64/#Encoding.WithPadding + +Looking at the current implementation, the padding character can not be a multi-byte rune as the code compare bytes with padChar: https://github.com/golang/go/blob/87b1aaa37cefec8deacdf9c3c30d26015bdfb00b/src/encoding/base64/base64.go#L285 + +### What did you see instead? +I would like the documentation to be changed so it's explicit that we don't support multi-byte padding characters as I don't think it makes sense. +",1.0,"encoding/base64: document that padchar cannot be multi-byte - ### What version of Go are you using (`go version`)? +Go 1.8 + +### What did you expect to see? +Looking at encoding/base64 we see that WithPadding accepts a rune: +https://golang.org/pkg/encoding/base64/#Encoding.WithPadding + +Looking at the current implementation, the padding character can not be a multi-byte rune as the code compare bytes with padChar: https://github.com/golang/go/blob/87b1aaa37cefec8deacdf9c3c30d26015bdfb00b/src/encoding/base64/base64.go#L285 + +### What did you see instead? +I would like the documentation to be changed so it's explicit that we don't support multi-byte padding characters as I don't think it makes sense. +",1,encoding document that padchar cannot be multi byte what version of go are you using go version go what did you expect to see looking at encoding we see that withpadding accepts a rune looking at the current implementation the padding character can not be a multi byte rune as the code compare bytes with padchar what did you see instead i would like the documentation to be changed so it s explicit that we don t support multi byte padding characters as i don t think it makes sense ,1 +72151,19043005898.0,IssuesEvent,2021-11-25 01:52:39,golang/go,https://api.github.com/repos/golang/go,closed,x/build: add a Windows ARM32 builder,Builders NeedsInvestigation new-builder,"Per https://github.com/golang/go/issues/42604#issuecomment-848870326 and https://github.com/golang/go/issues/42604#issuecomment-849186123, my builder will be decommissioned quite soon. This issue is to track spinning up of a builder on Google infrastructure, using the new ARM64 systems to run `GOOS=windows GOARCH=arm GOARM=7`. My builder was just running the 32-bit tests on the normal 64-bit OS. The replacement builder can do the same. There shouldn't be much work to do for this, as it's already been done for #42604. + +CC @toothrot @dmitshur @cagedmantis ",2.0,"x/build: add a Windows ARM32 builder - Per https://github.com/golang/go/issues/42604#issuecomment-848870326 and https://github.com/golang/go/issues/42604#issuecomment-849186123, my builder will be decommissioned quite soon. This issue is to track spinning up of a builder on Google infrastructure, using the new ARM64 systems to run `GOOS=windows GOARCH=arm GOARM=7`. My builder was just running the 32-bit tests on the normal 64-bit OS. The replacement builder can do the same. There shouldn't be much work to do for this, as it's already been done for #42604. + +CC @toothrot @dmitshur @cagedmantis ",0,x build add a windows builder per and my builder will be decommissioned quite soon this issue is to track spinning up of a builder on google infrastructure using the new systems to run goos windows goarch arm goarm my builder was just running the bit tests on the normal bit os the replacement builder can do the same there shouldn t be much work to do for this as it s already been done for cc toothrot dmitshur cagedmantis ,0 +56909,8130483924.0,IssuesEvent,2018-08-17 18:39:14,golang/go,https://api.github.com/repos/golang/go,closed,doc: document go/build vs golang.org/x/tools/go/packages,Documentation NeedsFix release-blocker,"Per https://tip.golang.org/doc/go1.11#gopackages: + +> TODO: Note about go/build versus golang.org/x/tools/go/packages.",1.0,"doc: document go/build vs golang.org/x/tools/go/packages - Per https://tip.golang.org/doc/go1.11#gopackages: + +> TODO: Note about go/build versus golang.org/x/tools/go/packages.",1,doc document go build vs golang org x tools go packages per todo note about go build versus golang org x tools go packages ,1 +335461,24469059360.0,IssuesEvent,2022-10-07 17:50:20,golang/go,https://api.github.com/repos/golang/go,closed,testing: add an example showcasing B.RunParallel with B.ReportMetric,Suggested Documentation NeedsFix,"I had a parallel benchmark in the form of: + +``` +var totalFoo int64 +b.RunParallel(func(pb *testing.PB) { + for pb.Next() { + // benchmark... + totalFoo += someFoo() + } +}) +b.ReportMetric(float64(totalAmount)/float64(b.N), ""foo/op"") +``` + +I was taking a second look at the benchmark because dividing by `b.N` seemed fishy. This is a parallel benchmark, where I iterate via `pb.Next` and not `b.N`, so can I rely on `b.N` being an accurate detail of how many iterations were run across all goroutines? + +The docs seem to imply so: + +> RunParallel runs a benchmark in parallel. It creates multiple goroutines and distributes b.N iterations among them. + +> ReportMetric adds ""n unit"" to the reported benchmark results. If the metric is per-iteration, the caller should divide by b.N + +Still, I had to re-read the docs multiple times to convince myself. I think it would be nice to add an example on ReportMetric for parallel benchmarks, such as `func ExampleB_ReportMetric_parallel`, to help clarify the interaction between the two and how they are meant to be used. + +And there's another reason why an example would be good: since `RunParallel` hides the goroutine spawning from the user, it's relatively easy to introduce data races by mistake, like I did above! `totalFoo += someFoo()` would need to be something like `atomic.AddInt64(&totalFoo, someFoo())`. The example could also show that. + +Marking as a good candidate for first time contributors. Happy to review it too. + +cc @mpvl per https://dev.golang.org/owners",1.0,"testing: add an example showcasing B.RunParallel with B.ReportMetric - I had a parallel benchmark in the form of: + +``` +var totalFoo int64 +b.RunParallel(func(pb *testing.PB) { + for pb.Next() { + // benchmark... + totalFoo += someFoo() + } +}) +b.ReportMetric(float64(totalAmount)/float64(b.N), ""foo/op"") +``` + +I was taking a second look at the benchmark because dividing by `b.N` seemed fishy. This is a parallel benchmark, where I iterate via `pb.Next` and not `b.N`, so can I rely on `b.N` being an accurate detail of how many iterations were run across all goroutines? + +The docs seem to imply so: + +> RunParallel runs a benchmark in parallel. It creates multiple goroutines and distributes b.N iterations among them. + +> ReportMetric adds ""n unit"" to the reported benchmark results. If the metric is per-iteration, the caller should divide by b.N + +Still, I had to re-read the docs multiple times to convince myself. I think it would be nice to add an example on ReportMetric for parallel benchmarks, such as `func ExampleB_ReportMetric_parallel`, to help clarify the interaction between the two and how they are meant to be used. + +And there's another reason why an example would be good: since `RunParallel` hides the goroutine spawning from the user, it's relatively easy to introduce data races by mistake, like I did above! `totalFoo += someFoo()` would need to be something like `atomic.AddInt64(&totalFoo, someFoo())`. The example could also show that. + +Marking as a good candidate for first time contributors. Happy to review it too. + +cc @mpvl per https://dev.golang.org/owners",1,testing add an example showcasing b runparallel with b reportmetric i had a parallel benchmark in the form of var totalfoo b runparallel func pb testing pb for pb next benchmark totalfoo somefoo b reportmetric totalamount b n foo op i was taking a second look at the benchmark because dividing by b n seemed fishy this is a parallel benchmark where i iterate via pb next and not b n so can i rely on b n being an accurate detail of how many iterations were run across all goroutines the docs seem to imply so runparallel runs a benchmark in parallel it creates multiple goroutines and distributes b n iterations among them reportmetric adds n unit to the reported benchmark results if the metric is per iteration the caller should divide by b n still i had to re read the docs multiple times to convince myself i think it would be nice to add an example on reportmetric for parallel benchmarks such as func exampleb reportmetric parallel to help clarify the interaction between the two and how they are meant to be used and there s another reason why an example would be good since runparallel hides the goroutine spawning from the user it s relatively easy to introduce data races by mistake like i did above totalfoo somefoo would need to be something like atomic totalfoo somefoo the example could also show that marking as a good candidate for first time contributors happy to review it too cc mpvl per ,1 +3404,2762330882.0,IssuesEvent,2015-04-28 22:00:15,golang/go,https://api.github.com/repos/golang/go,closed,net/http: PostForm docs should mention PATCH method,Documentation,"The `net/http` parses the request body for the PATCH HTTP method [for quite some time now](https://codereview.appspot.com/70990044). +I think the docs should mention that `PostForm` is available not only for POST and PUT but also for PATCH, that users don't need to dig into the code to discover that. +gov1.4.1 +",1.0,"net/http: PostForm docs should mention PATCH method - The `net/http` parses the request body for the PATCH HTTP method [for quite some time now](https://codereview.appspot.com/70990044). +I think the docs should mention that `PostForm` is available not only for POST and PUT but also for PATCH, that users don't need to dig into the code to discover that. +gov1.4.1 +",1,net http postform docs should mention patch method the net http parses the request body for the patch http method i think the docs should mention that postform is available not only for post and put but also for patch that users don t need to dig into the code to discover that ,1 +389619,26825754641.0,IssuesEvent,2023-02-02 12:46:02,golang/go,https://api.github.com/repos/golang/go,closed,go1.20: no docs for golang.org/x/crypto/x509roots/fallback,Documentation," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.20 darwin/arm64 ++ +### Does this issue reproduce with the latest release? + +yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""arm64"" +GOBIN="""" +GOCACHE=""/Users/andig/Library/Caches/go-build"" +GOENV=""/Users/andig/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""arm64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/andig/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/andig/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_arm64"" +GOVCS="""" +GOVERSION=""go1.20"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/andig/htdocs/evcc/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-O2 -g"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-O2 -g"" +CGO_FFLAGS=""-O2 -g"" +CGO_LDFLAGS=""-O2 -g"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch arm64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/sv/rs_453y57xj86xsbz3kw1mbc0000gn/T/go-build1228287512=/tmp/go-build -gno-record-gcc-switches -fno-common"" +GOROOT/bin/go version: go version go1.20 darwin/arm64 +GOROOT/bin/go tool compile -V: compile version go1.20 +uname -v: Darwin Kernel Version 22.2.0: Fri Nov 11 02:04:44 PST 2022; root:xnu-8792.61.2~4/RELEASE_ARM64_T8103 +ProductName: macOS +ProductVersion: 13.1 +BuildVersion: 22C65 +lldb --version: lldb-1400.0.38.17 +Apple Swift version 5.7.2 (swiftlang-5.7.2.135.5 clang-1400.0.29.51) +
+$ go version +go version go1.20 darwin/arm64 ++ +### Does this issue reproduce with the latest release? + +yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""arm64"" +GOBIN="""" +GOCACHE=""/Users/andig/Library/Caches/go-build"" +GOENV=""/Users/andig/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""arm64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/andig/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/andig/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_arm64"" +GOVCS="""" +GOVERSION=""go1.20"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/andig/htdocs/evcc/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-O2 -g"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-O2 -g"" +CGO_FFLAGS=""-O2 -g"" +CGO_LDFLAGS=""-O2 -g"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch arm64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/sv/rs_453y57xj86xsbz3kw1mbc0000gn/T/go-build1228287512=/tmp/go-build -gno-record-gcc-switches -fno-common"" +GOROOT/bin/go version: go version go1.20 darwin/arm64 +GOROOT/bin/go tool compile -V: compile version go1.20 +uname -v: Darwin Kernel Version 22.2.0: Fri Nov 11 02:04:44 PST 2022; root:xnu-8792.61.2~4/RELEASE_ARM64_T8103 +ProductName: macOS +ProductVersion: 13.1 +BuildVersion: 22C65 +lldb --version: lldb-1400.0.38.17 +Apple Swift version 5.7.2 (swiftlang-5.7.2.135.5 clang-1400.0.29.51) +
+(I'm not sure if making issues about draft documents is allowed, so +please feel free to close.) +
++https://tip.golang.org/doc/go1.14 +doesn't seem to mention the new RISC-V port anywhere. AFAIK, the port +will probably enter Go 1.14 in some way, even if highly experimental, so +I think it needs to be documented. +
+",1.0,"doc/go1.14: RISC-V status -
+(I'm not sure if making issues about draft documents is allowed, so +please feel free to close.) +
++https://tip.golang.org/doc/go1.14 +doesn't seem to mention the new RISC-V port anywhere. AFAIK, the port +will probably enter Go 1.14 in some way, even if highly experimental, so +I think it needs to be documented. +
+",1,doc risc v status i m not sure if making issues about draft documents is allowed so please feel free to close a href doesn t seem to mention the new risc v port anywhere afaik the port will probably enter go in some way even if highly experimental so i think it needs to be documented ,1 +5883,5198995154.0,IssuesEvent,2017-01-23 19:39:51,golang/go,https://api.github.com/repos/golang/go,closed,cmd/compile: 63% benchmark slowdown in 1.7 -> 1.8rc2,Performance,"Please answer these questions before submitting your issue. Thanks! + +### What version of Go are you using (`go version`)? +$ go version +go version go1.7 darwin/amd64 + +$ go1.8rc2 version +go version go1.8rc2 darwin/amd64 + +### What operating system and processor architecture are you using (`go env`)? +$ go env +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/smansfield/gopkg"" +GORACE="""" +GOROOT=""/usr/local/Cellar/go/1.7/libexec"" +GOTOOLDIR=""/usr/local/Cellar/go/1.7/libexec/pkg/tool/darwin_amd64"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/f2/wwlcfvc5267dkl3c2_5_mcsw0000gp/T/go-build461692826=/tmp/go-build -gno-record-gcc-switches -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" + +### What did you do? +If possible, provide a recipe for reproducing the error. +A complete runnable program is good. +A link on play.golang.org is best. + +I have the disasm output for both 1.7 and 1.8 with a command to run benchtime 10s + +1.7: https://play.golang.org/p/N04n8MwmS4 + +1.8: https://play.golang.org/p/sZpOz59PbS + +### What did you expect to see? +Approximately equal or better performance + +### What did you see instead? +Worse performance by far for 1.8, by 63% - 65% + +What's interesting in the 1.8 output is that the profiling shows a single MOVL taking 4.98 of the 9.37 seconds + +4.98s 1144938: MOVL 0x30(SP), CX + +Unfortunately the code to do all this is private, but I might be able to extract an example if it's necessary. Right now I don't have one outside my project.",True,"cmd/compile: 63% benchmark slowdown in 1.7 -> 1.8rc2 - Please answer these questions before submitting your issue. Thanks! + +### What version of Go are you using (`go version`)? +$ go version +go version go1.7 darwin/amd64 + +$ go1.8rc2 version +go version go1.8rc2 darwin/amd64 + +### What operating system and processor architecture are you using (`go env`)? +$ go env +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/smansfield/gopkg"" +GORACE="""" +GOROOT=""/usr/local/Cellar/go/1.7/libexec"" +GOTOOLDIR=""/usr/local/Cellar/go/1.7/libexec/pkg/tool/darwin_amd64"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/f2/wwlcfvc5267dkl3c2_5_mcsw0000gp/T/go-build461692826=/tmp/go-build -gno-record-gcc-switches -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" + +### What did you do? +If possible, provide a recipe for reproducing the error. +A complete runnable program is good. +A link on play.golang.org is best. + +I have the disasm output for both 1.7 and 1.8 with a command to run benchtime 10s + +1.7: https://play.golang.org/p/N04n8MwmS4 + +1.8: https://play.golang.org/p/sZpOz59PbS + +### What did you expect to see? +Approximately equal or better performance + +### What did you see instead? +Worse performance by far for 1.8, by 63% - 65% + +What's interesting in the 1.8 output is that the profiling shows a single MOVL taking 4.98 of the 9.37 seconds + +4.98s 1144938: MOVL 0x30(SP), CX + +Unfortunately the code to do all this is private, but I might be able to extract an example if it's necessary. Right now I don't have one outside my project.",0,cmd compile benchmark slowdown in please answer these questions before submitting your issue thanks what version of go are you using go version go version go version darwin version go version darwin what operating system and processor architecture are you using go env go env goarch gobin goexe gohostarch gohostos darwin goos darwin gopath users smansfield gopkg gorace goroot usr local cellar go libexec gotooldir usr local cellar go libexec pkg tool darwin cc clang gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map var folders t go tmp go build gno record gcc switches fno common cxx clang cgo enabled what did you do if possible provide a recipe for reproducing the error a complete runnable program is good a link on play golang org is best i have the disasm output for both and with a command to run benchtime what did you expect to see approximately equal or better performance what did you see instead worse performance by far for by what s interesting in the output is that the profiling shows a single movl taking of the seconds movl sp cx unfortunately the code to do all this is private but i might be able to extract an example if it s necessary right now i don t have one outside my project ,0 +55370,7978387939.0,IssuesEvent,2018-07-17 18:09:41,golang/go,https://api.github.com/repos/golang/go,closed,x/tools/cmd/godoc: show which version of Go introduced symbols,Documentation FeatureRequest NeedsFix help wanted,"
Go documentation is very good, but it doesn't clearly label which go version features +are available in. + +For instance I was caught out by http://golang.org/pkg/time/#Timer.Reset being a go 1.1 +feature which meant my code would no longer compile with go 1.0. + +Other examples are + + * http://golang.org/pkg/net/http/#Transport.CancelRequest + * ResponseHeaderTimeout in http://golang.org/pkg/net/http/#Transport+",1.0,"x/tools/cmd/godoc: show which version of Go introduced symbols -
Go documentation is very good, but it doesn't clearly label which go version features +are available in. + +For instance I was caught out by http://golang.org/pkg/time/#Timer.Reset being a go 1.1 +feature which meant my code would no longer compile with go 1.0. + +Other examples are + + * http://golang.org/pkg/net/http/#Transport.CancelRequest + * ResponseHeaderTimeout in http://golang.org/pkg/net/http/#Transport+",1,x tools cmd godoc show which version of go introduced symbols go documentation is very good but it doesn t clearly label which go version features are available in for instance i was caught out by a href being a go feature which meant my code would no longer compile with go other examples are a href responseheadertimeout in a href ,1 +246163,18837853004.0,IssuesEvent,2021-11-11 04:48:10,golang/go,https://api.github.com/repos/golang/go,closed,sync: clarify if it's valid to call Map methods inside the Map.Range callback,Documentation help wanted NeedsFix,"Map is documented as safe for concurrent use, so I understand it is safe to call a method like LoadAndDelete while Range is running in another goroutine, for example. + +However, what isn't clear is whether I can call a method like LoadAndDelete in Range's callback. Technically it's not a concurrent call, as it's happening on the same goroutine - it's just a nested call, as it happens within Range. + +Is that supported? From my reading of the code it seems like it shouldn't cause a data race. I wonder if it could lead to undesirable effects however, such as if I delete a key that I haven't ranged over yet, or if I keep adding more keys and potentially make the range run for a long time. + +I don't know what the answer is or what it should be, but I think the docs could be a bit clearer. + +cc @rsc @ianlancetaylor @dvyukov @aclements as per https://dev.golang.org/owners",1.0,"sync: clarify if it's valid to call Map methods inside the Map.Range callback - Map is documented as safe for concurrent use, so I understand it is safe to call a method like LoadAndDelete while Range is running in another goroutine, for example. + +However, what isn't clear is whether I can call a method like LoadAndDelete in Range's callback. Technically it's not a concurrent call, as it's happening on the same goroutine - it's just a nested call, as it happens within Range. + +Is that supported? From my reading of the code it seems like it shouldn't cause a data race. I wonder if it could lead to undesirable effects however, such as if I delete a key that I haven't ranged over yet, or if I keep adding more keys and potentially make the range run for a long time. + +I don't know what the answer is or what it should be, but I think the docs could be a bit clearer. + +cc @rsc @ianlancetaylor @dvyukov @aclements as per https://dev.golang.org/owners",1,sync clarify if it s valid to call map methods inside the map range callback map is documented as safe for concurrent use so i understand it is safe to call a method like loadanddelete while range is running in another goroutine for example however what isn t clear is whether i can call a method like loadanddelete in range s callback technically it s not a concurrent call as it s happening on the same goroutine it s just a nested call as it happens within range is that supported from my reading of the code it seems like it shouldn t cause a data race i wonder if it could lead to undesirable effects however such as if i delete a key that i haven t ranged over yet or if i keep adding more keys and potentially make the range run for a long time i don t know what the answer is or what it should be but i think the docs could be a bit clearer cc rsc ianlancetaylor dvyukov aclements as per ,1 +212963,16505752816.0,IssuesEvent,2021-05-25 19:04:41,golang/go,https://api.github.com/repos/golang/go,closed,doc/go1.17: document closure inlining affects function PC comparison,Documentation NeedsFix okay-after-beta1," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version devel go1.17-d5d24dbe41 Mon Apr 26 17:13:36 2021 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +only master + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +~/go/src/playground/at-2021-04-26-204402 $ ~/Code/go/bin/go env +GO111MODULE=""on"" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/rski/.cache/go-build"" +GOENV=""/home/rski/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/rski/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB=""="" +GOOS=""linux"" +GOPATH=""/home/rski/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/home/rski/Code/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/home/rski/Code/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""devel go1.17-d5d24dbe41 Mon Apr 26 17:13:36 2021 +0000"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""0"" +GOMOD=""/home/rski/go/src/playground/at-2021-04-26-204402/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build2782832869=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version devel go1.17-d5d24dbe41 Mon Apr 26 17:13:36 2021 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +only master + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +~/go/src/playground/at-2021-04-26-204402 $ ~/Code/go/bin/go env +GO111MODULE=""on"" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/rski/.cache/go-build"" +GOENV=""/home/rski/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/rski/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB=""="" +GOOS=""linux"" +GOPATH=""/home/rski/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/home/rski/Code/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/home/rski/Code/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""devel go1.17-d5d24dbe41 Mon Apr 26 17:13:36 2021 +0000"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""0"" +GOMOD=""/home/rski/go/src/playground/at-2021-04-26-204402/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build2782832869=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.16 ++ +### Does this issue reproduce with the latest release? +Yes + +### What did you do? +I were working with a module using command `go mod`; i expected that i can update dependency with commands: +`go mod update -u
+$ go version +go version go1.16 ++ +### Does this issue reproduce with the latest release? +Yes + +### What did you do? +I were working with a module using command `go mod`; i expected that i can update dependency with commands: +`go mod update -u
+$ go version +go version go1.13 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +It reproduces on play.golang.org and the underlying issue is still present in the source. + +### What operating system and processor architecture are you using (`go env`)? + +darwin/amd64 + +### What did you do? + +Parsed a faulty ISO 8601 string with a single-digit hour using `time.RFC3339`. E.g. `2020-02-02T2:02:02Z`. + + +### What did you expect to see? + +I expected this parse to error because [RFC-3339 sec 5.6](https://tools.ietf.org/html/rfc3339#section-5.6) defines the following token, requiring two digits for the hour: +``` +time-hour = 2DIGIT ; 00-23 +``` + +### What did you see instead? + +The parse succeeded. + +This could be fixed by changing `time.RFC3339` to `2006-01-02T03:04:05Z07:00`. If this is deemed a backward incompatible change, adding a new `time.RFC3339Strict` constant would also be an acceptable option. + +See https://play.golang.org/p/6qyFYfx6pMr for example with one and two-digit years with `time.Parse3339` and the stricter version.",1.0,"time: document that RFC3339 accepts invalid formats when used with Parse - + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.13 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +It reproduces on play.golang.org and the underlying issue is still present in the source. + +### What operating system and processor architecture are you using (`go env`)? + +darwin/amd64 + +### What did you do? + +Parsed a faulty ISO 8601 string with a single-digit hour using `time.RFC3339`. E.g. `2020-02-02T2:02:02Z`. + + +### What did you expect to see? + +I expected this parse to error because [RFC-3339 sec 5.6](https://tools.ietf.org/html/rfc3339#section-5.6) defines the following token, requiring two digits for the hour: +``` +time-hour = 2DIGIT ; 00-23 +``` + +### What did you see instead? + +The parse succeeded. + +This could be fixed by changing `time.RFC3339` to `2006-01-02T03:04:05Z07:00`. If this is deemed a backward incompatible change, adding a new `time.RFC3339Strict` constant would also be an acceptable option. + +See https://play.golang.org/p/6qyFYfx6pMr for example with one and two-digit years with `time.Parse3339` and the stricter version.",1,time document that accepts invalid formats when used with parse please answer these questions before submitting your issue thanks for questions please use one of our forums what version of go are you using go version go version go version darwin does this issue reproduce with the latest release it reproduces on play golang org and the underlying issue is still present in the source what operating system and processor architecture are you using go env darwin what did you do parsed a faulty iso string with a single digit hour using time e g what did you expect to see i expected this parse to error because defines the following token requiring two digits for the hour time hour what did you see instead the parse succeeded this could be fixed by changing time to if this is deemed a backward incompatible change adding a new time constant would also be an acceptable option see for example with one and two digit years with time and the stricter version ,1 +174243,13463579481.0,IssuesEvent,2020-09-09 17:49:33,golang/go,https://api.github.com/repos/golang/go,closed,"runtime: ""fatal error: unexpected signal during runtime execution"" on windows-amd64-longtest builder of Go 1.15.2 commit",NeedsFix Testing,"We've observed the following failure during `runtime` tests on a `windows-amd64-longtest` slowbot on a commit for the upcoming Go 1.15.2: + +``` +fatal error: unexpected signal during runtime execution +[signal 0xc0000005 code=0x0 addr=0x0 pc=0x12efa46] + +runtime stack: +runtime.throw(0x151e8d7, 0x2a) + C:/workdir/go/src/runtime/panic.go:1116 +0x79 fp=0xc0709ff8f8 sp=0xc0709ff8c8 pc=0x12bc659 +runtime.sigpanic() + C:/workdir/go/src/runtime/signal_windows.go:240 +0x285 fp=0xc0709ff928 sp=0xc0709ff8f8 pc=0x12d1745 +runtime.(*pageAlloc).chunkOf(...) + C:/workdir/go/src/runtime/mpagealloc.go:331 +runtime.CheckScavengedBitsCleared.func1() + C:/workdir/go/src/runtime/export_test.go:905 +0x186 fp=0xc0709ff960 sp=0xc0709ff928 pc=0x12efa46 +runtime.systemstack(0x0) + C:/workdir/go/src/runtime/asm_amd64.s:370 +0x6b fp=0xc0709ff968 sp=0xc0709ff960 pc=0x12f4e0b +runtime.mstart() + C:/workdir/go/src/runtime/proc.go:1116 fp=0xc0709ff970 sp=0xc0709ff968 pc=0x12c18e0 + +goroutine 20213428 [running]: +runtime.systemstack_switch() + C:/workdir/go/src/runtime/asm_amd64.s:330 fp=0xc0001a92c0 sp=0xc0001a92b8 pc=0x12f4d80 +[...] +FAIL runtime 143.911s +``` + +See [here](https://go-review.googlesource.com/c/go/+/253717/1#message-c1837523011ceb181c0cfff0399db6db44352946) for more context and the complete build log. + +The `windows-amd64-longtest` slowbot passed all tests on the second try, so this failure is intermittent. It doesn't seem to happen often, but it may be connected to (or the same as) issues #41285, #41099. + +I've tried running `go test -timeout=0 -count=5 runtime` on a machine with Windows 10, and it passed. + +We should see if there's any useful information in this particular instance, and if not, this issue can probably be closed as a duplicate. + +/cc @randall77 @ianlancetaylor @toothrot @andybons ",1.0,"runtime: ""fatal error: unexpected signal during runtime execution"" on windows-amd64-longtest builder of Go 1.15.2 commit - We've observed the following failure during `runtime` tests on a `windows-amd64-longtest` slowbot on a commit for the upcoming Go 1.15.2: + +``` +fatal error: unexpected signal during runtime execution +[signal 0xc0000005 code=0x0 addr=0x0 pc=0x12efa46] + +runtime stack: +runtime.throw(0x151e8d7, 0x2a) + C:/workdir/go/src/runtime/panic.go:1116 +0x79 fp=0xc0709ff8f8 sp=0xc0709ff8c8 pc=0x12bc659 +runtime.sigpanic() + C:/workdir/go/src/runtime/signal_windows.go:240 +0x285 fp=0xc0709ff928 sp=0xc0709ff8f8 pc=0x12d1745 +runtime.(*pageAlloc).chunkOf(...) + C:/workdir/go/src/runtime/mpagealloc.go:331 +runtime.CheckScavengedBitsCleared.func1() + C:/workdir/go/src/runtime/export_test.go:905 +0x186 fp=0xc0709ff960 sp=0xc0709ff928 pc=0x12efa46 +runtime.systemstack(0x0) + C:/workdir/go/src/runtime/asm_amd64.s:370 +0x6b fp=0xc0709ff968 sp=0xc0709ff960 pc=0x12f4e0b +runtime.mstart() + C:/workdir/go/src/runtime/proc.go:1116 fp=0xc0709ff970 sp=0xc0709ff968 pc=0x12c18e0 + +goroutine 20213428 [running]: +runtime.systemstack_switch() + C:/workdir/go/src/runtime/asm_amd64.s:330 fp=0xc0001a92c0 sp=0xc0001a92b8 pc=0x12f4d80 +[...] +FAIL runtime 143.911s +``` + +See [here](https://go-review.googlesource.com/c/go/+/253717/1#message-c1837523011ceb181c0cfff0399db6db44352946) for more context and the complete build log. + +The `windows-amd64-longtest` slowbot passed all tests on the second try, so this failure is intermittent. It doesn't seem to happen often, but it may be connected to (or the same as) issues #41285, #41099. + +I've tried running `go test -timeout=0 -count=5 runtime` on a machine with Windows 10, and it passed. + +We should see if there's any useful information in this particular instance, and if not, this issue can probably be closed as a duplicate. + +/cc @randall77 @ianlancetaylor @toothrot @andybons ",0,runtime fatal error unexpected signal during runtime execution on windows longtest builder of go commit we ve observed the following failure during runtime tests on a windows longtest slowbot on a commit for the upcoming go fatal error unexpected signal during runtime execution runtime stack runtime throw c workdir go src runtime panic go fp sp pc runtime sigpanic c workdir go src runtime signal windows go fp sp pc runtime pagealloc chunkof c workdir go src runtime mpagealloc go runtime checkscavengedbitscleared c workdir go src runtime export test go fp sp pc runtime systemstack c workdir go src runtime asm s fp sp pc runtime mstart c workdir go src runtime proc go fp sp pc goroutine runtime systemstack switch c workdir go src runtime asm s fp sp pc fail runtime see for more context and the complete build log the windows longtest slowbot passed all tests on the second try so this failure is intermittent it doesn t seem to happen often but it may be connected to or the same as issues i ve tried running go test timeout count runtime on a machine with windows and it passed we should see if there s any useful information in this particular instance and if not this issue can probably be closed as a duplicate cc ianlancetaylor toothrot andybons ,0 +33152,6160113552.0,IssuesEvent,2017-06-29 03:29:53,golang/go,https://api.github.com/repos/golang/go,closed,time: RFC3339Nano does not guarantee natural ordering,Documentation,"Hi! + +When the time.Time used in Format(time.RFC3339Nano) is rounded to the nearest second (or anything lower than nanosecond), any trailing 0s are not formatted due to the formatting string. +RFC3339Nano should format to a natural/string sortable value. This is mentioned in section 5.1 of RFC3339 https://www.ietf.org/rfc/rfc3339.txt +``` +5.1. Ordering + + If date and time components are ordered from least precise to most + precise, then a useful property is achieved. Assuming that the time + zones of the dates and times are the same (e.g., all in UTC), + expressed using the same string (e.g., all ""Z"" or all ""+00:00""), and + all times have the same number of fractional second digits, then the + date and time strings may be sorted as strings (e.g., using the + strcmp() function in C) and a time-ordered sequence will result. The + presence of optional punctuation would violate this characteristic. +``` +I propose that time.RFC3339Nano is updated to the following formatting string: + +`""2006-01-02T15:04:05.000000000Z07:00""` + +or that a time.RFC3339NanoNatural (or similar) constant is declared + +thanks for your time! + +### What version of Go are you using (`go version`)? +go version go1.8 darwin/amd64 + + +### What operating system and processor architecture are you using (`go env`)? +``` +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/alex/dev/go"" +GORACE="""" +GOROOT=""/usr/local/go"" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/l5/x43qw4sd10j_459gxsy9h3j80000gn/T/go-build164235018=/tmp/go-build -gno-record-gcc-switches -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +PKG_CONFIG=""pkg-config"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +``` + +### What did you do? +I formatted two time.Time values using RFC3339Nano +https://play.golang.org/p/qY81JM6Np8 + +### What did you expect to see? +``` +Hello, playground +2009-11-10T23:00:00.00000000Z +2009-11-10T23:00:00.00000001Z +``` +### What did you see instead? + +``` +Hello, playground +2009-11-10T23:00:00Z +2009-11-10T23:00:00.00000001Z +``` + + + +",1.0,"time: RFC3339Nano does not guarantee natural ordering - Hi! + +When the time.Time used in Format(time.RFC3339Nano) is rounded to the nearest second (or anything lower than nanosecond), any trailing 0s are not formatted due to the formatting string. +RFC3339Nano should format to a natural/string sortable value. This is mentioned in section 5.1 of RFC3339 https://www.ietf.org/rfc/rfc3339.txt +``` +5.1. Ordering + + If date and time components are ordered from least precise to most + precise, then a useful property is achieved. Assuming that the time + zones of the dates and times are the same (e.g., all in UTC), + expressed using the same string (e.g., all ""Z"" or all ""+00:00""), and + all times have the same number of fractional second digits, then the + date and time strings may be sorted as strings (e.g., using the + strcmp() function in C) and a time-ordered sequence will result. The + presence of optional punctuation would violate this characteristic. +``` +I propose that time.RFC3339Nano is updated to the following formatting string: + +`""2006-01-02T15:04:05.000000000Z07:00""` + +or that a time.RFC3339NanoNatural (or similar) constant is declared + +thanks for your time! + +### What version of Go are you using (`go version`)? +go version go1.8 darwin/amd64 + + +### What operating system and processor architecture are you using (`go env`)? +``` +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/alex/dev/go"" +GORACE="""" +GOROOT=""/usr/local/go"" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/l5/x43qw4sd10j_459gxsy9h3j80000gn/T/go-build164235018=/tmp/go-build -gno-record-gcc-switches -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +PKG_CONFIG=""pkg-config"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +``` + +### What did you do? +I formatted two time.Time values using RFC3339Nano +https://play.golang.org/p/qY81JM6Np8 + +### What did you expect to see? +``` +Hello, playground +2009-11-10T23:00:00.00000000Z +2009-11-10T23:00:00.00000001Z +``` +### What did you see instead? + +``` +Hello, playground +2009-11-10T23:00:00Z +2009-11-10T23:00:00.00000001Z +``` + + + +",1,time does not guarantee natural ordering hi when the time time used in format time is rounded to the nearest second or anything lower than nanosecond any trailing are not formatted due to the formatting string should format to a natural string sortable value this is mentioned in section of ordering if date and time components are ordered from least precise to most precise then a useful property is achieved assuming that the time zones of the dates and times are the same e g all in utc expressed using the same string e g all z or all and all times have the same number of fractional second digits then the date and time strings may be sorted as strings e g using the strcmp function in c and a time ordered sequence will result the presence of optional punctuation would violate this characteristic i propose that time is updated to the following formatting string or that a time or similar constant is declared thanks for your time what version of go are you using go version go version darwin what operating system and processor architecture are you using go env goarch gobin goexe gohostarch gohostos darwin goos darwin gopath users alex dev go gorace goroot usr local go gotooldir usr local go pkg tool darwin gccgo gccgo cc clang gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map var folders t go tmp go build gno record gcc switches fno common cxx clang cgo enabled pkg config pkg config cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g what did you do i formatted two time time values using what did you expect to see hello playground what did you see instead hello playground ,1 +327587,24143862200.0,IssuesEvent,2022-09-21 16:55:50,golang/go,https://api.github.com/repos/golang/go,closed,x/tools/gopls: index out of range while trying to run textDocument/codeAction on entire document,Documentation gopls Tools," + +### gopls version + + + +``` +Build info +---------- +golang.org/x/tools/gopls master + golang.org/x/tools/gopls@(devel) + github.com/BurntSushi/toml@v1.2.0 h1:Rt8g24XnyGTyglgET/PRUNlrUeu9F5L+7FilkXfZgs0= + github.com/google/go-cmp@v0.5.8 h1:e6P7q2lk1O+qJJb4BtCQXlK8vWEO8V1ZeuEdJNOqZyg= + github.com/sergi/go-diff@v1.1.0 h1:we8PVUC3FE2uYfodKH/nBHMSetSfHDR6scGdBi+erh0= + golang.org/x/exp@v0.0.0-20220722155223-a9213eeb770e h1:+WEEuIdZHnUeJJmEUjyYC2gfUMj69yZXw17EnHg/otA= + golang.org/x/exp/typeparams@v0.0.0-20220722155223-a9213eeb770e h1:7Xs2YCOpMlNqSQSmrrnhlzBXIE/bpMecZplbLePTJvE= + golang.org/x/mod@v0.6.0-dev.0.20220419223038-86c51ed26bb4 h1:6zppjxzCulZykYSLyVDYbneBfbaBIQPYMevg0bEwv2s= + golang.org/x/sync@v0.0.0-20220722155255-886fb9371eb4 h1:uVc8UZUe6tr40fFVnUP5Oj+veunVezqYl9z7DYw9xzw= + golang.org/x/sys@v0.0.0-20220808155132-1c4a2a72c664 h1:v1W7bwXHsnLLloWYTVEdvGvA7BHMeBYsPcF0GLDxIRs= + golang.org/x/text@v0.3.7 h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk= + golang.org/x/tools@v0.1.13-0.20220810174125-0ad49fdeb955 => ../ + golang.org/x/vuln@v0.0.0-20220919155316-41b1fc70d0a6 h1:tQFrcJZ95V1wiLLPoAIaEuEVXJ7JkhbZI4Hws7Fx69c= + honnef.co/go/tools@v0.3.3 h1:oDx7VAwstgpYpb3wv0oxiZlxY+foCpRAwY7Vk6XpAgA= + mvdan.cc/gofumpt@v0.3.1 h1:avhhrOmv0IuvQVK7fvwV91oFSGAk5/6Po8GXTzICeu8= + mvdan.cc/xurls/v2@v2.4.0 h1:tzxjVAj+wSBmDcF6zBB7/myTy3gX9xvi8Tyr28AuQgc= +go: devel go1.20-d11c58eedb Wed Sep 21 01:56:24 2022 +0000 +``` + +### go env + + + +``` +% go env +GO111MODULE="""" +GOARCH=""arm64"" +GOBIN=""/Users/fsouza/bin"" +GOCACHE=""/Users/fsouza/Library/Caches/go-build"" +GOENV=""/Users/fsouza/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS=""-modcacherw"" +GOHOSTARCH=""arm64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/fsouza/.cache/go/path/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/fsouza/.cache/go/path"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/Users/fsouza/.cache/go/sdk/gotip"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/Users/fsouza/.cache/go/sdk/gotip/pkg/tool/darwin_arm64"" +GOVCS="""" +GOVERSION=""devel go1.20-d11c58eedb Wed Sep 21 01:56:24 2022 +0000"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/fsouza/Projects/os/p/fake-gcs-server/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch arm64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/rz/8d0l4yp51sd3jh9f34x7pkg80000gn/T/go-build3810227374=/tmp/go-build -gno-record-gcc-switches -fno-common"" +``` + +### What did you do? + + + +Invoke `textDocument/codeAction` passing a range that covers the entire file +(following the [spec for +range](https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#range), +which means that the end position is exclusive). Here's what the range I'm +sending looks like (in JSON-ish): + +```json +{ + ... other fields + ""range"": { + ""start"": { + ""line"": 0, + ""character"": 0 + }, + ""end"": { + ""line"": $N, + ""character"": 0 + } + } +} +``` + +Where `$N` = number of lines in the file. + +For full reproduction steps, see ""Editor & Settings"" below. + +### What did you expect to see? + +The list of code actions available in the entire file. + +### What did you see instead? + +gopls panics with an index out of range. Since this is a panic, the stacktrace +isn't available in the logs for gopls, but I'm able to get the process output +from my editor's logs: + +``` +[ERROR][2022-09-21 09:02:06] .../vim/lsp/rpc.lua:733 ""rpc"" ""/Users/fsouza/.cache/nvim/langservers/bin/gopls"" ""stderr"" ""panic: runtime error: index out of range [2] with length 2\n\ngoroutine 8707 [running]:\ngolang.org/x/tools/gopls/internal/lsp/source.adjustRangeForCommentsAndWhiteSpace({0x140038d9380?, 0x69?, 0x1?}, 0x140038d9380, {0x14001dea000, 0xbc7, 0x140000f4640?}, 0x1400370b400)\n\t/Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/source/extract.go:704 +0x3e0\ngolang.org/x/tools/gopls/internal/lsp/source.CanExtractFunction(0x140038d9380, {0x140038d9380, 0x92e342, 0x92eef2}, {0x14001dea000, 0xbc7, 0xbc8"" +[ERROR][2022-09-21 09:02:06] .../vim/lsp/rpc.lua:733 ""rpc"" ""/Users/fsouza/.cache/nvim/langservers/bin/gopls"" ""stderr"" ""}, 0x102f5bfe4?)\n\t/Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/source/extract.go:984 +0xc4\ngolang.org/x/tools/gopls/internal/lsp.extractionFixes({0x1034480e0, 0x1400d856440}, {0x103453b18?, 0x140038e2640?}, {0x103408780?, 0x0?}, {0x140069ec9c0, 0x3a}, {{0x0?, 0x0?}, ...})\n\t/Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/code_action.go:301 +0x180\ngolang.org/x/tools/gopls/internal/lsp.(*Server).codeAction(0x1400d8b4180?, {0x1034480e0, 0x1400d856440}, 0x1400d8b4180)\n\t/Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/code_action.go:196 +0x13c4\ngolang.org/x/tools/gopls/internal/lsp.(*Server).CodeAction(0x14000138210?, {0x1034480e0?, 0x1400d856440?}, 0x1032e84c0?)\n\t/Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/server_gen.go:16 +0x24\ngolang.org/x/tools/gopls/internal/lsp/protocol.serverDispatch({0x1034480e0, 0x1400d856440}, {0x1034571a8, 0x140004f2360}, 0x1400d66e750, {0x103448498, 0x1400d8562c0})\n\t/Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/protocol/tsserver.go:239 +0x18cc\ngolang.org/x/tools/gopls/internal/lsp/protocol.ServerHandler.func1({0x1034480e0, 0x1400d856440}, 0x1400d66e750, {0x103448498, 0x1400d8562c0})\n\t/Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/protocol/protocol.go:157 +0x6c\ngolang.org/x/tools/gopls/internal/lsp/lsprpc.handshaker.func1({0x1034480e0, 0x1400d856440}, 0x1400d66e750, {0x103448498?, 0x1400d8562c0?})\n\t/Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/lsprpc/lsprpc.go:515 +0x768\ngolang.org/x/tools/internal/jsonrpc2.MustReplyHandler.func1({0x1034480e0, 0x1400d856440}, 0x1400d5bd128, {0x103448498?, 0x1400d8562c0?})\n\t/Users/fsouza/.cache/nvim/langservers/tools/internal/jsonrpc2/handler.go:35 +0xf0\ngolang.org/x/tools/internal/jsonrpc2.AsyncHandler.func1.2()\n\t/Users/fsouza/.cache/nvim/langservers/tools/internal/jsonrpc2/handler.go:103 +0x90\ncreated by golang.org/x/tools/internal/jsonrpc2.AsyncHandler.func1\n\t/Users/fsouza/.cache/nvim/langservers/tools/internal/jsonrpc2/handler.go:100 +0x1dc\n"" +``` + +In order to make it easier to read, I've also expanded the two lines above. This is the output from gopls: + +``` +panic: runtime error: index out of range [2] with length 2 + +goroutine 8707 [running]: +golang.org/x/tools/gopls/internal/lsp/source.adjustRangeForCommentsAndWhiteSpace({0x140038d9380?, 0x69?, 0x1?}, 0x140038d9380, {0x14001dea000, 0xbc7, 0x140000f4640?}, 0x1400370b400) + /Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/source/extract.go:704 +0x3e0 +golang.org/x/tools/gopls/internal/lsp/source.CanExtractFunction(0x140038d9380, {0x140038d9380, 0x92e342, 0x92eef2}, {0x14001dea000, 0xbc7, 0xbc8}, 0x102f5bfe4?) + /Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/source/extract.go:984 +0xc4 +golang.org/x/tools/gopls/internal/lsp.extractionFixes({0x1034480e0, 0x1400d856440}, {0x103453b18?, 0x140038e2640?}, {0x103408780?, 0x0?}, {0x140069ec9c0, 0x3a}, {{0x0?, 0x0?}, ...}) + /Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/code_action.go:301 +0x180 +golang.org/x/tools/gopls/internal/lsp.(*Server).codeAction(0x1400d8b4180?, {0x1034480e0, 0x1400d856440}, 0x1400d8b4180) + /Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/code_action.go:196 +0x13c4 +golang.org/x/tools/gopls/internal/lsp.(*Server).CodeAction(0x14000138210?, {0x1034480e0?, 0x1400d856440?}, 0x1032e84c0?) + /Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/server_gen.go:16 +0x24 +golang.org/x/tools/gopls/internal/lsp/protocol.serverDispatch({0x1034480e0, 0x1400d856440}, {0x1034571a8, 0x140004f2360}, 0x1400d66e750, {0x103448498, 0x1400d8562c0}) + /Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/protocol/tsserver.go:239 +0x18cc +golang.org/x/tools/gopls/internal/lsp/protocol.ServerHandler.func1({0x1034480e0, 0x1400d856440}, 0x1400d66e750, {0x103448498, 0x1400d8562c0}) + /Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/protocol/protocol.go:157 +0x6c +golang.org/x/tools/gopls/internal/lsp/lsprpc.handshaker.func1({0x1034480e0, 0x1400d856440}, 0x1400d66e750, {0x103448498?, 0x1400d8562c0?}) + /Users/fsouza/.cache/nvim/langservers/tools/gopls/internal/lsp/lsprpc/lsprpc.go:515 +0x768 +golang.org/x/tools/internal/jsonrpc2.MustReplyHandler.func1({0x1034480e0, 0x1400d856440}, 0x1400d5bd128, {0x103448498?, 0x1400d8562c0?}) + /Users/fsouza/.cache/nvim/langservers/tools/internal/jsonrpc2/handler.go:35 +0xf0 +golang.org/x/tools/internal/jsonrpc2.AsyncHandler.func1.2() + /Users/fsouza/.cache/nvim/langservers/tools/internal/jsonrpc2/handler.go:103 +0x90 +created by golang.org/x/tools/internal/jsonrpc2.AsyncHandler.func1 + /Users/fsouza/.cache/nvim/langservers/tools/internal/jsonrpc2/handler.go:100 +0x1dc +``` + +This is a regression and I was able to bisect it to this commit: + +``` +fdf581fdab091d9dd12425be67e59db67a2ad501 is the first bad commit +commit fdf581fdab091d9dd12425be67e59db67a2ad501 +Author: Suzy Mueller
+ TODO: https://golang.org/cl/216424: allow conversion from slice to array ptr +
+ ++ TODO: complete this section +
+ +--- + +This TODO needs to be resolved by July 1 so that we can have complete release notes for [Beta 1](https://golang.org/s/release#june-1--december-1-beta-1-issued). + +A sequence of steps to resolve this issue may be: + +1. Come up with a draft release note entry in this issue, then move the issue to NeedsFix state. +2. Send a CL with ""doc/go1.17:"" [prefix](https://go-review.googlesource.com/q/project:go+doc/go1.17) and include ""For #44513. Fixes #46020."" in the body.",1.0,"doc/go1.17: document changes to the language for Go 1.17 - As of filing this issue, the [Go 1.17 draft release notes](https://tip.golang.org/doc/go1.17) contained the following HTML: + ++ TODO: https://golang.org/cl/216424: allow conversion from slice to array ptr +
+ ++ TODO: complete this section +
+ +--- + +This TODO needs to be resolved by July 1 so that we can have complete release notes for [Beta 1](https://golang.org/s/release#june-1--december-1-beta-1-issued). + +A sequence of steps to resolve this issue may be: + +1. Come up with a draft release note entry in this issue, then move the issue to NeedsFix state. +2. Send a CL with ""doc/go1.17:"" [prefix](https://go-review.googlesource.com/q/project:go+doc/go1.17) and include ""For #44513. Fixes #46020."" in the body.",1,doc document changes to the language for go as of filing this issue the contained the following html changes to the language todo a href allow conversion from slice to array ptr todo complete this section this todo needs to be resolved by july so that we can have complete release notes for a sequence of steps to resolve this issue may be come up with a draft release note entry in this issue then move the issue to needsfix state send a cl with doc and include for fixes in the body ,1 +83684,24120418559.0,IssuesEvent,2022-09-20 18:10:55,golang/go,https://api.github.com/repos/golang/go,closed,x/build/internal/relui: TestSecurity failures,Builders NeedsInvestigation,"``` +#!watchflakes +post <- pkg == ""golang.org/x/build/internal/relui"" && test == ""TestSecurity"" +``` + +Bug automatically created to collect these failures. + +Example [log](https://build.golang.org/log/a28a274442b2a0ce03a2dc460a6ae6a36ed6b58c): + + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/linux-amd64-goamd64v3/1: 7 files, 2 dirs (1.027ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/linux-ppc64le-buildlet/4: 7 files, 2 dirs (1.38375ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/freebsd-386-13_0/10: 7 files, 2 dirs (1.946625ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/windows-amd64-race/9: 7 files, 2 dirs (3.469917ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/windows-386-2008-newcc/3: 7 files, 2 dirs (1.095334ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/linux-amd64-stretch/6: 7 files, 2 dirs (17.58825ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/linux-ppc64le-buildlet/4/go1.4: 1 files, 1 dirs (209.583µs) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/windows-amd64-newcc-race/23: 7 files, 2 dirs (1.339875ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/android-amd64-emu/7: 7 files, 2 dirs (18.910209ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/freebsd-amd64-12_3/22: 7 files, 2 dirs (2.683375ms) + ... + 2022/09/07 17:07:40 extracted tarball into /tmp/buildlet/tmp/TestSecuritysuccess1625173706/001/freebsd-amd64-12_3/71/go1.4: 1 files, 1 dirs (4.1065ms) + panic: test timed out after 10m0s + + golang.org/x/build/internal/workflow.(*Workflow).Run(0x140005d5fc0, {0x10573d6d0?, 0x140005d5440}, {0x105737cc8, 0x140000b9060}) + /tmp/buildlet/gopath/src/golang.org/x/build/internal/workflow/workflow.go:767 +0x244 + golang.org/x/build/internal/relui.testSecurity(0x14001a2b1e0, 0x1) + /tmp/buildlet/gopath/src/golang.org/x/build/internal/relui/buildrelease_test.go:304 +0x508 + golang.org/x/build/internal/relui.TestSecurity.func1(0x14000243980?) + /tmp/buildlet/gopath/src/golang.org/x/build/internal/relui/buildrelease_test.go:53 +0x20 + testing.tRunner(0x14001a2b1e0, 0x105727f28) + + +— [watchflakes](https://go.dev/wiki/Watchflakes) +",1.0,"x/build/internal/relui: TestSecurity failures - ``` +#!watchflakes +post <- pkg == ""golang.org/x/build/internal/relui"" && test == ""TestSecurity"" +``` + +Bug automatically created to collect these failures. + +Example [log](https://build.golang.org/log/a28a274442b2a0ce03a2dc460a6ae6a36ed6b58c): + + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/linux-amd64-goamd64v3/1: 7 files, 2 dirs (1.027ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/linux-ppc64le-buildlet/4: 7 files, 2 dirs (1.38375ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/freebsd-386-13_0/10: 7 files, 2 dirs (1.946625ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/windows-amd64-race/9: 7 files, 2 dirs (3.469917ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/windows-386-2008-newcc/3: 7 files, 2 dirs (1.095334ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/linux-amd64-stretch/6: 7 files, 2 dirs (17.58825ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/linux-ppc64le-buildlet/4/go1.4: 1 files, 1 dirs (209.583µs) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/windows-amd64-newcc-race/23: 7 files, 2 dirs (1.339875ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/android-amd64-emu/7: 7 files, 2 dirs (18.910209ms) + 2022/09/07 17:07:32 extracted tarball into /tmp/buildlet/tmp/TestReleasebeta1870346664/001/freebsd-amd64-12_3/22: 7 files, 2 dirs (2.683375ms) + ... + 2022/09/07 17:07:40 extracted tarball into /tmp/buildlet/tmp/TestSecuritysuccess1625173706/001/freebsd-amd64-12_3/71/go1.4: 1 files, 1 dirs (4.1065ms) + panic: test timed out after 10m0s + + golang.org/x/build/internal/workflow.(*Workflow).Run(0x140005d5fc0, {0x10573d6d0?, 0x140005d5440}, {0x105737cc8, 0x140000b9060}) + /tmp/buildlet/gopath/src/golang.org/x/build/internal/workflow/workflow.go:767 +0x244 + golang.org/x/build/internal/relui.testSecurity(0x14001a2b1e0, 0x1) + /tmp/buildlet/gopath/src/golang.org/x/build/internal/relui/buildrelease_test.go:304 +0x508 + golang.org/x/build/internal/relui.TestSecurity.func1(0x14000243980?) + /tmp/buildlet/gopath/src/golang.org/x/build/internal/relui/buildrelease_test.go:53 +0x20 + testing.tRunner(0x14001a2b1e0, 0x105727f28) + + +— [watchflakes](https://go.dev/wiki/Watchflakes) +",0,x build internal relui testsecurity failures watchflakes post pkg golang org x build internal relui test testsecurity bug automatically created to collect these failures example extracted tarball into tmp buildlet tmp linux files dirs extracted tarball into tmp buildlet tmp linux buildlet files dirs extracted tarball into tmp buildlet tmp freebsd files dirs extracted tarball into tmp buildlet tmp windows race files dirs extracted tarball into tmp buildlet tmp windows newcc files dirs extracted tarball into tmp buildlet tmp linux stretch files dirs extracted tarball into tmp buildlet tmp linux buildlet files dirs extracted tarball into tmp buildlet tmp windows newcc race files dirs extracted tarball into tmp buildlet tmp android emu files dirs extracted tarball into tmp buildlet tmp freebsd files dirs extracted tarball into tmp buildlet tmp freebsd files dirs panic test timed out after golang org x build internal workflow workflow run tmp buildlet gopath src golang org x build internal workflow workflow go golang org x build internal relui testsecurity tmp buildlet gopath src golang org x build internal relui buildrelease test go golang org x build internal relui testsecurity tmp buildlet gopath src golang org x build internal relui buildrelease test go testing trunner — ,0 +41707,6927746650.0,IssuesEvent,2017-12-01 00:25:54,golang/go,https://api.github.com/repos/golang/go,closed,testing: are T.Run and B.Run safe for concurrent use?,Documentation NeedsFix release-blocker,"I do not see any documentation specifying if T.Run is safe for concurrent use. I see the following doc for [testing.T](https://tip.golang.org/pkg/testing/#T), which does not mention T.Run: + +> A test ends when its Test function returns or calls any of the methods FailNow, Fatal, Fatalf, SkipNow, Skip, or Skipf. Those methods, as well as the Parallel method, must be called only from the goroutine running the Test function. +> +> The other reporting methods, such as the variations of Log and Error, may be called simultaneously from multiple goroutines. + +There is a similar doc for [testing.B](https://tip.golang.org/pkg/testing/#B). + +I ask because I believe T.Run was safe for concurrent use in go 1.7. Then, [this line](https://github.com/golang/go/blob/7fb16406139e934d84f7ec66ba440a772747270a/src/testing/testing.go#L663) was added in go 1.8, which made T.Run no longer safe for concurrent use. I don't particularly care whether T.Run is safe for concurrent use, but I think the semantics should be clarified. + +Optimistically labeling this go1.8. + +/cc @dsnet ",1.0,"testing: are T.Run and B.Run safe for concurrent use? - I do not see any documentation specifying if T.Run is safe for concurrent use. I see the following doc for [testing.T](https://tip.golang.org/pkg/testing/#T), which does not mention T.Run: + +> A test ends when its Test function returns or calls any of the methods FailNow, Fatal, Fatalf, SkipNow, Skip, or Skipf. Those methods, as well as the Parallel method, must be called only from the goroutine running the Test function. +> +> The other reporting methods, such as the variations of Log and Error, may be called simultaneously from multiple goroutines. + +There is a similar doc for [testing.B](https://tip.golang.org/pkg/testing/#B). + +I ask because I believe T.Run was safe for concurrent use in go 1.7. Then, [this line](https://github.com/golang/go/blob/7fb16406139e934d84f7ec66ba440a772747270a/src/testing/testing.go#L663) was added in go 1.8, which made T.Run no longer safe for concurrent use. I don't particularly care whether T.Run is safe for concurrent use, but I think the semantics should be clarified. + +Optimistically labeling this go1.8. + +/cc @dsnet ",1,testing are t run and b run safe for concurrent use i do not see any documentation specifying if t run is safe for concurrent use i see the following doc for which does not mention t run a test ends when its test function returns or calls any of the methods failnow fatal fatalf skipnow skip or skipf those methods as well as the parallel method must be called only from the goroutine running the test function the other reporting methods such as the variations of log and error may be called simultaneously from multiple goroutines there is a similar doc for i ask because i believe t run was safe for concurrent use in go then was added in go which made t run no longer safe for concurrent use i don t particularly care whether t run is safe for concurrent use but i think the semantics should be clarified optimistically labeling this cc dsnet ,1 +277221,21033186189.0,IssuesEvent,2022-03-31 04:12:11,golang/go,https://api.github.com/repos/golang/go,closed,cmd/link: -X requires the full import path for vendored packages,Documentation help wanted,"Please answer these questions before submitting your issue. Thanks! + + +### What version of Go are you using (`go version`)? +go version go1.10.1 linux/amd64 +### Does this issue reproduce with the latest release? +yes + +### What operating system and processor architecture are you using (`go env`)? +``` +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/root/.cache/go-build"" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/go"" +GORACE="""" +GOROOT=""/usr/local/go"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build528112336=/tmp/go-build -gno-record-gcc-switches"" +``` + +### What did you do? +``` +$ find +main.go +vendor/github.com/ckeyer/commons/version/version.go + +$ go build -a -v -ldflags=""-X github.com/ckeyer/commons/version.version=v0.1.0"" main.go version +``` +If possible, provide a recipe for reproducing the error. +A complete runnable program is good. +A link on play.golang.org is best. + + +### What did you expect to see? +I want to see print the `version v0.1.0` + +### What did you see instead? +none + +I use `go build -a -v -ldflags=""-X github.com/ckeyer/frog/vendor/github.com/ckeyer/commons/version.version=v0.1.0"" main.go version` ,it works. +",1.0,"cmd/link: -X requires the full import path for vendored packages - Please answer these questions before submitting your issue. Thanks! + + +### What version of Go are you using (`go version`)? +go version go1.10.1 linux/amd64 +### Does this issue reproduce with the latest release? +yes + +### What operating system and processor architecture are you using (`go env`)? +``` +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/root/.cache/go-build"" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/go"" +GORACE="""" +GOROOT=""/usr/local/go"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build528112336=/tmp/go-build -gno-record-gcc-switches"" +``` + +### What did you do? +``` +$ find +main.go +vendor/github.com/ckeyer/commons/version/version.go + +$ go build -a -v -ldflags=""-X github.com/ckeyer/commons/version.version=v0.1.0"" main.go version +``` +If possible, provide a recipe for reproducing the error. +A complete runnable program is good. +A link on play.golang.org is best. + + +### What did you expect to see? +I want to see print the `version v0.1.0` + +### What did you see instead? +none + +I use `go build -a -v -ldflags=""-X github.com/ckeyer/frog/vendor/github.com/ckeyer/commons/version.version=v0.1.0"" main.go version` ,it works. +",1,cmd link x requires the full import path for vendored packages please answer these questions before submitting your issue thanks what version of go are you using go version go version linux does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env goarch gobin gocache root cache go build goexe gohostarch gohostos linux goos linux gopath go gorace goroot usr local go gotmpdir gotooldir usr local go pkg tool linux gccgo gccgo cc gcc cxx g cgo enabled cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fmessage length fdebug prefix map tmp go tmp go build gno record gcc switches what did you do find main go vendor github com ckeyer commons version version go go build a v ldflags x github com ckeyer commons version version main go version if possible provide a recipe for reproducing the error a complete runnable program is good a link on play golang org is best what did you expect to see i want to see print the version what did you see instead none i use go build a v ldflags x github com ckeyer frog vendor github com ckeyer commons version version main go version it works ,1 +40812,6849208247.0,IssuesEvent,2017-11-13 21:15:21,golang/go,https://api.github.com/repos/golang/go,opened,"cmd/gofmt: document that tools must invoke gofmt, not use go/format",Documentation,"We've had reports of skew where people are using one tool that links against go/printer (or go/format, which wraps it) and writes code, and then some other tool runs gofmt and sees that the formatting is different, because gofmt has a newer/older/different version of go/printer. + +We should document that tools that write code files that will be checked in should run gofmt (the program) over their output, not assume that their copy of go/printer matches. One such tool is goimports. + +The alternative is that we somehow never ever again change the output of gofmt on existing code, which seems too restrictive. + +See: + - https://github.com/golang/go/issues/18782 (cmd/gofmt: comment lines broken at new position) + - https://github.com/golang/go/issues/18790 (proposal: cmd/gofmt: write official spec for gofmt) + - https://github.com/golang/go/issues/22607 (cmd/gofmt: formatting improvements may break existing presubmit checks) + +",1.0,"cmd/gofmt: document that tools must invoke gofmt, not use go/format - We've had reports of skew where people are using one tool that links against go/printer (or go/format, which wraps it) and writes code, and then some other tool runs gofmt and sees that the formatting is different, because gofmt has a newer/older/different version of go/printer. + +We should document that tools that write code files that will be checked in should run gofmt (the program) over their output, not assume that their copy of go/printer matches. One such tool is goimports. + +The alternative is that we somehow never ever again change the output of gofmt on existing code, which seems too restrictive. + +See: + - https://github.com/golang/go/issues/18782 (cmd/gofmt: comment lines broken at new position) + - https://github.com/golang/go/issues/18790 (proposal: cmd/gofmt: write official spec for gofmt) + - https://github.com/golang/go/issues/22607 (cmd/gofmt: formatting improvements may break existing presubmit checks) + +",1,cmd gofmt document that tools must invoke gofmt not use go format we ve had reports of skew where people are using one tool that links against go printer or go format which wraps it and writes code and then some other tool runs gofmt and sees that the formatting is different because gofmt has a newer older different version of go printer we should document that tools that write code files that will be checked in should run gofmt the program over their output not assume that their copy of go printer matches one such tool is goimports the alternative is that we somehow never ever again change the output of gofmt on existing code which seems too restrictive see cmd gofmt comment lines broken at new position proposal cmd gofmt write official spec for gofmt cmd gofmt formatting improvements may break existing presubmit checks ,1 +48722,7451765286.0,IssuesEvent,2018-03-29 05:09:23,golang/go,https://api.github.com/repos/golang/go,closed,testing: document cap the number of concurrent goroutines with -race,Documentation NeedsFix,"### What version of Go are you using (`go version`)? + +1.9.2 +GOOS=linux +GOARCH=amd64 + +### What did you do? + +``` +package main + +import ( + ""math/rand"" + ""strconv"" + ""testing"" + ""time"" +) + +func TestGoRoutines(t *testing.T) { + for i := 0; i < 1<<15; i++ { + t.Run(strconv.Itoa(i), func(t *testing.T) { + t.Parallel() + time.Sleep(time.Duration(rand.Intn(500000000))) + }) + } +} +``` + +saved as `x_test.go` and run with `go test -race` + +### What did you expect to see? + +The tests to pass. Instead, + +``` +race: limit on 8192 simultaneously alive goroutines is exceeded, dying +``` + +As I understand it, this is likely a technical limitation on Go's race detector. However, it would be nice for the `testing` package to be aware of this and, if raceenabled, cap the number of parallel tests at something below the 8192 limit (say, 7000?). Perhaps a better way would be a warning, but I know Go doesn't really like warnings. + + +",1.0,"testing: document cap the number of concurrent goroutines with -race - ### What version of Go are you using (`go version`)? + +1.9.2 +GOOS=linux +GOARCH=amd64 + +### What did you do? + +``` +package main + +import ( + ""math/rand"" + ""strconv"" + ""testing"" + ""time"" +) + +func TestGoRoutines(t *testing.T) { + for i := 0; i < 1<<15; i++ { + t.Run(strconv.Itoa(i), func(t *testing.T) { + t.Parallel() + time.Sleep(time.Duration(rand.Intn(500000000))) + }) + } +} +``` + +saved as `x_test.go` and run with `go test -race` + +### What did you expect to see? + +The tests to pass. Instead, + +``` +race: limit on 8192 simultaneously alive goroutines is exceeded, dying +``` + +As I understand it, this is likely a technical limitation on Go's race detector. However, it would be nice for the `testing` package to be aware of this and, if raceenabled, cap the number of parallel tests at something below the 8192 limit (say, 7000?). Perhaps a better way would be a warning, but I know Go doesn't really like warnings. + + +",1,testing document cap the number of concurrent goroutines with race what version of go are you using go version goos linux goarch what did you do package main import math rand strconv testing time func testgoroutines t testing t for i i i t run strconv itoa i func t testing t t parallel time sleep time duration rand intn saved as x test go and run with go test race what did you expect to see the tests to pass instead race limit on simultaneously alive goroutines is exceeded dying as i understand it this is likely a technical limitation on go s race detector however it would be nice for the testing package to be aware of this and if raceenabled cap the number of parallel tests at something below the limit say perhaps a better way would be a warning but i know go doesn t really like warnings ,1 +211839,16460094382.0,IssuesEvent,2021-05-21 17:35:40,golang/go,https://api.github.com/repos/golang/go,closed,doc/go1.17: document archive/zip changes for Go 1.17,Documentation NeedsInvestigation help wanted release-blocker,"As of filing this issue, the [Go 1.17 draft release notes](https://tip.golang.org/doc/go1.17) contained the following HTML: + ++ TODO: https://golang.org/cl/312310: add File.OpenRaw, Writer.CreateRaw, Writer.Copy +
++ TODO: https://golang.org/cl/312310: add File.OpenRaw, Writer.CreateRaw, Writer.Copy +
++$ go version +go version go1.19 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/shuang/Library/Caches/go-build"" +GOENV=""/Users/shuang/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/shuang/.go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/shuang/.go"" +GOPRIVATE="""" +GOPROXY=""https://goproxy.cn,direct"" +GOROOT=""/usr/local/Cellar/go/1.19/libexec"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.19/libexec/pkg/tool/darwin_amd64"" +GOVCS="""" +GOVERSION=""go1.19"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/1y/2t35nccn4tg5pzrjyx6bgjhw0000gn/T/go-build1994239392=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ go version +go version go1.19 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/shuang/Library/Caches/go-build"" +GOENV=""/Users/shuang/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/shuang/.go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/shuang/.go"" +GOPRIVATE="""" +GOPROXY=""https://goproxy.cn,direct"" +GOROOT=""/usr/local/Cellar/go/1.19/libexec"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.19/libexec/pkg/tool/darwin_amd64"" +GOVCS="""" +GOVERSION=""go1.19"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/1y/2t35nccn4tg5pzrjyx6bgjhw0000gn/T/go-build1994239392=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ go version +go version go1.18beta2 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +
+$ go version +go version go1.18beta2 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +
require directiverequire directiverequire directiverequire directive+$ go version +go version devel go1.19-47f806ce81 Sat Jun 4 21:18:25 2022 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/ncw/.cache/go-build"" +GOENV=""/home/ncw/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/ncw/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/ncw/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/opt/go/go-tip"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/opt/go/go-tip/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""devel go1.19-47f806ce81 Sat Jun 4 21:18:25 2022 +0000"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/ncw/go/src/github.com/rclone/rclone/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build2093186880=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version devel go1.19-47f806ce81 Sat Jun 4 21:18:25 2022 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/ncw/.cache/go-build"" +GOENV=""/home/ncw/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/ncw/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/ncw/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/opt/go/go-tip"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/opt/go/go-tip/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""devel go1.19-47f806ce81 Sat Jun 4 21:18:25 2022 +0000"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/ncw/go/src/github.com/rclone/rclone/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build2093186880=/tmp/go-build -gno-record-gcc-switches"" +
To reproduce: + +1. Decode CMYK jpeg (attached) + +What is the expected output? + +A successfully decoded image. Works in Preview.app and ImageMagick. + +What do you see instead? + +Error "unsupported JPEG feature: SOF has wrong length" + +Which version are you using? (run 'go version') + +go version devel +a5efcd1675eb Thu Dec 06 09:47:12 2012 -0800 + +Please provide any additional information below. + +I'm seeing this error for all CMYK jpegs I've tried.+ + + + + +Attachments: + +1. err1.jpeg (902176 bytes)",1.0,"image/jpeg: support for CMYK images - by **samuel.stauffer**: + +
To reproduce: + +1. Decode CMYK jpeg (attached) + +What is the expected output? + +A successfully decoded image. Works in Preview.app and ImageMagick. + +What do you see instead? + +Error "unsupported JPEG feature: SOF has wrong length" + +Which version are you using? (run 'go version') + +go version devel +a5efcd1675eb Thu Dec 06 09:47:12 2012 -0800 + +Please provide any additional information below. + +I'm seeing this error for all CMYK jpegs I've tried.+ + + + + +Attachments: + +1. err1.jpeg (902176 bytes)",0,image jpeg support for cmyk images by samuel stauffer to reproduce decode cmyk jpeg attached what is the expected output a successfully decoded image works in preview app and imagemagick what do you see instead error quot unsupported jpeg feature sof has wrong length quot which version are you using run go version go version devel thu dec please provide any additional information below i m seeing this error for all cmyk jpegs i ve tried attachments a href bytes ,0 +317544,27244072978.0,IssuesEvent,2023-02-21 23:33:54,golang/go,https://api.github.com/repos/golang/go,closed,syscall: introduce IoctlPtr for exec_unix tests,Testing NeedsFix compiler/runtime,"This is a followup for https://github.com/golang/go/issues/44834. Similar issue [is](https://github.com/golang/go/blob/master/src/syscall/exec_unix_test.go#L180) [present](https://github.com/golang/go/blob/master/src/syscall/exec_unix_test.go#L217) [in](https://github.com/golang/go/blob/master/src/syscall/exec_unix_test.go#L231) `exec_unix_test.go`, which calls [sysctl.Ioctl()](https://github.com/golang/go/blob/master/src/syscall/export_unix_test.go#L9) and passes Go pointers as uintptr, violating unsafe.Pointer safety rules. As sysctl.Ioctl() is exported solely for tests (and called only by exec_unix_test.go), replace it with sysctl.IoctlPtr() that accepts arg argument as unsafe.Pointer.",1.0,"syscall: introduce IoctlPtr for exec_unix tests - This is a followup for https://github.com/golang/go/issues/44834. Similar issue [is](https://github.com/golang/go/blob/master/src/syscall/exec_unix_test.go#L180) [present](https://github.com/golang/go/blob/master/src/syscall/exec_unix_test.go#L217) [in](https://github.com/golang/go/blob/master/src/syscall/exec_unix_test.go#L231) `exec_unix_test.go`, which calls [sysctl.Ioctl()](https://github.com/golang/go/blob/master/src/syscall/export_unix_test.go#L9) and passes Go pointers as uintptr, violating unsafe.Pointer safety rules. As sysctl.Ioctl() is exported solely for tests (and called only by exec_unix_test.go), replace it with sysctl.IoctlPtr() that accepts arg argument as unsafe.Pointer.",0,syscall introduce ioctlptr for exec unix tests this is a followup for similar issue exec unix test go which calls and passes go pointers as uintptr violating unsafe pointer safety rules as sysctl ioctl is exported solely for tests and called only by exec unix test go replace it with sysctl ioctlptr that accepts arg argument as unsafe pointer ,0 +49873,7544489717.0,IssuesEvent,2018-04-17 18:35:51,golang/go,https://api.github.com/repos/golang/go,closed,x/crypto/acme/autocert: clarify usage of (*Manager).GetCertificate,Documentation,"Would be nice to have a example of `cert, err := m.GetCertificate(...)` so the certificates can be used in GRPC. I fail to come up with a solution. +```go + m := &autocert.Manager{ + Cache: autocert.DirCache(""tls""), + Prompt: autocert.AcceptTOS, + HostPolicy: autocert.HostWhitelist(""example.com""), + } + go http.ListenAndServe("":http"", m.HTTPHandler(nil)) + cert, err := m.GetCertificate(...) + if err != nil { + t.Fatalf(""Failed to generate certificates %s"", err) + } + creds := credentials.NewServerTLSFromCert(cert) + srv := grpc.NewServer(grpc.Creds(creds)) + reflection.Register(srv) +``` +https://godoc.org/golang.org/x/crypto/acme/autocert + +https://stackoverflow.com/questions/49874945/acme-certificate-for-grpc",1.0,"x/crypto/acme/autocert: clarify usage of (*Manager).GetCertificate - Would be nice to have a example of `cert, err := m.GetCertificate(...)` so the certificates can be used in GRPC. I fail to come up with a solution. +```go + m := &autocert.Manager{ + Cache: autocert.DirCache(""tls""), + Prompt: autocert.AcceptTOS, + HostPolicy: autocert.HostWhitelist(""example.com""), + } + go http.ListenAndServe("":http"", m.HTTPHandler(nil)) + cert, err := m.GetCertificate(...) + if err != nil { + t.Fatalf(""Failed to generate certificates %s"", err) + } + creds := credentials.NewServerTLSFromCert(cert) + srv := grpc.NewServer(grpc.Creds(creds)) + reflection.Register(srv) +``` +https://godoc.org/golang.org/x/crypto/acme/autocert + +https://stackoverflow.com/questions/49874945/acme-certificate-for-grpc",1,x crypto acme autocert clarify usage of manager getcertificate would be nice to have a example of cert err m getcertificate so the certificates can be used in grpc i fail to come up with a solution go m autocert manager cache autocert dircache tls prompt autocert accepttos hostpolicy autocert hostwhitelist example com go http listenandserve http m httphandler nil cert err m getcertificate if err nil t fatalf failed to generate certificates s err creds credentials newservertlsfromcert cert srv grpc newserver grpc creds creds reflection register srv ,1 +56436,8072944437.0,IssuesEvent,2018-08-06 17:36:51,golang/go,https://api.github.com/repos/golang/go,closed,cmd/cgo: CoreFoundation go-keychain compile failure on tip,Documentation NeedsFix OS-Darwin release-blocker,"Please answer these questions before submitting your issue. Thanks! + +#### What did you do? + +Check out tip of github.com/keybase/go-keychain (commit https://github.com/keybase/go-keychain/commit/70b98e9c8d754db775c5bd3b2de3670cc76f1825) and run `go build github.com/keybase/go-keychain` + +#### What did you expect to see? + +I expected the program to compile. + +#### What did you see instead? + +``` +$ go build . +# github.com/keybase/go-keychain +./corefoundation_1.10.go:55: cannot use nil as type _Ctype_CFAllocatorRef in argument to _Cfunc_CFDataCreate +./corefoundation_1.10.go:81: cannot use nil as type _Ctype_CFAllocatorRef in argument to func literal +./corefoundation_1.10.go:118: cannot use nil as type _Ctype_CFAllocatorRef in argument to _Cfunc_CFStringCreateWithBytes +./corefoundation_1.10.go:153: cannot use nil as type _Ctype_CFAllocatorRef in argument to func literal +``` + +#### Does this issue reproduce with the latest release (go1.10.3)? + +No. I can reproduce it using tip though, which suggests that this code will break in the upcoming Go 1.11 release. + +A git bisect revealed that commit 94076feef53c41c0c558a8686d6f2650b1614414 is the first commit to break; versions of Go compiled with commits earlier than this commit successfully compile the go-keychain library, newer ones don't. + +#### System details + +``` +go version devel +94076feef5 Mon Jul 9 22:19:21 2018 +0000 darwin/amd64 +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/kevin.burke/Library/Caches/go-build"" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/kevin.burke"" +GOPROXY="""" +GORACE="""" +GOROOT=""/Users/kevin.burke/go"" +GOTMPDIR="""" +GOTOOLDIR=""/Users/kevin.burke/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/bs/n3zm0wvn7j14n9gm_ybk4klsg6mgyh/T/go-build618247201=/tmp/go-build -gno-record-gcc-switches -fno-common"" +VGOMODROOT="""" +GOROOT/bin/go version: go version devel +94076feef5 Mon Jul 9 22:19:21 2018 +0000 darwin/amd64 +GOROOT/bin/go tool compile -V: compile version devel +94076feef5 Mon Jul 9 22:19:21 2018 +0000 +uname -v: Darwin Kernel Version 17.7.0: Thu Jun 21 22:53:14 PDT 2018; root:xnu-4570.71.2~1/RELEASE_X86_64 +ProductName: Mac OS X +ProductVersion: 10.13.6 +BuildVersion: 17G65 +lldb --version: lldb-902.0.79.7 + Swift-4.1 +``` +",1.0,"cmd/cgo: CoreFoundation go-keychain compile failure on tip - Please answer these questions before submitting your issue. Thanks! + +#### What did you do? + +Check out tip of github.com/keybase/go-keychain (commit https://github.com/keybase/go-keychain/commit/70b98e9c8d754db775c5bd3b2de3670cc76f1825) and run `go build github.com/keybase/go-keychain` + +#### What did you expect to see? + +I expected the program to compile. + +#### What did you see instead? + +``` +$ go build . +# github.com/keybase/go-keychain +./corefoundation_1.10.go:55: cannot use nil as type _Ctype_CFAllocatorRef in argument to _Cfunc_CFDataCreate +./corefoundation_1.10.go:81: cannot use nil as type _Ctype_CFAllocatorRef in argument to func literal +./corefoundation_1.10.go:118: cannot use nil as type _Ctype_CFAllocatorRef in argument to _Cfunc_CFStringCreateWithBytes +./corefoundation_1.10.go:153: cannot use nil as type _Ctype_CFAllocatorRef in argument to func literal +``` + +#### Does this issue reproduce with the latest release (go1.10.3)? + +No. I can reproduce it using tip though, which suggests that this code will break in the upcoming Go 1.11 release. + +A git bisect revealed that commit 94076feef53c41c0c558a8686d6f2650b1614414 is the first commit to break; versions of Go compiled with commits earlier than this commit successfully compile the go-keychain library, newer ones don't. + +#### System details + +``` +go version devel +94076feef5 Mon Jul 9 22:19:21 2018 +0000 darwin/amd64 +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/kevin.burke/Library/Caches/go-build"" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/kevin.burke"" +GOPROXY="""" +GORACE="""" +GOROOT=""/Users/kevin.burke/go"" +GOTMPDIR="""" +GOTOOLDIR=""/Users/kevin.burke/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/bs/n3zm0wvn7j14n9gm_ybk4klsg6mgyh/T/go-build618247201=/tmp/go-build -gno-record-gcc-switches -fno-common"" +VGOMODROOT="""" +GOROOT/bin/go version: go version devel +94076feef5 Mon Jul 9 22:19:21 2018 +0000 darwin/amd64 +GOROOT/bin/go tool compile -V: compile version devel +94076feef5 Mon Jul 9 22:19:21 2018 +0000 +uname -v: Darwin Kernel Version 17.7.0: Thu Jun 21 22:53:14 PDT 2018; root:xnu-4570.71.2~1/RELEASE_X86_64 +ProductName: Mac OS X +ProductVersion: 10.13.6 +BuildVersion: 17G65 +lldb --version: lldb-902.0.79.7 + Swift-4.1 +``` +",1,cmd cgo corefoundation go keychain compile failure on tip please answer these questions before submitting your issue thanks what did you do check out tip of github com keybase go keychain commit and run go build github com keybase go keychain what did you expect to see i expected the program to compile what did you see instead go build github com keybase go keychain corefoundation go cannot use nil as type ctype cfallocatorref in argument to cfunc cfdatacreate corefoundation go cannot use nil as type ctype cfallocatorref in argument to func literal corefoundation go cannot use nil as type ctype cfallocatorref in argument to cfunc cfstringcreatewithbytes corefoundation go cannot use nil as type ctype cfallocatorref in argument to func literal does this issue reproduce with the latest release no i can reproduce it using tip though which suggests that this code will break in the upcoming go release a git bisect revealed that commit is the first commit to break versions of go compiled with commits earlier than this commit successfully compile the go keychain library newer ones don t system details go version devel mon jul darwin goarch gobin gocache users kevin burke library caches go build goexe gohostarch gohostos darwin goos darwin gopath users kevin burke goproxy gorace goroot users kevin burke go gotmpdir gotooldir users kevin burke go pkg tool darwin gccgo gccgo cc clang cxx clang cgo enabled cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map var folders bs t go tmp go build gno record gcc switches fno common vgomodroot goroot bin go version go version devel mon jul darwin goroot bin go tool compile v compile version devel mon jul uname v darwin kernel version thu jun pdt root xnu release productname mac os x productversion buildversion lldb version lldb swift ,1 +152015,13441559559.0,IssuesEvent,2020-09-08 04:31:42,golang/go,https://api.github.com/repos/golang/go,opened,testing: document rules for using TB,Documentation,"There's rules about what a `TestFoo` may do with the `*testing.T` it is given. Some are documented (e.g. https://golang.org/pkg/testing/#T puts restrictions on invoking `Fatalf` and friends), but some are not (e.g. `Logf` and probably most other methods should not be called after `TestFoo` returns). Same applies to `*testing.B` and any future such values/types. + +I came across this while trying to diagnose a problem that seems to be due to #40908, but realised I couldn't find the rules written down anywhere.",1.0,"testing: document rules for using TB - There's rules about what a `TestFoo` may do with the `*testing.T` it is given. Some are documented (e.g. https://golang.org/pkg/testing/#T puts restrictions on invoking `Fatalf` and friends), but some are not (e.g. `Logf` and probably most other methods should not be called after `TestFoo` returns). Same applies to `*testing.B` and any future such values/types. + +I came across this while trying to diagnose a problem that seems to be due to #40908, but realised I couldn't find the rules written down anywhere.",1,testing document rules for using tb there s rules about what a testfoo may do with the testing t it is given some are documented e g puts restrictions on invoking fatalf and friends but some are not e g logf and probably most other methods should not be called after testfoo returns same applies to testing b and any future such values types i came across this while trying to diagnose a problem that seems to be due to but realised i couldn t find the rules written down anywhere ,1 +23773,4974258524.0,IssuesEvent,2016-12-06 05:31:25,golang/go,https://api.github.com/repos/golang/go,opened,doc: installation docs don't list all OS architectures,Documentation,"https://beta.golang.org/doc/install says: + +Operating System: ""Linux 2.6.23 or later with glibc"" .... Architectures: ""amd64, 386, arm"" + +That's missing a bunch. + +Also, for FreeBSD, it only lists amd64, but 386 and arm are also supported. + +/cc @minux ",1.0,"doc: installation docs don't list all OS architectures - https://beta.golang.org/doc/install says: + +Operating System: ""Linux 2.6.23 or later with glibc"" .... Architectures: ""amd64, 386, arm"" + +That's missing a bunch. + +Also, for FreeBSD, it only lists amd64, but 386 and arm are also supported. + +/cc @minux ",1,doc installation docs don t list all os architectures says operating system linux or later with glibc architectures arm that s missing a bunch also for freebsd it only lists but and arm are also supported cc minux ,1 +58616,8289435903.0,IssuesEvent,2018-09-19 14:41:10,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: provide advice for authors of existing packages with version v2.0+,Documentation NeedsInvestigation modules,"Hi, +I was testing vgo the other day, trying to import some 3rd party dependencies that have version v2.0 or higher released on Github, but I couldn't figure out how. + +Example: +Given [github.com/go-chi/chi](https://github.com/go-chi/chi) has latest version v3.3.2 released as a [git tag](https://github.com/go-chi/chi/releases/tag/v3.3.2) on Github, +I'd like to import `github.com/go-chi/chi/v3` in my project, develop against it and eventually vendor it via `vgo vendor`. + +```go +package main + +import ""github.com/go-chi/chi/v3"" + +func main() { + _ = chi.NewRouter() +} +``` + +But since github.com/go-chi/chi didn't release a v3 module yet, I get this error: +```bash +$ vgo run main.go +vgo: creating new go.mod: module github.com/VojtechVitek/vgo-test +vgo: resolving import ""github.com/go-chi/chi/v3"" +vgo: finding github.com/go-chi/chi (latest) +vgo: adding github.com/go-chi/chi v1.0.0 +vgo: import ""github.com/go-chi/chi/v3"" [/Users/vojtechvitek/go/src/v/github.com/go-chi/chi@v1.0.0/v3]: open /Users/vojtechvitek/go/src/v/github.com/go-chi/chi@v1.0.0/v3: no such file or directory +``` + +vgo found version v1.0.0 but couldn't find ""v3"" subpkg. So I added an explicit version to my go.mod file and tried again: +``` +$ cat go.mod +module github.com/VojtechVitek/vgo-test + +require ( + github.com/go-chi/chi v3.3.2 +) +``` + +running vgo again caused a silent side effect: +```diff +module github.com/VojtechVitek/vgo-test + +require ( +- github.com/go-chi/chi v3.3.2 ++ github.com/go-chi/chi v0.0.0-20171222161133-e83ac2304db3 +) +``` + +Hmm, seems like vgo doesn't see any v2.0+ tags? After reading some more blog posts on https://research.swtch.com (since `vgo` CLI help didn't seem to be very helpful / novice user friendly), I confirmed with: +``` +$ vgo list -t github.com/go-chi/chi +github.com/go-chi/chi + v0.9.0 + v1.0.0 +``` + +Now, I might be missing something, but it's not really clear to me how can I import v2.0+ or v3.0+ of a package (should I say module?) that I don't have any control over and ""is not ready yet"". + +Are there any guidelines for package consumers about this? Are there any guidelines for package authors? I couldn't find anything useful neither in research.swtch.com/vgo-module, nor in the accepted proposal or in the [wiki](https://github.com/golang/go/wiki/vgo). + + +// EDIT: +``` +$ vgo list -t github.com/go-chi/chi/v3 +github.com/go-chi/chi/v3 + v3.0.0 + v3.1.0 + v3.1.1 + v3.1.2 + v3.1.3 + v3.1.4 + v3.1.5 + v3.2.0 + v3.2.1 + v3.3.0 + v3.3.1 + v3.3.2 +``` + +Ahaa, so I can list v3.0+ tags. But how do I use them in my monorepo properly? + +``` +$ vgo get github.com/go-chi/chi/v3 +vgo: creating new go.mod: module github.com/VojtechVitek/vgo-test +vgo: github.com/go-chi/chi/v3 v3.3.2: missing or invalid go.mod +vgo get: missing or invalid go.mod +```",1.0,"cmd/go: provide advice for authors of existing packages with version v2.0+ - Hi, +I was testing vgo the other day, trying to import some 3rd party dependencies that have version v2.0 or higher released on Github, but I couldn't figure out how. + +Example: +Given [github.com/go-chi/chi](https://github.com/go-chi/chi) has latest version v3.3.2 released as a [git tag](https://github.com/go-chi/chi/releases/tag/v3.3.2) on Github, +I'd like to import `github.com/go-chi/chi/v3` in my project, develop against it and eventually vendor it via `vgo vendor`. + +```go +package main + +import ""github.com/go-chi/chi/v3"" + +func main() { + _ = chi.NewRouter() +} +``` + +But since github.com/go-chi/chi didn't release a v3 module yet, I get this error: +```bash +$ vgo run main.go +vgo: creating new go.mod: module github.com/VojtechVitek/vgo-test +vgo: resolving import ""github.com/go-chi/chi/v3"" +vgo: finding github.com/go-chi/chi (latest) +vgo: adding github.com/go-chi/chi v1.0.0 +vgo: import ""github.com/go-chi/chi/v3"" [/Users/vojtechvitek/go/src/v/github.com/go-chi/chi@v1.0.0/v3]: open /Users/vojtechvitek/go/src/v/github.com/go-chi/chi@v1.0.0/v3: no such file or directory +``` + +vgo found version v1.0.0 but couldn't find ""v3"" subpkg. So I added an explicit version to my go.mod file and tried again: +``` +$ cat go.mod +module github.com/VojtechVitek/vgo-test + +require ( + github.com/go-chi/chi v3.3.2 +) +``` + +running vgo again caused a silent side effect: +```diff +module github.com/VojtechVitek/vgo-test + +require ( +- github.com/go-chi/chi v3.3.2 ++ github.com/go-chi/chi v0.0.0-20171222161133-e83ac2304db3 +) +``` + +Hmm, seems like vgo doesn't see any v2.0+ tags? After reading some more blog posts on https://research.swtch.com (since `vgo` CLI help didn't seem to be very helpful / novice user friendly), I confirmed with: +``` +$ vgo list -t github.com/go-chi/chi +github.com/go-chi/chi + v0.9.0 + v1.0.0 +``` + +Now, I might be missing something, but it's not really clear to me how can I import v2.0+ or v3.0+ of a package (should I say module?) that I don't have any control over and ""is not ready yet"". + +Are there any guidelines for package consumers about this? Are there any guidelines for package authors? I couldn't find anything useful neither in research.swtch.com/vgo-module, nor in the accepted proposal or in the [wiki](https://github.com/golang/go/wiki/vgo). + + +// EDIT: +``` +$ vgo list -t github.com/go-chi/chi/v3 +github.com/go-chi/chi/v3 + v3.0.0 + v3.1.0 + v3.1.1 + v3.1.2 + v3.1.3 + v3.1.4 + v3.1.5 + v3.2.0 + v3.2.1 + v3.3.0 + v3.3.1 + v3.3.2 +``` + +Ahaa, so I can list v3.0+ tags. But how do I use them in my monorepo properly? + +``` +$ vgo get github.com/go-chi/chi/v3 +vgo: creating new go.mod: module github.com/VojtechVitek/vgo-test +vgo: github.com/go-chi/chi/v3 v3.3.2: missing or invalid go.mod +vgo get: missing or invalid go.mod +```",1,cmd go provide advice for authors of existing packages with version hi i was testing vgo the other day trying to import some party dependencies that have version or higher released on github but i couldn t figure out how example given has latest version released as a on github i d like to import github com go chi chi in my project develop against it and eventually vendor it via vgo vendor go package main import github com go chi chi func main chi newrouter but since github com go chi chi didn t release a module yet i get this error bash vgo run main go vgo creating new go mod module github com vojtechvitek vgo test vgo resolving import github com go chi chi vgo finding github com go chi chi latest vgo adding github com go chi chi vgo import github com go chi chi open users vojtechvitek go src v github com go chi chi no such file or directory vgo found version but couldn t find subpkg so i added an explicit version to my go mod file and tried again cat go mod module github com vojtechvitek vgo test require github com go chi chi running vgo again caused a silent side effect diff module github com vojtechvitek vgo test require github com go chi chi github com go chi chi hmm seems like vgo doesn t see any tags after reading some more blog posts on since vgo cli help didn t seem to be very helpful novice user friendly i confirmed with vgo list t github com go chi chi github com go chi chi now i might be missing something but it s not really clear to me how can i import or of a package should i say module that i don t have any control over and is not ready yet are there any guidelines for package consumers about this are there any guidelines for package authors i couldn t find anything useful neither in research swtch com vgo module nor in the accepted proposal or in the edit vgo list t github com go chi chi github com go chi chi ahaa so i can list tags but how do i use them in my monorepo properly vgo get github com go chi chi vgo creating new go mod module github com vojtechvitek vgo test vgo github com go chi chi missing or invalid go mod vgo get missing or invalid go mod ,1 +435639,30511131430.0,IssuesEvent,2023-07-18 20:56:44,golang/go,https://api.github.com/repos/golang/go,opened,doc: write release notes for Go 1.22,Documentation NeedsFix release-blocker umbrella,"This is the tracking issue for writing the Go 1.22 Release Notes. The version at tip can be viewed at https://tip.golang.org/doc/go1.22. + +When the Go 1.22 Release Notes are complete, this should be closed, and a similar issue should be made for the next release. The previous issue was #58645.",1.0,"doc: write release notes for Go 1.22 - This is the tracking issue for writing the Go 1.22 Release Notes. The version at tip can be viewed at https://tip.golang.org/doc/go1.22. + +When the Go 1.22 Release Notes are complete, this should be closed, and a similar issue should be made for the next release. The previous issue was #58645.",1,doc write release notes for go this is the tracking issue for writing the go release notes the version at tip can be viewed at when the go release notes are complete this should be closed and a similar issue should be made for the next release the previous issue was ,1 +130845,12463776118.0,IssuesEvent,2020-05-28 11:14:51,golang/go,https://api.github.com/repos/golang/go,closed,x/tools/cmd/godoc: support exporting HTML documentation,Documentation Tools WaitingForInfo,"Is there a way to generate a godoc for a module/package or export the generated documentation in a static file format? + +Currently way of generating docs: +`godoc -http=:PORT` + +Can we add an export button mechanism to the page? That can export the document for the entire project. ",1.0,"x/tools/cmd/godoc: support exporting HTML documentation - Is there a way to generate a godoc for a module/package or export the generated documentation in a static file format? + +Currently way of generating docs: +`godoc -http=:PORT` + +Can we add an export button mechanism to the page? That can export the document for the entire project. ",1,x tools cmd godoc support exporting html documentation is there a way to generate a godoc for a module package or export the generated documentation in a static file format currently way of generating docs godoc http port can we add an export button mechanism to the page that can export the document for the entire project ,1 +117146,9914440812.0,IssuesEvent,2019-06-28 14:23:08,golang/go,https://api.github.com/repos/golang/go,opened,golang.org/x/tools/go/packages: panic in testParseFileModifyAST,NeedsInvestigation Testing,"Observed in https://build.golang.org/log/269df758e38c6dcc180de71777773231b6f98014 (on `windows-amd64-2016`): + +``` +panic: runtime error: index out of range [recovered] + panic: runtime error: index out of range + +goroutine 512 [running]: +testing.tRunner.func1(0xc0001bab00) + C:/workdir/go/src/testing/testing.go:830 +0x399 +panic(0x6e5800, 0x9959e0) + C:/workdir/go/src/runtime/panic.go:522 +0x1c3 +golang.org/x/tools/go/packages_test.testParseFileModifyAST(0xc0001bab00, 0x7a5740, 0x9bbf10) + C:/workdir/gopath/src/golang.org/x/tools/go/packages/packages_test.go:852 +0x4b9 +golang.org/x/tools/go/packages/packagestest.TestAll.func1(0xc0001bab00) + C:/workdir/gopath/src/golang.org/x/tools/go/packages/packagestest/export.go:101 +0x6f +testing.tRunner(0xc0001bab00, 0xc000047e60) + C:/workdir/go/src/testing/testing.go:865 +0xc7 +created by testing.(*T).Run + C:/workdir/go/src/testing/testing.go:916 +0x361 +FAIL golang.org/x/tools/go/packages 17.895s +``` + +It's not obvious to me whether this is a secondary symptom of the race reported in #31749 or an unrelated bug. + +CC @matloob @ianthehat ",1.0,"golang.org/x/tools/go/packages: panic in testParseFileModifyAST - Observed in https://build.golang.org/log/269df758e38c6dcc180de71777773231b6f98014 (on `windows-amd64-2016`): + +``` +panic: runtime error: index out of range [recovered] + panic: runtime error: index out of range + +goroutine 512 [running]: +testing.tRunner.func1(0xc0001bab00) + C:/workdir/go/src/testing/testing.go:830 +0x399 +panic(0x6e5800, 0x9959e0) + C:/workdir/go/src/runtime/panic.go:522 +0x1c3 +golang.org/x/tools/go/packages_test.testParseFileModifyAST(0xc0001bab00, 0x7a5740, 0x9bbf10) + C:/workdir/gopath/src/golang.org/x/tools/go/packages/packages_test.go:852 +0x4b9 +golang.org/x/tools/go/packages/packagestest.TestAll.func1(0xc0001bab00) + C:/workdir/gopath/src/golang.org/x/tools/go/packages/packagestest/export.go:101 +0x6f +testing.tRunner(0xc0001bab00, 0xc000047e60) + C:/workdir/go/src/testing/testing.go:865 +0xc7 +created by testing.(*T).Run + C:/workdir/go/src/testing/testing.go:916 +0x361 +FAIL golang.org/x/tools/go/packages 17.895s +``` + +It's not obvious to me whether this is a secondary symptom of the race reported in #31749 or an unrelated bug. + +CC @matloob @ianthehat ",0,golang org x tools go packages panic in testparsefilemodifyast observed in on windows panic runtime error index out of range panic runtime error index out of range goroutine testing trunner c workdir go src testing testing go panic c workdir go src runtime panic go golang org x tools go packages test testparsefilemodifyast c workdir gopath src golang org x tools go packages packages test go golang org x tools go packages packagestest testall c workdir gopath src golang org x tools go packages packagestest export go testing trunner c workdir go src testing testing go created by testing t run c workdir go src testing testing go fail golang org x tools go packages it s not obvious to me whether this is a secondary symptom of the race reported in or an unrelated bug cc matloob ianthehat ,0 +96630,27963934469.0,IssuesEvent,2023-03-24 17:46:57,golang/go,https://api.github.com/repos/golang/go,closed,x/build/cmd/gitmirror: down due to new GitHub key,Builders NeedsFix Soon,https://github.blog/2023-03-23-we-updated-our-rsa-ssh-host-key/ broke gitmirror. I'm updating the key built into the Docker image.,1.0,x/build/cmd/gitmirror: down due to new GitHub key - https://github.blog/2023-03-23-we-updated-our-rsa-ssh-host-key/ broke gitmirror. I'm updating the key built into the Docker image.,0,x build cmd gitmirror down due to new github key broke gitmirror i m updating the key built into the docker image ,0 +275121,20907589675.0,IssuesEvent,2022-03-24 05:09:39,golang/go,https://api.github.com/repos/golang/go,closed,"spec: in array and slice literals, the index/key can be non-integer type",Documentation NeedsFix,"### What version of Go are you using (`go version`)? +Go playground + +### What operating system and processor architecture are you using (`go env`)? +```golang +package main + +const k float64 = 3.0 + +var _ = []int{k: 3} +var _ = [...]int{k: 3} + +func main() {} +``` +See https://play.golang.org/p/x3keRiD0fVT. This compiles without an error. + +### What did you expect to see? + +From the spec: + +> For array and slice literals the following rules apply: +> * Each element has an associated integer index marking its position in the array. +> * An element with a key uses the key as its index. The key must be a non-negative constant representable by a value of type int; and **_if it is typed it must be of integer type_**. +> * An element without a key uses the previous element's index plus one. If the first element has no key, its index is zero. + +It mentions that if the index is typed, it must be of integer type. However, the above code compiles even if the index has type `float64`. Probably the spec should be saying ""can be converted to int"" or something, or the compiler should report an error?",1.0,"spec: in array and slice literals, the index/key can be non-integer type - ### What version of Go are you using (`go version`)? +Go playground + +### What operating system and processor architecture are you using (`go env`)? +```golang +package main + +const k float64 = 3.0 + +var _ = []int{k: 3} +var _ = [...]int{k: 3} + +func main() {} +``` +See https://play.golang.org/p/x3keRiD0fVT. This compiles without an error. + +### What did you expect to see? + +From the spec: + +> For array and slice literals the following rules apply: +> * Each element has an associated integer index marking its position in the array. +> * An element with a key uses the key as its index. The key must be a non-negative constant representable by a value of type int; and **_if it is typed it must be of integer type_**. +> * An element without a key uses the previous element's index plus one. If the first element has no key, its index is zero. + +It mentions that if the index is typed, it must be of integer type. However, the above code compiles even if the index has type `float64`. Probably the spec should be saying ""can be converted to int"" or something, or the compiler should report an error?",1,spec in array and slice literals the index key can be non integer type what version of go are you using go version go playground what operating system and processor architecture are you using go env golang package main const k var int k var int k func main see this compiles without an error what did you expect to see from the spec for array and slice literals the following rules apply each element has an associated integer index marking its position in the array an element with a key uses the key as its index the key must be a non negative constant representable by a value of type int and if it is typed it must be of integer type an element without a key uses the previous element s index plus one if the first element has no key its index is zero it mentions that if the index is typed it must be of integer type however the above code compiles even if the index has type probably the spec should be saying can be converted to int or something or the compiler should report an error ,1 +98234,11048750026.0,IssuesEvent,2019-12-09 21:51:31,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: document that go env GOMOD can return /dev/null,Documentation NeedsInvestigation," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version devel +da4d58587e Sat Dec 7 15:57:30 2019 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/myitcv/.cache/go-build"" +GOENV=""/home/myitcv/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/myitcv/gostuff"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/home/myitcv/gos"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/home/myitcv/gos/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build492256999=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version devel +da4d58587e Sat Dec 7 15:57:30 2019 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/myitcv/.cache/go-build"" +GOENV=""/home/myitcv/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/myitcv/gostuff"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/home/myitcv/gos"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/home/myitcv/gos/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build492256999=/tmp/go-build -gno-record-gcc-switches"" +
There's almost no text on what a function actually is. Needs to be expanded.,1.0,spec: define what a function is -
There's almost no text on what a function actually is. Needs to be expanded.,1,spec define what a function is there s almost no text on what a function actually is needs to be expanded ,1 +32175,6037238832.0,IssuesEvent,2017-06-09 18:10:05,golang/go,https://api.github.com/repos/golang/go,closed,os/exec: docs bugs sections points to an issue with unsupported OS version,Documentation,"https://golang.org/pkg/os/exec/#pkg-note-BUG points to a bug which exists in an unsupported macosx version 10.6 only (I suppose). (https://github.com/golang/go/wiki/MinimumRequirements) + +Should this be removed?",1.0,"os/exec: docs bugs sections points to an issue with unsupported OS version - https://golang.org/pkg/os/exec/#pkg-note-BUG points to a bug which exists in an unsupported macosx version 10.6 only (I suppose). (https://github.com/golang/go/wiki/MinimumRequirements) + +Should this be removed?",1,os exec docs bugs sections points to an issue with unsupported os version points to a bug which exists in an unsupported macosx version only i suppose should this be removed ,1 +278802,21097007494.0,IssuesEvent,2022-04-04 11:17:01,golang/go,https://api.github.com/repos/golang/go,closed,strings: Docs & Examples unclear about difference between ToTitle and ToUpper,Documentation NeedsInvestigation," + +### What version of Go are you using (`go version`)? + +The current documentation on https://golang.org/pkg/strings/ + +### Does this issue reproduce with the latest release? + +Yes, using the examples inside the strings package documentation + +### What operating system and processor architecture are you using (`go env`)? + +None providable + +### What did you do? + +Copied `strings.ToTitle` example to `strings.ToUpper` and changed `ToTitle()` to `ToUpper()`: +``` +package main + +import ( + ""fmt"" + ""strings"" +) + +func main() { + fmt.Println(strings.ToUpper(""her royal highness"")) + fmt.Println(strings.ToUpper(""loud noises"")) + fmt.Println(strings.ToUpper(""хлеб"")) +} +``` + +### What did you expect to see? + +A difference in output. + +### What did you see instead? + +Example ToTitle (unmodified) outputs: +``` +HER ROYAL HIGHNESS +LOUD NOISES +ХЛЕБ +``` + +Example ToUpper (modified as described above) outputs: +``` +HER ROYAL HIGHNESS +LOUD NOISES +ХЛЕБ +``` + +No difference. So for me it is unclear which function is now the correct one to use for an imaginary case.",1.0,"strings: Docs & Examples unclear about difference between ToTitle and ToUpper - + +### What version of Go are you using (`go version`)? + +The current documentation on https://golang.org/pkg/strings/ + +### Does this issue reproduce with the latest release? + +Yes, using the examples inside the strings package documentation + +### What operating system and processor architecture are you using (`go env`)? + +None providable + +### What did you do? + +Copied `strings.ToTitle` example to `strings.ToUpper` and changed `ToTitle()` to `ToUpper()`: +``` +package main + +import ( + ""fmt"" + ""strings"" +) + +func main() { + fmt.Println(strings.ToUpper(""her royal highness"")) + fmt.Println(strings.ToUpper(""loud noises"")) + fmt.Println(strings.ToUpper(""хлеб"")) +} +``` + +### What did you expect to see? + +A difference in output. + +### What did you see instead? + +Example ToTitle (unmodified) outputs: +``` +HER ROYAL HIGHNESS +LOUD NOISES +ХЛЕБ +``` + +Example ToUpper (modified as described above) outputs: +``` +HER ROYAL HIGHNESS +LOUD NOISES +ХЛЕБ +``` + +No difference. So for me it is unclear which function is now the correct one to use for an imaginary case.",1,strings docs examples unclear about difference between totitle and toupper please answer these questions before submitting your issue thanks for questions please use one of our forums what version of go are you using go version the current documentation on does this issue reproduce with the latest release yes using the examples inside the strings package documentation what operating system and processor architecture are you using go env none providable what did you do copied strings totitle example to strings toupper and changed totitle to toupper package main import fmt strings func main fmt println strings toupper her royal highness fmt println strings toupper loud noises fmt println strings toupper хлеб what did you expect to see a difference in output what did you see instead example totitle unmodified outputs her royal highness loud noises хлеб example toupper modified as described above outputs her royal highness loud noises хлеб no difference so for me it is unclear which function is now the correct one to use for an imaginary case ,1 +55167,30612707400.0,IssuesEvent,2023-07-23 20:15:22,golang/go,https://api.github.com/repos/golang/go,closed,runtime: special case timer channels,Performance NeedsFix early-in-cycle,"
Consider special-casing timer channels created with time.Ticker and time.After.
+Namely, such chans need to contain next fire time and period. Then receive from such
+looks like:
+
+func chanrecv(c *Hchan) {
+ ...
+ if c.isTimeChan {
+ for {
+ next := c.nextTime
+ if next == -1 {
+ // already fired one-time timer
+ blockForever()
+ }
+ newTime := -1
+ if c.period != 0 {
+ newTime = next + c.period
+ }
+ if CAS(&c.nextTime, next, newTime) {
+ wait := next - now
+ if wait > 0 {
+ sleepFor(wait)
+ }
+ return
+ }
+ }
+ }
+ ...
+}
+
+This has several advantages:
+1. No need to stop timers. If nobody waits on a timers, it's just a normal heap object
+that can be garbage collected.
+2. Faster operation for both blocking and non-blocking case.
+3. Faster selects involving time chans.
+4. Can combine time.Ticker/After into a single allocation.
+",True,"runtime: special case timer channels - Consider special-casing timer channels created with time.Ticker and time.After.
+Namely, such chans need to contain next fire time and period. Then receive from such
+looks like:
+
+func chanrecv(c *Hchan) {
+ ...
+ if c.isTimeChan {
+ for {
+ next := c.nextTime
+ if next == -1 {
+ // already fired one-time timer
+ blockForever()
+ }
+ newTime := -1
+ if c.period != 0 {
+ newTime = next + c.period
+ }
+ if CAS(&c.nextTime, next, newTime) {
+ wait := next - now
+ if wait > 0 {
+ sleepFor(wait)
+ }
+ return
+ }
+ }
+ }
+ ...
+}
+
+This has several advantages:
+1. No need to stop timers. If nobody waits on a timers, it's just a normal heap object
+that can be garbage collected.
+2. Faster operation for both blocking and non-blocking case.
+3. Faster selects involving time chans.
+4. Can combine time.Ticker/After into a single allocation.
+",0,runtime special case timer channels consider special casing timer channels created with time ticker and time after namely such chans need to contain next fire time and period then receive from such looks like func chanrecv c hchan if c istimechan for next c nexttime if next already fired one time timer blockforever newtime if c period newtime next c period if cas amp c nexttime next newtime wait next now if wait gt sleepfor wait return this has several advantages no need to stop timers if nobody waits on a timers it s just a normal heap object that can be garbage collected faster operation for both blocking and non blocking case faster selects involving time chans can combine time ticker after into a single allocation ,0
+149775,13302143613.0,IssuesEvent,2020-08-25 13:54:29,golang/go,https://api.github.com/repos/golang/go,opened,x/pkgsite: documentation how to add experiments locally,Documentation NeedsFix pkgsite,"We should add a `doc/experiment.md` file which describes how to add experiments when running locally, including:
+
+- Running `go run devtools/cmd/experiment/experiment.go create +$ go version +go version devel +c20b71eb37 Sat Nov 16 02:06:39 2019 +0000 linux/amd6 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/u/.cache/go-build"" +GOENV=""/home/u/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/u/goget:/home/u/Desktop/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/home/u/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/home/u/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/u/go/src/cmd/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build745246669=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version devel +c20b71eb37 Sat Nov 16 02:06:39 2019 +0000 linux/amd6 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/u/.cache/go-build"" +GOENV=""/home/u/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/u/goget:/home/u/Desktop/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/home/u/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/home/u/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/u/go/src/cmd/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build745246669=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +1.15 ++ +### Does this issue reproduce with the latest release? +yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/josh/.cache/go-build"" +GOENV=""/home/josh/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/josh/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/josh/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/josh/projects/go/greetings/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build087138363=/tmp/go-build -gno-record-gcc-switches"" + +
+$ go version +1.15 ++ +### Does this issue reproduce with the latest release? +yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/josh/.cache/go-build"" +GOENV=""/home/josh/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/josh/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/josh/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/josh/projects/go/greetings/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build087138363=/tmp/go-build -gno-record-gcc-switches"" + +
+$ go version +go version devel +633f9e2060 Wed Nov 4 06:42:33 2020 +0000 darwin/amd64 + ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE=""on"" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/artyom/Library/Caches/go-build"" +GOENV=""/Users/artyom/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS=""-ldflags=-w -trimpath"" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/artyom/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/artyom/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/Users/artyom/Repositories/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/Users/artyom/Repositories/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/lb/3rk8rqs53czgb4v35w_342xc0000gn/T/go-build536273506=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
+$ go version +go version devel +633f9e2060 Wed Nov 4 06:42:33 2020 +0000 darwin/amd64 + ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE=""on"" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/artyom/Library/Caches/go-build"" +GOENV=""/Users/artyom/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS=""-ldflags=-w -trimpath"" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/artyom/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/artyom/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/Users/artyom/Repositories/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/Users/artyom/Repositories/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/lb/3rk8rqs53czgb4v35w_342xc0000gn/T/go-build536273506=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
go env Output+$ go env + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/yenlinc/Library/Caches/go-build"" +GOENV=""/Users/yenlinc/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GONOPROXY=""*"" +GONOSUMDB=""*"" +GOOS=""darwin"" +GOPATH=""/Users/yenlinc/go"" +GOPRIVATE=""*"" +GOPROXY=""direct"" +GOROOT=""/usr/local/Cellar/go/1.14.3/libexec"" +GOSUMDB=""off"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.14.3/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/yenlinc/workplace/yenlinc/amazon-kinesis-streams-for-fluent-bit/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/v4/nbxvs8tj4ms68w5ghhnzn_f1ckngqg/T/go-build594642831=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
go env Output+$ go env + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/yenlinc/Library/Caches/go-build"" +GOENV=""/Users/yenlinc/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GONOPROXY=""*"" +GONOSUMDB=""*"" +GOOS=""darwin"" +GOPATH=""/Users/yenlinc/go"" +GOPRIVATE=""*"" +GOPROXY=""direct"" +GOROOT=""/usr/local/Cellar/go/1.14.3/libexec"" +GOSUMDB=""off"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.14.3/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/yenlinc/workplace/yenlinc/amazon-kinesis-streams-for-fluent-bit/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/v4/nbxvs8tj4ms68w5ghhnzn_f1ckngqg/T/go-build594642831=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+ TODO: https://golang.org/cl/301493: add a mode to skip func-check on parsing +
++ TODO: https://golang.org/cl/301493: add a mode to skip func-check on parsing +
+Most websites store their templates in files on disk. It would be convenient if the +documentation provided an example with template data stored in a file, then loaded into +memory and executed with variables and a byte buffer.",1.0,"html/template: Provide an example of loading a template from a file and executing it. - by **kburkeorg**: + +
Most websites store their templates in files on disk. It would be convenient if the +documentation provided an example with template data stored in a file, then loaded into +memory and executed with variables and a byte buffer.",1,html template provide an example of loading a template from a file and executing it by kburkeorg most websites store their templates in files on disk it would be convenient if the documentation provided an example with template data stored in a file then loaded into memory and executed with variables and a byte buffer ,1 +108063,11579674191.0,IssuesEvent,2020-02-21 18:27:03,golang/go,https://api.github.com/repos/golang/go,closed,encoding/json: document change in Number behavior for 1.14,Documentation NeedsFix release-blocker,"I just upgraded one of our internal repositories to Go 1.14rc1 and our tests failed. + +The reason the tests failed is due to this issue: https://github.com/golang/go/issues/14702 + +I had to go in and update our code base to make Go 1.14 work, so it's technically a breaking change. + +More dangerously, this is a **runtime** breaking change and not a compile time one. + +so I can only imagine the number of Go apps out there running in production that would break because of this. + +As much as I like the new behavior, I imagine this might cause some production apps to go down in the wild. + +On one hand, the repository was incorrectly using json.Number and treating it as something that *could* be a number, but would also **allow strings**. In fact, people probably assume that's what json.Number is since it is of type string. + +I'm opening a new issue instead of commenting on the old one because I'd like to bring light into this breaking behavior and make sure we have a decision before Go 1.14 is officially released. + +cc: @mvdan @rsc + +Thanks! + +$ go version +Go 1.14rc1, darwin + + +",1.0,"encoding/json: document change in Number behavior for 1.14 - I just upgraded one of our internal repositories to Go 1.14rc1 and our tests failed. + +The reason the tests failed is due to this issue: https://github.com/golang/go/issues/14702 + +I had to go in and update our code base to make Go 1.14 work, so it's technically a breaking change. + +More dangerously, this is a **runtime** breaking change and not a compile time one. + +so I can only imagine the number of Go apps out there running in production that would break because of this. + +As much as I like the new behavior, I imagine this might cause some production apps to go down in the wild. + +On one hand, the repository was incorrectly using json.Number and treating it as something that *could* be a number, but would also **allow strings**. In fact, people probably assume that's what json.Number is since it is of type string. + +I'm opening a new issue instead of commenting on the old one because I'd like to bring light into this breaking behavior and make sure we have a decision before Go 1.14 is officially released. + +cc: @mvdan @rsc + +Thanks! + +$ go version +Go 1.14rc1, darwin + + +",1,encoding json document change in number behavior for i just upgraded one of our internal repositories to go and our tests failed the reason the tests failed is due to this issue i had to go in and update our code base to make go work so it s technically a breaking change more dangerously this is a runtime breaking change and not a compile time one so i can only imagine the number of go apps out there running in production that would break because of this as much as i like the new behavior i imagine this might cause some production apps to go down in the wild on one hand the repository was incorrectly using json number and treating it as something that could be a number but would also allow strings in fact people probably assume that s what json number is since it is of type string i m opening a new issue instead of commenting on the old one because i d like to bring light into this breaking behavior and make sure we have a decision before go is officially released cc mvdan rsc thanks go version go darwin ,1 +180843,14814879837.0,IssuesEvent,2021-01-14 06:03:17,golang/go,https://api.github.com/repos/golang/go,closed,x/tools/gopls: defining the workspace root,Documentation Tools gopls,"`gopls` supports both module and GOPATH modes. However, we need to define a scope in which language features like references, rename, and implementation should operate. The following is subject to, and will likely, change. + +For now, we have the following cases: + +### Module mode + +#### Supported +- Open workspace at the module root (directory containing the `go.mod` file). The scope is the entire module. +- Open a subdirectory of a module. The scope is the subdirectory that has been opened. + +#### Unsupported +- Open a directory that contains a module in a subdirectory. `gopls` will not work in this case. + +### GOPATH mode + +#### Supported +- Open a directory inside of your GOPATH. The scope is the open directory. + +#### At your own risk +- Open your entire GOPATH. The workspace scope will be your entire `GOPATH`. Note that this will cause `gopls` to load your entire GOPATH. If your GOPATH is large, this will take a long time and cause `gopls` to be very slow. + +To work around this case, you can create a new GOPATH that contains only the packages you want to work on. + +#### Unsupported +- Open a directory containing your GOPATH. Similar to the case above, this will cause `gopls` to treat your entire GOPATH as the workspace scope. It will be very slow to start because it will try to find all of the Go files in the directory you have opened. It will then load all of the files it has found. + +--- + +We are working on addressing all of these cases and improving the behavior of `gopls` in the unsupported cases. All of these cases will be supported once `gopls` reaches `v1.0.0`. + +We understand it may be inconvenient to change your typical workflow to accommodate frequent changes in `gopls`. In this case, it may be easier to stick with a version of `gopls` that works for you (`gopls/v0.2.2`, for instance), or if you are using GOPATH, `gopls` may not be the best tool to use until it reaches `v1.0.0`. + +If you have additional use cases that are not mentioned above, please comment below. +",1.0,"x/tools/gopls: defining the workspace root - `gopls` supports both module and GOPATH modes. However, we need to define a scope in which language features like references, rename, and implementation should operate. The following is subject to, and will likely, change. + +For now, we have the following cases: + +### Module mode + +#### Supported +- Open workspace at the module root (directory containing the `go.mod` file). The scope is the entire module. +- Open a subdirectory of a module. The scope is the subdirectory that has been opened. + +#### Unsupported +- Open a directory that contains a module in a subdirectory. `gopls` will not work in this case. + +### GOPATH mode + +#### Supported +- Open a directory inside of your GOPATH. The scope is the open directory. + +#### At your own risk +- Open your entire GOPATH. The workspace scope will be your entire `GOPATH`. Note that this will cause `gopls` to load your entire GOPATH. If your GOPATH is large, this will take a long time and cause `gopls` to be very slow. + +To work around this case, you can create a new GOPATH that contains only the packages you want to work on. + +#### Unsupported +- Open a directory containing your GOPATH. Similar to the case above, this will cause `gopls` to treat your entire GOPATH as the workspace scope. It will be very slow to start because it will try to find all of the Go files in the directory you have opened. It will then load all of the files it has found. + +--- + +We are working on addressing all of these cases and improving the behavior of `gopls` in the unsupported cases. All of these cases will be supported once `gopls` reaches `v1.0.0`. + +We understand it may be inconvenient to change your typical workflow to accommodate frequent changes in `gopls`. In this case, it may be easier to stick with a version of `gopls` that works for you (`gopls/v0.2.2`, for instance), or if you are using GOPATH, `gopls` may not be the best tool to use until it reaches `v1.0.0`. + +If you have additional use cases that are not mentioned above, please comment below. +",1,x tools gopls defining the workspace root gopls supports both module and gopath modes however we need to define a scope in which language features like references rename and implementation should operate the following is subject to and will likely change for now we have the following cases module mode supported open workspace at the module root directory containing the go mod file the scope is the entire module open a subdirectory of a module the scope is the subdirectory that has been opened unsupported open a directory that contains a module in a subdirectory gopls will not work in this case gopath mode supported open a directory inside of your gopath the scope is the open directory at your own risk open your entire gopath the workspace scope will be your entire gopath note that this will cause gopls to load your entire gopath if your gopath is large this will take a long time and cause gopls to be very slow to work around this case you can create a new gopath that contains only the packages you want to work on unsupported open a directory containing your gopath similar to the case above this will cause gopls to treat your entire gopath as the workspace scope it will be very slow to start because it will try to find all of the go files in the directory you have opened it will then load all of the files it has found we are working on addressing all of these cases and improving the behavior of gopls in the unsupported cases all of these cases will be supported once gopls reaches we understand it may be inconvenient to change your typical workflow to accommodate frequent changes in gopls in this case it may be easier to stick with a version of gopls that works for you gopls for instance or if you are using gopath gopls may not be the best tool to use until it reaches if you have additional use cases that are not mentioned above please comment below ,1 +151629,13428050122.0,IssuesEvent,2020-09-06 20:24:28,golang/go,https://api.github.com/repos/golang/go,closed,go/ast: mention strconv.Unquote in BasicLit documentation,Documentation NeedsFix," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.14.4 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/tenntenn/Library/Caches/go-build"" +GOENV=""/Users/tenntenn/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/tenntenn/Documents/gopath"" +GOPRIVATE="""" +GOPROXY=""direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/wm/76fqhrc52ls25p4cmjrjbdqh0000gp/T/go-build969893907=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
+$ go version +go version go1.14.4 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/tenntenn/Library/Caches/go-build"" +GOENV=""/Users/tenntenn/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/tenntenn/Documents/gopath"" +GOPRIVATE="""" +GOPROXY=""direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/wm/76fqhrc52ls25p4cmjrjbdqh0000gp/T/go-build969893907=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
+https://go.dev/play/p/Ztyu2FJaajl +go1.20.1 ++ +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? +Go Playground server + +### What did you do? +```go +package main + +type A[T any, U ~T] struct{} +type B[T any, U ~T | ~*T] struct{} +type C[T any] interface{ ~T | ~*T } + +func main() {} +``` + +### What did you expect to see? +no error + +### What did you see instead? +``` +./prog.go:3:18: type in term ~T cannot be a type parameter +./prog.go:4:18: type in term ~T cannot be a type parameter +./prog.go:5:27: type in term ~T cannot be a type parameter + +Go build failed. +``` + +Too bad Google isn't using numbered sections in the Go spec, that would make it easier to cite precise specification items. + +So constraints are interfaces and implicitly converted to them using the syntax of the first four examples. The spec states that ""An interface type
T may not embed a type element that is, contains, or embeds T, directly or indirectly."" However, we're specifying a type with T as an underlying type. If I read the specification correctly then this should be legal.
+
+It's probably a separate issue with the specification that a constraint of `type A[T any, U T | *T] struct{}` is not legal.",1.0,"spec: unable to create constraint based upon type parameter: ""type in term ~T cannot be a type parameter"" -
+
+### What version of Go are you using (`go version`)?
++https://go.dev/play/p/Ztyu2FJaajl +go1.20.1 ++ +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? +Go Playground server + +### What did you do? +```go +package main + +type A[T any, U ~T] struct{} +type B[T any, U ~T | ~*T] struct{} +type C[T any] interface{ ~T | ~*T } + +func main() {} +``` + +### What did you expect to see? +no error + +### What did you see instead? +``` +./prog.go:3:18: type in term ~T cannot be a type parameter +./prog.go:4:18: type in term ~T cannot be a type parameter +./prog.go:5:27: type in term ~T cannot be a type parameter + +Go build failed. +``` + +Too bad Google isn't using numbered sections in the Go spec, that would make it easier to cite precise specification items. + +So constraints are interfaces and implicitly converted to them using the syntax of the first four examples. The spec states that ""An interface type
T may not embed a type element that is, contains, or embeds T, directly or indirectly."" However, we're specifying a type with T as an underlying type. If I read the specification correctly then this should be legal.
+
+It's probably a separate issue with the specification that a constraint of `type A[T any, U T | *T] struct{}` is not legal.",1,spec unable to create constraint based upon type parameter type in term t cannot be a type parameter please answer these questions before submitting your issue thanks what version of go are you using go version does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env go playground server what did you do go package main type a struct type b struct type c interface t t func main what did you expect to see no error what did you see instead prog go type in term t cannot be a type parameter prog go type in term t cannot be a type parameter prog go type in term t cannot be a type parameter go build failed too bad google isn t using numbered sections in the go spec that would make it easier to cite precise specification items so constraints are interfaces and implicitly converted to them using the syntax of the first four examples the spec states that an interface type t may not embed a type element that is contains or embeds t directly or indirectly however we re specifying a type with t as an underlying type if i read the specification correctly then this should be legal it s probably a separate issue with the specification that a constraint of type a struct is not legal ,1
+365987,25562770277.0,IssuesEvent,2022-11-30 12:06:32,golang/go,https://api.github.com/repos/golang/go,opened,testing: document the usage of export_test.go ,Documentation,"While I am trying to introduce the usage of `export_test.go` to someone new to Go, I failed to find a document regarding this feature neither in [testing](https://pkg.go.dev/testing) nor in [go command](https://pkg.go.dev/cmd/go@go1.19.3#hdr-Testing_flags), not even in the wiki.
+
+I am not sure if I overlooked somewhere, but I would propose documenting this somewhere more visible, such as the [testing](https://pkg.go.dev/testing) package's document.
+
+",1.0,"testing: document the usage of export_test.go - While I am trying to introduce the usage of `export_test.go` to someone new to Go, I failed to find a document regarding this feature neither in [testing](https://pkg.go.dev/testing) nor in [go command](https://pkg.go.dev/cmd/go@go1.19.3#hdr-Testing_flags), not even in the wiki.
+
+I am not sure if I overlooked somewhere, but I would propose documenting this somewhere more visible, such as the [testing](https://pkg.go.dev/testing) package's document.
+
+",1,testing document the usage of export test go while i am trying to introduce the usage of export test go to someone new to go i failed to find a document regarding this feature neither in nor in not even in the wiki i am not sure if i overlooked somewhere but i would propose documenting this somewhere more visible such as the package s document ,1
+21564,4725397131.0,IssuesEvent,2016-10-18 06:20:16,golang/go,https://api.github.com/repos/golang/go,closed,net/url: url.RawQuery = url.Query().Encode() can change the URL,Documentation,"In the following code:
+
+```go
+u, _ := url.Parse(""http://www.example.com/path?foo"")
+fmt.Println(u)
+u.RawQuery = u.Query().Encode()
+fmt.Println(u)
+```
+
+The third line actually changes the URL. The [output](https://play.golang.org/p/HPRB2NlCq4) is:
+
+```
+http://www.example.com/path?foo
+http://www.example.com/path?foo=
+```
+
+A strict reading of [RFC 3986 Section 6](https://tools.ietf.org/html/rfc3986#section-6) suggests that these are two different URLs even after applying the (optional) syntax-based normalizations described in Section 6.2.2. I know of some servers that consider these URLs different. For example, compare the following links:
+
+[http://www.vcfed.org/forum/forumdisplay.php?23-DEC](http://www.vcfed.org/forum/forumdisplay.php?23-DEC)
+[http://www.vcfed.org/forum/forumdisplay.php?23-DEC=](http://www.vcfed.org/forum/forumdisplay.php?23-DEC=)
+
+I consider this a bug, but I doubt we could fix this bug in a backwards-compatible way. At least, I think we should update the documentation to make it clear that url.Query().Encode() can change query param ""foo"" to ""foo="", which may be considered a different URL by some servers.",1.0,"net/url: url.RawQuery = url.Query().Encode() can change the URL - In the following code:
+
+```go
+u, _ := url.Parse(""http://www.example.com/path?foo"")
+fmt.Println(u)
+u.RawQuery = u.Query().Encode()
+fmt.Println(u)
+```
+
+The third line actually changes the URL. The [output](https://play.golang.org/p/HPRB2NlCq4) is:
+
+```
+http://www.example.com/path?foo
+http://www.example.com/path?foo=
+```
+
+A strict reading of [RFC 3986 Section 6](https://tools.ietf.org/html/rfc3986#section-6) suggests that these are two different URLs even after applying the (optional) syntax-based normalizations described in Section 6.2.2. I know of some servers that consider these URLs different. For example, compare the following links:
+
+[http://www.vcfed.org/forum/forumdisplay.php?23-DEC](http://www.vcfed.org/forum/forumdisplay.php?23-DEC)
+[http://www.vcfed.org/forum/forumdisplay.php?23-DEC=](http://www.vcfed.org/forum/forumdisplay.php?23-DEC=)
+
+I consider this a bug, but I doubt we could fix this bug in a backwards-compatible way. At least, I think we should update the documentation to make it clear that url.Query().Encode() can change query param ""foo"" to ""foo="", which may be considered a different URL by some servers.",1,net url url rawquery url query encode can change the url in the following code go u url parse fmt println u u rawquery u query encode fmt println u the third line actually changes the url the is a strict reading of suggests that these are two different urls even after applying the optional syntax based normalizations described in section i know of some servers that consider these urls different for example compare the following links i consider this a bug but i doubt we could fix this bug in a backwards compatible way at least i think we should update the documentation to make it clear that url query encode can change query param foo to foo which may be considered a different url by some servers ,1
+24467,12302098557.0,IssuesEvent,2020-05-11 16:24:34,golang/go,https://api.github.com/repos/golang/go,closed,cmd/compile: optimize division for positive integers,NeedsInvestigation Performance,"
+
+### What version of Go are you using (`go version`)?
+
+go version go1.13.1 windows/amd64
+
+### Does this issue reproduce with the latest release?
+
+yes
+
+### What did you do?
+
+~~~go
+func Indent(width int) string {
+ const tabsAndSpaces = ""\t\t\t\t\t\t\t\t\t ""
+ middle := len(tabsAndSpaces) - 7
+ if width >= 0 && width <= 8*middle+7 {
+ start := middle - width/8
+ end := middle + width%8
+ return tabsAndSpaces[start:end]
+ }
+ return strings.Repeat(""\t"", width/8) + "" ""[:width%8]
+}
+~~~
+
+### What did you expect to see?
+
+Since the variable `width` has bounds checks and is thus guaranteed to be positive, the generated code omits the extra instructions for negative numbers.
+
+In general, I prefer to write arithmetic expressions in my code instead of bit manipulations because the expressions `width/8` and `width%8` pair up nicely. In contrast, `width>>3` and `width&7` requires more thought.
+
+### What did you see instead?
+
+~~~text
+ util.go:7 MOVQ BX, SI
+ util.go:7 SARQ $0x3f, BX
+ util.go:7 SHRQ $0x3d, BX
+ util.go:7 ADDQ SI, BX
+ util.go:7 SARQ $0x3, BX
+ util.go:8 MOVQ BX, DI
+ util.go:8 SHLQ $0x3, BX
+ util.go:8 SUBQ BX, SI
+ util.go:8 LEAQ 0x9(SI), CX
+~~~
+
+The `SARQ` and `SHRQ` are not necessary here.",True,"cmd/compile: optimize division for positive integers -
+
+### What version of Go are you using (`go version`)?
+
+go version go1.13.1 windows/amd64
+
+### Does this issue reproduce with the latest release?
+
+yes
+
+### What did you do?
+
+~~~go
+func Indent(width int) string {
+ const tabsAndSpaces = ""\t\t\t\t\t\t\t\t\t ""
+ middle := len(tabsAndSpaces) - 7
+ if width >= 0 && width <= 8*middle+7 {
+ start := middle - width/8
+ end := middle + width%8
+ return tabsAndSpaces[start:end]
+ }
+ return strings.Repeat(""\t"", width/8) + "" ""[:width%8]
+}
+~~~
+
+### What did you expect to see?
+
+Since the variable `width` has bounds checks and is thus guaranteed to be positive, the generated code omits the extra instructions for negative numbers.
+
+In general, I prefer to write arithmetic expressions in my code instead of bit manipulations because the expressions `width/8` and `width%8` pair up nicely. In contrast, `width>>3` and `width&7` requires more thought.
+
+### What did you see instead?
+
+~~~text
+ util.go:7 MOVQ BX, SI
+ util.go:7 SARQ $0x3f, BX
+ util.go:7 SHRQ $0x3d, BX
+ util.go:7 ADDQ SI, BX
+ util.go:7 SARQ $0x3, BX
+ util.go:8 MOVQ BX, DI
+ util.go:8 SHLQ $0x3, BX
+ util.go:8 SUBQ BX, SI
+ util.go:8 LEAQ 0x9(SI), CX
+~~~
+
+The `SARQ` and `SHRQ` are not necessary here.",0,cmd compile optimize division for positive integers what version of go are you using go version go version windows does this issue reproduce with the latest release yes what did you do go func indent width int string const tabsandspaces t t t t t t t t t middle len tabsandspaces if width width middle start middle width end middle width return tabsandspaces return strings repeat t width what did you expect to see since the variable width has bounds checks and is thus guaranteed to be positive the generated code omits the extra instructions for negative numbers in general i prefer to write arithmetic expressions in my code instead of bit manipulations because the expressions width and width pair up nicely in contrast width and width requires more thought what did you see instead text util go movq bx si util go sarq bx util go shrq bx util go addq si bx util go sarq bx util go movq bx di util go shlq bx util go subq bx si util go leaq si cx the sarq and shrq are not necessary here ,0
+183532,14944063121.0,IssuesEvent,2021-01-26 00:30:58,golang/go,https://api.github.com/repos/golang/go,closed,os: document file descriptor ownership semantics for os.NewFile(),Documentation NeedsFix,"### What version of Go are you using (`go version`)?
+
++$ go version +go version go1.15.6 linux/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/vic/.cache/go-build"" +GOENV=""/home/vic/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/vic/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/vic/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go-1.15"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go-1.15/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/vic/go/src/github.com/optimyze/prodfiler/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build483022862=/tmp/go-build -gno-record-gcc-switches"" + +
+$ go version +go version go1.15.6 linux/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/vic/.cache/go-build"" +GOENV=""/home/vic/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/vic/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/vic/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go-1.15"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go-1.15/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/vic/go/src/github.com/optimyze/prodfiler/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build483022862=/tmp/go-build -gno-record-gcc-switches"" + +
+$ go version +go version devel +1fba10c999 Wed Oct 9 15:07:29 2019 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +No. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/homes/hawklords/cks/.cache/go-build"" +GOENV=""/homes/hawklords/cks/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/homes/hawklords/cks/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/data/code/go-lang/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/data/code/go-lang/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/data/code/go-lang/go/src/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmpfs/go-build183007954=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version devel +1fba10c999 Wed Oct 9 15:07:29 2019 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +No. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/homes/hawklords/cks/.cache/go-build"" +GOENV=""/homes/hawklords/cks/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/homes/hawklords/cks/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/data/code/go-lang/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/data/code/go-lang/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/data/code/go-lang/go/src/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmpfs/go-build183007954=/tmp/go-build -gno-record-gcc-switches"" +
+$ 1.15.6 darwin/amd64 + ++ +### Does this issue reproduce with the latest release? + +N/A + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ N/A + +
+$ 1.15.6 darwin/amd64 + ++ +### Does this issue reproduce with the latest release? + +N/A + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ N/A + +
+ TODO: https://golang.org/cl/242998: export errFinished as ErrProcessDone +
++ TODO: https://golang.org/cl/242998: export errFinished as ErrProcessDone +
++go version go1.12.4 linux/amd64 ++ +### Does this issue reproduce with the latest release? +Affirmative. + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/howard/.cache/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/howard/gopath"" +GOPROXY="""" +GORACE="""" +GOROOT=""/home/howard/go"" +GOTMPDIR="""" +GOTOOLDIR=""/home/howard/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build043222332=/tmp/go-build -gno-record-gcc-switches"" + +
+go version go1.12.4 linux/amd64 ++ +### Does this issue reproduce with the latest release? +Affirmative. + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/howard/.cache/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/howard/gopath"" +GOPROXY="""" +GORACE="""" +GOROOT=""/home/howard/go"" +GOTMPDIR="""" +GOTOOLDIR=""/home/howard/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build043222332=/tmp/go-build -gno-record-gcc-switches"" + +
http://golang.org/ref/spec#Interface_types does not clearly spell out the requirements +for a type to implement an interface. It should.+",1.0,"spec: document interface satisfaction more explicitly -
http://golang.org/ref/spec#Interface_types does not clearly spell out the requirements +for a type to implement an interface. It should.+",1,spec document interface satisfaction more explicitly a href does not clearly spell out the requirements for a type to implement an interface it should ,1 +36321,9792748791.0,IssuesEvent,2019-06-10 18:11:44,golang/go,https://api.github.com/repos/golang/go,opened,x/build/cmd/gopherbot: should not consider backport requests inside backport issues,Builders NeedsFix help wanted,"A backport issue should never itself be backported, so gopherbot should reject requests to backport inside such issues. + +See https://github.com/golang/go/issues/32261#issuecomment-496157952 where it happened by accident and caused confusing backport-backport issues to be created.",1.0,"x/build/cmd/gopherbot: should not consider backport requests inside backport issues - A backport issue should never itself be backported, so gopherbot should reject requests to backport inside such issues. + +See https://github.com/golang/go/issues/32261#issuecomment-496157952 where it happened by accident and caused confusing backport-backport issues to be created.",0,x build cmd gopherbot should not consider backport requests inside backport issues a backport issue should never itself be backported so gopherbot should reject requests to backport inside such issues see where it happened by accident and caused confusing backport backport issues to be created ,0 +433756,30348527179.0,IssuesEvent,2023-07-11 17:07:16,golang/go,https://api.github.com/repos/golang/go,closed,"log/slog: documentation passes nil contexts, which is discouraged",Documentation NeedsFix release-blocker,"The documentation of the slog package passes nil contexts, for example: + +``` +logger.LogAttrs(nil, slog.LevelInfo, ""hello"", slog.Int(""count"", 3)) +``` + +However, the context package discourages this: + +> Do not pass a nil Context, even if a function permits it. Pass context.TODO if you are unsure about which Context to use. + +slog internally turns nils into context.Background when calling methods on slog.Handler, which is probably good for resilience, but probably isn't something users should rely on. + +In particular, such calls will currently trigger Staticcheck's [SA1012](https://staticcheck.dev/docs/checks/#SA1012) and I'm not sure slog warrants an exception. + +I see from https://github.com/golang/exp/commit/f0f767cdffd6c3fe9fa17c685f39b1cf8e866c0c that this is intentional, so this issue might be contentious. However, I'm not sure the ""make them easier to write"" argument is as important now, considering there are helpers for pre-defined log levels that don't take context arguments, and it would be unfortunate for the standard library to ignore its own rules. + +/cc @jba ",1.0,"log/slog: documentation passes nil contexts, which is discouraged - The documentation of the slog package passes nil contexts, for example: + +``` +logger.LogAttrs(nil, slog.LevelInfo, ""hello"", slog.Int(""count"", 3)) +``` + +However, the context package discourages this: + +> Do not pass a nil Context, even if a function permits it. Pass context.TODO if you are unsure about which Context to use. + +slog internally turns nils into context.Background when calling methods on slog.Handler, which is probably good for resilience, but probably isn't something users should rely on. + +In particular, such calls will currently trigger Staticcheck's [SA1012](https://staticcheck.dev/docs/checks/#SA1012) and I'm not sure slog warrants an exception. + +I see from https://github.com/golang/exp/commit/f0f767cdffd6c3fe9fa17c685f39b1cf8e866c0c that this is intentional, so this issue might be contentious. However, I'm not sure the ""make them easier to write"" argument is as important now, considering there are helpers for pre-defined log levels that don't take context arguments, and it would be unfortunate for the standard library to ignore its own rules. + +/cc @jba ",1,log slog documentation passes nil contexts which is discouraged the documentation of the slog package passes nil contexts for example logger logattrs nil slog levelinfo hello slog int count however the context package discourages this do not pass a nil context even if a function permits it pass context todo if you are unsure about which context to use slog internally turns nils into context background when calling methods on slog handler which is probably good for resilience but probably isn t something users should rely on in particular such calls will currently trigger staticcheck s and i m not sure slog warrants an exception i see from that this is intentional so this issue might be contentious however i m not sure the make them easier to write argument is as important now considering there are helpers for pre defined log levels that don t take context arguments and it would be unfortunate for the standard library to ignore its own rules cc jba ,1 +14586,3868515918.0,IssuesEvent,2016-04-10 00:35:30,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: fix documentation typo in findInternal,Documentation,`Four cases...` at https://github.com/golang/go/blob/c31fdd4ee9fccd24a274cebd82dcc7123ad43d0e/src/cmd/go/pkg.go#L563 should be `Three cases...`.,1.0,cmd/go: fix documentation typo in findInternal - `Four cases...` at https://github.com/golang/go/blob/c31fdd4ee9fccd24a274cebd82dcc7123ad43d0e/src/cmd/go/pkg.go#L563 should be `Three cases...`.,1,cmd go fix documentation typo in findinternal four cases at should be three cases ,1 +105577,11454795771.0,IssuesEvent,2020-02-06 17:46:36,golang/go,https://api.github.com/repos/golang/go,closed,doc/install: update “Test your installation” step to be agnostic to module mode,Documentation NeedsFix modules," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.13.7 darwin/amd64 ++ + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE=""on"" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/xxxx/Library/Caches/go-build"" +GOENV=""/Users/xxxx/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/xxxx/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/5k/x27nkdh9605dcjwmgmxbdr0c0000gn/T/go-build407033626=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ pwd
+/Users/xxxx/go/src/hello
+$ ls
+hello.go
+$ go build
+go: cannot find main module; see 'go help modules'
+
+$ cat hello.go
+package main
+
+import ""fmt""
+
+func main() {
+ fmt.Printf(""hello, world\n"")
+}
+
+",1.0,"doc/install: update “Test your installation” step to be agnostic to module mode -
+
+### What version of Go are you using (`go version`)?
+
++$ go version +go version go1.13.7 darwin/amd64 ++ + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE=""on"" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/xxxx/Library/Caches/go-build"" +GOENV=""/Users/xxxx/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/xxxx/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/5k/x27nkdh9605dcjwmgmxbdr0c0000gn/T/go-build407033626=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ pwd
+/Users/xxxx/go/src/hello
+$ ls
+hello.go
+$ go build
+go: cannot find main module; see 'go help modules'
+
+$ cat hello.go
+package main
+
+import ""fmt""
+
+func main() {
+ fmt.Printf(""hello, world\n"")
+}
+
+",1,doc install update “test your installation” step to be agnostic to module mode please answer these questions before submitting your issue thanks for questions please use one of our forums what version of go are you using go version go version go version darwin what operating system and processor architecture are you using go env go env output go env on goarch gobin gocache users xxxx library caches go build goenv users xxxx library application support go env goexe goflags gohostarch gohostos darwin gonoproxy gonosumdb goos darwin gopath users xxxx go goprivate goproxy goroot usr local go gosumdb sum golang org gotmpdir gotooldir usr local go pkg tool darwin gccgo gccgo ar ar cc clang cxx clang cgo enabled gomod dev null cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map var folders t go tmp go build gno record gcc switches fno common what did you do i tried to create a go environment and proceeded according to the tutorial do you need go mod init before go build or execute go build hello go pwd users xxxx go src hello ls hello go go build go cannot find main module see go help modules cat hello go package main import fmt func main fmt printf hello world n ,1
+182948,14171248459.0,IssuesEvent,2020-11-12 15:29:27,golang/go,https://api.github.com/repos/golang/go,closed,"cmd/go: the ""build_plugin_non_main"" test case cannot pass for linux/mips64le port",NeedsFix Testing,"
+
+### What version of Go are you using (`go version`)?
+
++$ go version +go1.15.3 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? +linux/mips64le +
go env Output+$ go env + +
+$ go version +go1.15.3 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? +linux/mips64le +
go env Output+$ go env + +
+$ go version devel go1.21-39effbc105 Fri Jun 9 04:07:29 2023 +0000 windows/amd64 + ++ +### Does this issue reproduce with the latest release? +yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +set GOOS=windows +set GOARCH=amd64 +set GOAMD64=v2 +
code
+package main
+
+import (
+ //""slices""
+ ""sort""
+ ""strconv""
+ ""testing""
+)
+
+var s []string
+
+func init() {
+ const n = 10000000
+ s = make([]string, n)
+ for i := 0; i < n; i++ {
+ s[i] = strconv.Itoa(i)
+ }
+}
+
+func BenchmarkStringSort(b *testing.B) {
+ for i := 0; i < b.N; i++ {
+ sort.Strings(s)
+ }
+}
+
+// func BenchmarkStringSort(b *testing.B) {
+// for i := 0; i < b.N; i++ {
+// slices.Sort(s)
+// }
+// }
+
+
+ │ sort.txt │ slices.txt │
+ │ sec/op │ sec/op vs base │
+StringSort-4 123.7m ± 2% 134.0m ± 1% +8.36% (p=0.002 n=10)
+
+
+The test results do not match the document, which says slices is faster, but the test found that sort is faster.
+",True,"sort: slices.Sort is slightly slower than sort.Strings on some sorted inputs - ### What version of Go are you using (`go version`)?
+
++$ go version devel go1.21-39effbc105 Fri Jun 9 04:07:29 2023 +0000 windows/amd64 + ++ +### Does this issue reproduce with the latest release? +yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +set GOOS=windows +set GOARCH=amd64 +set GOAMD64=v2 +
code
+package main
+
+import (
+ //""slices""
+ ""sort""
+ ""strconv""
+ ""testing""
+)
+
+var s []string
+
+func init() {
+ const n = 10000000
+ s = make([]string, n)
+ for i := 0; i < n; i++ {
+ s[i] = strconv.Itoa(i)
+ }
+}
+
+func BenchmarkStringSort(b *testing.B) {
+ for i := 0; i < b.N; i++ {
+ sort.Strings(s)
+ }
+}
+
+// func BenchmarkStringSort(b *testing.B) {
+// for i := 0; i < b.N; i++ {
+// slices.Sort(s)
+// }
+// }
+
+
+ │ sort.txt │ slices.txt │
+ │ sec/op │ sec/op vs base │
+StringSort-4 123.7m ± 2% 134.0m ± 1% +8.36% (p=0.002 n=10)
+
+
+The test results do not match the document, which says slices is faster, but the test found that sort is faster.
+",0,sort slices sort is slightly slower than sort strings on some sorted inputs what version of go are you using go version go version devel fri jun windows does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env go env output go env set goos windows set goarch set what did you do use the following benchmark code code package main import slices sort strconv testing var s string func init const n s make string n for i i n i s strconv itoa i func benchmarkstringsort b testing b for i i b n i sort strings s func benchmarkstringsort b testing b for i i b n i slices sort s what did you expect to see expected document to be successfully validated note consider using the new slices sort function which runs faster what did you see instead │ sort txt │ slices txt │ │ sec op │ sec op vs base │ stringsort ± ± p n the test results do not match the document which says slices is faster but the test found that sort is faster ,0
+211781,16458122443.0,IssuesEvent,2021-05-21 15:04:47,golang/go,https://api.github.com/repos/golang/go,opened,net/http/pprof: add note about security implications to the docs,Documentation Security,"The net/http/pprof endpoints include stack traces with integer arguments, which can leak sensitive information depending on the settings. We should mention that in the docs.",1.0,"net/http/pprof: add note about security implications to the docs - The net/http/pprof endpoints include stack traces with integer arguments, which can leak sensitive information depending on the settings. We should mention that in the docs.",1,net http pprof add note about security implications to the docs the net http pprof endpoints include stack traces with integer arguments which can leak sensitive information depending on the settings we should mention that in the docs ,1
+348273,24910256349.0,IssuesEvent,2022-10-29 19:23:59,golang/go,https://api.github.com/repos/golang/go,opened,x/website: newer examples for security policy PRIVATE issues,Documentation website,"The security policy page https://go.dev/security/policy lists examples of PRIVATE issues.
+These are examples listed in the new security policy discussion #44918 , before the policy was in place.
+
+I've witnessed confusion on what PRIVATE means, as some of the issues listed there were open for quite some time before being fixed.
+
+Newer PRIVATE issues follow a different process with placeholder issues linking to a private tracker that is updated when it becomes public, ex: #53416 #53616 #54658 #56284 .
+
+The security policy would benefit from newer examples that follow the process laid out by it.
+
+cc @golang/security
+
+",1.0,"x/website: newer examples for security policy PRIVATE issues - The security policy page https://go.dev/security/policy lists examples of PRIVATE issues.
+These are examples listed in the new security policy discussion #44918 , before the policy was in place.
+
+I've witnessed confusion on what PRIVATE means, as some of the issues listed there were open for quite some time before being fixed.
+
+Newer PRIVATE issues follow a different process with placeholder issues linking to a private tracker that is updated when it becomes public, ex: #53416 #53616 #54658 #56284 .
+
+The security policy would benefit from newer examples that follow the process laid out by it.
+
+cc @golang/security
+
+",1,x website newer examples for security policy private issues the security policy page lists examples of private issues these are examples listed in the new security policy discussion before the policy was in place i ve witnessed confusion on what private means as some of the issues listed there were open for quite some time before being fixed newer private issues follow a different process with placeholder issues linking to a private tracker that is updated when it becomes public ex the security policy would benefit from newer examples that follow the process laid out by it cc golang security ,1
+221500,17019404340.0,IssuesEvent,2021-07-02 16:26:06,golang/go,https://api.github.com/repos/golang/go,closed,cmd/dist: typo in comment,Documentation NeedsFix,"
+
+### What version of Go are you using (`go version`)?
+
++$ go version +go version go1.16 linux/amd64 ++ +### Does this issue reproduce with the latest release? + + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN=""/home/vagrant/go/bin"" +GOCACHE=""/home/vagrant/.cache/go-build"" +GOENV=""/home/vagrant/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/vagrant/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/vagrant/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.16"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build2823638017=/tmp/go-build -gno-record-gcc-switches"" + +
+$ go version +go version go1.16 linux/amd64 ++ +### Does this issue reproduce with the latest release? + + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN=""/home/vagrant/go/bin"" +GOCACHE=""/home/vagrant/.cache/go-build"" +GOENV=""/home/vagrant/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/vagrant/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/vagrant/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.16"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build2823638017=/tmp/go-build -gno-record-gcc-switches"" + +
+$ go version +go version go1.16.4 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. +It also reproduces with go1.17 devel. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE=""on"" +GOARCH=""amd64"" +GOBIN=""/home/manlio/.local/bin"" +GOCACHE=""/home/manlio/.cache/go-build"" +GOENV=""/home/manlio/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE=""*.local"" +GOMODCACHE=""/home/manlio/.local/lib/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB=""*.local"" +GOOS=""linux"" +GOPATH=""/home/manlio/.local/lib/go:/home/manlio/src/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.16.4"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build1653706074=/tmp/go-build -gno-record-gcc-switches"" +GOROOT/bin/go version: go version go1.16.4 linux/amd64 +GOROOT/bin/go tool compile -V: compile version go1.16.4 +uname -sr: Linux 5.12.5-arch1-1 +/usr/lib/libc.so.6: GNU C Library (GNU libc) release release version 2.33. +gdb --version: GNU gdb (GDB) 10.2 +
+$ go version +go version go1.16.4 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. +It also reproduces with go1.17 devel. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE=""on"" +GOARCH=""amd64"" +GOBIN=""/home/manlio/.local/bin"" +GOCACHE=""/home/manlio/.cache/go-build"" +GOENV=""/home/manlio/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE=""*.local"" +GOMODCACHE=""/home/manlio/.local/lib/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB=""*.local"" +GOOS=""linux"" +GOPATH=""/home/manlio/.local/lib/go:/home/manlio/src/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.16.4"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build1653706074=/tmp/go-build -gno-record-gcc-switches"" +GOROOT/bin/go version: go version go1.16.4 linux/amd64 +GOROOT/bin/go tool compile -V: compile version go1.16.4 +uname -sr: Linux 5.12.5-arch1-1 +/usr/lib/libc.so.6: GNU C Library (GNU libc) release release version 2.33. +gdb --version: GNU gdb (GDB) 10.2 +
+$ go version +go version go1.12 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/henrywong/Library/Caches/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/henrywong/workspace/gopath"" +GOPROXY="""" +GORACE="""" +GOROOT=""/usr/local/Cellar/go/1.12/libexec"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.12/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/fm/bk0wqlkj523gdp9pbtnyvxmm0000gn/T/go-build954865857=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ go version +go version go1.12 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/henrywong/Library/Caches/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/henrywong/workspace/gopath"" +GOPROXY="""" +GORACE="""" +GOROOT=""/usr/local/Cellar/go/1.12/libexec"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.12/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/fm/bk0wqlkj523gdp9pbtnyvxmm0000gn/T/go-build954865857=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ go version +NA ++ +### Does this issue reproduce with the latest release? +NA + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +NA +
+$ go version +NA ++ +### Does this issue reproduce with the latest release? +NA + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +NA +
+$ go version +go version devel go1.18-8854368cb0 Sat Sep 25 01:24:46 2021 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? +I did not check for the release, but the tip of `master` branch [as of 25-Sep-2021] + + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/mfrw/.cache/go-build"" +GOENV=""/home/mfrw/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/mfrw/g/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/mfrw/g"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/home/mfrw/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/home/mfrw/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""devel go1.18-8854368cb0 Sat Sep 25 01:24:46 2021 +0000"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/mfrw/go/src/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build6268976=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version devel go1.18-8854368cb0 Sat Sep 25 01:24:46 2021 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? +I did not check for the release, but the tip of `master` branch [as of 25-Sep-2021] + + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/mfrw/.cache/go-build"" +GOENV=""/home/mfrw/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/mfrw/g/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/mfrw/g"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/home/mfrw/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/home/mfrw/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""devel go1.18-8854368cb0 Sat Sep 25 01:24:46 2021 +0000"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/mfrw/go/src/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build6268976=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.15 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Haven't tried + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/k0nst4nt1n/Library/Caches/go-build"" +GOENV=""/Users/k0nst4nt1n/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/k0nst4nt1n/_gopath/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/k0nst4nt1n/_gopath"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/Cellar/go/1.15/libexec"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.15/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/3q/jr3whwkn13ld3j1s1xms0v4w0000gp/T/go-build070878361=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ go version +go version go1.15 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Haven't tried + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/k0nst4nt1n/Library/Caches/go-build"" +GOENV=""/Users/k0nst4nt1n/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/k0nst4nt1n/_gopath/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/k0nst4nt1n/_gopath"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/Cellar/go/1.15/libexec"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.15/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/3q/jr3whwkn13ld3j1s1xms0v4w0000gp/T/go-build070878361=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+go version devel +a50c3ffbd4 linux/amd64 ++ +### Does this issue reproduce with the latest release? + + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/usr/local/google/home/pjw/.cache/go-build"" +GOENV=""/usr/local/google/home/pjw/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" + +
+go version devel +a50c3ffbd4 linux/amd64 ++ +### Does this issue reproduce with the latest release? + + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/usr/local/google/home/pjw/.cache/go-build"" +GOENV=""/usr/local/google/home/pjw/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" + +
+$ go version +go version go1.14beta1 linux/amd64 ++ +### Does this issue reproduce with the latest release? +yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/me/.cache/go-build"" +GOENV=""/home/me/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/me/sources/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/snap/go/4962"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/snap/go/4962/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/user/1000/go-build057059169=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.14beta1 linux/amd64 ++ +### Does this issue reproduce with the latest release? +yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/me/.cache/go-build"" +GOENV=""/home/me/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/me/sources/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/snap/go/4962"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/snap/go/4962/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/user/1000/go-build057059169=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.11.3 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +NA + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +NA +
+$ go version +go version go1.11.3 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +NA + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +NA +
+ TODO: https://golang.org/cl/247257: adds support for the SMTPUTF8 extension +
++ TODO: https://golang.org/cl/247257: adds support for the SMTPUTF8 extension +
++ TODO: https://golang.org/cl/240014: add Func +
++ TODO: https://golang.org/cl/240014: add Func +
++$ go version +go 1.15.2 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +Linux and macOS. + +### What did you do? + +Code: https://play.golang.org/p/YmHIIc7sha4 + +Note: This does not reproduce in go playground, but can reproduce on my mac/linux. + +### What did you expect to see? + +No panic. + +### What did you see instead? + +panic: bad file descriptor + +### Reason + +I found that this is because there's an implicitly close call when the `file` object is garbage-collected. + +In os/file_unix.go: +``` +func newFile(fd uintptr, name string, kind newFileKind) *File { + ... + + runtime.SetFinalizer(f.file, (*file).close) + return f +} +``` + +### What do I expect + +I know there's thousands of method to avoid being garbage-collected such as runtime.KeepAlive, but I think this is unreasonable, either this behaviour should be removed or the `file` object should not be garbage-collected. + +If a user forgets to call file.Close, the memory should be leaking. + +Also, this behaviour isn't documented anywhere. +",1.0,"os: File implicitly closed when garbage-collected due to runtime finalizer but this behavior is not documented - ### What version of Go are you using (`go version`)? + +
+$ go version +go 1.15.2 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +Linux and macOS. + +### What did you do? + +Code: https://play.golang.org/p/YmHIIc7sha4 + +Note: This does not reproduce in go playground, but can reproduce on my mac/linux. + +### What did you expect to see? + +No panic. + +### What did you see instead? + +panic: bad file descriptor + +### Reason + +I found that this is because there's an implicitly close call when the `file` object is garbage-collected. + +In os/file_unix.go: +``` +func newFile(fd uintptr, name string, kind newFileKind) *File { + ... + + runtime.SetFinalizer(f.file, (*file).close) + return f +} +``` + +### What do I expect + +I know there's thousands of method to avoid being garbage-collected such as runtime.KeepAlive, but I think this is unreasonable, either this behaviour should be removed or the `file` object should not be garbage-collected. + +If a user forgets to call file.Close, the memory should be leaking. + +Also, this behaviour isn't documented anywhere. +",1,os file implicitly closed when garbage collected due to runtime finalizer but this behavior is not documented what version of go are you using go version go version go does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env linux and macos what did you do code note this does not reproduce in go playground but can reproduce on my mac linux what did you expect to see no panic what did you see instead panic bad file descriptor reason i found that this is because there s an implicitly close call when the file object is garbage collected in os file unix go func newfile fd uintptr name string kind newfilekind file runtime setfinalizer f file file close return f what do i expect i know there s thousands of method to avoid being garbage collected such as runtime keepalive but i think this is unreasonable either this behaviour should be removed or the file object should not be garbage collected if a user forgets to call file close the memory should be leaking also this behaviour isn t documented anywhere ,1 +56889,8129711062.0,IssuesEvent,2018-08-17 15:53:26,golang/go,https://api.github.com/repos/golang/go,closed,doc/code.html: update description of install command,Documentation NeedsFix,"### What version of Go are you using (go version)? +`go version go1.10 windows/amd64` + +### Does this issue reproduce with the latest release? +1.10 is the latest at this moment + +### What operating system and processor architecture are you using (go env)? +GOARCH=amd64 +GOOS=windows + +### What did you do? +I have small test program with two small dummy libraries. + +Go program in the `src` has path `github.com/user/hello` + + package main + + import ( + ""fmt"" + + // Libraries bellow are not automatically generated in pkg + ""github.com/user/stringutil"" + ""github.com/user/tttt"" + ) + + func main() { + fmt.Printf(stringutil.Reverse(""\nHello, world.\n"")) + fmt.Println(add(85,tttt.Tttt(9))) + } + +`add()` function is in separate file, also in `hello` directory: + + package main + + func add(x int, y int) int { + return x + y + } + +When I don't have the above libraries compiled and just use go install `hello` program is installed and works but the `pkg` directory is not created and no `stringutil.a` and `tttt.a`. + +If I want to have libraries generated I have to use `go install` on every library, in which case `pkg` is generated and libraries in it. + +this is not behaviour according to this documentation: + +> Whenever the go tool installs a package or binary, it also installs whatever dependencies it has. So when you install the hello program +$ go install github.com/user/hello +the stringutil package will be installed as well, automatically. + +Note that I have just installed the latest version (1.10) and just start using it as is writing only one dummy program and two dummy libraries one of which is copied from Go documentation. + +### What did you expect to see? +Dependencies installed automatically in the `pkg` + +### What did you see instead? +No `pkg` and no installed dependencies",1.0,"doc/code.html: update description of install command - ### What version of Go are you using (go version)? +`go version go1.10 windows/amd64` + +### Does this issue reproduce with the latest release? +1.10 is the latest at this moment + +### What operating system and processor architecture are you using (go env)? +GOARCH=amd64 +GOOS=windows + +### What did you do? +I have small test program with two small dummy libraries. + +Go program in the `src` has path `github.com/user/hello` + + package main + + import ( + ""fmt"" + + // Libraries bellow are not automatically generated in pkg + ""github.com/user/stringutil"" + ""github.com/user/tttt"" + ) + + func main() { + fmt.Printf(stringutil.Reverse(""\nHello, world.\n"")) + fmt.Println(add(85,tttt.Tttt(9))) + } + +`add()` function is in separate file, also in `hello` directory: + + package main + + func add(x int, y int) int { + return x + y + } + +When I don't have the above libraries compiled and just use go install `hello` program is installed and works but the `pkg` directory is not created and no `stringutil.a` and `tttt.a`. + +If I want to have libraries generated I have to use `go install` on every library, in which case `pkg` is generated and libraries in it. + +this is not behaviour according to this documentation: + +> Whenever the go tool installs a package or binary, it also installs whatever dependencies it has. So when you install the hello program +$ go install github.com/user/hello +the stringutil package will be installed as well, automatically. + +Note that I have just installed the latest version (1.10) and just start using it as is writing only one dummy program and two dummy libraries one of which is copied from Go documentation. + +### What did you expect to see? +Dependencies installed automatically in the `pkg` + +### What did you see instead? +No `pkg` and no installed dependencies",1,doc code html update description of install command what version of go are you using go version go version windows does this issue reproduce with the latest release is the latest at this moment what operating system and processor architecture are you using go env goarch goos windows what did you do i have small test program with two small dummy libraries go program in the src has path github com user hello package main import fmt libraries bellow are not automatically generated in pkg github com user stringutil github com user tttt func main fmt printf stringutil reverse nhello world n fmt println add tttt tttt add function is in separate file also in hello directory package main func add x int y int int return x y when i don t have the above libraries compiled and just use go install hello program is installed and works but the pkg directory is not created and no stringutil a and tttt a if i want to have libraries generated i have to use go install on every library in which case pkg is generated and libraries in it this is not behaviour according to this documentation whenever the go tool installs a package or binary it also installs whatever dependencies it has so when you install the hello program go install github com user hello the stringutil package will be installed as well automatically note that i have just installed the latest version and just start using it as is writing only one dummy program and two dummy libraries one of which is copied from go documentation what did you expect to see dependencies installed automatically in the pkg what did you see instead no pkg and no installed dependencies,1 +12937,8751436818.0,IssuesEvent,2018-12-13 22:19:43,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: directory traversal via curly braces in import paths [Go 1.10],Security,"This is a tracking issue for #29231, a security vulnerability fixed in Go 1.10.6.",True,"cmd/go: directory traversal via curly braces in import paths [Go 1.10] - This is a tracking issue for #29231, a security vulnerability fixed in Go 1.10.6.",0,cmd go directory traversal via curly braces in import paths this is a tracking issue for a security vulnerability fixed in go ,0 +262461,19804440232.0,IssuesEvent,2022-01-19 04:00:48,golang/go,https://api.github.com/repos/golang/go,closed,spec: shift string(1 << s) should be invalid,Documentation,"```Go +package p +var s uint +var _ = string(1 << s) +``` +is not accepted by the compiler: +``` +bug.go:3:15: invalid operation: 1 << s (shift of type string) +``` +Per the spec (https://golang.org/ref/spec#Constant_expressions): +""If the left operand of a non-constant shift expression is an untyped constant, it is first implicitly converted to the type it would assume if the shift expression were replaced by its left operand alone."" + +In this case, the left operand would be converted to `int` (not string). This is different from cases such as, say `float64(1 << s)` where `1` is implicitly converted to `1.0` because it can be done without loss of precision. It seems a bit far-fetched to claim that a `1` can be converted to a string without loss of precision. (That said, the spec is notoriously difficult to decipher with respect to shifts and implicit conversions.) + +As an aside, there's still #3939 which is proposing to prohibit `string(int_value)`, and `go vet` is checking for this. So we're not permitting a new category of programs by making `string(1 << s)` valid. + +Both `go/types` and `types2` accept this code. + +The test `$GOROOT/test/fixedbugs/bug193.go` assumes that this code should fail. +",1.0,"spec: shift string(1 << s) should be invalid - ```Go +package p +var s uint +var _ = string(1 << s) +``` +is not accepted by the compiler: +``` +bug.go:3:15: invalid operation: 1 << s (shift of type string) +``` +Per the spec (https://golang.org/ref/spec#Constant_expressions): +""If the left operand of a non-constant shift expression is an untyped constant, it is first implicitly converted to the type it would assume if the shift expression were replaced by its left operand alone."" + +In this case, the left operand would be converted to `int` (not string). This is different from cases such as, say `float64(1 << s)` where `1` is implicitly converted to `1.0` because it can be done without loss of precision. It seems a bit far-fetched to claim that a `1` can be converted to a string without loss of precision. (That said, the spec is notoriously difficult to decipher with respect to shifts and implicit conversions.) + +As an aside, there's still #3939 which is proposing to prohibit `string(int_value)`, and `go vet` is checking for this. So we're not permitting a new category of programs by making `string(1 << s)` valid. + +Both `go/types` and `types2` accept this code. + +The test `$GOROOT/test/fixedbugs/bug193.go` assumes that this code should fail. +",1,spec shift string s should be invalid go package p var s uint var string s is not accepted by the compiler bug go invalid operation s shift of type string per the spec if the left operand of a non constant shift expression is an untyped constant it is first implicitly converted to the type it would assume if the shift expression were replaced by its left operand alone in this case the left operand would be converted to int not string this is different from cases such as say s where is implicitly converted to because it can be done without loss of precision it seems a bit far fetched to claim that a can be converted to a string without loss of precision that said the spec is notoriously difficult to decipher with respect to shifts and implicit conversions as an aside there s still which is proposing to prohibit string int value and go vet is checking for this so we re not permitting a new category of programs by making string s valid both go types and accept this code the test goroot test fixedbugs go assumes that this code should fail ,1 +11644,7633460459.0,IssuesEvent,2018-05-06 05:31:47,golang/go,https://api.github.com/repos/golang/go,closed,cmd/compile: optimize len([]rune(string)) to just count runes,NeedsFix Performance,"### What version of Go are you using (`go version`)? +go1.10.1 + +### Does this issue reproduce with the latest release? +Yes. + +### What operating system and processor architecture are you using (`go env`)? +darwin/amd64 + +### What did you do? +I've benchmarked `len([]rune(string))` and `utf8.RuneCountInString(string)` and I saw that the latter performs better. + +Here's the [benchmark code](https://play.golang.org/p/M2HHTtuHMI-). + +**Benchmark Results:** + + BenchmarkRunCountInString16ascii-8 100000000 11.9 ns/op 0 B/op 0 allocs/op + BenchmarkRunCountInString16multi-8 20000000 63.5 ns/op 0 B/op 0 allocs/op + BenchmarkRunCountInString32ascii-8 100000000 18.2 ns/op 0 B/op 0 allocs/op + BenchmarkRunCountInString32multi-8 10000000 120 ns/op 0 B/op 0 allocs/op + BenchmarkCastToRuneArray16ascii-8 50000000 26.2 ns/op 0 B/op 0 allocs/op + BenchmarkCastToRuneArray16multi-8 10000000 171 ns/op 0 B/op 0 allocs/op + BenchmarkCastToRuneArray32ascii-8 30000000 46.1 ns/op 0 B/op 0 allocs/op + BenchmarkCastToRuneArray32multi-8 5000000 322 ns/op + +### What did you expect to see? +Actually, I wasn't expecting `len([]rune(string))` to be faster compared to `utf8.RuneCountInString`, then again I wanted to open this issue. I noticed that there are a lot people are [using](https://github.com/search?l=Go&q=%22len%28%5B%5Drune%28%22&type=Code) this pattern. ",True,"cmd/compile: optimize len([]rune(string)) to just count runes - ### What version of Go are you using (`go version`)? +go1.10.1 + +### Does this issue reproduce with the latest release? +Yes. + +### What operating system and processor architecture are you using (`go env`)? +darwin/amd64 + +### What did you do? +I've benchmarked `len([]rune(string))` and `utf8.RuneCountInString(string)` and I saw that the latter performs better. + +Here's the [benchmark code](https://play.golang.org/p/M2HHTtuHMI-). + +**Benchmark Results:** + + BenchmarkRunCountInString16ascii-8 100000000 11.9 ns/op 0 B/op 0 allocs/op + BenchmarkRunCountInString16multi-8 20000000 63.5 ns/op 0 B/op 0 allocs/op + BenchmarkRunCountInString32ascii-8 100000000 18.2 ns/op 0 B/op 0 allocs/op + BenchmarkRunCountInString32multi-8 10000000 120 ns/op 0 B/op 0 allocs/op + BenchmarkCastToRuneArray16ascii-8 50000000 26.2 ns/op 0 B/op 0 allocs/op + BenchmarkCastToRuneArray16multi-8 10000000 171 ns/op 0 B/op 0 allocs/op + BenchmarkCastToRuneArray32ascii-8 30000000 46.1 ns/op 0 B/op 0 allocs/op + BenchmarkCastToRuneArray32multi-8 5000000 322 ns/op + +### What did you expect to see? +Actually, I wasn't expecting `len([]rune(string))` to be faster compared to `utf8.RuneCountInString`, then again I wanted to open this issue. I noticed that there are a lot people are [using](https://github.com/search?l=Go&q=%22len%28%5B%5Drune%28%22&type=Code) this pattern. ",0,cmd compile optimize len rune string to just count runes what version of go are you using go version does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env darwin what did you do i ve benchmarked len rune string and runecountinstring string and i saw that the latter performs better here s the benchmark results ns op b op allocs op ns op b op allocs op ns op b op allocs op ns op b op allocs op ns op b op allocs op ns op b op allocs op ns op b op allocs op ns op what did you expect to see actually i wasn t expecting len rune string to be faster compared to runecountinstring then again i wanted to open this issue i noticed that there are a lot people are this pattern ,0 +25110,5132878075.0,IssuesEvent,2017-01-11 00:47:10,golang/go,https://api.github.com/repos/golang/go,opened,testing: are T.Run and B.Run safe for concurrent use?,Documentation,"I do not see any documentation specifying if T.Run is safe for concurrent use. I see the following doc for [testing.T](https://tip.golang.org/pkg/testing/#T), which does not mention T.Run: + +> A test ends when its Test function returns or calls any of the methods FailNow, Fatal, Fatalf, SkipNow, Skip, or Skipf. Those methods, as well as the Parallel method, must be called only from the goroutine running the Test function. +> +> The other reporting methods, such as the variations of Log and Error, may be called simultaneously from multiple goroutines. + +There is a similar doc for [testing.B](https://tip.golang.org/pkg/testing/#B). + +I ask because I believe T.Run was safe for concurrent use in go 1.7. Then, [this line](https://github.com/golang/go/blob/7fb16406139e934d84f7ec66ba440a772747270a/src/testing/testing.go#L663) was added in go 1.8, which made T.Run no longer safe for concurrent use. I don't particularly care whether T.Run is safe for concurrent use, but I think the semantics should be clarified. + +Optimistically labeling this go1.8.",1.0,"testing: are T.Run and B.Run safe for concurrent use? - I do not see any documentation specifying if T.Run is safe for concurrent use. I see the following doc for [testing.T](https://tip.golang.org/pkg/testing/#T), which does not mention T.Run: + +> A test ends when its Test function returns or calls any of the methods FailNow, Fatal, Fatalf, SkipNow, Skip, or Skipf. Those methods, as well as the Parallel method, must be called only from the goroutine running the Test function. +> +> The other reporting methods, such as the variations of Log and Error, may be called simultaneously from multiple goroutines. + +There is a similar doc for [testing.B](https://tip.golang.org/pkg/testing/#B). + +I ask because I believe T.Run was safe for concurrent use in go 1.7. Then, [this line](https://github.com/golang/go/blob/7fb16406139e934d84f7ec66ba440a772747270a/src/testing/testing.go#L663) was added in go 1.8, which made T.Run no longer safe for concurrent use. I don't particularly care whether T.Run is safe for concurrent use, but I think the semantics should be clarified. + +Optimistically labeling this go1.8.",1,testing are t run and b run safe for concurrent use i do not see any documentation specifying if t run is safe for concurrent use i see the following doc for which does not mention t run a test ends when its test function returns or calls any of the methods failnow fatal fatalf skipnow skip or skipf those methods as well as the parallel method must be called only from the goroutine running the test function the other reporting methods such as the variations of log and error may be called simultaneously from multiple goroutines there is a similar doc for i ask because i believe t run was safe for concurrent use in go then was added in go which made t run no longer safe for concurrent use i don t particularly care whether t run is safe for concurrent use but i think the semantics should be clarified optimistically labeling this ,1 +14587,3868544421.0,IssuesEvent,2016-04-10 01:07:41,golang/go,https://api.github.com/repos/golang/go,closed,x/exp/shiny: better examples UX,Documentation,"Please answer these questions before submitting your issue. Thanks! + +1. What version of Go are you using (`go version`)? +go-1.6 + +2. What operating system and processor architecture are you using (`go env`)? +linux/amd64 + +3. What did you do? +``` +$> mkdir /tmp/gopath +$> cd /tmp/gopath +$> export GOPATH=/tmp/gopath +$> go get -u golang.org/x/exp/shiny/screen/... +$> cd $GOPATH/src/golang.org/x/exp/shiny/example/basic +$> go run ./main.go +${GOPATH}/golang.org/x/exp/shiny/driver/internal/x11key/x11key.go:9:2: cannot find package ""golang.org/x/mobile/event/key"" in any of: + +${GOPATH}/src/golang.org/x/exp/shiny/vendor/golang.org/x/mobile/event/key (vendor tree) + /usr/local/go/src/golang.org/x/mobile/event/key (from $GOROOT) + +${GOPATH}/src/golang.org/x/mobile/event/key (from $GOPATH) +${GOPATH}/src/golang.org/x/exp/shiny/driver/x11driver/window.go:25:2: cannot find package ""golang.org/x/mobile/event/lifecycle"" in any of: + +${GOPATH}/src/golang.org/x/exp/shiny/vendor/golang.org/x/mobile/event/lifecycle (vendor tree) + /usr/local/go/src/golang.org/x/mobile/event/lifecycle (from $GOROOT) + +${GOPATH}/src/golang.org/x/mobile/event/lifecycle (from $GOPATH) +${GOPATH}/src/golang.org/x/exp/shiny/driver/x11driver/screen.go:20:2: cannot find package ""golang.org/x/mobile/event/mouse"" in any of: + +[...etc...] +``` + +4. What did you expect to see? +A nicer way to run the example(s) + +I would propose to: + +``` +$> cd $GOPATH/src/golang.org/x/exp/shiny +$> git mv example _examples +``` + +and remove all the `// +build ignore` build tags from the examples, +so one could at least do: +``` +$> cd _examples/basic +$> go get -d . +``` +to download all the dependencies in one go. + +(I can send a CL) + +-s + +",1.0,"x/exp/shiny: better examples UX - Please answer these questions before submitting your issue. Thanks! + +1. What version of Go are you using (`go version`)? +go-1.6 + +2. What operating system and processor architecture are you using (`go env`)? +linux/amd64 + +3. What did you do? +``` +$> mkdir /tmp/gopath +$> cd /tmp/gopath +$> export GOPATH=/tmp/gopath +$> go get -u golang.org/x/exp/shiny/screen/... +$> cd $GOPATH/src/golang.org/x/exp/shiny/example/basic +$> go run ./main.go +${GOPATH}/golang.org/x/exp/shiny/driver/internal/x11key/x11key.go:9:2: cannot find package ""golang.org/x/mobile/event/key"" in any of: + +${GOPATH}/src/golang.org/x/exp/shiny/vendor/golang.org/x/mobile/event/key (vendor tree) + /usr/local/go/src/golang.org/x/mobile/event/key (from $GOROOT) + +${GOPATH}/src/golang.org/x/mobile/event/key (from $GOPATH) +${GOPATH}/src/golang.org/x/exp/shiny/driver/x11driver/window.go:25:2: cannot find package ""golang.org/x/mobile/event/lifecycle"" in any of: + +${GOPATH}/src/golang.org/x/exp/shiny/vendor/golang.org/x/mobile/event/lifecycle (vendor tree) + /usr/local/go/src/golang.org/x/mobile/event/lifecycle (from $GOROOT) + +${GOPATH}/src/golang.org/x/mobile/event/lifecycle (from $GOPATH) +${GOPATH}/src/golang.org/x/exp/shiny/driver/x11driver/screen.go:20:2: cannot find package ""golang.org/x/mobile/event/mouse"" in any of: + +[...etc...] +``` + +4. What did you expect to see? +A nicer way to run the example(s) + +I would propose to: + +``` +$> cd $GOPATH/src/golang.org/x/exp/shiny +$> git mv example _examples +``` + +and remove all the `// +build ignore` build tags from the examples, +so one could at least do: +``` +$> cd _examples/basic +$> go get -d . +``` +to download all the dependencies in one go. + +(I can send a CL) + +-s + +",1,x exp shiny better examples ux please answer these questions before submitting your issue thanks what version of go are you using go version go what operating system and processor architecture are you using go env linux what did you do mkdir tmp gopath cd tmp gopath export gopath tmp gopath go get u golang org x exp shiny screen cd gopath src golang org x exp shiny example basic go run main go gopath golang org x exp shiny driver internal go cannot find package golang org x mobile event key in any of gopath src golang org x exp shiny vendor golang org x mobile event key vendor tree usr local go src golang org x mobile event key from goroot gopath src golang org x mobile event key from gopath gopath src golang org x exp shiny driver window go cannot find package golang org x mobile event lifecycle in any of gopath src golang org x exp shiny vendor golang org x mobile event lifecycle vendor tree usr local go src golang org x mobile event lifecycle from goroot gopath src golang org x mobile event lifecycle from gopath gopath src golang org x exp shiny driver screen go cannot find package golang org x mobile event mouse in any of what did you expect to see a nicer way to run the example s i would propose to cd gopath src golang org x exp shiny git mv example examples and remove all the build ignore build tags from the examples so one could at least do cd examples basic go get d to download all the dependencies in one go i can send a cl s ,1 +46707,11872672939.0,IssuesEvent,2020-03-26 16:09:15,golang/go,https://api.github.com/repos/golang/go,closed,x/build/dashboard: macOS builders should specify filesystem case sensitivity in Notes field,Builders NeedsFix,"It should be easy to find out whether the filesystem is case sensitive or insensitive (macOS offers both options). + +We can put this information in the [`Notes`](https://github.com/golang/build/blob/2bf41cd70ade4691877019a878f4ad34d42be1b5/dashboard/builders.go#L732) field, so it'll show up at https://farmer.golang.org/builders. + +/cc @cagedmantis @toothrot @heschik",1.0,"x/build/dashboard: macOS builders should specify filesystem case sensitivity in Notes field - It should be easy to find out whether the filesystem is case sensitive or insensitive (macOS offers both options). + +We can put this information in the [`Notes`](https://github.com/golang/build/blob/2bf41cd70ade4691877019a878f4ad34d42be1b5/dashboard/builders.go#L732) field, so it'll show up at https://farmer.golang.org/builders. + +/cc @cagedmantis @toothrot @heschik",0,x build dashboard macos builders should specify filesystem case sensitivity in notes field it should be easy to find out whether the filesystem is case sensitive or insensitive macos offers both options we can put this information in the field so it ll show up at cc cagedmantis toothrot heschik,0 +436681,30564976848.0,IssuesEvent,2023-07-20 17:03:55,golang/go,https://api.github.com/repos/golang/go,closed,net/url: better handling or documentation of IPv6 addresses in url.URL.Host,Documentation NeedsDecision,"### What did you do? + +https://go.dev/play/p/Lypv_o9VMRf + + host := ""fc00::121:0:2:27"" + url := url.URL{ + Scheme: ""https"", + Host: host, + Path: ""/some/path"", + } + fmt.Println(url.String()) + +### What did you expect to see? + +`https://[fc00::121:0:2:27]/some/path` + +### What did you see instead? + +`https://fc00::121:0:2:27/some/path` + +This ends up being interpreted as `https://[fc00::121:0:2]:27/some/path`. + +The documentation for `url.URL.Host` is `host or host:port`, which leaves it unclear as to how a literal IPv6 address would be treated. + +I think it makes more sense to treat a literal IPv6 address as just that, and require the user to specify `[
+ TODO: https://golang.org/cl/247477: return overflow errors in Reader.ReadForm +
++ TODO: https://golang.org/cl/247477: return overflow errors in Reader.ReadForm +
++$ go version +go version go1.16.3 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +AFAIK I run the latest, havnt tried on tip. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/jaap/.cache/go-build"" +GOENV=""/home/jaap/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/jaap/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/jaap/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.16.3"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build3803926857=/tmp/go-build -gno-record-gcc-switches"" + +
+$ go version +go version go1.16.3 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +AFAIK I run the latest, havnt tried on tip. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/jaap/.cache/go-build"" +GOENV=""/home/jaap/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/jaap/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/jaap/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.16.3"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build3803926857=/tmp/go-build -gno-record-gcc-switches"" + +
+$ docker run --rm golang:1.11 go version +go version go1.11.2 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ docker run --rm golang:1.11 go env +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/root/.cache/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/go"" +GOPROXY="""" +GORACE="""" +GOROOT=""/usr/local/go"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build782466443=/tmp/go-build -gno-record-gcc-switches"" +
+$ docker run --rm golang:1.11 go version +go version go1.11.2 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ docker run --rm golang:1.11 go env +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/root/.cache/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/go"" +GOPROXY="""" +GORACE="""" +GOROOT=""/usr/local/go"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build782466443=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.16.3 linux/amd64 ++ +#### gopls version + +
+$ gopls version +golang.org/x/tools/gopls v0.6.10 ++ +#### vscode-go version + +``` +Id: golang.go +Version: 0.24.2 +``` + +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""~/.cache/go-build"" +GOENV=""~/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""~/.go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""~/.go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.16.3"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build1429872732=/tmp/go-build -gno-record-gcc-switches"" +
[Trace - 19:50:58.056 PM] Received response 'textDocument/completion - (57)' in 47ms.
+Result: {""isIncomplete"":true,""items"":[{""label"":""language.Language"",""kind"":7,""detail"":""uint16 (from \""golang.org/x/text/internal/language\"")"",""preselect"":true,""sortText"":""00000"",""filterText"":""language.Language"",""insertTextFormat"":2,""textEdit"":{""range"":{""start"":{""line"":36,""character"":1},""end"":{""line"":36,""character"":9}},""newText"":""language.Language""},""additionalTextEdits"":[{""range"":{""start"":{""line"":3,""character"":2},""end"":{""line"":3,""character"":2}},""newText"":""golang.org/x/text/internal/language\""\n\t\""""}]},{""label"":""language"",""kind"":9,""detail"":""\""golang.org/x/text/language\"""",""sortText"":""00001"",""filterText"":""language"",""insertTextFormat"":2,""textEdit"":{""range"":{""start"":{""line"":36,""character"":1},""end"":{""line"":36,""character"":9}},""newText"":""language""},""additionalTextEdits"":[{""range"":{""start"":{""line"":3,""character"":2},""end"":{""line"":3,""character"":2}},""newText"":""golang.org/x/text/language\""\n\t\""""}]},{""label"":""language"",""kind"":9,""detail"":""\""golang.org/x/text/internal/language\"""",""sortText"":""00002"",""filterText"":""language"",""insertTextFormat"":2,""textEdit"":{""range"":{""start"":{""line"":36,""character"":1},""end"":{""line"":36,""character"":9}},""newText"":""language""},""additionalTextEdits"":[{""range"":{""start"":{""line"":3,""character"":2},""end"":{""line"":3,""character"":2}},""newText"":""golang.org/x/text/internal/language\""\n\t\""""}]},{""label"":""language.BaseLanguages"",""kind"":3,""detail"":""func() []language.Language (from \""golang.org/x/text/internal/language\"")"",""documentation"":""BaseLanguages returns the list of all supported base languages. It generates\nthe list by traversing the internal structures.\n"",""sortText"":""00003"",""filterText"":""language.BaseLanguages"",""insertTextFormat"":2,""textEdit"":{""range"":{""start"":{""line"":36,""character"":1},""end"":{""line"":36,""character"":9}},""newText"":""language.BaseLanguages()""},""additionalTextEdits"":[{""range"":{""start"":{""line"":3,""character"":2},""end"":{""line"":3,""character"":2}},""newText"":""golang.org/x/text/internal/language\""\n\t\""""}]},{""label"":""language.ParseAcceptLanguage"",""kind"":3,""detail"":""func(s string) (tag []language.Tag, q []float32, err error) (from \""golang.org/x/text/language\"")"",""documentation"":""ParseAcceptLanguage parses the contents of an Accept-Language header as\ndefined in http://www.ietf.org/rfc/rfc2616.txt and returns a list of Tags and\na list of corresponding quality weights. It is more permissive than RFC 2616\nand may return non-nil slices even if the input is not valid.\nThe Tags will be sorted by highest weight first and then by first occurrence.\nTags with a weight of zero will be dropped. An error will be returned if the\ninput could not be parsed.\n"",""sortText"":""00004"",""filterText"":""language.ParseAcceptLanguage"",""insertTextFormat"":2,""textEdit"":{""range"":{""start"":{""line"":36,""character"":1},""end"":{""line"":36,""character"":9}},""newText"":""language.ParseAcceptLanguage(${1:})""},""additionalTextEdits"":[{""range"":{""start"":{""line"":3,""character"":2},""end"":{""line"":3,""character"":2}},""newText"":""golang.org/x/text/language\""\n\t\""""}]},{""label"":""language"",""kind"":9,""detail"":""\""google.golang.org/genproto/googleapis/cloud/language/v1\"""",""sortText"":""00007"",""filterText"":""language"",""insertTextFormat"":2,""textEdit"":{""range"":{""start"":{""line"":36,""character"":1},""end"":{""line"":36,""character"":9}},""newText"":""language""},""additionalTextEdits"":[{""range"":{""start"":{""line"":3,""character"":2},""end"":{""line"":3,""character"":2}},""newText"":""google.golang.org/genproto/googleapis/cloud/language/v1\""\n\t\""""}]},{""label"":""language"",""kind"":9,""detail"":""\""google.golang.org/api/language/v1\"""",""sortText"":""00008"",""filterText"":""language"",""insertTextFormat"":2,""textEdit"":{""range"":{""start"":{""line"":36,""character"":1},""end"":{""line"":36,""character"":9}},""newText"":""language""},""additionalTextEdits"":[{""range"":{""start"":{""line"":3,""character"":2},""end"":{""line"":3,""character"":2}},""newText"":""google.golang.org/api/language/v1\""\n\t\""""}]}]}+$ go version +go version go1.16.3 linux/amd64 ++ +#### gopls version + +
+$ gopls version +golang.org/x/tools/gopls v0.6.10 ++ +#### vscode-go version + +``` +Id: golang.go +Version: 0.24.2 +``` + +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""~/.cache/go-build"" +GOENV=""~/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""~/.go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""~/.go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.16.3"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build1429872732=/tmp/go-build -gno-record-gcc-switches"" +
[Trace - 19:50:58.056 PM] Received response 'textDocument/completion - (57)' in 47ms.
+Result: {""isIncomplete"":true,""items"":[{""label"":""language.Language"",""kind"":7,""detail"":""uint16 (from \""golang.org/x/text/internal/language\"")"",""preselect"":true,""sortText"":""00000"",""filterText"":""language.Language"",""insertTextFormat"":2,""textEdit"":{""range"":{""start"":{""line"":36,""character"":1},""end"":{""line"":36,""character"":9}},""newText"":""language.Language""},""additionalTextEdits"":[{""range"":{""start"":{""line"":3,""character"":2},""end"":{""line"":3,""character"":2}},""newText"":""golang.org/x/text/internal/language\""\n\t\""""}]},{""label"":""language"",""kind"":9,""detail"":""\""golang.org/x/text/language\"""",""sortText"":""00001"",""filterText"":""language"",""insertTextFormat"":2,""textEdit"":{""range"":{""start"":{""line"":36,""character"":1},""end"":{""line"":36,""character"":9}},""newText"":""language""},""additionalTextEdits"":[{""range"":{""start"":{""line"":3,""character"":2},""end"":{""line"":3,""character"":2}},""newText"":""golang.org/x/text/language\""\n\t\""""}]},{""label"":""language"",""kind"":9,""detail"":""\""golang.org/x/text/internal/language\"""",""sortText"":""00002"",""filterText"":""language"",""insertTextFormat"":2,""textEdit"":{""range"":{""start"":{""line"":36,""character"":1},""end"":{""line"":36,""character"":9}},""newText"":""language""},""additionalTextEdits"":[{""range"":{""start"":{""line"":3,""character"":2},""end"":{""line"":3,""character"":2}},""newText"":""golang.org/x/text/internal/language\""\n\t\""""}]},{""label"":""language.BaseLanguages"",""kind"":3,""detail"":""func() []language.Language (from \""golang.org/x/text/internal/language\"")"",""documentation"":""BaseLanguages returns the list of all supported base languages. It generates\nthe list by traversing the internal structures.\n"",""sortText"":""00003"",""filterText"":""language.BaseLanguages"",""insertTextFormat"":2,""textEdit"":{""range"":{""start"":{""line"":36,""character"":1},""end"":{""line"":36,""character"":9}},""newText"":""language.BaseLanguages()""},""additionalTextEdits"":[{""range"":{""start"":{""line"":3,""character"":2},""end"":{""line"":3,""character"":2}},""newText"":""golang.org/x/text/internal/language\""\n\t\""""}]},{""label"":""language.ParseAcceptLanguage"",""kind"":3,""detail"":""func(s string) (tag []language.Tag, q []float32, err error) (from \""golang.org/x/text/language\"")"",""documentation"":""ParseAcceptLanguage parses the contents of an Accept-Language header as\ndefined in http://www.ietf.org/rfc/rfc2616.txt and returns a list of Tags and\na list of corresponding quality weights. It is more permissive than RFC 2616\nand may return non-nil slices even if the input is not valid.\nThe Tags will be sorted by highest weight first and then by first occurrence.\nTags with a weight of zero will be dropped. An error will be returned if the\ninput could not be parsed.\n"",""sortText"":""00004"",""filterText"":""language.ParseAcceptLanguage"",""insertTextFormat"":2,""textEdit"":{""range"":{""start"":{""line"":36,""character"":1},""end"":{""line"":36,""character"":9}},""newText"":""language.ParseAcceptLanguage(${1:})""},""additionalTextEdits"":[{""range"":{""start"":{""line"":3,""character"":2},""end"":{""line"":3,""character"":2}},""newText"":""golang.org/x/text/language\""\n\t\""""}]},{""label"":""language"",""kind"":9,""detail"":""\""google.golang.org/genproto/googleapis/cloud/language/v1\"""",""sortText"":""00007"",""filterText"":""language"",""insertTextFormat"":2,""textEdit"":{""range"":{""start"":{""line"":36,""character"":1},""end"":{""line"":36,""character"":9}},""newText"":""language""},""additionalTextEdits"":[{""range"":{""start"":{""line"":3,""character"":2},""end"":{""line"":3,""character"":2}},""newText"":""google.golang.org/genproto/googleapis/cloud/language/v1\""\n\t\""""}]},{""label"":""language"",""kind"":9,""detail"":""\""google.golang.org/api/language/v1\"""",""sortText"":""00008"",""filterText"":""language"",""insertTextFormat"":2,""textEdit"":{""range"":{""start"":{""line"":36,""character"":1},""end"":{""line"":36,""character"":9}},""newText"":""language""},""additionalTextEdits"":[{""range"":{""start"":{""line"":3,""character"":2},""end"":{""line"":3,""character"":2}},""newText"":""google.golang.org/api/language/v1\""\n\t\""""}]}]}+$ go version +go version go1.15.6 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/olivierwulveryck/Library/Caches/go-build"" +GOENV=""/Users/olivierwulveryck/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/olivierwulveryck/GOPROJECTS/pkg/mod"" +GONOPROXY=""github.com/dktunited"" +GONOSUMDB=""github.com/dktunited"" +GOOS=""darwin"" +GOPATH=""/Users/olivierwulveryck/GOPROJECTS"" +GOPRIVATE=""github.com/dktunited"" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/olivierwulveryck/GOPROJECTS/src/github.com/owulveryck/linesToGo/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/j3/t2_lsqzd5mgbv7tqvxg9ty5r0000gn/T/go-build500293275=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ go version +go version go1.15.6 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/olivierwulveryck/Library/Caches/go-build"" +GOENV=""/Users/olivierwulveryck/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/olivierwulveryck/GOPROJECTS/pkg/mod"" +GONOPROXY=""github.com/dktunited"" +GONOSUMDB=""github.com/dktunited"" +GOOS=""darwin"" +GOPATH=""/Users/olivierwulveryck/GOPROJECTS"" +GOPRIVATE=""github.com/dktunited"" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/olivierwulveryck/GOPROJECTS/src/github.com/owulveryck/linesToGo/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/j3/t2_lsqzd5mgbv7tqvxg9ty5r0000gn/T/go-build500293275=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/b5/Library/Caches/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/b5/go"" +GOPROXY="""" +GORACE="""" +GOROOT=""/usr/local/go"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/6p/sjn8bct92397mbgwmwwvcb4h0000gn/T/go-build195699704=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/b5/Library/Caches/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/b5/go"" +GOPROXY="""" +GORACE="""" +GOROOT=""/usr/local/go"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/6p/sjn8bct92397mbgwmwwvcb4h0000gn/T/go-build195699704=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ go version +go version go1.18.4 linux/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/root/.cache/go-build"" +GOENV=""/root/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/root/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/root/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.18.4"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/root/GoServer/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build3785892550=/tmp/go-build -gno-record-gcc-switches"" +
+cat /etc/os-release +NAME=""Ubuntu"" +VERSION=""20.04.4 LTS (Focal Fossa)"" +ID=ubuntu +ID_LIKE=debian +PRETTY_NAME=""Ubuntu 20.04.4 LTS"" +VERSION_ID=""20.04"" +HOME_URL=""https://www.ubuntu.com/"" +SUPPORT_URL=""https://help.ubuntu.com/"" +BUG_REPORT_URL=""https://bugs.launchpad.net/ubuntu/"" +PRIVACY_POLICY_URL=""https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"" +VERSION_CODENAME=focal +UBUNTU_CODENAME=focal ++ +### What did you do? + +I was debugging higher than expected CPU usage for async socket operations in c#/net6 on linux and ran a series of socket tests in nodejs, python3, c, and go as a references. I noticed that go uses about twice as much cpu as python3/c/.net6 and somewhat more than nodejs in my synchronous read test case. It's not a bug but I thought I'd share the findings in case somebody is interested at looking at it. I suspect there is some optimization that can be done to bring the go results in line with the others. I'm not a go developer but the code and are test are very simple so I don't believe it's naivety on my part - though I apologize if it is. These tests are done with the default settings, I'm not adjusting any socket settings, OS settings, etc. Just plain socket reads into an oversized buffer. + +From another host on the network I run netcat to saturate the network (in my case the receiving server is 192.168.1.93 and my tests were with a gigabit network) +cat /dev/zero | nc 192.168.1.93 9989 + +Then I run a receiving application such as the go application below to read the data and print out some details when I kill the netcat. I monitored the cpu usage with top and confirmed the network usage with iftop in addition to the application output below. + +using netcat as a listener +nc -l 9989 >/dev/null +uses about 8% cpu + +using golang with a goroutine per connection receiving into a buffer +./GoServer (attached zip, but it's super simple and has the code) +uses about 14% cpu + +using nodejs and the socket.on data callback +nodejs jsserver.js +uses about 10% cpu (not re-using a receive buffer so it's less efficient) + +using python3 with a synchronous tcp socket receiving into a buffer +python3 pyserver.py +uses about 8% cpu + +using .net6 with a synchronous tcp socket receiving into a buffer +dotnet run --configuration Release PerfTestTCPListener +uses about 6-8% cpu + +Code for python3, nodejs, c#/net6 +[OtherSamples.zip](https://github.com/golang/go/files/9133779/OtherSamples.zip) + +Code for Go +[GoServer.zip](https://github.com/golang/go/files/9133803/GoServer.zip) + +
+package main
+
+import (
+ ""fmt""
+ ""io""
+ ""net""
+ ""os""
+ ""time""
+)
+
+func main() {
+ port := ""0.0.0.0:9989""
+ listener, err := net.Listen(""tcp"", port)
+ if err != nil {
+ fmt.Println(""failed to create listener, err:"", err)
+ os.Exit(1)
+ }
+ fmt.Printf(""listening on %s\n"", listener.Addr())
+
+ for {
+ conn, err := listener.Accept()
+ if err != nil {
+ fmt.Println(""failed to accept connection, err:"", err)
+ continue
+ }
+ // run connection in a goroutine
+ go handleConnection(conn)
+ }
+}
+
+func handleConnection(conn net.Conn) {
+ defer conn.Close()
+ buf := make([]byte, 1048576)
+ nBytes := 0
+ start := time.Now()
+ for {
+ n, err := conn.Read(buf)
+ if err != nil {
+ if err != io.EOF {
+ fmt.Println(""failed to read data, err:"", err)
+ }
+ t := time.Now()
+ elapsed := t.Sub(start)
+ fmt.Printf(""Read: %d MB in %s, %f MB/s\n"", nBytes/1048576, elapsed, float64(nBytes)/1048576.0/el apsed.Seconds())
+ return
+ }
+ nBytes += n
+ }
+}
+
+
+
+### What did you expect to see?
+Similar cpu usage to python/.net6/nodejs
+
+
+### What did you see instead?
+~14% cpu usage vs ~8% cpu usage for python3/net6 and ~10% cpu usage for nodejs
+
+",True,"net: TCPConn.Read Higher CPU usage than comparable operation in python3/c#/nodejs - ### What version of Go are you using (`go version`)?
++$ go version +go version go1.18.4 linux/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/root/.cache/go-build"" +GOENV=""/root/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/root/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/root/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.18.4"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/root/GoServer/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build3785892550=/tmp/go-build -gno-record-gcc-switches"" +
+cat /etc/os-release +NAME=""Ubuntu"" +VERSION=""20.04.4 LTS (Focal Fossa)"" +ID=ubuntu +ID_LIKE=debian +PRETTY_NAME=""Ubuntu 20.04.4 LTS"" +VERSION_ID=""20.04"" +HOME_URL=""https://www.ubuntu.com/"" +SUPPORT_URL=""https://help.ubuntu.com/"" +BUG_REPORT_URL=""https://bugs.launchpad.net/ubuntu/"" +PRIVACY_POLICY_URL=""https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"" +VERSION_CODENAME=focal +UBUNTU_CODENAME=focal ++ +### What did you do? + +I was debugging higher than expected CPU usage for async socket operations in c#/net6 on linux and ran a series of socket tests in nodejs, python3, c, and go as a references. I noticed that go uses about twice as much cpu as python3/c/.net6 and somewhat more than nodejs in my synchronous read test case. It's not a bug but I thought I'd share the findings in case somebody is interested at looking at it. I suspect there is some optimization that can be done to bring the go results in line with the others. I'm not a go developer but the code and are test are very simple so I don't believe it's naivety on my part - though I apologize if it is. These tests are done with the default settings, I'm not adjusting any socket settings, OS settings, etc. Just plain socket reads into an oversized buffer. + +From another host on the network I run netcat to saturate the network (in my case the receiving server is 192.168.1.93 and my tests were with a gigabit network) +cat /dev/zero | nc 192.168.1.93 9989 + +Then I run a receiving application such as the go application below to read the data and print out some details when I kill the netcat. I monitored the cpu usage with top and confirmed the network usage with iftop in addition to the application output below. + +using netcat as a listener +nc -l 9989 >/dev/null +uses about 8% cpu + +using golang with a goroutine per connection receiving into a buffer +./GoServer (attached zip, but it's super simple and has the code) +uses about 14% cpu + +using nodejs and the socket.on data callback +nodejs jsserver.js +uses about 10% cpu (not re-using a receive buffer so it's less efficient) + +using python3 with a synchronous tcp socket receiving into a buffer +python3 pyserver.py +uses about 8% cpu + +using .net6 with a synchronous tcp socket receiving into a buffer +dotnet run --configuration Release PerfTestTCPListener +uses about 6-8% cpu + +Code for python3, nodejs, c#/net6 +[OtherSamples.zip](https://github.com/golang/go/files/9133779/OtherSamples.zip) + +Code for Go +[GoServer.zip](https://github.com/golang/go/files/9133803/GoServer.zip) + +
+package main
+
+import (
+ ""fmt""
+ ""io""
+ ""net""
+ ""os""
+ ""time""
+)
+
+func main() {
+ port := ""0.0.0.0:9989""
+ listener, err := net.Listen(""tcp"", port)
+ if err != nil {
+ fmt.Println(""failed to create listener, err:"", err)
+ os.Exit(1)
+ }
+ fmt.Printf(""listening on %s\n"", listener.Addr())
+
+ for {
+ conn, err := listener.Accept()
+ if err != nil {
+ fmt.Println(""failed to accept connection, err:"", err)
+ continue
+ }
+ // run connection in a goroutine
+ go handleConnection(conn)
+ }
+}
+
+func handleConnection(conn net.Conn) {
+ defer conn.Close()
+ buf := make([]byte, 1048576)
+ nBytes := 0
+ start := time.Now()
+ for {
+ n, err := conn.Read(buf)
+ if err != nil {
+ if err != io.EOF {
+ fmt.Println(""failed to read data, err:"", err)
+ }
+ t := time.Now()
+ elapsed := t.Sub(start)
+ fmt.Printf(""Read: %d MB in %s, %f MB/s\n"", nBytes/1048576, elapsed, float64(nBytes)/1048576.0/el apsed.Seconds())
+ return
+ }
+ nBytes += n
+ }
+}
+
+
+
+### What did you expect to see?
+Similar cpu usage to python/.net6/nodejs
+
+
+### What did you see instead?
+~14% cpu usage vs ~8% cpu usage for python3/net6 and ~10% cpu usage for nodejs
+
+",0,net tcpconn read higher cpu usage than comparable operation in c nodejs what version of go are you using go version go version go version linux does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env go env output go env goarch gobin gocache root cache go build goenv root config go env goexe goexperiment goflags gohostarch gohostos linux goinsecure gomodcache root go pkg mod gonoproxy gonosumdb goos linux gopath root go goprivate goproxy goroot usr local go gosumdb sum golang org gotmpdir gotooldir usr local go pkg tool linux govcs goversion gccgo gccgo ar ar cc gcc cxx g cgo enabled gomod root goserver go mod gowork cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fmessage length fdebug prefix map tmp go tmp go build gno record gcc switches cat etc os release name ubuntu version lts focal fossa id ubuntu id like debian pretty name ubuntu lts version id home url support url bug report url privacy policy url version codename focal ubuntu codename focal what did you do i was debugging higher than expected cpu usage for async socket operations in c on linux and ran a series of socket tests in nodejs c and go as a references i noticed that go uses about twice as much cpu as c and somewhat more than nodejs in my synchronous read test case it s not a bug but i thought i d share the findings in case somebody is interested at looking at it i suspect there is some optimization that can be done to bring the go results in line with the others i m not a go developer but the code and are test are very simple so i don t believe it s naivety on my part though i apologize if it is these tests are done with the default settings i m not adjusting any socket settings os settings etc just plain socket reads into an oversized buffer from another host on the network i run netcat to saturate the network in my case the receiving server is and my tests were with a gigabit network cat dev zero nc then i run a receiving application such as the go application below to read the data and print out some details when i kill the netcat i monitored the cpu usage with top and confirmed the network usage with iftop in addition to the application output below using netcat as a listener nc l dev null uses about cpu using golang with a goroutine per connection receiving into a buffer goserver attached zip but it s super simple and has the code uses about cpu using nodejs and the socket on data callback nodejs jsserver js uses about cpu not re using a receive buffer so it s less efficient using with a synchronous tcp socket receiving into a buffer pyserver py uses about cpu using with a synchronous tcp socket receiving into a buffer dotnet run configuration release perftesttcplistener uses about cpu code for nodejs c code for go package main import fmt io net os time func main port listener err net listen tcp port if err nil fmt println failed to create listener err err os exit fmt printf listening on s n listener addr for conn err listener accept if err nil fmt println failed to accept connection err err continue run connection in a goroutine go handleconnection conn func handleconnection conn net conn defer conn close buf make byte nbytes start time now for n err conn read buf if err nil if err io eof fmt println failed to read data err err t time now elapsed t sub start fmt printf read d mb in s f mb s n nbytes elapsed nbytes el apsed seconds return nbytes n what did you expect to see similar cpu usage to python nodejs what did you see instead cpu usage vs cpu usage for and cpu usage for nodejs ,0
+85571,24627315498.0,IssuesEvent,2022-10-16 17:33:45,golang/go,https://api.github.com/repos/golang/go,closed,x/build/cmd/updatestd: test failures without useful output,Builders WaitingForInfo NeedsFix,"```
+2022/09/08 04:11:11 > go list -mod=readonly -m -json all
+2022/09/08 04:11:11 command failed: exit status 1
+FAIL golang.org/x/build/cmd/updatestd 92.408s
+```
+
+It looks like the `go list` command failed, but I can't dig into it further because the `stderr` stream from the `go list` command is not logged. A good first step would probably be to update this test in line with https://go.dev/wiki/CodeReviewComments#useful-test-failures.",1.0,"x/build/cmd/updatestd: test failures without useful output - ```
+2022/09/08 04:11:11 > go list -mod=readonly -m -json all
+2022/09/08 04:11:11 command failed: exit status 1
+FAIL golang.org/x/build/cmd/updatestd 92.408s
+```
+
+It looks like the `go list` command failed, but I can't dig into it further because the `stderr` stream from the `go list` command is not logged. A good first step would probably be to update this test in line with https://go.dev/wiki/CodeReviewComments#useful-test-failures.",0,x build cmd updatestd test failures without useful output go list mod readonly m json all command failed exit status fail golang org x build cmd updatestd it looks like the go list command failed but i can t dig into it further because the stderr stream from the go list command is not logged a good first step would probably be to update this test in line with ,0
+48765,7456980382.0,IssuesEvent,2018-03-30 00:57:42,golang/go,https://api.github.com/repos/golang/go,closed,database/sql: improve documentation for DB.Close() (graceful close or not),Documentation,"The documentation doesn't make clear what DB.Close() does.
+
+Does it close the Pool immediately even if there are still queries happening in some of the connections, or does it wait for the queries to finish and gradually closes the connections and then closes the pool?",1.0,"database/sql: improve documentation for DB.Close() (graceful close or not) - The documentation doesn't make clear what DB.Close() does.
+
+Does it close the Pool immediately even if there are still queries happening in some of the connections, or does it wait for the queries to finish and gradually closes the connections and then closes the pool?",1,database sql improve documentation for db close graceful close or not the documentation doesn t make clear what db close does does it close the pool immediately even if there are still queries happening in some of the connections or does it wait for the queries to finish and gradually closes the connections and then closes the pool ,1
+47021,7299398061.0,IssuesEvent,2018-02-26 19:59:25,golang/go,https://api.github.com/repos/golang/go,closed,archive/zip: improve Writer.Create documentation on how to add directories,Documentation NeedsFix help wanted,"I tried to add an empty folder to a zip.Writer with zip.Writer.Create. From the [docs](https://golang.org/pkg/archive/zip/#Writer.Create) it is not clear how to do this. There is a [google group post](https://groups.google.com/forum/#!topic/golang-nuts/Te0oScOV3KM) that provides the solution, which is to add a slash at the end of the path given to zip.Writer.Create.
+
+I suggest adding this detail to the documentation comment on zip.Writer.Create, e.g. ""... To create a folder instead of a file, add a trailing slash to the path."".",1.0,"archive/zip: improve Writer.Create documentation on how to add directories - I tried to add an empty folder to a zip.Writer with zip.Writer.Create. From the [docs](https://golang.org/pkg/archive/zip/#Writer.Create) it is not clear how to do this. There is a [google group post](https://groups.google.com/forum/#!topic/golang-nuts/Te0oScOV3KM) that provides the solution, which is to add a slash at the end of the path given to zip.Writer.Create.
+
+I suggest adding this detail to the documentation comment on zip.Writer.Create, e.g. ""... To create a folder instead of a file, add a trailing slash to the path."".",1,archive zip improve writer create documentation on how to add directories i tried to add an empty folder to a zip writer with zip writer create from the it is not clear how to do this there is a that provides the solution which is to add a slash at the end of the path given to zip writer create i suggest adding this detail to the documentation comment on zip writer create e g to create a folder instead of a file add a trailing slash to the path ,1
+26966,5302645011.0,IssuesEvent,2017-02-10 13:40:23,golang/go,https://api.github.com/repos/golang/go,closed,encoding/json: Unmarshal to nil pointer documentation discrepancy,Documentation,"When trying to unmarshal a json string into a nil pointer, the operation fails as can be seen here:
+https://play.golang.org/p/wL6UDpaJ-h
+
+The error returned is InvalidUnmarshalError whose docs clearly state:
+""The argument to Unmarshal must be a non-nil pointer."" (https://golang.org/pkg/encoding/json/#InvalidUnmarshalError)
+
+But the docs for the Unmarshal function state:
+""Unmarshal unmarshals the JSON into the value pointed at by the pointer. If the pointer is nil, Unmarshal allocates a new value for it to point to.""
+(https://golang.org/pkg/encoding/json/#Unmarshal)
+
+Obviously, the behaviour implemented is the one from the error docs.
+
+Curiously, this works:
+https://play.golang.org/p/w-Sg24qcCo
+So, a reference to a nil pointer is accepted but the nil pointer itself is not. Anyone care to clarify?
+
+go1.7.4 darwin/amd64
+
+
+
+",1.0,"encoding/json: Unmarshal to nil pointer documentation discrepancy - When trying to unmarshal a json string into a nil pointer, the operation fails as can be seen here:
+https://play.golang.org/p/wL6UDpaJ-h
+
+The error returned is InvalidUnmarshalError whose docs clearly state:
+""The argument to Unmarshal must be a non-nil pointer."" (https://golang.org/pkg/encoding/json/#InvalidUnmarshalError)
+
+But the docs for the Unmarshal function state:
+""Unmarshal unmarshals the JSON into the value pointed at by the pointer. If the pointer is nil, Unmarshal allocates a new value for it to point to.""
+(https://golang.org/pkg/encoding/json/#Unmarshal)
+
+Obviously, the behaviour implemented is the one from the error docs.
+
+Curiously, this works:
+https://play.golang.org/p/w-Sg24qcCo
+So, a reference to a nil pointer is accepted but the nil pointer itself is not. Anyone care to clarify?
+
+go1.7.4 darwin/amd64
+
+
+
+",1,encoding json unmarshal to nil pointer documentation discrepancy when trying to unmarshal a json string into a nil pointer the operation fails as can be seen here the error returned is invalidunmarshalerror whose docs clearly state the argument to unmarshal must be a non nil pointer but the docs for the unmarshal function state unmarshal unmarshals the json into the value pointed at by the pointer if the pointer is nil unmarshal allocates a new value for it to point to obviously the behaviour implemented is the one from the error docs curiously this works so a reference to a nil pointer is accepted but the nil pointer itself is not anyone care to clarify darwin ,1
+31006,5893901807.0,IssuesEvent,2017-05-17 23:31:27,golang/go,https://api.github.com/repos/golang/go,closed,doc: add IntelliJ Go editor guide,DevExp Documentation,"This is a tracking bug for an editor guide on IntelliJ Go, see #20398 .
+
+Create a brief info card based on the template at #20398 and create screencast for a few top features as 1280x640 gifs.
+
+/cc @dlsniper ",1.0,"doc: add IntelliJ Go editor guide - This is a tracking bug for an editor guide on IntelliJ Go, see #20398 .
+
+Create a brief info card based on the template at #20398 and create screencast for a few top features as 1280x640 gifs.
+
+/cc @dlsniper ",1,doc add intellij go editor guide this is a tracking bug for an editor guide on intellij go see create a brief info card based on the template at and create screencast for a few top features as gifs cc dlsniper ,1
+55814,8031414597.0,IssuesEvent,2018-07-28 01:16:07,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: `go help mod` should mention `go help module`,Documentation NeedsFix modules,"go version devel +5f5402b Tue Jul 24 23:54:08 2018 +0000 linux/amd64
+
+The help for `go help mod` should mention the existence of the modules help page
+which contains crucial information about GO111MODULE and how modules work.
+I didn't know that existed until I grepped for GO111 in the Go source tree and found
+that help text.
+
+Perhaps if #26581 was addressed, then the output of `go help mod` could be the same as that of `go help modules` now, as well as mentioning the subcommands.",1.0,"cmd/go: `go help mod` should mention `go help module` - go version devel +5f5402b Tue Jul 24 23:54:08 2018 +0000 linux/amd64
+
+The help for `go help mod` should mention the existence of the modules help page
+which contains crucial information about GO111MODULE and how modules work.
+I didn't know that existed until I grepped for GO111 in the Go source tree and found
+that help text.
+
+Perhaps if #26581 was addressed, then the output of `go help mod` could be the same as that of `go help modules` now, as well as mentioning the subcommands.",1,cmd go go help mod should mention go help module go version devel tue jul linux the help for go help mod should mention the existence of the modules help page which contains crucial information about and how modules work i didn t know that existed until i grepped for in the go source tree and found that help text perhaps if was addressed then the output of go help mod could be the same as that of go help modules now as well as mentioning the subcommands ,1
+47125,7307953166.0,IssuesEvent,2018-02-28 05:55:56,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: go run: triggers Symantec malware alert.,Documentation,"### What version of Go are you using (`go version`)?
+
+`go version go1.9.4 windows/amd64`
+
+### Does this issue reproduce with the latest release?
+Yes.
+
+### What operating system and processor architecture are you using (`go env`)?
+```
+set GOARCH=amd64
+set GOBIN=
+set GOEXE=.exe
+set GOHOSTARCH=amd64
+set GOHOSTOS=windows
+set GOOS=windows
+set GOPATH=C:\Users\-snip-\go
+set GORACE=
+set GOROOT=C:\Go
+set GOTOOLDIR=C:\Go\pkg\tool\windows_amd64
+set GCCGO=gccgo
+set CC=gcc
+set GOGCCFLAGS=-m64 -mthreads -fmessage-length=0
+set CXX=g++
+set CGO_ENABLED=1
+set CGO_CFLAGS=-g -O2
+set CGO_CPPFLAGS=
+set CGO_CXXFLAGS=-g -O2
+set CGO_FFLAGS=-g -O2
+set CGO_LDFLAGS=-g -O2
+set PKG_CONFIG=pkg-config
+```
+
+### What did you do?
+I ran the following program:
+
+```
+package main
+
+import ""fmt""
+
+func main() {
+ fmt.Println(""1 + 1 ="", 1 + 1)
+ fmt.Println(""1 + 1 ="", 1.0 + 1.0)
+}
+```
+
+### What did you expect to see?
+```
+1 + 1 = 2
+1 + 1 = 2
+```
+
+### What did you see instead?
+```
+exit status 3221225506
+```
+Symantec got triggered. https://www.symantec.com/security_response/writeup.jsp?docid=2017-032721-5748-99&vid=4294924267",1.0,"cmd/go: go run: triggers Symantec malware alert. - ### What version of Go are you using (`go version`)?
+
+`go version go1.9.4 windows/amd64`
+
+### Does this issue reproduce with the latest release?
+Yes.
+
+### What operating system and processor architecture are you using (`go env`)?
+```
+set GOARCH=amd64
+set GOBIN=
+set GOEXE=.exe
+set GOHOSTARCH=amd64
+set GOHOSTOS=windows
+set GOOS=windows
+set GOPATH=C:\Users\-snip-\go
+set GORACE=
+set GOROOT=C:\Go
+set GOTOOLDIR=C:\Go\pkg\tool\windows_amd64
+set GCCGO=gccgo
+set CC=gcc
+set GOGCCFLAGS=-m64 -mthreads -fmessage-length=0
+set CXX=g++
+set CGO_ENABLED=1
+set CGO_CFLAGS=-g -O2
+set CGO_CPPFLAGS=
+set CGO_CXXFLAGS=-g -O2
+set CGO_FFLAGS=-g -O2
+set CGO_LDFLAGS=-g -O2
+set PKG_CONFIG=pkg-config
+```
+
+### What did you do?
+I ran the following program:
+
+```
+package main
+
+import ""fmt""
+
+func main() {
+ fmt.Println(""1 + 1 ="", 1 + 1)
+ fmt.Println(""1 + 1 ="", 1.0 + 1.0)
+}
+```
+
+### What did you expect to see?
+```
+1 + 1 = 2
+1 + 1 = 2
+```
+
+### What did you see instead?
+```
+exit status 3221225506
+```
+Symantec got triggered. https://www.symantec.com/security_response/writeup.jsp?docid=2017-032721-5748-99&vid=4294924267",1,cmd go go run triggers symantec malware alert what version of go are you using go version go version windows does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env set goarch set gobin set goexe exe set gohostarch set gohostos windows set goos windows set gopath c users snip go set gorace set goroot c go set gotooldir c go pkg tool windows set gccgo gccgo set cc gcc set gogccflags mthreads fmessage length set cxx g set cgo enabled set cgo cflags g set cgo cppflags set cgo cxxflags g set cgo fflags g set cgo ldflags g set pkg config pkg config what did you do i ran the following program package main import fmt func main fmt println fmt println what did you expect to see what did you see instead exit status symantec got triggered ,1
+22078,4771761463.0,IssuesEvent,2016-10-26 18:55:03,golang/go,https://api.github.com/repos/golang/go,opened,net: no docs about the behavior of announcing or listening on IP dual stack,Documentation,"I asked several times on golang-nuts, golang-dev or golang-codereviews like the following:
+https://groups.google.com/d/msg/golang-dev/MvAlef3CTqk/DGs5sLBcCgAJ
+",1.0,"net: no docs about the behavior of announcing or listening on IP dual stack - I asked several times on golang-nuts, golang-dev or golang-codereviews like the following:
+https://groups.google.com/d/msg/golang-dev/MvAlef3CTqk/DGs5sLBcCgAJ
+",1,net no docs about the behavior of announcing or listening on ip dual stack i asked several times on golang nuts golang dev or golang codereviews like the following ,1
+65560,8819660880.0,IssuesEvent,2018-12-31 22:49:20,golang/go,https://api.github.com/repos/golang/go,closed,strconv: Atoi documentation is slightly misleading,Documentation NeedsFix,"
+
+### What version of Go are you using (`go version`)?
+
++$ go version 1.11.4 ++ +### Does this issue reproduce with the latest release? +Yes. + + +### What operating system and processor architecture are you using (`go env`)? +Irrelevant. + +
go env Output+$ go env + +
+$ go version 1.11.4 ++ +### Does this issue reproduce with the latest release? +Yes. + + +### What operating system and processor architecture are you using (`go env`)? +Irrelevant. + +
go env Output+$ go env + +
+$ go version +1.20.1 ++ +### Does this issue reproduce with the latest release? + +Yep + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +
+$ go version +1.20.1 ++ +### Does this issue reproduce with the latest release? + +Yep + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +
+$ go version +1.19.2 ++ +### Does this issue reproduce with the latest release? + +y + +### What operating system and processor architecture are you using (`go env`)? + +N/A + +### What did you do? + +Read the docs. + +### What did you expect to see? + +Fewer typos. + +### What did you see instead? + +In the FuzzJSONMarshaling example: +``` +t.Error(""Marshal: %v"", err) +``` +Either this shouldn't have the ""%v"", or it should be `t.Errorf`. +",1.0,"testing: silly typo in documentation - ### What version of Go are you using (`go version`)? + +
+$ go version +1.19.2 ++ +### Does this issue reproduce with the latest release? + +y + +### What operating system and processor architecture are you using (`go env`)? + +N/A + +### What did you do? + +Read the docs. + +### What did you expect to see? + +Fewer typos. + +### What did you see instead? + +In the FuzzJSONMarshaling example: +``` +t.Error(""Marshal: %v"", err) +``` +Either this shouldn't have the ""%v"", or it should be `t.Errorf`. +",1,testing silly typo in documentation what version of go are you using go version go version does this issue reproduce with the latest release y what operating system and processor architecture are you using go env n a what did you do read the docs what did you expect to see fewer typos what did you see instead in the fuzzjsonmarshaling example t error marshal v err either this shouldn t have the v or it should be t errorf ,1 +62464,8613956615.0,IssuesEvent,2018-11-19 16:16:12,golang/go,https://api.github.com/repos/golang/go,closed,cmd/link: difference between s.P and s.Size,Documentation," + +### What version of Go are you using (`go version`)? +go version devel +66fa0ae2e6 Thu Nov 8 14:29:02 2018 -0600 aix/ppc64 + +### Does this issue reproduce with the latest release? +I don't know. But I think so. + + +### What operating system and processor architecture are you using (`go env`)? +I'm on aix/ppc64. But I've quickly tried on linux/amd64 and I have the same issue. + +### What did you do? +This is linked with //go:cgo_import_dynamic. My program looks like this: + +``` +package main + +import ( + ""fmt"" + _ ""unsafe"" +) + +//go:cgo_import_dynamic libc_exit exit ""libc.so"" +//go:linkname libc_exit libc_exit + +var libc_exit uintptr + +func main() { + fmt.Printf(""0x%x\n"", &libc_exit) +} +``` + +During XCOFF creation (doxcoff), I'm trying to add a relocation from ""libc_exit"" symbol to a new needed symbol ""exit"". (The same can be done in doelf on linux/amd64) +My code looks like: + +``` +s := ctxt.Syms.Lookup(""libc_exit"", 0) +extsym := ctxt.Syms.Lookup(s.Extname(), 0) +// setup of extsym +s.AddAddr(ctxt.Arch, extsym) +``` + +Before this operation, s.Size = 8 and len(s.P) = 0. I'm not sure if it's wanted but as libc_exit is linkname to a bss symbol, it's not that strange. +Therefore, when I do s.AddAddr(ctxt.Arch, extsym), I've s.Size = 16 and len(s.P) = 16. But I don't want that as the relocation will be at off = 8 and ""libc_exit"" should have only 8 bytes. + +So, I've tried with s.SetAddr(ctxt.Arch, 0, extsym) to set these 8 bytes. But in this case, during relocsym I've this error: +libc_exit: invalid relocation exit: 0+8 not in [0,0) (numbers in order: r.Off, s.Size, 0, len(s.P)) +because s.P isn't growth during this operation. +If I increase s.P manually, everything is OK: +``` +s.AddBytes(make([]byte, 8)) +s.SetAddr(ctxt.Arch, 0, extsym) +``` + + +Therefore, I'm understanding it's not possible to create such relocation with the current sym functions. This might not be a problem, but the second behavior doesn't seem intended. Is this a bug ? + + +",1.0,"cmd/link: difference between s.P and s.Size - + +### What version of Go are you using (`go version`)? +go version devel +66fa0ae2e6 Thu Nov 8 14:29:02 2018 -0600 aix/ppc64 + +### Does this issue reproduce with the latest release? +I don't know. But I think so. + + +### What operating system and processor architecture are you using (`go env`)? +I'm on aix/ppc64. But I've quickly tried on linux/amd64 and I have the same issue. + +### What did you do? +This is linked with //go:cgo_import_dynamic. My program looks like this: + +``` +package main + +import ( + ""fmt"" + _ ""unsafe"" +) + +//go:cgo_import_dynamic libc_exit exit ""libc.so"" +//go:linkname libc_exit libc_exit + +var libc_exit uintptr + +func main() { + fmt.Printf(""0x%x\n"", &libc_exit) +} +``` + +During XCOFF creation (doxcoff), I'm trying to add a relocation from ""libc_exit"" symbol to a new needed symbol ""exit"". (The same can be done in doelf on linux/amd64) +My code looks like: + +``` +s := ctxt.Syms.Lookup(""libc_exit"", 0) +extsym := ctxt.Syms.Lookup(s.Extname(), 0) +// setup of extsym +s.AddAddr(ctxt.Arch, extsym) +``` + +Before this operation, s.Size = 8 and len(s.P) = 0. I'm not sure if it's wanted but as libc_exit is linkname to a bss symbol, it's not that strange. +Therefore, when I do s.AddAddr(ctxt.Arch, extsym), I've s.Size = 16 and len(s.P) = 16. But I don't want that as the relocation will be at off = 8 and ""libc_exit"" should have only 8 bytes. + +So, I've tried with s.SetAddr(ctxt.Arch, 0, extsym) to set these 8 bytes. But in this case, during relocsym I've this error: +libc_exit: invalid relocation exit: 0+8 not in [0,0) (numbers in order: r.Off, s.Size, 0, len(s.P)) +because s.P isn't growth during this operation. +If I increase s.P manually, everything is OK: +``` +s.AddBytes(make([]byte, 8)) +s.SetAddr(ctxt.Arch, 0, extsym) +``` + + +Therefore, I'm understanding it's not possible to create such relocation with the current sym functions. This might not be a problem, but the second behavior doesn't seem intended. Is this a bug ? + + +",1,cmd link difference between s p and s size what version of go are you using go version go version devel thu nov aix does this issue reproduce with the latest release i don t know but i think so what operating system and processor architecture are you using go env i m on aix but i ve quickly tried on linux and i have the same issue what did you do this is linked with go cgo import dynamic my program looks like this package main import fmt unsafe go cgo import dynamic libc exit exit libc so go linkname libc exit libc exit var libc exit uintptr func main fmt printf x n libc exit during xcoff creation doxcoff i m trying to add a relocation from libc exit symbol to a new needed symbol exit the same can be done in doelf on linux my code looks like s ctxt syms lookup libc exit extsym ctxt syms lookup s extname setup of extsym s addaddr ctxt arch extsym before this operation s size and len s p i m not sure if it s wanted but as libc exit is linkname to a bss symbol it s not that strange therefore when i do s addaddr ctxt arch extsym i ve s size and len s p but i don t want that as the relocation will be at off and libc exit should have only bytes so i ve tried with s setaddr ctxt arch extsym to set these bytes but in this case during relocsym i ve this error libc exit invalid relocation exit not in numbers in order r off s size len s p because s p isn t growth during this operation if i increase s p manually everything is ok s addbytes make byte s setaddr ctxt arch extsym therefore i m understanding it s not possible to create such relocation with the current sym functions this might not be a problem but the second behavior doesn t seem intended is this a bug ,1 +91784,26486495872.0,IssuesEvent,2023-01-17 18:29:01,golang/go,https://api.github.com/repos/golang/go,closed,x/build: 2 out of 3 host-ios-arm64-corellium-ios are missing,Builders NeedsFix mobile,"According to farmer.golang.org, some of the machines are missing: + +`host-ios-arm64-corellium-ios: 1/1 (2 missing)` + +@golang/ios @steeve @changkun",1.0,"x/build: 2 out of 3 host-ios-arm64-corellium-ios are missing - According to farmer.golang.org, some of the machines are missing: + +`host-ios-arm64-corellium-ios: 1/1 (2 missing)` + +@golang/ios @steeve @changkun",0,x build out of host ios corellium ios are missing according to farmer golang org some of the machines are missing host ios corellium ios missing golang ios steeve changkun,0 +90325,10678700100.0,IssuesEvent,2019-10-21 17:48:09,golang/go,https://api.github.com/repos/golang/go,closed,io: CopyBuffer should document when buf is not used,Documentation NeedsDecision,"The follow is the comment for io.CopyBuffer, +// CopyBuffer is identical to Copy except that it stages through the +// provided buffer (if one is required) rather than allocating a +// temporary one. If buf is nil, one is allocated; otherwise if it has +// zero length, CopyBuffer panics. +func CopyBuffer(dst Writer, src Reader, buf []byte) (written int64, err error) + + which is not precise enough, in the case of src implements the WriterTo interface or the case of if dst implements the ReaderFrom interface , buf will be ignore ,which is not mentioned at all. Which is very easy to lead people to wrong way. +",1.0,"io: CopyBuffer should document when buf is not used - The follow is the comment for io.CopyBuffer, +// CopyBuffer is identical to Copy except that it stages through the +// provided buffer (if one is required) rather than allocating a +// temporary one. If buf is nil, one is allocated; otherwise if it has +// zero length, CopyBuffer panics. +func CopyBuffer(dst Writer, src Reader, buf []byte) (written int64, err error) + + which is not precise enough, in the case of src implements the WriterTo interface or the case of if dst implements the ReaderFrom interface , buf will be ignore ,which is not mentioned at all. Which is very easy to lead people to wrong way. +",1,io copybuffer should document when buf is not used the follow is the comment for io copybuffer copybuffer is identical to copy except that it stages through the provided buffer if one is required rather than allocating a temporary one if buf is nil one is allocated otherwise if it has zero length copybuffer panics func copybuffer dst writer src reader buf byte written err error which is not precise enough in the case of src implements the writerto interface or the case of if dst implements the readerfrom interface buf will be ignore which is not mentioned at all which is very easy to lead people to wrong way ,1 +36074,5030162240.0,IssuesEvent,2016-12-15 23:33:56,golang/go,https://api.github.com/repos/golang/go,closed,net/http: TestServerTimeouts flake,NeedsInvestigation Testing,"https://storage.googleapis.com/go-build-log/00bd9228/linux-amd64-race_7b9a8856.log +``` +2016/11/23 21:53:28 http: TLS handshake error from 127.0.0.1:41658: read tcp 127.0.0.1:34022->127.0.0.1:41658: use of closed network connection +--- FAIL: TestServerTimeouts (0.79s) + serve_test.go:512: http Get #2: Get http://127.0.0.1:38239: http: server closed idle connection +FAIL +FAIL net/http 11.248s +```",1.0,"net/http: TestServerTimeouts flake - https://storage.googleapis.com/go-build-log/00bd9228/linux-amd64-race_7b9a8856.log +``` +2016/11/23 21:53:28 http: TLS handshake error from 127.0.0.1:41658: read tcp 127.0.0.1:34022->127.0.0.1:41658: use of closed network connection +--- FAIL: TestServerTimeouts (0.79s) + serve_test.go:512: http Get #2: Get http://127.0.0.1:38239: http: server closed idle connection +FAIL +FAIL net/http 11.248s +```",0,net http testservertimeouts flake http tls handshake error from read tcp use of closed network connection fail testservertimeouts serve test go http get get http server closed idle connection fail fail net http ,0 +117479,9936815271.0,IssuesEvent,2019-07-02 20:08:59,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: TestScript/mod_sumdb_golang currently failing,NeedsInvestigation Soon Testing modules release-blocker,"There is a new `cmd/go` failure in the `longtest` builder: +https://build.golang.org/log/6f541b96e3d3bd306c36aa040dc7341d544552ce + +It is reproducible locally, but the first failure in the dashboard is at an unrelated CL. That suggests that something has changed in the interaction with the proxy: for some reason we're apparently needing to download additional checksum tiles. + +
+$ go version +go version go1.20.2 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+``` +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/paj/Library/Caches/go-build"" +GOENV=""/Users/paj/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/paj/.asdf/installs/golang/1.20.2/packages/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/paj/.asdf/installs/golang/1.20.2/packages"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/Users/paj/.asdf/installs/golang/1.20.2/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/Users/paj/.asdf/installs/golang/1.20.2/go/pkg/tool/darwin_amd64"" +GOVCS="""" +GOVERSION=""go1.20.2"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +GOWORK="""" +CGO_CFLAGS=""-O2 -g"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-O2 -g"" +CGO_FFLAGS=""-O2 -g"" +CGO_LDFLAGS=""-O2 -g"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/4d/zd6b5xpn7rq00306yspzfy3r0000gn/T/go-build17349328=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
+$ go version +go version go1.20.2 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+``` +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/paj/Library/Caches/go-build"" +GOENV=""/Users/paj/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/paj/.asdf/installs/golang/1.20.2/packages/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/paj/.asdf/installs/golang/1.20.2/packages"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/Users/paj/.asdf/installs/golang/1.20.2/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/Users/paj/.asdf/installs/golang/1.20.2/go/pkg/tool/darwin_amd64"" +GOVCS="""" +GOVERSION=""go1.20.2"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +GOWORK="""" +CGO_CFLAGS=""-O2 -g"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-O2 -g"" +CGO_FFLAGS=""-O2 -g"" +CGO_LDFLAGS=""-O2 -g"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/4d/zd6b5xpn7rq00306yspzfy3r0000gn/T/go-build17349328=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
+1.17 ++ +### Does this issue reproduce with the latest release? + +Reproducible on the tip. + +### What operating system and processor architecture are you using (`go env`)? + +linux/amd64. + +### What did you do? + +`go run example.go` (https://play.golang.org/p/dU4NQ2vTVyF): + +```go +package main + +import ( + ""fmt"" + ""encoding/xml"" + ""strings"" +) + +func main() { + const input = `
+1.17 ++ +### Does this issue reproduce with the latest release? + +Reproducible on the tip. + +### What operating system and processor architecture are you using (`go env`)? + +linux/amd64. + +### What did you do? + +`go run example.go` (https://play.golang.org/p/dU4NQ2vTVyF): + +```go +package main + +import ( + ""fmt"" + ""encoding/xml"" + ""strings"" +) + +func main() { + const input = `
+$ go version +go version devel +f0c383b833 Wed May 1 16:53:19 2019 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What did you do? + +Read `go help modules` and `go help go.mod`. + +### What did you expect to see? + +Some discussion of what replacements are and what they do. + +### What did you see instead? + +The only documentation I can find is these lines in `go help go.mod`: +``` + replace bad/thing v1.4.5 => good/thing v1.4.5 +``` +``` + replace, to replace a module version with a different module version. +Exclude and replace apply only in the main module's go.mod and are ignored +in dependencies. See https://research.swtch.com/vgo-mvs for details. +``` + +I think there's probably more to say about how replace works. For example, it doesn't explicitly state that the thing to replace is on the left side of the arrow. It also doesn't mention that the version on the left is optional.",1.0,"cmd/go: replace directives are not thoroughly documented - + +### What version of Go are you using (`go version`)? + +
+$ go version +go version devel +f0c383b833 Wed May 1 16:53:19 2019 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What did you do? + +Read `go help modules` and `go help go.mod`. + +### What did you expect to see? + +Some discussion of what replacements are and what they do. + +### What did you see instead? + +The only documentation I can find is these lines in `go help go.mod`: +``` + replace bad/thing v1.4.5 => good/thing v1.4.5 +``` +``` + replace, to replace a module version with a different module version. +Exclude and replace apply only in the main module's go.mod and are ignored +in dependencies. See https://research.swtch.com/vgo-mvs for details. +``` + +I think there's probably more to say about how replace works. For example, it doesn't explicitly state that the thing to replace is on the left side of the arrow. It also doesn't mention that the version on the left is optional.",1,cmd go replace directives are not thoroughly documented what version of go are you using go version go version go version devel wed may linux does this issue reproduce with the latest release yes what did you do read go help modules and go help go mod what did you expect to see some discussion of what replacements are and what they do what did you see instead the only documentation i can find is these lines in go help go mod replace bad thing good thing replace to replace a module version with a different module version exclude and replace apply only in the main module s go mod and are ignored in dependencies see for details i think there s probably more to say about how replace works for example it doesn t explicitly state that the thing to replace is on the left side of the arrow it also doesn t mention that the version on the left is optional ,1 +337946,24563349809.0,IssuesEvent,2022-10-12 22:56:54,golang/go,https://api.github.com/repos/golang/go,closed,runtime/cgo: incorrectly handle SIGPIPE(and other signals) from non-Go thread,Documentation NeedsFix compiler/runtime," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.19.2 linux/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/secret/.cache/go-build"" +GOENV=""/home/secret/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/secret/go/pkg/mod"" +GOOS=""linux"" +GOPATH=""/home/secret/go"" +GOPROXY=""https://goproxy.cn|https://proxy.golang.org|direct"" +GOROOT=""/data00/home/secret/go1.19"" +GOSUMDB=""sum.golang.google.cn"" +GOTMPDIR="""" +GOTOOLDIR=""/data00/home/secret/go1.19/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.19.2"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build457638227=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.19.2 linux/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/secret/.cache/go-build"" +GOENV=""/home/secret/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/secret/go/pkg/mod"" +GOOS=""linux"" +GOPATH=""/home/secret/go"" +GOPROXY=""https://goproxy.cn|https://proxy.golang.org|direct"" +GOROOT=""/data00/home/secret/go1.19"" +GOSUMDB=""sum.golang.google.cn"" +GOTMPDIR="""" +GOTOOLDIR=""/data00/home/secret/go1.19/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.19.2"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build457638227=/tmp/go-build -gno-record-gcc-switches"" +
+1.17.5 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? +Windows + + +### What did you do? + +Running 'go tool cover -help' issues a help message that includes this command suggestion: + +` +go tool cover -func=c.out +` + +This works on the Mac and Linux, but not on Windows. On Windows it produces the following error message: + +` +too many arguments +For usage information, run ""go tool cover -help"" +` + +The correct way to call this is: + +` +go tool cover -func c.out +` + +This works on all platforms. + +Note that this bad usage pattern is sprinkled throughout the go ecosystem. For example, this web page: https://pkg.go.dev/cmd/cover, has this line: + +` +Cover is a program for analyzing the coverage profiles generated by 'go test -coverprofile=cover.out'. +` + +However, running that line in a windows cmd terminal produces: +` +no required module provides package .out; to add it: go get .out +` + +Or here: https://pkg.go.dev/cmd/go#hdr-Build_constraints, it uses examples of `-buildmode=mode`, even though the documentation earlier specs it as `-buildmode mode`. + +This clearly is a longstanding problem that should be easy to clean up. + + + + + +",1.0,"cmd/go: cover tool help command syntax does not work on Windows - + +### What version of Go are you using (`go version`)? + +
+1.17.5 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? +Windows + + +### What did you do? + +Running 'go tool cover -help' issues a help message that includes this command suggestion: + +` +go tool cover -func=c.out +` + +This works on the Mac and Linux, but not on Windows. On Windows it produces the following error message: + +` +too many arguments +For usage information, run ""go tool cover -help"" +` + +The correct way to call this is: + +` +go tool cover -func c.out +` + +This works on all platforms. + +Note that this bad usage pattern is sprinkled throughout the go ecosystem. For example, this web page: https://pkg.go.dev/cmd/cover, has this line: + +` +Cover is a program for analyzing the coverage profiles generated by 'go test -coverprofile=cover.out'. +` + +However, running that line in a windows cmd terminal produces: +` +no required module provides package .out; to add it: go get .out +` + +Or here: https://pkg.go.dev/cmd/go#hdr-Build_constraints, it uses examples of `-buildmode=mode`, even though the documentation earlier specs it as `-buildmode mode`. + +This clearly is a longstanding problem that should be easy to clean up. + + + + + +",1,cmd go cover tool help command syntax does not work on windows what version of go are you using go version does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env windows what did you do running go tool cover help issues a help message that includes this command suggestion go tool cover func c out this works on the mac and linux but not on windows on windows it produces the following error message too many arguments for usage information run go tool cover help the correct way to call this is go tool cover func c out this works on all platforms note that this bad usage pattern is sprinkled throughout the go ecosystem for example this web page has this line cover is a program for analyzing the coverage profiles generated by go test coverprofile cover out however running that line in a windows cmd terminal produces no required module provides package out to add it go get out or here it uses examples of buildmode mode even though the documentation earlier specs it as buildmode mode this clearly is a longstanding problem that should be easy to clean up ,1 +82063,10268250761.0,IssuesEvent,2019-08-23 05:33:24,golang/go,https://api.github.com/repos/golang/go,closed,unsafe docs and SliceHeader: I am not sure what is defined here,Documentation,"### What version of Go are you using (`go version`)? + +1.12, but N/A + +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +N/A + +### What did you do? + +Read the documentation for `unsafe`. + +### What did you expect to see? + +Something that did not confuse me. + +### What did you see instead? + +Something that confused me. + +> In general, `reflect.SliceHeader and` `reflect.StringHeader` should be used only as `*reflect.SliceHeader` and `*reflect.StringHeader` pointing at actual slices or strings, never as plain structs. A program should not declare or allocate variables of these struct types. + +This has an accompanying example: + +``` +// INVALID: a directly-declared header will not hold Data as a reference. +var hdr reflect.StringHeader +hdr.Data = uintptr(unsafe.Pointer(p)) +hdr.Len = n +s := *(*string)(unsafe.Pointer(&hdr)) // p possibly already lost +``` + +What's not obvious to me: Is the *only* reason this is ""INVALID"" that p might already be lost, such that a `runtime.KeepAlive(p)` after the last line would have saved it? Or is this also intended to cover the possibility that some future version of Go may have additional unspecified magic in a slice object which is not in the `SliceHeader` parts, such that simply creating a SliceHeader (or a StringHeader) doesn't actually make a thing which could be a valid object? + +I've been writing code which has a pointer (which is persistent, and in a data structure which survives past the current scope, thus at no risk of being garbage collected), and which does something to the effect of: + +``` +asUint16 := *(*[]uint16)(unsafe.Pointer(&reflect.SliceHeader{Data: uintptr(unsafe.Pointer(obj.ptr)), Len: int(obj.len), Cap: int(obj.len)})) +``` + +In fact, obj.ptr isn't going away, so I'm not worried about garbage collection. But if an actual Slice were not exactly the same size as a SliceHeader, but rather, the SliceHeader were just a *prefix* of the actual internal slice representation... This code would in fact be just plain wrong, because other code might try to access the ""rest"" of the slice object, and not find it. + +Instead, I'd need to do something like: + +``` +var u []uint16 +h := (*reflect.SliceHeader)&u +h.Data, h.Len, h.Cap = uintptr(obj.ptr), obj.len, obj.len +``` + +Which is, I suppose, certainly no harder to read, but I'm not sure whether it offers any semantic difference, apart from `u` holding the reference to the pointer, in a way that a temporary slice header object wouldn't. + +(Related-ish: #20171, #19367.) +",1.0,"unsafe docs and SliceHeader: I am not sure what is defined here - ### What version of Go are you using (`go version`)? + +1.12, but N/A + +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +N/A + +### What did you do? + +Read the documentation for `unsafe`. + +### What did you expect to see? + +Something that did not confuse me. + +### What did you see instead? + +Something that confused me. + +> In general, `reflect.SliceHeader and` `reflect.StringHeader` should be used only as `*reflect.SliceHeader` and `*reflect.StringHeader` pointing at actual slices or strings, never as plain structs. A program should not declare or allocate variables of these struct types. + +This has an accompanying example: + +``` +// INVALID: a directly-declared header will not hold Data as a reference. +var hdr reflect.StringHeader +hdr.Data = uintptr(unsafe.Pointer(p)) +hdr.Len = n +s := *(*string)(unsafe.Pointer(&hdr)) // p possibly already lost +``` + +What's not obvious to me: Is the *only* reason this is ""INVALID"" that p might already be lost, such that a `runtime.KeepAlive(p)` after the last line would have saved it? Or is this also intended to cover the possibility that some future version of Go may have additional unspecified magic in a slice object which is not in the `SliceHeader` parts, such that simply creating a SliceHeader (or a StringHeader) doesn't actually make a thing which could be a valid object? + +I've been writing code which has a pointer (which is persistent, and in a data structure which survives past the current scope, thus at no risk of being garbage collected), and which does something to the effect of: + +``` +asUint16 := *(*[]uint16)(unsafe.Pointer(&reflect.SliceHeader{Data: uintptr(unsafe.Pointer(obj.ptr)), Len: int(obj.len), Cap: int(obj.len)})) +``` + +In fact, obj.ptr isn't going away, so I'm not worried about garbage collection. But if an actual Slice were not exactly the same size as a SliceHeader, but rather, the SliceHeader were just a *prefix* of the actual internal slice representation... This code would in fact be just plain wrong, because other code might try to access the ""rest"" of the slice object, and not find it. + +Instead, I'd need to do something like: + +``` +var u []uint16 +h := (*reflect.SliceHeader)&u +h.Data, h.Len, h.Cap = uintptr(obj.ptr), obj.len, obj.len +``` + +Which is, I suppose, certainly no harder to read, but I'm not sure whether it offers any semantic difference, apart from `u` holding the reference to the pointer, in a way that a temporary slice header object wouldn't. + +(Related-ish: #20171, #19367.) +",1,unsafe docs and sliceheader i am not sure what is defined here what version of go are you using go version but n a does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env n a what did you do read the documentation for unsafe what did you expect to see something that did not confuse me what did you see instead something that confused me in general reflect sliceheader and reflect stringheader should be used only as reflect sliceheader and reflect stringheader pointing at actual slices or strings never as plain structs a program should not declare or allocate variables of these struct types this has an accompanying example invalid a directly declared header will not hold data as a reference var hdr reflect stringheader hdr data uintptr unsafe pointer p hdr len n s string unsafe pointer hdr p possibly already lost what s not obvious to me is the only reason this is invalid that p might already be lost such that a runtime keepalive p after the last line would have saved it or is this also intended to cover the possibility that some future version of go may have additional unspecified magic in a slice object which is not in the sliceheader parts such that simply creating a sliceheader or a stringheader doesn t actually make a thing which could be a valid object i ve been writing code which has a pointer which is persistent and in a data structure which survives past the current scope thus at no risk of being garbage collected and which does something to the effect of unsafe pointer reflect sliceheader data uintptr unsafe pointer obj ptr len int obj len cap int obj len in fact obj ptr isn t going away so i m not worried about garbage collection but if an actual slice were not exactly the same size as a sliceheader but rather the sliceheader were just a prefix of the actual internal slice representation this code would in fact be just plain wrong because other code might try to access the rest of the slice object and not find it instead i d need to do something like var u h reflect sliceheader u h data h len h cap uintptr obj ptr obj len obj len which is i suppose certainly no harder to read but i m not sure whether it offers any semantic difference apart from u holding the reference to the pointer in a way that a temporary slice header object wouldn t related ish ,1 +32182,6038104812.0,IssuesEvent,2017-06-09 20:29:49,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: typo in test.go doc,Documentation NeedsFix Suggested,"In the doc string in src/cmd/go/test.go, line 65 it says: '...no arguments. It compiles...'. +There are two spaces before the 'It', should be only one.",1.0,"cmd/go: typo in test.go doc - In the doc string in src/cmd/go/test.go, line 65 it says: '...no arguments. It compiles...'. +There are two spaces before the 'It', should be only one.",1,cmd go typo in test go doc in the doc string in src cmd go test go line it says no arguments it compiles there are two spaces before the it should be only one ,1 +175472,14530066888.0,IssuesEvent,2020-12-14 18:42:36,golang/go,https://api.github.com/repos/golang/go,closed,x/pkgsite: document that GitHub PRs are accepted in the CONTRIBUTING.md,Documentation NeedsFix Suggested help wanted pkgsite,"Per https://golang.org/doc/contribute.html#sending_a_change_github, x/pkgsite accepts PRs. + +We should add this to the [CONTRIBUTING.md](https://github.com/golang/pkgsite/blob/master/CONTRIBUTING.md#getting-started), so that new contributors are aware of this option for contributing. + +",1.0,"x/pkgsite: document that GitHub PRs are accepted in the CONTRIBUTING.md - Per https://golang.org/doc/contribute.html#sending_a_change_github, x/pkgsite accepts PRs. + +We should add this to the [CONTRIBUTING.md](https://github.com/golang/pkgsite/blob/master/CONTRIBUTING.md#getting-started), so that new contributors are aware of this option for contributing. + +",1,x pkgsite document that github prs are accepted in the contributing md per x pkgsite accepts prs we should add this to the so that new contributors are aware of this option for contributing ,1 +56614,13893832039.0,IssuesEvent,2020-10-19 13:59:39,golang/go,https://api.github.com/repos/golang/go,opened,cmd/go/internal/renameio: TestConcurrentReadsAndWrites failure on ios-arm64-corellium builder,Builders NeedsInvestigation OS-Darwin mobile,"The `ios-arm64-corellium` builder seems to be affected by the same `darwin` kernel bug reported in #33041. + +Perhaps we should expand the `skip` for that bug to also apply to `ios-arm64-corellium`, although it's not obvious to me how we could apply the skip to only the affected kernel. + +CC @cherrymui @dmitshur + +[2020-10-17T00:26:52-a2eb53c/ios-arm64-corellium](https://build.golang.org/log/a6130e0004d62ba55ad1eced5a39806618b7b0c5) +[2020-10-16T18:54:38-570b49d/ios-arm64-corellium](https://build.golang.org/log/162b21b2e9af2efa400c3bcc8466c4cf67a298d1) +[2020-10-12T17:23:06-1aa43a5/ios-arm64-corellium](https://build.golang.org/log/ed899e6a1307915bb9270cbc83e7e06cb1926328) +[2020-10-06T19:39:32-1fb149f/ios-arm64-corellium](https://build.golang.org/log/74a338f801881c51267dcfec563e2a1c8e0359c4) +",1.0,"cmd/go/internal/renameio: TestConcurrentReadsAndWrites failure on ios-arm64-corellium builder - The `ios-arm64-corellium` builder seems to be affected by the same `darwin` kernel bug reported in #33041. + +Perhaps we should expand the `skip` for that bug to also apply to `ios-arm64-corellium`, although it's not obvious to me how we could apply the skip to only the affected kernel. + +CC @cherrymui @dmitshur + +[2020-10-17T00:26:52-a2eb53c/ios-arm64-corellium](https://build.golang.org/log/a6130e0004d62ba55ad1eced5a39806618b7b0c5) +[2020-10-16T18:54:38-570b49d/ios-arm64-corellium](https://build.golang.org/log/162b21b2e9af2efa400c3bcc8466c4cf67a298d1) +[2020-10-12T17:23:06-1aa43a5/ios-arm64-corellium](https://build.golang.org/log/ed899e6a1307915bb9270cbc83e7e06cb1926328) +[2020-10-06T19:39:32-1fb149f/ios-arm64-corellium](https://build.golang.org/log/74a338f801881c51267dcfec563e2a1c8e0359c4) +",0,cmd go internal renameio testconcurrentreadsandwrites failure on ios corellium builder the ios corellium builder seems to be affected by the same darwin kernel bug reported in perhaps we should expand the skip for that bug to also apply to ios corellium although it s not obvious to me how we could apply the skip to only the affected kernel cc cherrymui dmitshur ,0 +9404,6886910800.0,IssuesEvent,2017-11-21 21:14:29,golang/go,https://api.github.com/repos/golang/go,closed,crypto/aes: linux/arm64 Go 1.9 performance is +20X slower than OpenSSL,Performance,"Please answer these questions before submitting your issue. Thanks! + + +### What version of Go are you using (`go version`)? +go version go1.9.2 linux/arm64 + +### Does this issue reproduce with the latest release? +yes + +### What operating system and processor architecture are you using (`go env`)? +GOARCH=""arm64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""arm64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH="""" +GORACE="""" +GOROOT=""/usr/lib/go-1.6"" +GOTOOLDIR=""/usr/lib/go-1.6/pkg/tool/linux_arm64"" +GO15VENDOREXPERIMENT=""1"" +CC=""gcc"" +GOGCCFLAGS=""-fPIC -pthread -fmessage-length=0"" +CXX=""g++"" +CGO_ENABLED=""1"" + +### What did you do? +go test crypto/cipher -bench GCM + +### What did you expect to see? +Performance can be on par with OpenSSL (https://blog.cloudflare.com/content/images/2017/11/sym_key_1_core.png) + +### What did you see instead? ++20X slower than OpenSSL( https://blog.cloudflare.com/content/images/2017/11/go_sym_key_1_core.png) +",True,"crypto/aes: linux/arm64 Go 1.9 performance is +20X slower than OpenSSL - Please answer these questions before submitting your issue. Thanks! + + +### What version of Go are you using (`go version`)? +go version go1.9.2 linux/arm64 + +### Does this issue reproduce with the latest release? +yes + +### What operating system and processor architecture are you using (`go env`)? +GOARCH=""arm64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""arm64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH="""" +GORACE="""" +GOROOT=""/usr/lib/go-1.6"" +GOTOOLDIR=""/usr/lib/go-1.6/pkg/tool/linux_arm64"" +GO15VENDOREXPERIMENT=""1"" +CC=""gcc"" +GOGCCFLAGS=""-fPIC -pthread -fmessage-length=0"" +CXX=""g++"" +CGO_ENABLED=""1"" + +### What did you do? +go test crypto/cipher -bench GCM + +### What did you expect to see? +Performance can be on par with OpenSSL (https://blog.cloudflare.com/content/images/2017/11/sym_key_1_core.png) + +### What did you see instead? ++20X slower than OpenSSL( https://blog.cloudflare.com/content/images/2017/11/go_sym_key_1_core.png) +",0,crypto aes linux go performance is slower than openssl please answer these questions before submitting your issue thanks what version of go are you using go version go version linux does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env goarch gobin goexe gohostarch gohostos linux goos linux gopath gorace goroot usr lib go gotooldir usr lib go pkg tool linux cc gcc gogccflags fpic pthread fmessage length cxx g cgo enabled what did you do go test crypto cipher bench gcm what did you expect to see performance can be on par with openssl what did you see instead slower than openssl ,0 +414321,27984207650.0,IssuesEvent,2023-03-26 14:08:07,golang/go,https://api.github.com/repos/golang/go,closed,io: Documentation of the io package at website is contrary to its documentation in comments inside source code.,Documentation,"### What version of Go are you using (`go version`)? +go version go1.20.2 windows/amd64 + +### Does this issue reproduce with the latest release? +Yes. + +### What operating system and processor architecture are you using (`go env`)? +O.S. is Microsoft Windows 10. +CPU uses Intel x86-64 (a.k.a. AMD64) architecture. + +### What did you do? +Documentation of the `io` package at website states following. + +> An instance of this general case is that a Reader returning a non-zero number of bytes at the end of the input stream may return either err == EOF or err == nil. The next Read should return 0, EOF. + +Documentation of the same `io` package in comments inside the source code states following. + +> EOF is the error returned by Read when no more input is available. + +### What did you expect to see? +I expect to see no controversy in documentation. + +### What did you see instead? +I saw the controversy in documentation. +",1.0,"io: Documentation of the io package at website is contrary to its documentation in comments inside source code. - ### What version of Go are you using (`go version`)? +go version go1.20.2 windows/amd64 + +### Does this issue reproduce with the latest release? +Yes. + +### What operating system and processor architecture are you using (`go env`)? +O.S. is Microsoft Windows 10. +CPU uses Intel x86-64 (a.k.a. AMD64) architecture. + +### What did you do? +Documentation of the `io` package at website states following. + +> An instance of this general case is that a Reader returning a non-zero number of bytes at the end of the input stream may return either err == EOF or err == nil. The next Read should return 0, EOF. + +Documentation of the same `io` package in comments inside the source code states following. + +> EOF is the error returned by Read when no more input is available. + +### What did you expect to see? +I expect to see no controversy in documentation. + +### What did you see instead? +I saw the controversy in documentation. +",1,io documentation of the io package at website is contrary to its documentation in comments inside source code what version of go are you using go version go version windows does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env o s is microsoft windows cpu uses intel a k a architecture what did you do documentation of the io package at website states following an instance of this general case is that a reader returning a non zero number of bytes at the end of the input stream may return either err eof or err nil the next read should return eof documentation of the same io package in comments inside the source code states following eof is the error returned by read when no more input is available what did you expect to see i expect to see no controversy in documentation what did you see instead i saw the controversy in documentation ,1 +214635,16569051449.0,IssuesEvent,2021-05-30 02:38:18,golang/go,https://api.github.com/repos/golang/go,closed,go/types: unexport the GoVersion configuration option for Go 1.17,Documentation NeedsFix release-blocker,"`+pkg go/types, type Config struct, GoVersion string` + +The `GoVersion` field was added to `types.Config` to configure the language version being type checked. + +CC @griesemer ",1.0,"go/types: unexport the GoVersion configuration option for Go 1.17 - `+pkg go/types, type Config struct, GoVersion string` + +The `GoVersion` field was added to `types.Config` to configure the language version being type checked. + +CC @griesemer ",1,go types unexport the goversion configuration option for go pkg go types type config struct goversion string the goversion field was added to types config to configure the language version being type checked cc griesemer ,1 +43306,7037406856.0,IssuesEvent,2017-12-28 14:40:44,golang/go,https://api.github.com/repos/golang/go,closed,doc: add Go to the list of languages at syntax-across-languages-per-language,Documentation help wanted,"Looks like Go is missing from the list: +http://rigaux.org/language-study/syntax-across-languages-per-language/what-is-missing.html",1.0,"doc: add Go to the list of languages at syntax-across-languages-per-language - Looks like Go is missing from the list: +http://rigaux.org/language-study/syntax-across-languages-per-language/what-is-missing.html",1,doc add go to the list of languages at syntax across languages per language looks like go is missing from the list ,1 +11613,3508959598.0,IssuesEvent,2016-01-08 20:18:42,golang/go,https://api.github.com/repos/golang/go,closed,math/big: Typo in the documentation of Int.DivMod,Documentation,"The documentation for DivMod, in the big library, suggests that z.DivMod(x,y,w) sets z to the quotient q and w to the modulus m, where q and m satisfy +> m = x - y*q with 0 <= m < |q| + +I believe that this should read +> m = x - y*q with 0 <= m < |y| + +so that it agrees with the reference mentioned in the documentation for DivMod: Raymond T. Boute, “The Euclidean definition of the functions div and mod”. ACM Transactions on Programming Languages and Systems (TOPLAS), 14(2):127-144, New York, NY, USA, 4/1992. ACM press. ",1.0,"math/big: Typo in the documentation of Int.DivMod - The documentation for DivMod, in the big library, suggests that z.DivMod(x,y,w) sets z to the quotient q and w to the modulus m, where q and m satisfy +> m = x - y*q with 0 <= m < |q| + +I believe that this should read +> m = x - y*q with 0 <= m < |y| + +so that it agrees with the reference mentioned in the documentation for DivMod: Raymond T. Boute, “The Euclidean definition of the functions div and mod”. ACM Transactions on Programming Languages and Systems (TOPLAS), 14(2):127-144, New York, NY, USA, 4/1992. ACM press. ",1,math big typo in the documentation of int divmod the documentation for divmod in the big library suggests that z divmod x y w sets z to the quotient q and w to the modulus m where q and m satisfy m x y q with m q i believe that this should read m x y q with m y so that it agrees with the reference mentioned in the documentation for divmod raymond t boute “the euclidean definition of the functions div and mod” acm transactions on programming languages and systems toplas new york ny usa acm press ,1 +40053,6796333191.0,IssuesEvent,2017-11-01 18:38:49,golang/go,https://api.github.com/repos/golang/go,closed,os/signal: document how to forward all signals,Documentation HelpWanted,"I'm writing a command line wrapper that sets some state in the world, starts a child process, waits for it to complete, and then unsets some state in the world. + +So basically something like + +```go +doSomeStatefulThing() +cmd := exec.Command(""subcmd"", args...) +cmd.Stdin = os.Stdin +cmd.Stdout = os.Stdout +cmd.Stderr = os.Stderr +err := cmd.Run() +undoSomeStatefulThing() +return err +``` + +I missed the line in the `signal.Notify` docs that says + +> If no signals are provided, all incoming signals will be relayed to c. Otherwise, just the provided signals will. + +It might be good to provide a second Example for Notify where the args... list is empty, for people who are silly like me and miss the doc. + +(It might also be good if it was easier to set up a proxied command - it seems like it's easy to miss some of the steps involved in proxying through all FD's/signals in both directions.)",1.0,"os/signal: document how to forward all signals - I'm writing a command line wrapper that sets some state in the world, starts a child process, waits for it to complete, and then unsets some state in the world. + +So basically something like + +```go +doSomeStatefulThing() +cmd := exec.Command(""subcmd"", args...) +cmd.Stdin = os.Stdin +cmd.Stdout = os.Stdout +cmd.Stderr = os.Stderr +err := cmd.Run() +undoSomeStatefulThing() +return err +``` + +I missed the line in the `signal.Notify` docs that says + +> If no signals are provided, all incoming signals will be relayed to c. Otherwise, just the provided signals will. + +It might be good to provide a second Example for Notify where the args... list is empty, for people who are silly like me and miss the doc. + +(It might also be good if it was easier to set up a proxied command - it seems like it's easy to miss some of the steps involved in proxying through all FD's/signals in both directions.)",1,os signal document how to forward all signals i m writing a command line wrapper that sets some state in the world starts a child process waits for it to complete and then unsets some state in the world so basically something like go dosomestatefulthing cmd exec command subcmd args cmd stdin os stdin cmd stdout os stdout cmd stderr os stderr err cmd run undosomestatefulthing return err i missed the line in the signal notify docs that says if no signals are provided all incoming signals will be relayed to c otherwise just the provided signals will it might be good to provide a second example for notify where the args list is empty for people who are silly like me and miss the doc it might also be good if it was easier to set up a proxied command it seems like it s easy to miss some of the steps involved in proxying through all fd s signals in both directions ,1 +37348,9994595442.0,IssuesEvent,2019-07-11 18:04:31,golang/go,https://api.github.com/repos/golang/go,closed,x/playground: Deploy Playground Automatically,Builders NeedsFix,"We want to reduce toil and ensure that we’re running the latest Playground version for play.golang.org. The current process involves manual steps, which can be error-prone, forgotten, or interruptive. After this work, changes to Playground or a new Go release should be available on play.golang.org shortly after they’re made. + +In either scenario below, we need to ensure that we're always deploying playground built on the latest stable release of Go. It's possible to get this information from maintner. + +We have a number of other services that could benefit from CI/CD, but we should focus on solving this issue for playground for the moment, and see what we learn. + +### Deploying the latest Playground: + +It’s possible to configure this flow entirely within Cloud Console and a `cloudbuild.yaml` file. + +- Grant App Engine access to Cloud Build +- Create a cloudbuild.yaml file in the playground repo + - Add step for gcloud app deploy + - Configure build timeout to avoid currently documented issue +- Create a Cloud Build trigger, and link to github.com/golang/playground + - The user authorizing this trigger needs to be in the golang github org, and an admin of the playground repo on github. +- Convert GO_VERSION in the playground Dockerfile to an ARG with a default value + +Our docker build step must populate the latest GO_VERSION when it builds. + +There are other options available for pushing directly from gerrit, but would involve additional manual configuration, as well as figuring out where to store it and document it. + +### Deploying Playground with the latest Go release + +This update flow requires determining the latest stable Go release after it happens, then building deploying Playground with the new release. This workflow more involved, as Cloud Build doesn't provide a way to add the business logic that we want out of the box: mainly that we want to trigger based on the latest stable tagged release of a different repository, and not accidentally downgrade (say, if 1.11.x is tagged after 1.12.x) + +If either of these workflows feels too difficult to configure, or feels fragile, we should try a gerrit based flow instead. + +`cloudbuild.yaml` reference: https://cloud.google.com/cloud-build/docs/build-config +App Engine automation quickstart: https://cloud.google.com/source-repositories/docs/quickstart-triggering-builds-with-source-repositories +Cloud Build API for manual (or programmatic) triggers: https://cloud.google.com/cloud-build/docs/running-builds/start-build-manually",1.0,"x/playground: Deploy Playground Automatically - We want to reduce toil and ensure that we’re running the latest Playground version for play.golang.org. The current process involves manual steps, which can be error-prone, forgotten, or interruptive. After this work, changes to Playground or a new Go release should be available on play.golang.org shortly after they’re made. + +In either scenario below, we need to ensure that we're always deploying playground built on the latest stable release of Go. It's possible to get this information from maintner. + +We have a number of other services that could benefit from CI/CD, but we should focus on solving this issue for playground for the moment, and see what we learn. + +### Deploying the latest Playground: + +It’s possible to configure this flow entirely within Cloud Console and a `cloudbuild.yaml` file. + +- Grant App Engine access to Cloud Build +- Create a cloudbuild.yaml file in the playground repo + - Add step for gcloud app deploy + - Configure build timeout to avoid currently documented issue +- Create a Cloud Build trigger, and link to github.com/golang/playground + - The user authorizing this trigger needs to be in the golang github org, and an admin of the playground repo on github. +- Convert GO_VERSION in the playground Dockerfile to an ARG with a default value + +Our docker build step must populate the latest GO_VERSION when it builds. + +There are other options available for pushing directly from gerrit, but would involve additional manual configuration, as well as figuring out where to store it and document it. + +### Deploying Playground with the latest Go release + +This update flow requires determining the latest stable Go release after it happens, then building deploying Playground with the new release. This workflow more involved, as Cloud Build doesn't provide a way to add the business logic that we want out of the box: mainly that we want to trigger based on the latest stable tagged release of a different repository, and not accidentally downgrade (say, if 1.11.x is tagged after 1.12.x) + +If either of these workflows feels too difficult to configure, or feels fragile, we should try a gerrit based flow instead. + +`cloudbuild.yaml` reference: https://cloud.google.com/cloud-build/docs/build-config +App Engine automation quickstart: https://cloud.google.com/source-repositories/docs/quickstart-triggering-builds-with-source-repositories +Cloud Build API for manual (or programmatic) triggers: https://cloud.google.com/cloud-build/docs/running-builds/start-build-manually",0,x playground deploy playground automatically we want to reduce toil and ensure that we’re running the latest playground version for play golang org the current process involves manual steps which can be error prone forgotten or interruptive after this work changes to playground or a new go release should be available on play golang org shortly after they’re made in either scenario below we need to ensure that we re always deploying playground built on the latest stable release of go it s possible to get this information from maintner we have a number of other services that could benefit from ci cd but we should focus on solving this issue for playground for the moment and see what we learn deploying the latest playground it’s possible to configure this flow entirely within cloud console and a cloudbuild yaml file grant app engine access to cloud build create a cloudbuild yaml file in the playground repo add step for gcloud app deploy configure build timeout to avoid currently documented issue create a cloud build trigger and link to github com golang playground the user authorizing this trigger needs to be in the golang github org and an admin of the playground repo on github convert go version in the playground dockerfile to an arg with a default value our docker build step must populate the latest go version when it builds there are other options available for pushing directly from gerrit but would involve additional manual configuration as well as figuring out where to store it and document it deploying playground with the latest go release this update flow requires determining the latest stable go release after it happens then building deploying playground with the new release this workflow more involved as cloud build doesn t provide a way to add the business logic that we want out of the box mainly that we want to trigger based on the latest stable tagged release of a different repository and not accidentally downgrade say if x is tagged after x if either of these workflows feels too difficult to configure or feels fragile we should try a gerrit based flow instead cloudbuild yaml reference app engine automation quickstart cloud build api for manual or programmatic triggers ,0 +2867,3675582915.0,IssuesEvent,2016-02-23 00:15:59,golang/go,https://api.github.com/repos/golang/go,closed,runtime: improve performance of == on arrays.,Performance,"What version of Go are you using (go version)? go1.5.3 +What operating system and processor architecture are you using? Linux, amd64 +What did you do? benchmarked `==` vs `bytes.Equal` for array types +What did you expect to see? `==` be as fast as or faster than `bytes.Equal` +What did you see instead? `==` is slower than `bytes.Equal` + +Given: + +``` +type A [16]byte +var a1, a2 A +``` +`a1== a2` is slower than `bytes.Equal(a1[:], a2[:])` with the regular gc compiler. + +On my machine, the two benchmarks: +``` +type A [16]byte +func BenchmarkEqual(b *testing.B) { + a1 := A{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16} + a2 := A{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16} + b.ResetTimer() + for i := 0; i < b.N; i++ { + if a1 != a2 { + b.Fatal(""not equal"") + } + } +} + +func BenchmarkBytesEqual(b *testing.B) { + a1 := A{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16} + a2 := A{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16} + b.ResetTimer() + for i := 0; i < b.N; i++ { + if !bytes.Equal(a1[:], a2[:]) { + b.Fatal(""not equal"") + } + } +} +``` +result in times of: +``` +BenchmarkEqual-12 200000000 6.02 ns/op +BenchmarkBytesEqual-12 300000000 4.90 ns/op +``` +It seems the same optimizations that have been applied to bytes.Equal could be applied to the code generated by the compiler (or the compiler could simply call the equivalent of the bytes.Equal function). + +I also ran the test with 8, 128, and 1024 byte arrays (as well as 16 bytes). The source code is +[a_test.go.txt](https://github.com/golang/go/files/127410/a_test.go.txt). + +The results: + +``` +BenchmarkEqual8-12 200000000 5.78 ns/op +BenchmarkBytesEqual8-12 300000000 4.89 ns/op +BenchmarkEqual16-12 200000000 6.77 ns/op +BenchmarkBytesEqual16-12 300000000 5.93 ns/op +BenchmarkEqual128-12 200000000 8.48 ns/op +BenchmarkBytesEqual128-12 200000000 7.57 ns/op +BenchmarkEqual1024-12 50000000 30.1 ns/op +BenchmarkBytesEqual1024-12 50000000 30.4 ns/op + +``` + +As a side note, with gccgo the results are the opposite, `==` is faster than `bytes.Equal`. `bytes.Equal` with gccgo is also slower than `bytes.Equal` with the regular gc compiler.",True,"runtime: improve performance of == on arrays. - What version of Go are you using (go version)? go1.5.3 +What operating system and processor architecture are you using? Linux, amd64 +What did you do? benchmarked `==` vs `bytes.Equal` for array types +What did you expect to see? `==` be as fast as or faster than `bytes.Equal` +What did you see instead? `==` is slower than `bytes.Equal` + +Given: + +``` +type A [16]byte +var a1, a2 A +``` +`a1== a2` is slower than `bytes.Equal(a1[:], a2[:])` with the regular gc compiler. + +On my machine, the two benchmarks: +``` +type A [16]byte +func BenchmarkEqual(b *testing.B) { + a1 := A{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16} + a2 := A{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16} + b.ResetTimer() + for i := 0; i < b.N; i++ { + if a1 != a2 { + b.Fatal(""not equal"") + } + } +} + +func BenchmarkBytesEqual(b *testing.B) { + a1 := A{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16} + a2 := A{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16} + b.ResetTimer() + for i := 0; i < b.N; i++ { + if !bytes.Equal(a1[:], a2[:]) { + b.Fatal(""not equal"") + } + } +} +``` +result in times of: +``` +BenchmarkEqual-12 200000000 6.02 ns/op +BenchmarkBytesEqual-12 300000000 4.90 ns/op +``` +It seems the same optimizations that have been applied to bytes.Equal could be applied to the code generated by the compiler (or the compiler could simply call the equivalent of the bytes.Equal function). + +I also ran the test with 8, 128, and 1024 byte arrays (as well as 16 bytes). The source code is +[a_test.go.txt](https://github.com/golang/go/files/127410/a_test.go.txt). + +The results: + +``` +BenchmarkEqual8-12 200000000 5.78 ns/op +BenchmarkBytesEqual8-12 300000000 4.89 ns/op +BenchmarkEqual16-12 200000000 6.77 ns/op +BenchmarkBytesEqual16-12 300000000 5.93 ns/op +BenchmarkEqual128-12 200000000 8.48 ns/op +BenchmarkBytesEqual128-12 200000000 7.57 ns/op +BenchmarkEqual1024-12 50000000 30.1 ns/op +BenchmarkBytesEqual1024-12 50000000 30.4 ns/op + +``` + +As a side note, with gccgo the results are the opposite, `==` is faster than `bytes.Equal`. `bytes.Equal` with gccgo is also slower than `bytes.Equal` with the regular gc compiler.",0,runtime improve performance of on arrays what version of go are you using go version what operating system and processor architecture are you using linux what did you do benchmarked vs bytes equal for array types what did you expect to see be as fast as or faster than bytes equal what did you see instead is slower than bytes equal given type a byte var a is slower than bytes equal with the regular gc compiler on my machine the two benchmarks type a byte func benchmarkequal b testing b a a b resettimer for i i b n i if b fatal not equal func benchmarkbytesequal b testing b a a b resettimer for i i b n i if bytes equal b fatal not equal result in times of benchmarkequal ns op benchmarkbytesequal ns op it seems the same optimizations that have been applied to bytes equal could be applied to the code generated by the compiler or the compiler could simply call the equivalent of the bytes equal function i also ran the test with and byte arrays as well as bytes the source code is the results ns op ns op ns op ns op ns op ns op ns op ns op as a side note with gccgo the results are the opposite is faster than bytes equal bytes equal with gccgo is also slower than bytes equal with the regular gc compiler ,0 +436747,30567890355.0,IssuesEvent,2023-07-20 19:19:13,golang/go,https://api.github.com/repos/golang/go,reopened,doc: write release notes for Go 1.21,Documentation NeedsFix release-blocker umbrella,"This is the tracking issue for writing the Go 1.21 Release Notes. The version at tip can be viewed at https://tip.golang.org/doc/go1.21. + +When the Go 1.21 Release Notes are complete, this should be closed, and a similar issue should be made for the next release. Previous issues are https://github.com/golang/go/issues/54202, https://github.com/golang/go/issues/51400, https://github.com/golang/go/issues/47694, https://github.com/golang/go/issues/44513, etc. + +",1.0,"doc: write release notes for Go 1.21 - This is the tracking issue for writing the Go 1.21 Release Notes. The version at tip can be viewed at https://tip.golang.org/doc/go1.21. + +When the Go 1.21 Release Notes are complete, this should be closed, and a similar issue should be made for the next release. Previous issues are https://github.com/golang/go/issues/54202, https://github.com/golang/go/issues/51400, https://github.com/golang/go/issues/47694, https://github.com/golang/go/issues/44513, etc. + +",1,doc write release notes for go this is the tracking issue for writing the go release notes the version at tip can be viewed at when the go release notes are complete this should be closed and a similar issue should be made for the next release previous issues are etc ,1 +280093,24279971617.0,IssuesEvent,2022-09-28 16:31:36,golang/go,https://api.github.com/repos/golang/go,closed,os/signal: TestTerminalSignal is flaky due to GNU readline,Testing NeedsFix compiler/runtime,"### What version of Go are you using (`go version`)? + +
+$ go version +go version devel go1.20-9aa7107cb5 Wed Sep 28 03:17:13 2022 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/zeke/.cache/go-build"" +GOENV=""/home/zeke/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/zeke/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/zeke/go"" +GOPRIVATE="""" +GOPROXY=""https://goproxy.cn,direct"" +GOROOT=""/snap/go/9951"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/snap/go/9951/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.19"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/zeke/src/golang/gotip/src/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build1116265555=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version devel go1.20-9aa7107cb5 Wed Sep 28 03:17:13 2022 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/zeke/.cache/go-build"" +GOENV=""/home/zeke/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/zeke/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/zeke/go"" +GOPRIVATE="""" +GOPROXY=""https://goproxy.cn,direct"" +GOROOT=""/snap/go/9951"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/snap/go/9951/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.19"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/zeke/src/golang/gotip/src/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build1116265555=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.12.1 linux/amd64 +$ go list -m golang.org/x/tools +golang.org/x/tools v0.0.0-20190328211700-ab21143f2384 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN=""/home/myitcv/gostuff/src/github.com/myitcv/govim/.bin"" +GOCACHE=""/home/myitcv/.cache/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/myitcv/gostuff"" +GOPROXY="""" +GORACE="""" +GOROOT=""/home/myitcv/gos"" +GOTMPDIR="""" +GOTOOLDIR=""/home/myitcv/gos/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/myitcv/gostuff/src/github.com/myitcv/govim/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build120717318=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.12.1 linux/amd64 +$ go list -m golang.org/x/tools +golang.org/x/tools v0.0.0-20190328211700-ab21143f2384 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN=""/home/myitcv/gostuff/src/github.com/myitcv/govim/.bin"" +GOCACHE=""/home/myitcv/.cache/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/myitcv/gostuff"" +GOPROXY="""" +GORACE="""" +GOROOT=""/home/myitcv/gos"" +GOTMPDIR="""" +GOTOOLDIR=""/home/myitcv/gos/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/myitcv/gostuff/src/github.com/myitcv/govim/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build120717318=/tmp/go-build -gno-record-gcc-switches"" +
+ TODO: https://golang.org/cl/272668: add IP.IsPrivate +
++ TODO: https://golang.org/cl/301709: make go resolver aware of network parameter +
++ TODO: https://golang.org/cl/307030: make ErrClosed and ParseError implement net.Error +
++ TODO: https://golang.org/cl/272668: add IP.IsPrivate +
++ TODO: https://golang.org/cl/301709: make go resolver aware of network parameter +
++ TODO: https://golang.org/cl/307030: make ErrClosed and ParseError implement net.Error +
++$ go version +go version go1.12.1 linux/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN=""/home/gheibi/.go/bin/"" +GOCACHE=""/home/gheibi/.cache/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/gheibi/.go/"" +GOPROXY="""" +GORACE="""" +GOROOT=""/local/go1.12.1.linux_amd64/go"" +GOTMPDIR="""" +GOTOOLDIR=""/local/go1.12.1.linux_amd64/go /pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build865790926=/tmp/go-build"" + +
+$ go version +go version go1.12.1 linux/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN=""/home/gheibi/.go/bin/"" +GOCACHE=""/home/gheibi/.cache/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/gheibi/.go/"" +GOPROXY="""" +GORACE="""" +GOROOT=""/local/go1.12.1.linux_amd64/go"" +GOTMPDIR="""" +GOTOOLDIR=""/local/go1.12.1.linux_amd64/go /pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build865790926=/tmp/go-build"" + +
The code generated by 6g for multiplication with a constant (t*10) appears to run slower +then a "manual" multiplication (t<<3+t+t). Specifically, for math/big, +revision 78944b6b971c, changing line nat.go:869 from: + +s[i] = charset[r-t*10] + +to: + +s[i] = charset[r-t<<3-t-t] + +leads to a significant (> 10%) performance improvement for some code: + +gotest -bench=String1000*Base10 + +benchmark old ns/op new ns/op delta +big.BenchmarkString100Base10 1909 1855 -2.83% +big.BenchmarkString1000Base10 12867 12243 -4.85% +big.BenchmarkString10000Base10 65974 58307 -11.62% +big.BenchmarkString100000Base10 19938530 19831100 -0.54% + +The compiler should be able to do the right thing here w/o manual intervention.",True,"cmd/compile: t*10 seems slower than t<<3+t+t -
The code generated by 6g for multiplication with a constant (t*10) appears to run slower +then a "manual" multiplication (t<<3+t+t). Specifically, for math/big, +revision 78944b6b971c, changing line nat.go:869 from: + +s[i] = charset[r-t*10] + +to: + +s[i] = charset[r-t<<3-t-t] + +leads to a significant (> 10%) performance improvement for some code: + +gotest -bench=String1000*Base10 + +benchmark old ns/op new ns/op delta +big.BenchmarkString100Base10 1909 1855 -2.83% +big.BenchmarkString1000Base10 12867 12243 -4.85% +big.BenchmarkString10000Base10 65974 58307 -11.62% +big.BenchmarkString100000Base10 19938530 19831100 -0.54% + +The compiler should be able to do the right thing here w/o manual intervention.",0,cmd compile t seems slower than t the code generated by for multiplication with a constant t appears to run slower then a quot manual quot multiplication t lt lt t t specifically for math big revision changing line nat go from s charset to s charset leads to a significant gt performance improvement for some code gotest bench benchmark old ns op new ns op delta big big big big the compiler should be able to do the right thing here w o manual intervention ,0 +174087,14446294178.0,IssuesEvent,2020-12-08 00:55:14,golang/go,https://api.github.com/repos/golang/go,closed,"You can only export basic function signatures. @ianlancetaylor, are the rules documented somewhere?",Documentation,"You can only export basic function signatures. @ianlancetaylor, are the rules documented somewhere? + +_Originally posted by @bradfitz in https://github.com/golang/go/issues/18412#issuecomment-268796091_ + +FUCK THAT SHIT, GOOGLE CODERS ARE MONKEYS",1.0,"You can only export basic function signatures. @ianlancetaylor, are the rules documented somewhere? - You can only export basic function signatures. @ianlancetaylor, are the rules documented somewhere? + +_Originally posted by @bradfitz in https://github.com/golang/go/issues/18412#issuecomment-268796091_ + +FUCK THAT SHIT, GOOGLE CODERS ARE MONKEYS",1,you can only export basic function signatures ianlancetaylor are the rules documented somewhere you can only export basic function signatures ianlancetaylor are the rules documented somewhere originally posted by bradfitz in fuck that shit google coders are monkeys,1 +215794,16617611379.0,IssuesEvent,2021-06-02 18:53:37,golang/go,https://api.github.com/repos/golang/go,closed,io/fs: documentation of func Sub,Documentation NeedsInvestigation," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.16 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/harald/.cache/go-build"" +GOENV=""/home/harald/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/harald/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/harald/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/opt/golang/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/opt/golang/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.16"" +GCCGO=""/usr/bin/gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build2438140086=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.16 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/harald/.cache/go-build"" +GOENV=""/home/harald/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/harald/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/harald/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/opt/golang/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/opt/golang/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.16"" +GCCGO=""/usr/bin/gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build2438140086=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.13.5 windows/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +set GO111MODULE= +set GOARCH=amd64 +set GOBIN= +set GOCACHE=C:\Users\username\AppData\Local\go-build +set GOENV=C:\Users\username\AppData\Roaming\go\env +set GOEXE=.exe +set GOFLAGS= +set GOHOSTARCH=amd64 +set GOHOSTOS=windows +set GONOPROXY= +set GONOSUMDB= +set GOOS=windows +set GOPATH=C:\Users\username\dev +set GOPRIVATE= +set GOPROXY=https://proxy.golang.org,direct +set GOROOT=C:\Program Files\Go +set GOSUMDB=sum.golang.org +set GOTMPDIR= +set GOTOOLDIR=C:\Program Files\Go\pkg\tool\windows_amd64 +set GCCGO=gccgo +set AR=ar +set CC=gcc +set CXX=g++ +set CGO_ENABLED=0 +set GOMOD=C:\Users\username\Dev\src\path\to\repo\go.mod +set CGO_CFLAGS=-g -O2 +set CGO_CPPFLAGS= +set CGO_CXXFLAGS=-g -O2 +set CGO_FFLAGS=-g -O2 +set CGO_LDFLAGS=-g -O2 +set PKG_CONFIG=pkg-config +set GOGCCFLAGS=-m64 -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=C:\Users\username\AppData\Local\Temp\go-build955724962=/tmp/go-build -gno-record-gcc-switches +
+$ go version +go version go1.13.5 windows/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +set GO111MODULE= +set GOARCH=amd64 +set GOBIN= +set GOCACHE=C:\Users\username\AppData\Local\go-build +set GOENV=C:\Users\username\AppData\Roaming\go\env +set GOEXE=.exe +set GOFLAGS= +set GOHOSTARCH=amd64 +set GOHOSTOS=windows +set GONOPROXY= +set GONOSUMDB= +set GOOS=windows +set GOPATH=C:\Users\username\dev +set GOPRIVATE= +set GOPROXY=https://proxy.golang.org,direct +set GOROOT=C:\Program Files\Go +set GOSUMDB=sum.golang.org +set GOTMPDIR= +set GOTOOLDIR=C:\Program Files\Go\pkg\tool\windows_amd64 +set GCCGO=gccgo +set AR=ar +set CC=gcc +set CXX=g++ +set CGO_ENABLED=0 +set GOMOD=C:\Users\username\Dev\src\path\to\repo\go.mod +set CGO_CFLAGS=-g -O2 +set CGO_CPPFLAGS= +set CGO_CXXFLAGS=-g -O2 +set CGO_FFLAGS=-g -O2 +set CGO_LDFLAGS=-g -O2 +set PKG_CONFIG=pkg-config +set GOGCCFLAGS=-m64 -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=C:\Users\username\AppData\Local\Temp\go-build955724962=/tmp/go-build -gno-record-gcc-switches +
+$ go version +go version go1.14 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/fraenky8/Library/Caches/go-build"" +GOENV=""/Users/fraenky8/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOOS=""darwin"" +GOPATH=""/Users/fraenky8/Coding/Go"" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/Cellar/go/1.14/libexec"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.14/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/8v/jgh2dzcn62n0lfyws13mc_rw0000gp/T/go-build103321297=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
+$ go version +go version go1.14 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/fraenky8/Library/Caches/go-build"" +GOENV=""/Users/fraenky8/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOOS=""darwin"" +GOPATH=""/Users/fraenky8/Coding/Go"" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/Cellar/go/1.14/libexec"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.14/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/8v/jgh2dzcn62n0lfyws13mc_rw0000gp/T/go-build103321297=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
+$ gotip version +go version devel +48be3ed Sat Oct 31 00:35:33 2020 +0000 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What did you do? + +Tried out the new embed.FS feature. + +example.go: + +``` +package main + +import ( + ""embed"" + ""fmt"" + ""io/fs"" +) + +func main() { + //go:embed example/* + var files embed.FS + des, _ := fs.ReadDir(files, ""example"") + for _, de := range des { + fmt.Printf(""%q\n"", de.Name()) + } +} +``` + +example: + +``` +total 1504 +drwxr-xr-x@ 6 adhoc staff 192 Oct 30 21:49 . +drwx------ 8 adhoc staff 256 Nov 1 13:34 .. +-rw-r--r--@ 1 adhoc staff 6148 Oct 30 21:49 .DS_Store +-rw-r--r-- 1 adhoc staff 0 Oct 30 21:47 .dot +-rw-r--r--@ 1 adhoc staff 0 Oct 30 21:48 Icon +-rw-r--r-- 1 adhoc staff 0 Oct 30 21:47 one.txt +``` + +### What did you expect to see? + +``` +$ gotip run . +""one.txt"" +``` + +### What did you see instead? + +``` +$ gotip run . +"".DS_Store"" +"".dot"" +""Icon\r"" +""one.txt"" +``` + +- - - - + +There should be a warning in the documentation that dotfiles and hidden files are included.",1.0,"embed: warn about dotfiles in embed.FS documentation - ### What version of Go are you using (`go version`)? + +Tip. + +
+$ gotip version +go version devel +48be3ed Sat Oct 31 00:35:33 2020 +0000 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What did you do? + +Tried out the new embed.FS feature. + +example.go: + +``` +package main + +import ( + ""embed"" + ""fmt"" + ""io/fs"" +) + +func main() { + //go:embed example/* + var files embed.FS + des, _ := fs.ReadDir(files, ""example"") + for _, de := range des { + fmt.Printf(""%q\n"", de.Name()) + } +} +``` + +example: + +``` +total 1504 +drwxr-xr-x@ 6 adhoc staff 192 Oct 30 21:49 . +drwx------ 8 adhoc staff 256 Nov 1 13:34 .. +-rw-r--r--@ 1 adhoc staff 6148 Oct 30 21:49 .DS_Store +-rw-r--r-- 1 adhoc staff 0 Oct 30 21:47 .dot +-rw-r--r--@ 1 adhoc staff 0 Oct 30 21:48 Icon +-rw-r--r-- 1 adhoc staff 0 Oct 30 21:47 one.txt +``` + +### What did you expect to see? + +``` +$ gotip run . +""one.txt"" +``` + +### What did you see instead? + +``` +$ gotip run . +"".DS_Store"" +"".dot"" +""Icon\r"" +""one.txt"" +``` + +- - - - + +There should be a warning in the documentation that dotfiles and hidden files are included.",1,embed warn about dotfiles in embed fs documentation what version of go are you using go version tip gotip version go version devel sat oct darwin does this issue reproduce with the latest release yes what did you do tried out the new embed fs feature example go package main import embed fmt io fs func main go embed example var files embed fs des fs readdir files example for de range des fmt printf q n de name example total drwxr xr x adhoc staff oct drwx adhoc staff nov rw r r adhoc staff oct ds store rw r r adhoc staff oct dot rw r r adhoc staff oct icon rw r r adhoc staff oct one txt what did you expect to see gotip run one txt what did you see instead gotip run ds store dot icon r one txt there should be a warning in the documentation that dotfiles and hidden files are included ,1 +8278,2974683394.0,IssuesEvent,2015-07-15 03:12:26,golang/go,https://api.github.com/repos/golang/go,closed,net: windows TestDialTimeout flake,OS-Windows Testing,"Noticed this flake: +http://build.golang.org/log/de2ea0b431bc216003fd8762e62bbd46b3511fca + +``` +... +ok math/rand 5.305s +ok mime 1.365s +ok mime/multipart 2.470s +ok mime/quotedprintable 3.075s +--- FAIL: TestDialTimeout (0.00s) + timeout_test.go:82: #3: dial tcp 127.0.0.1:0: connectex: The requested address is not valid in its context. +FAIL +FAIL net 21.902s +ok net/http 10.666s +ok net/http/cgi 6.718s +ok net/http/cookiejar 1.583s +... +``` + +/cc @alexbrainman @mikioh ",1.0,"net: windows TestDialTimeout flake - Noticed this flake: +http://build.golang.org/log/de2ea0b431bc216003fd8762e62bbd46b3511fca + +``` +... +ok math/rand 5.305s +ok mime 1.365s +ok mime/multipart 2.470s +ok mime/quotedprintable 3.075s +--- FAIL: TestDialTimeout (0.00s) + timeout_test.go:82: #3: dial tcp 127.0.0.1:0: connectex: The requested address is not valid in its context. +FAIL +FAIL net 21.902s +ok net/http 10.666s +ok net/http/cgi 6.718s +ok net/http/cookiejar 1.583s +... +``` + +/cc @alexbrainman @mikioh ",0,net windows testdialtimeout flake noticed this flake ok math rand ok mime ok mime multipart ok mime quotedprintable fail testdialtimeout timeout test go dial tcp connectex the requested address is not valid in its context fail fail net ok net http ok net http cgi ok net http cookiejar cc alexbrainman mikioh ,0 +39181,10311932208.0,IssuesEvent,2019-08-29 18:35:07,golang/go,https://api.github.com/repos/golang/go,closed,x/perf/analysis/appengine: failing in release-branch.go1.12 builders,Builders NeedsInvestigation Testing,"As of [CL 191378](https://golang.org/cl/191378), the `x/perf` build now requires module mode in order to build the binaries in `analysis/appengine`. + +The problem seems to be the dependency on `google.golang.org/appengine`, which used to be notched out by the `+build appengine` constraint but no longer is. + +That works fine on builders in module mode, because they can fetch the module — but it causes the builds to fail in GOPATH-mode builders. + +CC @andybons @katiehockman @toothrot @dmitshur ",1.0,"x/perf/analysis/appengine: failing in release-branch.go1.12 builders - As of [CL 191378](https://golang.org/cl/191378), the `x/perf` build now requires module mode in order to build the binaries in `analysis/appengine`. + +The problem seems to be the dependency on `google.golang.org/appengine`, which used to be notched out by the `+build appengine` constraint but no longer is. + +That works fine on builders in module mode, because they can fetch the module — but it causes the builds to fail in GOPATH-mode builders. + +CC @andybons @katiehockman @toothrot @dmitshur ",0,x perf analysis appengine failing in release branch builders as of the x perf build now requires module mode in order to build the binaries in analysis appengine the problem seems to be the dependency on google golang org appengine which used to be notched out by the build appengine constraint but no longer is that works fine on builders in module mode because they can fetch the module — but it causes the builds to fail in gopath mode builders cc andybons katiehockman toothrot dmitshur ,0 +7524,6061309710.0,IssuesEvent,2017-06-14 06:05:35,golang/go,https://api.github.com/repos/golang/go,closed,go/token: use fine-grained locking in token.File,Performance,"Because access to the lines and info fields of token.File are protected by the mutex of the parent FileSet, all concurrent calls to AddLine in a typical application contend for the same lock, which becomes a major bottleneck when parsing files in parallel, as done by golang.org/x/tools/go/loader for example. + +Fine-grained locking, that is, an additional mutex in each token.File that protects these two fields, eliminates the bottleneck. I quickly prototyped and measured it on a realistic application, and execution time fell to 580ms from 700m, an improvement of nearly 20%. + +The necessary change is straightforward except for two places: +(1) In its loop, (*FileSet).Write needs to make a copy of each File's lines and infos while holding the file's mutex. +(2) (*File).PositionFor seems to have a pre-existing data race, since it calls File.position without a lock, which calls unpack, which reads the lines and info fields.",True,"go/token: use fine-grained locking in token.File - Because access to the lines and info fields of token.File are protected by the mutex of the parent FileSet, all concurrent calls to AddLine in a typical application contend for the same lock, which becomes a major bottleneck when parsing files in parallel, as done by golang.org/x/tools/go/loader for example. + +Fine-grained locking, that is, an additional mutex in each token.File that protects these two fields, eliminates the bottleneck. I quickly prototyped and measured it on a realistic application, and execution time fell to 580ms from 700m, an improvement of nearly 20%. + +The necessary change is straightforward except for two places: +(1) In its loop, (*FileSet).Write needs to make a copy of each File's lines and infos while holding the file's mutex. +(2) (*File).PositionFor seems to have a pre-existing data race, since it calls File.position without a lock, which calls unpack, which reads the lines and info fields.",0,go token use fine grained locking in token file because access to the lines and info fields of token file are protected by the mutex of the parent fileset all concurrent calls to addline in a typical application contend for the same lock which becomes a major bottleneck when parsing files in parallel as done by golang org x tools go loader for example fine grained locking that is an additional mutex in each token file that protects these two fields eliminates the bottleneck i quickly prototyped and measured it on a realistic application and execution time fell to from an improvement of nearly the necessary change is straightforward except for two places in its loop fileset write needs to make a copy of each file s lines and infos while holding the file s mutex file positionfor seems to have a pre existing data race since it calls file position without a lock which calls unpack which reads the lines and info fields ,0 +6197,3005376773.0,IssuesEvent,2015-07-26 21:04:59,golang/go,https://api.github.com/repos/golang/go,closed,doc: clarify usage of CGO_ENABLED,Documentation,"I was trying to repro issue #9510. I'm on a linux/amd64 system, and I used ""GOARCH=386 ./make.bash --no-clean"" to setup a cross-compiler toolchain. However, subsequently running ""GOARCH=386 go build issue"" per iant@'s instructions yielded an unhelpful ""no buildable Go source files in .../issue/a"" error. + +Poking into the package go/build source code, I discovered mention of ""CGO_ENABLED"" so I tried ""GOARCH=386 CGO_ENABLED=1 go build issue"". This worked to reproduce the issue. + +However, trying to learn more about this setting, I found this in cmd/cgo/doc.go: + + To enable cgo during cross compiling builds, set the CGO_ENABLED + environment variable to 1 when building the Go tools with make.bash. + +So I inferred I was misusing it and decided to startover with ""GOARCH=386 CGO_ENABLED=1 ./make.bash --no-clean"" instead, but then running just ""GOARCH=386 go build issue"" again produced the same ""no buildable Go source files"" error. + +Confusingly, src/make.bash also seems to mention CGO_ENABLED having some significance, but at the moment (even having poked through run.bash and grep'd the source code), I'm still not sure I entirely understand the significance.",1.0,"doc: clarify usage of CGO_ENABLED - I was trying to repro issue #9510. I'm on a linux/amd64 system, and I used ""GOARCH=386 ./make.bash --no-clean"" to setup a cross-compiler toolchain. However, subsequently running ""GOARCH=386 go build issue"" per iant@'s instructions yielded an unhelpful ""no buildable Go source files in .../issue/a"" error. + +Poking into the package go/build source code, I discovered mention of ""CGO_ENABLED"" so I tried ""GOARCH=386 CGO_ENABLED=1 go build issue"". This worked to reproduce the issue. + +However, trying to learn more about this setting, I found this in cmd/cgo/doc.go: + + To enable cgo during cross compiling builds, set the CGO_ENABLED + environment variable to 1 when building the Go tools with make.bash. + +So I inferred I was misusing it and decided to startover with ""GOARCH=386 CGO_ENABLED=1 ./make.bash --no-clean"" instead, but then running just ""GOARCH=386 go build issue"" again produced the same ""no buildable Go source files"" error. + +Confusingly, src/make.bash also seems to mention CGO_ENABLED having some significance, but at the moment (even having poked through run.bash and grep'd the source code), I'm still not sure I entirely understand the significance.",1,doc clarify usage of cgo enabled i was trying to repro issue i m on a linux system and i used goarch make bash no clean to setup a cross compiler toolchain however subsequently running goarch go build issue per iant s instructions yielded an unhelpful no buildable go source files in issue a error poking into the package go build source code i discovered mention of cgo enabled so i tried goarch cgo enabled go build issue this worked to reproduce the issue however trying to learn more about this setting i found this in cmd cgo doc go to enable cgo during cross compiling builds set the cgo enabled environment variable to when building the go tools with make bash so i inferred i was misusing it and decided to startover with goarch cgo enabled make bash no clean instead but then running just goarch go build issue again produced the same no buildable go source files error confusingly src make bash also seems to mention cgo enabled having some significance but at the moment even having poked through run bash and grep d the source code i m still not sure i entirely understand the significance ,1 +71720,18849410500.0,IssuesEvent,2021-11-11 18:45:22,golang/go,https://api.github.com/repos/golang/go,closed,x/review/git-codereview: test timed out on windows-arm-zx2c4 builder,Builders NeedsInvestigation,"[2020-09-11T20:38:40-0edcede/windows-arm-zx2c4](https://build.golang.org/log/58a8dd9300dc4313d7f829aa0b794177a94a948f) + +Not obvious to me whether the builder is just slow or the test triggered some kind of deadlock. + +CC @zx2c4 @golang/release ",1.0,"x/review/git-codereview: test timed out on windows-arm-zx2c4 builder - [2020-09-11T20:38:40-0edcede/windows-arm-zx2c4](https://build.golang.org/log/58a8dd9300dc4313d7f829aa0b794177a94a948f) + +Not obvious to me whether the builder is just slow or the test triggered some kind of deadlock. + +CC @zx2c4 @golang/release ",0,x review git codereview test timed out on windows arm builder not obvious to me whether the builder is just slow or the test triggered some kind of deadlock cc golang release ,0 +6435,3022485562.0,IssuesEvent,2015-07-31 20:39:03,golang/go,https://api.github.com/repos/golang/go,closed,spec: minor changes to examples,Documentation,"Three small suggestions for the examples in the Go Specification: + +In the ```TimeZone``` type, the line +``` +return fmt.Sprintf(""GMT+%dh"", tz) +``` +returns something like ```GMT+-5h```. I think it would be better to change ```+%``` to ```%+```: +``` +return fmt.Sprintf(""GMT%+dh"", tz) +``` +so the result is ```GMT-5h```. + +In ```findMarker```, if a return statement were added, the loop would only check every other item in the channel, because it uses both a for/range and a channel receive operation. The example would be less confusing with just one of those. For/range hasn't been introduced yet, so that's what I would remove. + +In the Selectors section, the anonymous field ```T0``` of type ```T2``` is already a pointer. So the line +``` +p.M0() // ((&(*p).T0)).M0() M0 expects *T0 receiver, see section on Calls +``` +isn't an example of a shorthand reference to an addressable value. I think the comment should be: +``` +p.M0() // ((*p).T0).M0() M0 expects *T0 receiver +``` +A shorthand example could be added: +``` +t.M2() // (&t).M2() M2 expects *T2 receiver, see section on Calls +``` + +These suggestions are current as of Go 1.5 beta 3.",1.0,"spec: minor changes to examples - Three small suggestions for the examples in the Go Specification: + +In the ```TimeZone``` type, the line +``` +return fmt.Sprintf(""GMT+%dh"", tz) +``` +returns something like ```GMT+-5h```. I think it would be better to change ```+%``` to ```%+```: +``` +return fmt.Sprintf(""GMT%+dh"", tz) +``` +so the result is ```GMT-5h```. + +In ```findMarker```, if a return statement were added, the loop would only check every other item in the channel, because it uses both a for/range and a channel receive operation. The example would be less confusing with just one of those. For/range hasn't been introduced yet, so that's what I would remove. + +In the Selectors section, the anonymous field ```T0``` of type ```T2``` is already a pointer. So the line +``` +p.M0() // ((&(*p).T0)).M0() M0 expects *T0 receiver, see section on Calls +``` +isn't an example of a shorthand reference to an addressable value. I think the comment should be: +``` +p.M0() // ((*p).T0).M0() M0 expects *T0 receiver +``` +A shorthand example could be added: +``` +t.M2() // (&t).M2() M2 expects *T2 receiver, see section on Calls +``` + +These suggestions are current as of Go 1.5 beta 3.",1,spec minor changes to examples three small suggestions for the examples in the go specification in the timezone type the line return fmt sprintf gmt dh tz returns something like gmt i think it would be better to change to return fmt sprintf gmt dh tz so the result is gmt in findmarker if a return statement were added the loop would only check every other item in the channel because it uses both a for range and a channel receive operation the example would be less confusing with just one of those for range hasn t been introduced yet so that s what i would remove in the selectors section the anonymous field of type is already a pointer so the line p p expects receiver see section on calls isn t an example of a shorthand reference to an addressable value i think the comment should be p p expects receiver a shorthand example could be added t t expects receiver see section on calls these suggestions are current as of go beta ,1 +62155,8578619326.0,IssuesEvent,2018-11-13 06:03:14,golang/go,https://api.github.com/repos/golang/go,closed,builtin: documentation should clarify how len() behaves,Documentation,"Currently the `len( )` function returns an `int`. Changing it to `uint` has already been proposed and rejected. + +Can the documentation clarify what `len( )` returns when the number of items in a slice exceeds the max value of an int?",1.0,"builtin: documentation should clarify how len() behaves - Currently the `len( )` function returns an `int`. Changing it to `uint` has already been proposed and rejected. + +Can the documentation clarify what `len( )` returns when the number of items in a slice exceeds the max value of an int?",1,builtin documentation should clarify how len behaves currently the len function returns an int changing it to uint has already been proposed and rejected can the documentation clarify what len returns when the number of items in a slice exceeds the max value of an int ,1 +28866,5543546478.0,IssuesEvent,2017-03-22 17:09:47,golang/go,https://api.github.com/repos/golang/go,closed,wiki: wrong/outdated instructions on the Ubuntu page,Documentation,"Please answer these questions before submitting your issue. Thanks! + +### What version of Go are you using (`go version`)? +1.8 + +### What operating system and processor architecture are you using (`go env`)? +Ubuntu Linux 16.10 + +### What did you do? +Followed the readme + +If possible, provide a recipe for reproducing the error. +A complete runnable program is good. +A link on play.golang.org is best. + + +### What did you expect to see? +Golang 1.8 as a package. + +### What did you see instead? +Your instructions appear to be installing LXD PPA repo and then installing golang 1.6 from the universe repository. + +>sudo add-apt-repository ppa:ubuntu-lxc/lxd-stable +sudo apt-get update +sudo apt-get install golang + +That's just wrong. +The bottom of the page instructions work alright. +But if you have a PPA you should update the instructions and if you don't have a PPA (I couldn't find one), then you should remove those instructions. + +Thanks!",1.0,"wiki: wrong/outdated instructions on the Ubuntu page - Please answer these questions before submitting your issue. Thanks! + +### What version of Go are you using (`go version`)? +1.8 + +### What operating system and processor architecture are you using (`go env`)? +Ubuntu Linux 16.10 + +### What did you do? +Followed the readme + +If possible, provide a recipe for reproducing the error. +A complete runnable program is good. +A link on play.golang.org is best. + + +### What did you expect to see? +Golang 1.8 as a package. + +### What did you see instead? +Your instructions appear to be installing LXD PPA repo and then installing golang 1.6 from the universe repository. + +>sudo add-apt-repository ppa:ubuntu-lxc/lxd-stable +sudo apt-get update +sudo apt-get install golang + +That's just wrong. +The bottom of the page instructions work alright. +But if you have a PPA you should update the instructions and if you don't have a PPA (I couldn't find one), then you should remove those instructions. + +Thanks!",1,wiki wrong outdated instructions on the ubuntu page please answer these questions before submitting your issue thanks what version of go are you using go version what operating system and processor architecture are you using go env ubuntu linux what did you do followed the readme if possible provide a recipe for reproducing the error a complete runnable program is good a link on play golang org is best what did you expect to see golang as a package what did you see instead your instructions appear to be installing lxd ppa repo and then installing golang from the universe repository sudo add apt repository ppa ubuntu lxc lxd stable sudo apt get update sudo apt get install golang that s just wrong the bottom of the page instructions work alright but if you have a ppa you should update the instructions and if you don t have a ppa i couldn t find one then you should remove those instructions thanks ,1 +32364,6050103331.0,IssuesEvent,2017-06-12 20:18:22,golang/go,https://api.github.com/repos/golang/go,closed,database/sql: QueryRow should verify that we have only one row,Documentation,"`QueryRow` is documented as follows: +```go +// QueryRow executes a query that is expected to return at most one row. +// QueryRow always returns a non-nil value. Errors are deferred until +// Row's Scan method is called. +``` +This suggests that we should get an error if the query returns more than one row. However `Row.Scan()` doesn't check that `r.rows.Next()` returns false after processing one row, so it would ignore any remaining rows. + +Conversely ""at most one row"" suggests that getting no rows is somehow acceptable, but an error is returned in that case. I think it should say ""exactly one row"".",1.0,"database/sql: QueryRow should verify that we have only one row - `QueryRow` is documented as follows: +```go +// QueryRow executes a query that is expected to return at most one row. +// QueryRow always returns a non-nil value. Errors are deferred until +// Row's Scan method is called. +``` +This suggests that we should get an error if the query returns more than one row. However `Row.Scan()` doesn't check that `r.rows.Next()` returns false after processing one row, so it would ignore any remaining rows. + +Conversely ""at most one row"" suggests that getting no rows is somehow acceptable, but an error is returned in that case. I think it should say ""exactly one row"".",1,database sql queryrow should verify that we have only one row queryrow is documented as follows go queryrow executes a query that is expected to return at most one row queryrow always returns a non nil value errors are deferred until row s scan method is called this suggests that we should get an error if the query returns more than one row however row scan doesn t check that r rows next returns false after processing one row so it would ignore any remaining rows conversely at most one row suggests that getting no rows is somehow acceptable but an error is returned in that case i think it should say exactly one row ,1 +75574,7477548311.0,IssuesEvent,2018-04-04 08:41:01,golang/go,https://api.github.com/repos/golang/go,closed,x/crypto/ssh: TestMuxReadWrite flake,NeedsFix Testing help wanted,"Flake on trybot run at https://storage.googleapis.com/go-build-log/4468b0ba/windows-386-2008_b5f0b931.log ... + +``` +panic: Fail in goroutine after TestMuxReadWrite has completed + +goroutine 1387 [running]: +testing.(*common).Fail(0x12841200) + C:/workdir/go/src/testing/testing.go:512 +0xf8 +testing.(*common).FailNow(0x12841200) + C:/workdir/go/src/testing/testing.go:534 +0x21 +testing.(*common).Fatalf(0x12841200, 0x6ce724, 0x9, 0x12cf5fbc, 0x1, 0x1) + C:/workdir/go/src/testing/testing.go:600 +0x69 +golang.org/x/crypto/ssh.TestMuxReadWrite.func1(0x12a7a400, 0x6cf433, 0xb, 0x12841200, 0x6cfa12, 0xc) + C:/workdir/gopath/src/golang.org/x/crypto/ssh/mux_test.go:113 +0x1e8 +created by golang.org/x/crypto/ssh.TestMuxReadWrite + C:/workdir/gopath/src/golang.org/x/crypto/ssh/mux_test.go:102 +0x102 +FAIL golang.org/x/crypto/ssh 3.991s +``` + +/cc @hanwen ",1.0,"x/crypto/ssh: TestMuxReadWrite flake - Flake on trybot run at https://storage.googleapis.com/go-build-log/4468b0ba/windows-386-2008_b5f0b931.log ... + +``` +panic: Fail in goroutine after TestMuxReadWrite has completed + +goroutine 1387 [running]: +testing.(*common).Fail(0x12841200) + C:/workdir/go/src/testing/testing.go:512 +0xf8 +testing.(*common).FailNow(0x12841200) + C:/workdir/go/src/testing/testing.go:534 +0x21 +testing.(*common).Fatalf(0x12841200, 0x6ce724, 0x9, 0x12cf5fbc, 0x1, 0x1) + C:/workdir/go/src/testing/testing.go:600 +0x69 +golang.org/x/crypto/ssh.TestMuxReadWrite.func1(0x12a7a400, 0x6cf433, 0xb, 0x12841200, 0x6cfa12, 0xc) + C:/workdir/gopath/src/golang.org/x/crypto/ssh/mux_test.go:113 +0x1e8 +created by golang.org/x/crypto/ssh.TestMuxReadWrite + C:/workdir/gopath/src/golang.org/x/crypto/ssh/mux_test.go:102 +0x102 +FAIL golang.org/x/crypto/ssh 3.991s +``` + +/cc @hanwen ",0,x crypto ssh testmuxreadwrite flake flake on trybot run at panic fail in goroutine after testmuxreadwrite has completed goroutine testing common fail c workdir go src testing testing go testing common failnow c workdir go src testing testing go testing common fatalf c workdir go src testing testing go golang org x crypto ssh testmuxreadwrite c workdir gopath src golang org x crypto ssh mux test go created by golang org x crypto ssh testmuxreadwrite c workdir gopath src golang org x crypto ssh mux test go fail golang org x crypto ssh cc hanwen ,0 +3242,2752093801.0,IssuesEvent,2015-04-24 13:45:14,golang/go,https://api.github.com/repos/golang/go,closed,hash/crc32: clarify documentation,Documentation,"by **sheetjs**: + +
Documentation currently says: + +"MakeTable returns the Table constructed from the specified polynomial." + +Somewhere in the doc, it should explicitly state that poly (the 32 bit integer) should +be based on the reversed representation. It's implied by the constant "IEEE = +0xedb88320" (the normal representation for that case is 0x04c11db7), but making it +clear wouldn't hurt",1.0,"hash/crc32: clarify documentation - by **sheetjs**: + +
Documentation currently says: + +"MakeTable returns the Table constructed from the specified polynomial." + +Somewhere in the doc, it should explicitly state that poly (the 32 bit integer) should +be based on the reversed representation. It's implied by the constant "IEEE = +0xedb88320" (the normal representation for that case is 0x04c11db7), but making it +clear wouldn't hurt",1,hash clarify documentation by sheetjs documentation currently says quot maketable returns the table constructed from the specified polynomial quot somewhere in the doc it should explicitly state that poly the bit integer should be based on the reversed representation it s implied by the constant quot ieee quot the normal representation for that case is but making it clear wouldn t hurt ,1 +31979,6022657744.0,IssuesEvent,2017-06-07 21:35:57,golang/go,https://api.github.com/repos/golang/go,closed,"sync: clarify Cond ""created as part of other structures"" documentation",Documentation,"### What version of Go are you using (`go version`)? + +go version go1.8.1 darwin/amd64 + +### What operating system and processor architecture are you using (`go env`)? + +``` +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/joneskoo"" +GORACE="""" +GOROOT=""/usr/local/Cellar/go/1.8.1/libexec"" +GOTOOLDIR=""/usr/local/Cellar/go/1.8.1/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/p9/8mb6mhcx7p3br8f18crtczzw0000gn/T/go-build980179018=/tmp/go-build -gno-record-gcc-switches -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +PKG_CONFIG=""pkg-config"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" + +``` + +### What did you do? + +I'm creating a sync.Cond as part of a struct. [Documentation explicitly says this is ok](https://tip.golang.org/pkg/sync/#Cond). + +https://play.golang.org/p/k0EkYJPC4A + +### What did you expect to see? + +Wait for Cond until Broadcast is called one second later. + +### What did you see instead? + +``` +panic: runtime error: invalid memory address or nil pointer dereference +[signal SIGSEGV: segmentation violation code=0xffffffff addr=0x0 pc=0x82ffb] + +goroutine 1 [running]: +sync.(*Cond).Wait(0x104401a0, 0x0) + /usr/local/go/src/sync/cond.go:56 +0x7b +main.main() + /tmp/sandbox578695461/main.go:17 +0x120 +``` + +There isn't an example for sync.Cond in the documentation and it's hardly used in the standard library. + +Should the documentation explain that the locker must be set if the Cond is created as part of a structure? If yes, then what does this really mean: + +> A Cond can be created as part of other structures. A Cond must not be copied after first use. + +Please update title if this turns out to be a documentation issue. A simple example and where the Cond might be useful would be nice.",1.0,"sync: clarify Cond ""created as part of other structures"" documentation - ### What version of Go are you using (`go version`)? + +go version go1.8.1 darwin/amd64 + +### What operating system and processor architecture are you using (`go env`)? + +``` +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/joneskoo"" +GORACE="""" +GOROOT=""/usr/local/Cellar/go/1.8.1/libexec"" +GOTOOLDIR=""/usr/local/Cellar/go/1.8.1/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/p9/8mb6mhcx7p3br8f18crtczzw0000gn/T/go-build980179018=/tmp/go-build -gno-record-gcc-switches -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +PKG_CONFIG=""pkg-config"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" + +``` + +### What did you do? + +I'm creating a sync.Cond as part of a struct. [Documentation explicitly says this is ok](https://tip.golang.org/pkg/sync/#Cond). + +https://play.golang.org/p/k0EkYJPC4A + +### What did you expect to see? + +Wait for Cond until Broadcast is called one second later. + +### What did you see instead? + +``` +panic: runtime error: invalid memory address or nil pointer dereference +[signal SIGSEGV: segmentation violation code=0xffffffff addr=0x0 pc=0x82ffb] + +goroutine 1 [running]: +sync.(*Cond).Wait(0x104401a0, 0x0) + /usr/local/go/src/sync/cond.go:56 +0x7b +main.main() + /tmp/sandbox578695461/main.go:17 +0x120 +``` + +There isn't an example for sync.Cond in the documentation and it's hardly used in the standard library. + +Should the documentation explain that the locker must be set if the Cond is created as part of a structure? If yes, then what does this really mean: + +> A Cond can be created as part of other structures. A Cond must not be copied after first use. + +Please update title if this turns out to be a documentation issue. A simple example and where the Cond might be useful would be nice.",1,sync clarify cond created as part of other structures documentation what version of go are you using go version go version darwin what operating system and processor architecture are you using go env goarch gobin goexe gohostarch gohostos darwin goos darwin gopath users joneskoo gorace goroot usr local cellar go libexec gotooldir usr local cellar go libexec pkg tool darwin gccgo gccgo cc clang gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map var folders t go tmp go build gno record gcc switches fno common cxx clang cgo enabled pkg config pkg config cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g what did you do i m creating a sync cond as part of a struct what did you expect to see wait for cond until broadcast is called one second later what did you see instead panic runtime error invalid memory address or nil pointer dereference goroutine sync cond wait usr local go src sync cond go main main tmp main go there isn t an example for sync cond in the documentation and it s hardly used in the standard library should the documentation explain that the locker must be set if the cond is created as part of a structure if yes then what does this really mean a cond can be created as part of other structures a cond must not be copied after first use please update title if this turns out to be a documentation issue a simple example and where the cond might be useful would be nice ,1 +69603,9310121042.0,IssuesEvent,2019-03-25 18:00:16,golang/go,https://api.github.com/repos/golang/go,closed,"cmd/go: building Go distribution from source fails with ""missing $GOPATH""",Documentation NeedsFix release-blocker,"On an amd64 GNU/Linux system with no `GOPATH` set in the environment, and with the Go source code at `$HOME/go` so that the default `GOPATH` setting does not work, running make.bash fails with + +``` +Building Go cmd/dist using /usr/local/google/home/iant/go1.4. +Building Go toolchain1 using /usr/local/google/home/iant/go1.4. +Building Go bootstrap cmd/go (go_bootstrap) using Go toolchain1. +Building Go toolchain2 using go_bootstrap and Go toolchain1. +missing $GOPATH +go tool dist: FAILED: /usr/local/google/home/iant/go/pkg/tool/linux_amd64/go_bootstrap install -gcflags=all= -ldflags=all= -i cmd/asm cmd/cgo cmd/compile cmd/link: exit status 1 +```",1.0,"cmd/go: building Go distribution from source fails with ""missing $GOPATH"" - On an amd64 GNU/Linux system with no `GOPATH` set in the environment, and with the Go source code at `$HOME/go` so that the default `GOPATH` setting does not work, running make.bash fails with + +``` +Building Go cmd/dist using /usr/local/google/home/iant/go1.4. +Building Go toolchain1 using /usr/local/google/home/iant/go1.4. +Building Go bootstrap cmd/go (go_bootstrap) using Go toolchain1. +Building Go toolchain2 using go_bootstrap and Go toolchain1. +missing $GOPATH +go tool dist: FAILED: /usr/local/google/home/iant/go/pkg/tool/linux_amd64/go_bootstrap install -gcflags=all= -ldflags=all= -i cmd/asm cmd/cgo cmd/compile cmd/link: exit status 1 +```",1,cmd go building go distribution from source fails with missing gopath on an gnu linux system with no gopath set in the environment and with the go source code at home go so that the default gopath setting does not work running make bash fails with building go cmd dist using usr local google home iant building go using usr local google home iant building go bootstrap cmd go go bootstrap using go building go using go bootstrap and go missing gopath go tool dist failed usr local google home iant go pkg tool linux go bootstrap install gcflags all ldflags all i cmd asm cmd cgo cmd compile cmd link exit status ,1 +16699,6262338808.0,IssuesEvent,2017-07-15 09:32:33,golang/go,https://api.github.com/repos/golang/go,opened,"cmd/dist: ""moved GOROOT"" test failing on plan9/386 builder",Builders OS-Plan9,"CL [48550](https://golang.org/cl/48550) added ""moved GOROOT"" test, which is failing on the plan9/386 builder. The plan9/386 builder is running as a buildlet on GCE, while the other builders are old-style builders. +``` +##### moved GOROOT +go: cannot find GOROOT directory: /tmp/workdir/go +``` + +See https://build.golang.org/log/6fc6155f74eeff35e8a05ce78ab0531a4f9018bf +",1.0,"cmd/dist: ""moved GOROOT"" test failing on plan9/386 builder - CL [48550](https://golang.org/cl/48550) added ""moved GOROOT"" test, which is failing on the plan9/386 builder. The plan9/386 builder is running as a buildlet on GCE, while the other builders are old-style builders. +``` +##### moved GOROOT +go: cannot find GOROOT directory: /tmp/workdir/go +``` + +See https://build.golang.org/log/6fc6155f74eeff35e8a05ce78ab0531a4f9018bf +",0,cmd dist moved goroot test failing on builder cl added moved goroot test which is failing on the builder the builder is running as a buildlet on gce while the other builders are old style builders moved goroot go cannot find goroot directory tmp workdir go see ,0 +68394,9172201049.0,IssuesEvent,2019-03-04 06:01:37,golang/go,https://api.github.com/repos/golang/go,closed,doc: Release History doesn't mention 1.11.5,Documentation,"The release history page doesn't list the go1.11.5 minor release: + +https://golang.org/doc/devel/release.html#go1.11.minor + +However, tip.golang.org has it: + +https://tip.golang.org/doc/devel/release.html#go1.11.minor + +Does the main website need a redeploy or something? + +cc @dmitshur",1.0,"doc: Release History doesn't mention 1.11.5 - The release history page doesn't list the go1.11.5 minor release: + +https://golang.org/doc/devel/release.html#go1.11.minor + +However, tip.golang.org has it: + +https://tip.golang.org/doc/devel/release.html#go1.11.minor + +Does the main website need a redeploy or something? + +cc @dmitshur",1,doc release history doesn t mention the release history page doesn t list the minor release however tip golang org has it does the main website need a redeploy or something cc dmitshur,1 +42465,6980426260.0,IssuesEvent,2017-12-13 01:38:48,golang/go,https://api.github.com/repos/golang/go,closed,doc: mention plugins working on Mac,Documentation NeedsFix release-blocker,"According to the unsubmitted https://go-review.googlesource.com/c/go/+/65670 , the plugin package now works on macOS. + +If that's true, it should be documented in the Go 1.10 release notes, and that CL should be submitted. + +/cc @rsc @ianlancetaylor @crawshaw ",1.0,"doc: mention plugins working on Mac - According to the unsubmitted https://go-review.googlesource.com/c/go/+/65670 , the plugin package now works on macOS. + +If that's true, it should be documented in the Go 1.10 release notes, and that CL should be submitted. + +/cc @rsc @ianlancetaylor @crawshaw ",1,doc mention plugins working on mac according to the unsubmitted the plugin package now works on macos if that s true it should be documented in the go release notes and that cl should be submitted cc rsc ianlancetaylor crawshaw ,1 +33121,6157501553.0,IssuesEvent,2017-06-28 19:05:26,golang/go,https://api.github.com/repos/golang/go,opened,http: Document change in cookie sanitization in the release notes?,Documentation,"[This](https://github.com/golang/go/commit/8f6d68ebaa660c6db8a87d418e95f8c0d3a221e4) change to sanitizeCookieValue (to fix #18627) broke the quic-go unit tests going from 1.8 to 1.9b2. I don't know about the policy for mentioning bugfixes there, but maybe this should be mentioned in the release notes for net/http? I'd be happy to write a CL if you feel like it's worth it.",1.0,"http: Document change in cookie sanitization in the release notes? - [This](https://github.com/golang/go/commit/8f6d68ebaa660c6db8a87d418e95f8c0d3a221e4) change to sanitizeCookieValue (to fix #18627) broke the quic-go unit tests going from 1.8 to 1.9b2. I don't know about the policy for mentioning bugfixes there, but maybe this should be mentioned in the release notes for net/http? I'd be happy to write a CL if you feel like it's worth it.",1,http document change in cookie sanitization in the release notes change to sanitizecookievalue to fix broke the quic go unit tests going from to i don t know about the policy for mentioning bugfixes there but maybe this should be mentioned in the release notes for net http i d be happy to write a cl if you feel like it s worth it ,1 +22061,4770831254.0,IssuesEvent,2016-10-26 16:14:27,golang/go,https://api.github.com/repos/golang/go,closed,doc: rephrase sentence about comments in Effective Go,Documentation,"In Effective Go, [Commentary](https://golang.org/doc/effective_go.html#commentary) section: + +> If the name always begins the comment, the output of godoc can usefully be run through grep. + +is better phrased as: + +> If comments always begin with a name, the output of godoc can usefully be run through grep. +",1.0,"doc: rephrase sentence about comments in Effective Go - In Effective Go, [Commentary](https://golang.org/doc/effective_go.html#commentary) section: + +> If the name always begins the comment, the output of godoc can usefully be run through grep. + +is better phrased as: + +> If comments always begin with a name, the output of godoc can usefully be run through grep. +",1,doc rephrase sentence about comments in effective go in effective go section if the name always begins the comment the output of godoc can usefully be run through grep is better phrased as if comments always begin with a name the output of godoc can usefully be run through grep ,1 +318605,27317213327.0,IssuesEvent,2023-02-24 16:36:53,golang/go,https://api.github.com/repos/golang/go,reopened,runtime/pprof: TestLabelSystemstack due to sample with no location,Testing NeedsInvestigation,"``` +#!watchflakes +post <- pkg == ""runtime/pprof"" && test == ""TestLabelSystemstack"" +``` + +This one is a doozy. The failure message comes from here: +https://cs.opensource.google/go/go/+/master:src/runtime/pprof/pprof_test.go;l=1535;drc=18c2033ba587ce63fc9f2d6f52b8bb2e395c561f + +That seems to imply that the sample was labeled but its stack was empty(!!), which does seem to be the case in the dump of collected profiles: +``` + 1: labels: map[key:[value]] +``` + +(attn @prattmic, CC @golang/runtime) + +``` +--- FAIL: TestLabelSystemstack (0.32s) + pprof_test.go:524: total 85 CPU profile samples collected: + 1: 0x866eef (_ZN6__tsanL14MemoryRangeSetEPNS_11ThreadStateEyyyy.isra.39.part.40:0) 0x8e1ec0 (runtime._System:4432) labels: map[] + + 2: 0x86a6bc (_ZN6__tsan7MetaMap9FreeRangeEPNS_9ProcessorEyy:0) 0x8e1ec0 (runtime._System:4432) labels: map[key:[value]] + + 1: 0x8d2f04 (runtime.stdcall1:1090) 0x8d23a9 (runtime.semawakeup:871) 0x8a96ad (runtime.notewakeup:161) 0x8dce48 (runtime.startm:2324) 0x8ded1e (runtime.injectglist.func1:3076 runtime.injectglist:3100) 0x8bf5b6 (runtime.wakeScavenger:222) 0x8bf6d6 (runtime.bgscavenge.func1:268) 0x8f6d21 (runtime.runOneTimer:867) 0x8f6ad2 (runtime.runtimer:775) 0x8df2cf (runtime.checkTimers:3286) 0x8de484 (runtime.stealWork:2868) 0x8dda35 (runtime.findrunnable:2599) 0x8defd8 (runtime.schedule:3187) 0x8df52c (runtime.park_m:3336) 0x905f89 (runtime.mcall:425) labels: map[] + + 13: 0x907ee6 (runtime.procyield:733) 0x8a9475 (runtime.lock2:69) 0x8bf1f1 (runtime.lockWithRank:22 runtime.lock:36 runtime.setGCPercent.func1:1255) 0x90600d (runtime.systemstack:469) 0x9020a5 (runtime/debug.setGCPercent:1254) 0xa8de99 (runtime/debug.SetGCPercent:92 runtime/pprof.labelHog:1552) 0xa8e152 (runtime/pprof.parallelLabelHog.func1:1565) labels: map[key:[value]] + + 1: 0x866ef7 (_ZN6__tsanL14MemoryRangeSetEPNS_11ThreadStateEyyyy.isra.39.part.40:0) 0x8e1ec0 (runtime._System:4432) labels: map[] + + 1: 0x8bf0d0 (runtime.(*gcControllerState).commit:1089) 0x8bf195 (runtime.(*gcControllerState).setGCPercent:1246) 0x8bf204 (runtime.setGCPercent.func1:1256) 0x90600d (runtime.systemstack:469) 0x9020a5 (runtime/debug.setGCPercent:1254) 0xa8de99 (runtime/debug.SetGCPercent:92 runtime/pprof.labelHog:1552) 0xa8e152 (runtime/pprof.parallelLabelHog.func1:1565) labels: map[key:[value]] + + 5: 0x8a9402 (runtime.lock2:61) 0x8bf1f1 (runtime.lockWithRank:22 runtime.lock:36 runtime.setGCPercent.func1:1255) 0x90600d (runtime.systemstack:469) 0x9020a5 (runtime/debug.setGCPercent:1254) 0xa8de99 (runtime/debug.SetGCPercent:92 runtime/pprof.labelHog:1552) 0xa8e152 (runtime/pprof.parallelLabelHog.func1:1565) labels: map[key:[value]] + + 27: 0x8d2f84 (runtime.stdcall2:1099) 0x8d204e (runtime.semasleep:819) 0x8a94f7 (runtime.lock2:89) 0x8bf1f1 (runtime.lockWithRank:22 runtime.lock:36 runtime.setGCPercent.func1:1255) 0x90600d (runtime.systemstack:469) labels: map[key:[value]] + + 4: 0x8a9419 (runtime.lock2:63) 0x8bf1f1 (runtime.lockWithRank:22 runtime.lock:36 runtime.setGCPercent.func1:1255) 0x90600d (runtime.systemstack:469) 0x9020a5 (runtime/debug.setGCPercent:1254) 0xa8de99 (runtime/debug.SetGCPercent:92 runtime/pprof.labelHog:1552) 0xa8e152 (runtime/pprof.parallelLabelHog.func1:1565) labels: map[key:[value]] + + 11: 0x8e1f00 (runtime._ExternalCode:4433) 0x8e1ec0 (runtime._System:4432) labels: map[key:[value]] + + 10: 0x8d2f04 (runtime.stdcall1:1090) 0x8d23a9 (runtime.semawakeup:871) 0x8a95f5 (runtime.unlock2:117) 0x8bf238 (runtime.unlockWithRank:31 runtime.unlock:97 runtime.setGCPercent.func1:1259) 0x90600d (runtime.systemstack:469) labels: map[key:[value]] + + 1: 0x8d3004 (runtime.stdcall3:1108) 0x8b5ba4 (runtime.sysUnused:33) 0x8c098a (runtime.(*pageAlloc).scavengeRangeLocked:775) 0x8c07cd (runtime.(*pageAlloc).scavengeOneFast:726) 0x8c0324 (runtime.(*pageAlloc).scavengeOne:637) 0x8bfcfc (runtime.(*pageAlloc).scavenge.func1:454) 0x90600d (runtime.systemstack:469) labels: map[] + + 3: 0x907ee4 (runtime.procyield:732) 0x8a9475 (runtime.lock2:69) 0x8bf1f1 (runtime.lockWithRank:22 runtime.lock:36 runtime.setGCPercent.func1:1255) 0x90600d (runtime.systemstack:469) 0x9020a5 (runtime/debug.setGCPercent:1254) 0xa8de99 (runtime/debug.SetGCPercent:92 runtime/pprof.labelHog:1552) 0xa8e152 (runtime/pprof.parallelLabelHog.func1:1565) labels: map[key:[value]] + + 1: 0x8d2037 (runtime.semasleep:819) 0x8a94f7 (runtime.lock2:89) 0x8bf1f1 (runtime.lockWithRank:22 runtime.lock:36 runtime.setGCPercent.func1:1255) 0x90600d (runtime.systemstack:469) 0x9020a5 (runtime/debug.setGCPercent:1254) 0xa8de99 (runtime/debug.SetGCPercent:92 runtime/pprof.labelHog:1552) 0xa8e152 (runtime/pprof.parallelLabelHog.func1:1565) labels: map[key:[value]] + + 1: 0xa8de9a (runtime/pprof.labelHog:1549) 0xa8e152 (runtime/pprof.parallelLabelHog.func1:1565) labels: map[key:[value]] + + 1: 0x8d2f04 (runtime.stdcall1:1090) 0x8d23a9 (runtime.semawakeup:871) 0x8a95f5 (runtime.unlock2:117) 0x8c07e7 (runtime.unlockWithRank:31 runtime.unlock:97 runtime.(*pageAlloc).scavengeOneFast:727) 0x8c0324 (runtime.(*pageAlloc).scavengeOne:637) 0x8bfcfc (runtime.(*pageAlloc).scavenge.func1:454) 0x90600d (runtime.systemstack:469) labels: map[] + + 1: labels: map[key:[value]] + + 1: 0x89a3a8 (.text$_ZN6__tsan14DenseSlabAllocINS_10ClockBlockELy65536ELy1024EE6RefillEPNS_19DenseSlabAllocCacheE:0) 0x8e1ec0 (runtime._System:4432) labels: map[] + + pprof_test.go:595: runtime.systemstack;key=value: 64 + pprof_test.go:1535: Sample labeled got true want false: +FAIL +FAIL runtime/pprof 19.664s +``` + +`greplogs --dashboard -md -l -e '(?ms)FAIL: TestLabelSystemstack.*Sample labeled got true want false:\s*$'` + +[2022-03-05T08:36:13-55a60ca/windows-amd64-race](https://build.golang.org/log/daf96d123ec840e876eb2865886e67013f1161da)",1.0,"runtime/pprof: TestLabelSystemstack due to sample with no location - ``` +#!watchflakes +post <- pkg == ""runtime/pprof"" && test == ""TestLabelSystemstack"" +``` + +This one is a doozy. The failure message comes from here: +https://cs.opensource.google/go/go/+/master:src/runtime/pprof/pprof_test.go;l=1535;drc=18c2033ba587ce63fc9f2d6f52b8bb2e395c561f + +That seems to imply that the sample was labeled but its stack was empty(!!), which does seem to be the case in the dump of collected profiles: +``` + 1: labels: map[key:[value]] +``` + +(attn @prattmic, CC @golang/runtime) + +``` +--- FAIL: TestLabelSystemstack (0.32s) + pprof_test.go:524: total 85 CPU profile samples collected: + 1: 0x866eef (_ZN6__tsanL14MemoryRangeSetEPNS_11ThreadStateEyyyy.isra.39.part.40:0) 0x8e1ec0 (runtime._System:4432) labels: map[] + + 2: 0x86a6bc (_ZN6__tsan7MetaMap9FreeRangeEPNS_9ProcessorEyy:0) 0x8e1ec0 (runtime._System:4432) labels: map[key:[value]] + + 1: 0x8d2f04 (runtime.stdcall1:1090) 0x8d23a9 (runtime.semawakeup:871) 0x8a96ad (runtime.notewakeup:161) 0x8dce48 (runtime.startm:2324) 0x8ded1e (runtime.injectglist.func1:3076 runtime.injectglist:3100) 0x8bf5b6 (runtime.wakeScavenger:222) 0x8bf6d6 (runtime.bgscavenge.func1:268) 0x8f6d21 (runtime.runOneTimer:867) 0x8f6ad2 (runtime.runtimer:775) 0x8df2cf (runtime.checkTimers:3286) 0x8de484 (runtime.stealWork:2868) 0x8dda35 (runtime.findrunnable:2599) 0x8defd8 (runtime.schedule:3187) 0x8df52c (runtime.park_m:3336) 0x905f89 (runtime.mcall:425) labels: map[] + + 13: 0x907ee6 (runtime.procyield:733) 0x8a9475 (runtime.lock2:69) 0x8bf1f1 (runtime.lockWithRank:22 runtime.lock:36 runtime.setGCPercent.func1:1255) 0x90600d (runtime.systemstack:469) 0x9020a5 (runtime/debug.setGCPercent:1254) 0xa8de99 (runtime/debug.SetGCPercent:92 runtime/pprof.labelHog:1552) 0xa8e152 (runtime/pprof.parallelLabelHog.func1:1565) labels: map[key:[value]] + + 1: 0x866ef7 (_ZN6__tsanL14MemoryRangeSetEPNS_11ThreadStateEyyyy.isra.39.part.40:0) 0x8e1ec0 (runtime._System:4432) labels: map[] + + 1: 0x8bf0d0 (runtime.(*gcControllerState).commit:1089) 0x8bf195 (runtime.(*gcControllerState).setGCPercent:1246) 0x8bf204 (runtime.setGCPercent.func1:1256) 0x90600d (runtime.systemstack:469) 0x9020a5 (runtime/debug.setGCPercent:1254) 0xa8de99 (runtime/debug.SetGCPercent:92 runtime/pprof.labelHog:1552) 0xa8e152 (runtime/pprof.parallelLabelHog.func1:1565) labels: map[key:[value]] + + 5: 0x8a9402 (runtime.lock2:61) 0x8bf1f1 (runtime.lockWithRank:22 runtime.lock:36 runtime.setGCPercent.func1:1255) 0x90600d (runtime.systemstack:469) 0x9020a5 (runtime/debug.setGCPercent:1254) 0xa8de99 (runtime/debug.SetGCPercent:92 runtime/pprof.labelHog:1552) 0xa8e152 (runtime/pprof.parallelLabelHog.func1:1565) labels: map[key:[value]] + + 27: 0x8d2f84 (runtime.stdcall2:1099) 0x8d204e (runtime.semasleep:819) 0x8a94f7 (runtime.lock2:89) 0x8bf1f1 (runtime.lockWithRank:22 runtime.lock:36 runtime.setGCPercent.func1:1255) 0x90600d (runtime.systemstack:469) labels: map[key:[value]] + + 4: 0x8a9419 (runtime.lock2:63) 0x8bf1f1 (runtime.lockWithRank:22 runtime.lock:36 runtime.setGCPercent.func1:1255) 0x90600d (runtime.systemstack:469) 0x9020a5 (runtime/debug.setGCPercent:1254) 0xa8de99 (runtime/debug.SetGCPercent:92 runtime/pprof.labelHog:1552) 0xa8e152 (runtime/pprof.parallelLabelHog.func1:1565) labels: map[key:[value]] + + 11: 0x8e1f00 (runtime._ExternalCode:4433) 0x8e1ec0 (runtime._System:4432) labels: map[key:[value]] + + 10: 0x8d2f04 (runtime.stdcall1:1090) 0x8d23a9 (runtime.semawakeup:871) 0x8a95f5 (runtime.unlock2:117) 0x8bf238 (runtime.unlockWithRank:31 runtime.unlock:97 runtime.setGCPercent.func1:1259) 0x90600d (runtime.systemstack:469) labels: map[key:[value]] + + 1: 0x8d3004 (runtime.stdcall3:1108) 0x8b5ba4 (runtime.sysUnused:33) 0x8c098a (runtime.(*pageAlloc).scavengeRangeLocked:775) 0x8c07cd (runtime.(*pageAlloc).scavengeOneFast:726) 0x8c0324 (runtime.(*pageAlloc).scavengeOne:637) 0x8bfcfc (runtime.(*pageAlloc).scavenge.func1:454) 0x90600d (runtime.systemstack:469) labels: map[] + + 3: 0x907ee4 (runtime.procyield:732) 0x8a9475 (runtime.lock2:69) 0x8bf1f1 (runtime.lockWithRank:22 runtime.lock:36 runtime.setGCPercent.func1:1255) 0x90600d (runtime.systemstack:469) 0x9020a5 (runtime/debug.setGCPercent:1254) 0xa8de99 (runtime/debug.SetGCPercent:92 runtime/pprof.labelHog:1552) 0xa8e152 (runtime/pprof.parallelLabelHog.func1:1565) labels: map[key:[value]] + + 1: 0x8d2037 (runtime.semasleep:819) 0x8a94f7 (runtime.lock2:89) 0x8bf1f1 (runtime.lockWithRank:22 runtime.lock:36 runtime.setGCPercent.func1:1255) 0x90600d (runtime.systemstack:469) 0x9020a5 (runtime/debug.setGCPercent:1254) 0xa8de99 (runtime/debug.SetGCPercent:92 runtime/pprof.labelHog:1552) 0xa8e152 (runtime/pprof.parallelLabelHog.func1:1565) labels: map[key:[value]] + + 1: 0xa8de9a (runtime/pprof.labelHog:1549) 0xa8e152 (runtime/pprof.parallelLabelHog.func1:1565) labels: map[key:[value]] + + 1: 0x8d2f04 (runtime.stdcall1:1090) 0x8d23a9 (runtime.semawakeup:871) 0x8a95f5 (runtime.unlock2:117) 0x8c07e7 (runtime.unlockWithRank:31 runtime.unlock:97 runtime.(*pageAlloc).scavengeOneFast:727) 0x8c0324 (runtime.(*pageAlloc).scavengeOne:637) 0x8bfcfc (runtime.(*pageAlloc).scavenge.func1:454) 0x90600d (runtime.systemstack:469) labels: map[] + + 1: labels: map[key:[value]] + + 1: 0x89a3a8 (.text$_ZN6__tsan14DenseSlabAllocINS_10ClockBlockELy65536ELy1024EE6RefillEPNS_19DenseSlabAllocCacheE:0) 0x8e1ec0 (runtime._System:4432) labels: map[] + + pprof_test.go:595: runtime.systemstack;key=value: 64 + pprof_test.go:1535: Sample labeled got true want false: +FAIL +FAIL runtime/pprof 19.664s +``` + +`greplogs --dashboard -md -l -e '(?ms)FAIL: TestLabelSystemstack.*Sample labeled got true want false:\s*$'` + +[2022-03-05T08:36:13-55a60ca/windows-amd64-race](https://build.golang.org/log/daf96d123ec840e876eb2865886e67013f1161da)",0,runtime pprof testlabelsystemstack due to sample with no location watchflakes post pkg runtime pprof test testlabelsystemstack this one is a doozy the failure message comes from here that seems to imply that the sample was labeled but its stack was empty which does seem to be the case in the dump of collected profiles labels map attn prattmic cc golang runtime fail testlabelsystemstack pprof test go total cpu profile samples collected isra part runtime system labels map runtime system labels map runtime runtime semawakeup runtime notewakeup runtime startm runtime injectglist runtime injectglist runtime wakescavenger runtime bgscavenge runtime runonetimer runtime runtimer runtime checktimers runtime stealwork runtime findrunnable runtime schedule runtime park m runtime mcall labels map runtime procyield runtime runtime lockwithrank runtime lock runtime setgcpercent runtime systemstack runtime debug setgcpercent runtime debug setgcpercent runtime pprof labelhog runtime pprof parallellabelhog labels map isra part runtime system labels map runtime gccontrollerstate commit runtime gccontrollerstate setgcpercent runtime setgcpercent runtime systemstack runtime debug setgcpercent runtime debug setgcpercent runtime pprof labelhog runtime pprof parallellabelhog labels map runtime runtime lockwithrank runtime lock runtime setgcpercent runtime systemstack runtime debug setgcpercent runtime debug setgcpercent runtime pprof labelhog runtime pprof parallellabelhog labels map runtime runtime semasleep runtime runtime lockwithrank runtime lock runtime setgcpercent runtime systemstack labels map runtime runtime lockwithrank runtime lock runtime setgcpercent runtime systemstack runtime debug setgcpercent runtime debug setgcpercent runtime pprof labelhog runtime pprof parallellabelhog labels map runtime externalcode runtime system labels map runtime runtime semawakeup runtime runtime unlockwithrank runtime unlock runtime setgcpercent runtime systemstack labels map runtime runtime sysunused runtime pagealloc scavengerangelocked runtime pagealloc scavengeonefast runtime pagealloc scavengeone runtime pagealloc scavenge runtime systemstack labels map runtime procyield runtime runtime lockwithrank runtime lock runtime setgcpercent runtime systemstack runtime debug setgcpercent runtime debug setgcpercent runtime pprof labelhog runtime pprof parallellabelhog labels map runtime semasleep runtime runtime lockwithrank runtime lock runtime setgcpercent runtime systemstack runtime debug setgcpercent runtime debug setgcpercent runtime pprof labelhog runtime pprof parallellabelhog labels map runtime pprof labelhog runtime pprof parallellabelhog labels map runtime runtime semawakeup runtime runtime unlockwithrank runtime unlock runtime pagealloc scavengeonefast runtime pagealloc scavengeone runtime pagealloc scavenge runtime systemstack labels map labels map text runtime system labels map pprof test go runtime systemstack key value pprof test go sample labeled got true want false fail fail runtime pprof greplogs dashboard md l e ms fail testlabelsystemstack sample labeled got true want false s ,0 +30224,8499160626.0,IssuesEvent,2018-10-29 16:29:21,golang/go,https://api.github.com/repos/golang/go,closed,x/build/env/openbsd: set sysctl hw.smt=1,Builders NeedsFix OS-OpenBSD Performance,"The OpenBSD images should disable Spectre/Meltdown protections and set `sysctl hw.smt=1` per + +https://go-review.googlesource.com/c/build/+/144777#message-b10c10646c34b670194db8c9d72ac8a551d3ab80",1.0,"x/build/env/openbsd: set sysctl hw.smt=1 - The OpenBSD images should disable Spectre/Meltdown protections and set `sysctl hw.smt=1` per + +https://go-review.googlesource.com/c/build/+/144777#message-b10c10646c34b670194db8c9d72ac8a551d3ab80",0,x build env openbsd set sysctl hw smt the openbsd images should disable spectre meltdown protections and set sysctl hw smt per ,0 +312849,23445610329.0,IssuesEvent,2022-08-15 19:17:30,golang/go,https://api.github.com/repos/golang/go,closed,runtime: cpu suboption for GODEBUG is not documented with the others for GODEBUG,Documentation help wanted NeedsFix compiler/runtime,"I've seen mention of using GODEBUG=cpu to disable certain cpu capabilities in various issues. I expected to find it described in runtime/extern.go where the other GODEBUG suboptions are documented, but it is not.",1.0,"runtime: cpu suboption for GODEBUG is not documented with the others for GODEBUG - I've seen mention of using GODEBUG=cpu to disable certain cpu capabilities in various issues. I expected to find it described in runtime/extern.go where the other GODEBUG suboptions are documented, but it is not.",1,runtime cpu suboption for godebug is not documented with the others for godebug i ve seen mention of using godebug cpu to disable certain cpu capabilities in various issues i expected to find it described in runtime extern go where the other godebug suboptions are documented but it is not ,1 +2541,2695314347.0,IssuesEvent,2015-04-02 03:54:14,golang/go,https://api.github.com/repos/golang/go,closed,go/ast: incorrect docs for Inspect,documentation repo-main,"I am not good in Engilsh. + +The documents of ast.Inspect says: + +``` +If f returns true, Inspect invokes f for all the non-nil children of node, recursively. +``` + +see the play http://play.golang.org/p/HID53LSwv_ + + +",1.0,"go/ast: incorrect docs for Inspect - I am not good in Engilsh. + +The documents of ast.Inspect says: + +``` +If f returns true, Inspect invokes f for all the non-nil children of node, recursively. +``` + +see the play http://play.golang.org/p/HID53LSwv_ + + +",1,go ast incorrect docs for inspect i am not good in engilsh the documents of ast inspect says if f returns true inspect invokes f for all the non nil children of node recursively see the play ,1 +178435,14669556632.0,IssuesEvent,2020-12-30 01:13:13,golang/go,https://api.github.com/repos/golang/go,closed,x/tools/gopls: add autogenerated documentation for analyzers,Documentation Tools gopls,`gopls/analyzers.md` could be populated from the analyzer.Doc fields of all of the analyzers in internal/lsp/source/options.go.,1.0,x/tools/gopls: add autogenerated documentation for analyzers - `gopls/analyzers.md` could be populated from the analyzer.Doc fields of all of the analyzers in internal/lsp/source/options.go.,1,x tools gopls add autogenerated documentation for analyzers gopls analyzers md could be populated from the analyzer doc fields of all of the analyzers in internal lsp source options go ,1 +304901,23089769467.0,IssuesEvent,2022-07-26 14:21:20,golang/go,https://api.github.com/repos/golang/go,closed,bytes: Reader.Size method documentation is inaccurate,Documentation NeedsFix," + +### What version of Go are you using (`go version`)? + +Documentation issue; currently visible default version is 1.18.4 + +### Does this issue reproduce with the latest release? + +Yes, 1.18.4 is the latest release. This doesn't seem to have been fixed as of 1.19rc2 either. + +### What operating system and processor architecture are you using (`go env`)? + +N/A (platform-agnostic documentation issue) + +### What did you do? + + + +Viewed the docs for [`Reader.Size`](https://pkg.go.dev/bytes#Reader.Size) method in `bytes` standard library package + +### What did you expect to see? + +The [`Reader.Reset`](https://pkg.go.dev/bytes#Reader.Reset) method can change the underlying byte slice. The docs for `Size` method should say something like (changes italicized): + +> Size returns the original length of the underlying byte slice. Size is the number of bytes available for reading via ReadAt. The returned value _will not change between calls unless the byte slice is changed by Reset_. + +### What did you see instead? + +The docs currently say: + +> Size returns the original length of the underlying byte slice. Size is the number of bytes available for reading via ReadAt. The returned value is always the same and is not affected by calls to any other method. + +The `Reset` method is the only violation of this wording, and it was added in Go 1.7, but the `Size` method dates back to 1.5. This minor documentation issue seems to have arisen because an assumption (immutability of the byte slice) changed between versions of the language/library.",1.0,"bytes: Reader.Size method documentation is inaccurate - + +### What version of Go are you using (`go version`)? + +Documentation issue; currently visible default version is 1.18.4 + +### Does this issue reproduce with the latest release? + +Yes, 1.18.4 is the latest release. This doesn't seem to have been fixed as of 1.19rc2 either. + +### What operating system and processor architecture are you using (`go env`)? + +N/A (platform-agnostic documentation issue) + +### What did you do? + + + +Viewed the docs for [`Reader.Size`](https://pkg.go.dev/bytes#Reader.Size) method in `bytes` standard library package + +### What did you expect to see? + +The [`Reader.Reset`](https://pkg.go.dev/bytes#Reader.Reset) method can change the underlying byte slice. The docs for `Size` method should say something like (changes italicized): + +> Size returns the original length of the underlying byte slice. Size is the number of bytes available for reading via ReadAt. The returned value _will not change between calls unless the byte slice is changed by Reset_. + +### What did you see instead? + +The docs currently say: + +> Size returns the original length of the underlying byte slice. Size is the number of bytes available for reading via ReadAt. The returned value is always the same and is not affected by calls to any other method. + +The `Reset` method is the only violation of this wording, and it was added in Go 1.7, but the `Size` method dates back to 1.5. This minor documentation issue seems to have arisen because an assumption (immutability of the byte slice) changed between versions of the language/library.",1,bytes reader size method documentation is inaccurate please answer these questions before submitting your issue thanks what version of go are you using go version documentation issue currently visible default version is does this issue reproduce with the latest release yes is the latest release this doesn t seem to have been fixed as of either what operating system and processor architecture are you using go env n a platform agnostic documentation issue what did you do if possible provide a recipe for reproducing the error a complete runnable program is good a link on go dev play is best viewed the docs for method in bytes standard library package what did you expect to see the method can change the underlying byte slice the docs for size method should say something like changes italicized size returns the original length of the underlying byte slice size is the number of bytes available for reading via readat the returned value will not change between calls unless the byte slice is changed by reset what did you see instead the docs currently say size returns the original length of the underlying byte slice size is the number of bytes available for reading via readat the returned value is always the same and is not affected by calls to any other method the reset method is the only violation of this wording and it was added in go but the size method dates back to this minor documentation issue seems to have arisen because an assumption immutability of the byte slice changed between versions of the language library ,1 +41030,6888053494.0,IssuesEvent,2017-11-22 03:11:26,golang/go,https://api.github.com/repos/golang/go,closed,encoding/json: Unmarshal replaces interface{} types instead of acting on the underlying type,Documentation NeedsDecision,"Please answer these questions before submitting your issue. Thanks! + +### What version of Go are you using (`go version`)? +go version go1.8.3 darwin/amd64 + +### What operating system and processor architecture are you using (`go env`)? +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" + +### What did you do? + +Unmarshal to existing `map[string]interface{}` that is hidden behind an `interface{}`: +https://play.golang.org/p/kgaRznDOwb +```golang +var test interface{} +if err := json.Unmarshal([]byte(`{""A"": ""B""}`), &test); err != nil { + panic(err) +} +fmt.Printf(""First:\n %+v\n"", test) + +if err := json.Unmarshal([]byte(`{""C"": ""D""}`), &test); err != nil { + panic(err) +} +fmt.Printf(""Second:\n %+v\n"", test) +``` + +### What did you expect to see? + +First: + map[A:B] +Second: + map[A:B C:D] + +According to docs: + +> To unmarshal JSON into an interface value, Unmarshal stores one of these in the interface value: +> ... +> map[string]interface{}, for JSON objects + +> To unmarshal a JSON object into a map, Unmarshal first establishes a map to use. If the map is nil, Unmarshal allocates a new map. Otherwise Unmarshal reuses the existing map, keeping existing entries. + +I expect unmarshal to reuse the existing map, instead of replacing it. + +### What did you see instead? +First: + map[A:B] +Second: + map[C:D] + +",1.0,"encoding/json: Unmarshal replaces interface{} types instead of acting on the underlying type - Please answer these questions before submitting your issue. Thanks! + +### What version of Go are you using (`go version`)? +go version go1.8.3 darwin/amd64 + +### What operating system and processor architecture are you using (`go env`)? +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" + +### What did you do? + +Unmarshal to existing `map[string]interface{}` that is hidden behind an `interface{}`: +https://play.golang.org/p/kgaRznDOwb +```golang +var test interface{} +if err := json.Unmarshal([]byte(`{""A"": ""B""}`), &test); err != nil { + panic(err) +} +fmt.Printf(""First:\n %+v\n"", test) + +if err := json.Unmarshal([]byte(`{""C"": ""D""}`), &test); err != nil { + panic(err) +} +fmt.Printf(""Second:\n %+v\n"", test) +``` + +### What did you expect to see? + +First: + map[A:B] +Second: + map[A:B C:D] + +According to docs: + +> To unmarshal JSON into an interface value, Unmarshal stores one of these in the interface value: +> ... +> map[string]interface{}, for JSON objects + +> To unmarshal a JSON object into a map, Unmarshal first establishes a map to use. If the map is nil, Unmarshal allocates a new map. Otherwise Unmarshal reuses the existing map, keeping existing entries. + +I expect unmarshal to reuse the existing map, instead of replacing it. + +### What did you see instead? +First: + map[A:B] +Second: + map[C:D] + +",1,encoding json unmarshal replaces interface types instead of acting on the underlying type please answer these questions before submitting your issue thanks what version of go are you using go version go version darwin what operating system and processor architecture are you using go env goarch gobin goexe gohostarch gohostos darwin goos darwin what did you do unmarshal to existing map interface that is hidden behind an interface golang var test interface if err json unmarshal byte a b test err nil panic err fmt printf first n v n test if err json unmarshal byte c d test err nil panic err fmt printf second n v n test what did you expect to see first map second map according to docs to unmarshal json into an interface value unmarshal stores one of these in the interface value map interface for json objects to unmarshal a json object into a map unmarshal first establishes a map to use if the map is nil unmarshal allocates a new map otherwise unmarshal reuses the existing map keeping existing entries i expect unmarshal to reuse the existing map instead of replacing it what did you see instead first map second map ,1 +62996,8650730769.0,IssuesEvent,2018-11-26 23:43:33,golang/go,https://api.github.com/repos/golang/go,closed,doc: memclrNoHeapPointers documentation looks strange,Documentation,"https://golang.org/pkg/runtime/?m=all#memclrNoHeapPointers +
[...]
++ TODO: https://golang.org/cl/250039: set Content-Length:0 for empty PATCH requests as with POST, PATCH +
++ TODO: https://golang.org/cl/249440: match http scheme when selecting http_proxy +
+[...]
++ TODO: https://golang.org/cl/250039: set Content-Length:0 for empty PATCH requests as with POST, PATCH +
++ TODO: https://golang.org/cl/249440: match http scheme when selecting http_proxy +
++$ go version +go version go1.14.6 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +
+package main
+import ""context""
+import ""net""
+func GoogleDNSDialer(ctx context.Context, network, address string) (net.Conn, error) {
+ d := net.Dialer{}
+ return d.DialContext(ctx, ""udp"", ""8.8.8.8:53"")
+}
+var local_resolver net.Resolver = net.Resolver{
+ Dial: GoogleDNSDialer,
+}
+func LocalLookupIP(name string) ([]net.IP, error) {
+ return local_resolver.LookupIP(context.Background(), ""ip"", name)
+}
+
+
++go build ++### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/thierryfournier/Library/Caches/go-build"" +GOENV=""/Users/thierryfournier/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/thierryfournier/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/_d/zs7l5ldx1r94fn_qh1zvn1rw0000gn/T/go-build235743352=/tmp/go-build -gno-record-gcc-switches -fno-common"" + + +
+$ go version +go version go1.14.6 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +
+package main
+import ""context""
+import ""net""
+func GoogleDNSDialer(ctx context.Context, network, address string) (net.Conn, error) {
+ d := net.Dialer{}
+ return d.DialContext(ctx, ""udp"", ""8.8.8.8:53"")
+}
+var local_resolver net.Resolver = net.Resolver{
+ Dial: GoogleDNSDialer,
+}
+func LocalLookupIP(name string) ([]net.IP, error) {
+ return local_resolver.LookupIP(context.Background(), ""ip"", name)
+}
+
+
++go build ++### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/thierryfournier/Library/Caches/go-build"" +GOENV=""/Users/thierryfournier/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/thierryfournier/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/_d/zs7l5ldx1r94fn_qh1zvn1rw0000gn/T/go-build235743352=/tmp/go-build -gno-record-gcc-switches -fno-common"" + + +
What does 'go version' print? +go version devel +5b9ac653acf6 Mon May 19 22:57:59 2014 -0400 darwin/amd64 + +What steps reproduce the problem? +If possible, include a link to a program on play.golang.org. + +1. Go to $GOROOT/src/cmd/6l/6.out.h +2. According to http://golang.org/doc/asm#architectures , this file contains a list of +all the assembler instructions Go recognizes. +3. No fused-multiply-add instructions are in the list. + +Please provide any additional information below. + +Using FMA allows for several faster and more accurate versions of several algorithms. My +current main use case is polynomial evaluation (Horner's scheme and Estrin's scheme are +both built on FMA), but another very important one is matrix multiplication. Adding at +least a subset of the FMA instructions available on newer AMD and Intel CPUs (available +on PowerPC since at least the 600 series) would improve the ability of performance +minded coders and compiler optimization writers to make faster running code. + +For instance, a more accurate version of the update in the Mandelbrot set is: +if the starting point is Cr + i*Ci (and halfCi = 0.5 * Ci) +Zr, Zi = fma( Zr - Zi, Zr + Zi, Cr ), 2 * fma( Zr, Zi, halfCi ) + +The update to Zr is likely slower than what is presently done for the The Computer +Language Benchmarks Game, but an fma based update to Zi would definitely speed things up. + +Granted, the speedup would only materialize when issue #4978 ( +https://golang.org/issue/4978 ) is resolved, but having code in +useful libraries in place to take advantage of that optimization would be nice instead +of having to recode everything afterwords. + +To that end, I would request exposing at least the following (would do it myself if I +could find an understandable listing of the opcodes and documentation on how to add them +to the compiler): + +For greatest compatibility with AMD chips, 4 operand forms ( from +http://en.wikipedia.org/wiki/X86_instruction_listings#FMA_instructions ): +VFMADDPD, VFMADDPS, VFMADDSD, VFMADDSS. + +And for Intel chips, the 3 operand forms ( from Vol. 1 14-21 of Intel's developer's +manual: +http://www.intel.com/content/www/us/en/processors/architectures-software-developer-manuals.html?iid=tech_vt_tech+64-32_manuals +): +VFMADD231PD, VFMADD231PS, VFMADD231SD, VFMADD231SS + +All of the other operations are permutations of minus signs applied to these (and which +register gets clobbered for the 3 op version - the one I'm requesting is the one that +works best with polynomial evaluation, naturally). + +Solving this issue would also make issue #681 more straightforward ( +https://golang.org/issue/681 ), although even having the opcodes +would be enough for that one.+",True,"cmd/internal/obj/x86: add fma - by **odysseus9672**: + +
What does 'go version' print? +go version devel +5b9ac653acf6 Mon May 19 22:57:59 2014 -0400 darwin/amd64 + +What steps reproduce the problem? +If possible, include a link to a program on play.golang.org. + +1. Go to $GOROOT/src/cmd/6l/6.out.h +2. According to http://golang.org/doc/asm#architectures , this file contains a list of +all the assembler instructions Go recognizes. +3. No fused-multiply-add instructions are in the list. + +Please provide any additional information below. + +Using FMA allows for several faster and more accurate versions of several algorithms. My +current main use case is polynomial evaluation (Horner's scheme and Estrin's scheme are +both built on FMA), but another very important one is matrix multiplication. Adding at +least a subset of the FMA instructions available on newer AMD and Intel CPUs (available +on PowerPC since at least the 600 series) would improve the ability of performance +minded coders and compiler optimization writers to make faster running code. + +For instance, a more accurate version of the update in the Mandelbrot set is: +if the starting point is Cr + i*Ci (and halfCi = 0.5 * Ci) +Zr, Zi = fma( Zr - Zi, Zr + Zi, Cr ), 2 * fma( Zr, Zi, halfCi ) + +The update to Zr is likely slower than what is presently done for the The Computer +Language Benchmarks Game, but an fma based update to Zi would definitely speed things up. + +Granted, the speedup would only materialize when issue #4978 ( +https://golang.org/issue/4978 ) is resolved, but having code in +useful libraries in place to take advantage of that optimization would be nice instead +of having to recode everything afterwords. + +To that end, I would request exposing at least the following (would do it myself if I +could find an understandable listing of the opcodes and documentation on how to add them +to the compiler): + +For greatest compatibility with AMD chips, 4 operand forms ( from +http://en.wikipedia.org/wiki/X86_instruction_listings#FMA_instructions ): +VFMADDPD, VFMADDPS, VFMADDSD, VFMADDSS. + +And for Intel chips, the 3 operand forms ( from Vol. 1 14-21 of Intel's developer's +manual: +http://www.intel.com/content/www/us/en/processors/architectures-software-developer-manuals.html?iid=tech_vt_tech+64-32_manuals +): +VFMADD231PD, VFMADD231PS, VFMADD231SD, VFMADD231SS + +All of the other operations are permutations of minus signs applied to these (and which +register gets clobbered for the 3 op version - the one I'm requesting is the one that +works best with polynomial evaluation, naturally). + +Solving this issue would also make issue #681 more straightforward ( +https://golang.org/issue/681 ), although even having the opcodes +would be enough for that one.+",0,cmd internal obj add fma by what does go version print go version devel mon may darwin what steps reproduce the problem if possible include a link to a program on play golang org go to goroot src cmd out h according to a href this file contains a list of all the assembler instructions go recognizes no fused multiply add instructions are in the list please provide any additional information below using fma allows for several faster and more accurate versions of several algorithms my current main use case is polynomial evaluation horner s scheme and estrin s scheme are both built on fma but another very important one is matrix multiplication adding at least a subset of the fma instructions available on newer amd and intel cpus available on powerpc since at least the series would improve the ability of performance minded coders and compiler optimization writers to make faster running code for instance a more accurate version of the update in the mandelbrot set is if the starting point is cr i ci and halfci ci zr zi fma zr zi zr zi cr fma zr zi halfci the update to zr is likely slower than what is presently done for the the computer language benchmarks game but an fma based update to zi would definitely speed things up granted the speedup would only materialize when a href is resolved but having code in useful libraries in place to take advantage of that optimization would be nice instead of having to recode everything afterwords to that end i would request exposing at least the following would do it myself if i could find an understandable listing of the opcodes and documentation on how to add them to the compiler for greatest compatibility with amd chips operand forms from a href vfmaddpd vfmaddps vfmaddsd vfmaddss and for intel chips the operand forms from vol of intel s developer s manual a href all of the other operations are permutations of minus signs applied to these and which register gets clobbered for the op version the one i m requesting is the one that works best with polynomial evaluation naturally solving this issue would also make more straightforward a href although even having the opcodes would be enough for that one ,0 +5864,2981785951.0,IssuesEvent,2015-07-17 05:31:30,golang/go,https://api.github.com/repos/golang/go,closed,"cmd/go,cmd/trace: document the trace command",Documentation,"go help testflag does not mention the -trace flag + +The output of go tool trace -help is unhelpful: + +Usage of 'go tool trace': +Given a trace file produced by 'go test': + go test -trace=trace.out pkg + +Open a web browser displaying trace: + go tool trace [flags] pkg.test trace.out + +Flags: + -http=addr: HTTP service address (e.g., ':6060') + +Also, shortly after the 1.5 release, there should be a blog post about the feature. +",1.0,"cmd/go,cmd/trace: document the trace command - go help testflag does not mention the -trace flag + +The output of go tool trace -help is unhelpful: + +Usage of 'go tool trace': +Given a trace file produced by 'go test': + go test -trace=trace.out pkg + +Open a web browser displaying trace: + go tool trace [flags] pkg.test trace.out + +Flags: + -http=addr: HTTP service address (e.g., ':6060') + +Also, shortly after the 1.5 release, there should be a blog post about the feature. +",1,cmd go cmd trace document the trace command go help testflag does not mention the trace flag the output of go tool trace help is unhelpful usage of go tool trace given a trace file produced by go test go test trace trace out pkg open a web browser displaying trace go tool trace pkg test trace out flags http addr http service address e g also shortly after the release there should be a blog post about the feature ,1 +59422,8362833451.0,IssuesEvent,2018-10-03 17:59:23,golang/go,https://api.github.com/repos/golang/go,closed,proposal: go/doc: package-level functions should also be listed at the beginning of package doc page,Documentation Proposal,"It looks some package-level functions are listed with the methods of the return types of these functions instead of at the beginning of the package doc page from some version. However I find doing this is often very inconvenient for package users to find the desired package-level functions. For example, the `http.Get`, `http.Post`, etc functions are all listed under the `http.Response` type now. It is really hard to a new user to find out what global functions a package provides. + + I can't say doing this is always bad, so I propose that such package-level functions should be listed both at the beginning of the package doc page and under the return types. +",1.0,"proposal: go/doc: package-level functions should also be listed at the beginning of package doc page - It looks some package-level functions are listed with the methods of the return types of these functions instead of at the beginning of the package doc page from some version. However I find doing this is often very inconvenient for package users to find the desired package-level functions. For example, the `http.Get`, `http.Post`, etc functions are all listed under the `http.Response` type now. It is really hard to a new user to find out what global functions a package provides. + + I can't say doing this is always bad, so I propose that such package-level functions should be listed both at the beginning of the package doc page and under the return types. +",1,proposal go doc package level functions should also be listed at the beginning of package doc page it looks some package level functions are listed with the methods of the return types of these functions instead of at the beginning of the package doc page from some version however i find doing this is often very inconvenient for package users to find the desired package level functions for example the http get http post etc functions are all listed under the http response type now it is really hard to a new user to find out what global functions a package provides i can t say doing this is always bad so i propose that such package level functions should be listed both at the beginning of the package doc page and under the return types ,1 +263791,19975830588.0,IssuesEvent,2022-01-29 03:54:07,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: update -trimpath documentation,Documentation help wanted NeedsFix," + +### What version of Go are you using (`go version`)? + +
+$ go version +go1.18beta1 ++ + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/hakim/Library/Caches/go-build"" +GOENV=""/Users/hakim/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/hakim/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/hakim/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/Users/hakim/sdk/go1.18beta1"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/Users/hakim/sdk/go1.18beta1/pkg/tool/darwin_amd64"" +GOVCS="""" +GOVERSION=""go1.18beta1"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/hakim/ww/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/bw/6r6k9d113sv1_vvzk_1kfxbm001py5/T/go-build1609535835=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ go version +go1.18beta1 ++ + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/hakim/Library/Caches/go-build"" +GOENV=""/Users/hakim/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/hakim/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/hakim/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/Users/hakim/sdk/go1.18beta1"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/Users/hakim/sdk/go1.18beta1/pkg/tool/darwin_amd64"" +GOVCS="""" +GOVERSION=""go1.18beta1"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/hakim/ww/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/bw/6r6k9d113sv1_vvzk_1kfxbm001py5/T/go-build1609535835=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ go version +go version go1.20.1 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Uncertain + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOOS=""darwin"" +
+BenchmarkSwapIntPtrs-8 842213125 1.422 ns/op +BenchmarkSwapAny-8 749056459 1.575 ns/op +BenchmarkSwapAnyAsUintptrs-8 812162583 1.471 ns/op ++ +My assumption is that the compiler should get the performance of the 3rd benchmark in which I use unsafe to force my expected asm to be generated, but is represented here as the 2nd benchmark. + +### What did you expect to see? + +For the code
arr[0], arr[1] = arr[1], arr[0]where arr is an array of the empty interface, I expected to see just one write barrier check, just as I do for the (paraphrased) asm for swapping a normal pointer type. + +
+MOVQ the interfaces into registers +MOVQ both interface *type* parts into their new positions in the array +CMPL runtime.writeBarrier +MOVQ both interface *value* parts into their new positions in the array ++ +### What did you see instead? + +I unexpectedly found *two* writebarrier checks, where the asm was writing the values of each interface with separate writebarrier checks, like this (paraphrased) asm. + +
+MOVQ the interfaces into registers +MOVQ both interface *type* parts into their new positions in the slice +CMPL runtime.writeBarrier +MOVQ one interface *value* into its new position in the slice +CMPL runtime.writeBarrier +MOVQ the other interface *value* into its new position in the slice ++ +By using unsafe to treat the [2]any as a [4]uintptr and doing 2 sets of swaps, I was able to observe the asm doing just 1 writebarrier check. I currently believe that one check has the same semantics as two checks (in regards to concurrent gc sweep correctness), and this might be incorrect. I'm almost certain however it has the same semantics in regards to concurrent observability promises.",True,"cmd/compile: Swapping elements of a `[2]any` uses 2 separate writebarriers - + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.20.1 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Uncertain + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOOS=""darwin"" +
+BenchmarkSwapIntPtrs-8 842213125 1.422 ns/op +BenchmarkSwapAny-8 749056459 1.575 ns/op +BenchmarkSwapAnyAsUintptrs-8 812162583 1.471 ns/op ++ +My assumption is that the compiler should get the performance of the 3rd benchmark in which I use unsafe to force my expected asm to be generated, but is represented here as the 2nd benchmark. + +### What did you expect to see? + +For the code
arr[0], arr[1] = arr[1], arr[0]where arr is an array of the empty interface, I expected to see just one write barrier check, just as I do for the (paraphrased) asm for swapping a normal pointer type. + +
+MOVQ the interfaces into registers +MOVQ both interface *type* parts into their new positions in the array +CMPL runtime.writeBarrier +MOVQ both interface *value* parts into their new positions in the array ++ +### What did you see instead? + +I unexpectedly found *two* writebarrier checks, where the asm was writing the values of each interface with separate writebarrier checks, like this (paraphrased) asm. + +
+MOVQ the interfaces into registers +MOVQ both interface *type* parts into their new positions in the slice +CMPL runtime.writeBarrier +MOVQ one interface *value* into its new position in the slice +CMPL runtime.writeBarrier +MOVQ the other interface *value* into its new position in the slice ++ +By using unsafe to treat the [2]any as a [4]uintptr and doing 2 sets of swaps, I was able to observe the asm doing just 1 writebarrier check. I currently believe that one check has the same semantics as two checks (in regards to concurrent gc sweep correctness), and this might be incorrect. I'm almost certain however it has the same semantics in regards to concurrent observability promises.",0,cmd compile swapping elements of a any uses separate writebarriers please answer these questions before submitting your issue thanks what version of go are you using go version go version go version darwin does this issue reproduce with the latest release uncertain what operating system and processor architecture are you using go env go env output go env goarch goos darwin what did you do i was profiling some code and found that swapping elements of a slice was slower than expected i found that swapping elements if they were pointer types instead of interfaces reached the performance i expected this link shows the naive method of swapping elements and the unsafe method which produces the asm and performance i expected here are the benchmarks benchmarkswapintptrs ns op benchmarkswapany ns op benchmarkswapanyasuintptrs ns op my assumption is that the compiler should get the performance of the benchmark in which i use unsafe to force my expected asm to be generated but is represented here as the benchmark what did you expect to see for the code arr arr arr arr where arr is an array of the empty interface i expected to see just one write barrier check just as i do for the paraphrased asm for swapping a normal pointer type movq the interfaces into registers movq both interface type parts into their new positions in the array cmpl runtime writebarrier movq both interface value parts into their new positions in the array what did you see instead i unexpectedly found two writebarrier checks where the asm was writing the values of each interface with separate writebarrier checks like this paraphrased asm movq the interfaces into registers movq both interface type parts into their new positions in the slice cmpl runtime writebarrier movq one interface value into its new position in the slice cmpl runtime writebarrier movq the other interface value into its new position in the slice by using unsafe to treat the any as a uintptr and doing sets of swaps i was able to observe the asm doing just writebarrier check i currently believe that one check has the same semantics as two checks in regards to concurrent gc sweep correctness and this might be incorrect i m almost certain however it has the same semantics in regards to concurrent observability promises ,0 +35945,6515005389.0,IssuesEvent,2017-08-26 09:21:11,golang/go,https://api.github.com/repos/golang/go,closed,website: Command Documentation,Documentation,"Please answer these questions before submitting your issue. Thanks! + +### What version of Go are you using (`go version`)? +konstantin@debian:~$ go version +go version go1.8.3 linux/amd64 + +### What operating system and processor architecture are you using (`go env`)? +debian + +### What did you do? + +Read documentation on web site https://golang.org/doc/cmd + +### What did you expect to see? + +Not clear organization of ""command"": +* some ... +* full command reference + +### What did you see instead? + +Merge 2 list of commands to one solid list, like we see in page https://golang.org/pkg/ for packages and . Preliminary : +* go | Descriptions for go + * go commands | Descriptions for go commands + * go build | Descriptions for go build + * go clean | Descriptions for go clean +... + +But I want to clarify some points: +1. If we open link **go** on page https://golang.org/doc/cmd, then we will see big good information about **go doc**. But, If we open on link **full command reference** https://golang.org/doc/cmd, after that link **doc** - then we see short information. +2. On page https://golang.org/doc/cmd link **cover** ---> result documentation from X tools. But on page https://golang.org/cmd/ link **cover** ---> result looks nice. + +Please separate page https://golang.org/cmd/go/ to single small parts. + +### The reason + +Simple organization of documents is clear and easy to translate. +",1.0,"website: Command Documentation - Please answer these questions before submitting your issue. Thanks! + +### What version of Go are you using (`go version`)? +konstantin@debian:~$ go version +go version go1.8.3 linux/amd64 + +### What operating system and processor architecture are you using (`go env`)? +debian + +### What did you do? + +Read documentation on web site https://golang.org/doc/cmd + +### What did you expect to see? + +Not clear organization of ""command"": +* some ... +* full command reference + +### What did you see instead? + +Merge 2 list of commands to one solid list, like we see in page https://golang.org/pkg/ for packages and . Preliminary : +* go | Descriptions for go + * go commands | Descriptions for go commands + * go build | Descriptions for go build + * go clean | Descriptions for go clean +... + +But I want to clarify some points: +1. If we open link **go** on page https://golang.org/doc/cmd, then we will see big good information about **go doc**. But, If we open on link **full command reference** https://golang.org/doc/cmd, after that link **doc** - then we see short information. +2. On page https://golang.org/doc/cmd link **cover** ---> result documentation from X tools. But on page https://golang.org/cmd/ link **cover** ---> result looks nice. + +Please separate page https://golang.org/cmd/go/ to single small parts. + +### The reason + +Simple organization of documents is clear and easy to translate. +",1,website command documentation please answer these questions before submitting your issue thanks what version of go are you using go version konstantin debian go version go version linux what operating system and processor architecture are you using go env debian what did you do read documentation on web site what did you expect to see not clear organization of command some full command reference what did you see instead merge list of commands to one solid list like we see in page for packages and preliminary go descriptions for go go commands descriptions for go commands go build descriptions for go build go clean descriptions for go clean but i want to clarify some points if we open link go on page then we will see big good information about go doc but if we open on link full command reference after that link doc then we see short information on page link cover result documentation from x tools but on page link cover result looks nice please separate page to single small parts the reason simple organization of documents is clear and easy to translate ,1 +30085,5725524164.0,IssuesEvent,2017-04-20 16:45:41,golang/go,https://api.github.com/repos/golang/go,closed,cmd/trace: traceviewer tool doesn't work in non-chrome browsers,Documentation NeedsFix,"### What version of Go are you using (`go version`)? +go version go1.8 + +### What operating system and processor architecture are you using (`go env`)? +darwin/amd64 + +### What did you do? +Call `go tool trace trace.file` as described in https://godoc.org/cmd/trace and open the ""View trace"" link using Safari (or other non-Chrome) web browser. + +### What did you expect to see? +Expected to see the Trace viewer. + +### What did you see instead? +There is a JavaScript error, saying ""ReferenceError: Can't find variable: tr"" in the console of the browser. + +I know that the trace-viewer itself comes from [the catapult project](https://github.com/catapult-project/catapult), as well as that the project was built specifically for Chrome and/or Android, but I think it would be worth to add a notice to `cmd/trace` documentation about this fact. +",1.0,"cmd/trace: traceviewer tool doesn't work in non-chrome browsers - ### What version of Go are you using (`go version`)? +go version go1.8 + +### What operating system and processor architecture are you using (`go env`)? +darwin/amd64 + +### What did you do? +Call `go tool trace trace.file` as described in https://godoc.org/cmd/trace and open the ""View trace"" link using Safari (or other non-Chrome) web browser. + +### What did you expect to see? +Expected to see the Trace viewer. + +### What did you see instead? +There is a JavaScript error, saying ""ReferenceError: Can't find variable: tr"" in the console of the browser. + +I know that the trace-viewer itself comes from [the catapult project](https://github.com/catapult-project/catapult), as well as that the project was built specifically for Chrome and/or Android, but I think it would be worth to add a notice to `cmd/trace` documentation about this fact. +",1,cmd trace traceviewer tool doesn t work in non chrome browsers what version of go are you using go version go version what operating system and processor architecture are you using go env darwin what did you do call go tool trace trace file as described in and open the view trace link using safari or other non chrome web browser what did you expect to see expected to see the trace viewer what did you see instead there is a javascript error saying referenceerror can t find variable tr in the console of the browser i know that the trace viewer itself comes from as well as that the project was built specifically for chrome and or android but i think it would be worth to add a notice to cmd trace documentation about this fact ,1 +95097,10865926874.0,IssuesEvent,2019-11-14 20:04:06,golang/go,https://api.github.com/repos/golang/go,closed,x/tools/gopls: only use import text as range for textDocument/documentLink responses ,Documentation Tools gopls,"Please answer these questions before submitting your issue. Thanks! + +#### What did you do? + +Have import statements, a mix of normal imports, aliased imports, `_` imports. + +#### What did you expect to see? + +Links which span the package path. + +#### What did you see instead? + +The links span the entire import statement, and not just the link. See: + + + +Note how the package aliases are also underlined, and even the `_` imported package. Including the quotes also feels wrong. I would personally prefer them to look like: + + + +Which is just a change to: + +```go +toProtocolLink(view, m, target, n.Path.Pos()+1, n.End()-1) +``` + +(But I'm not sure if this is the correct way to get the span of a literal, just a PoC.) + +#### Build info + +``` +golang.org/x/tools/gopls master + golang.org/x/tools/gopls@v0.1.8-0.20191113163402-bc1376d635b8 h1:xSNm5FMZDYQjehCHcVzpGm4D9oNz/+AD+C/pRROxjMk= + github.com/BurntSushi/toml@v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ= + github.com/sergi/go-diff@v1.0.0 h1:Kpca3qRNrduNnOQeazBd0ysaKrUJiIuISHxogkT9RPQ= + golang.org/x/sync@v0.0.0-20190423024810-112230192c58 h1:8gQV6CLnAEikrhgkHFbMAEhagSSnXWGV915qUMm9mrU= + golang.org/x/tools@v0.0.0-20191113163402-bc1376d635b8 h1:3xDEBhGRwlUGJue2GW3jVaqWs/HrAm+Lz4HAoQVWuJs= + golang.org/x/xerrors@v0.0.0-20190717185122-a985d3407aa7 h1:9zdDQZ7Thm29KFXgAX/+yaf3eVbP7djjWp/dXAppNCc= + honnef.co/go/tools@v0.0.1-2019.2.3 h1:3JgtbtFHMiCmsznwGVTUWbgGov+pVqnlf1dEJTNAXeM= +``` + +#### Go info + +``` +go version go1.13.4 linux/amd64 + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/jake/.cache/go-build"" +GOENV=""/home/jake/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/jake/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/jake/zikaeroh/hortbot/hortbot/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build705508798=/tmp/go-build -gno-record-gcc-switches"" +``` +",1.0,"x/tools/gopls: only use import text as range for textDocument/documentLink responses - Please answer these questions before submitting your issue. Thanks! + +#### What did you do? + +Have import statements, a mix of normal imports, aliased imports, `_` imports. + +#### What did you expect to see? + +Links which span the package path. + +#### What did you see instead? + +The links span the entire import statement, and not just the link. See: + + + +Note how the package aliases are also underlined, and even the `_` imported package. Including the quotes also feels wrong. I would personally prefer them to look like: + + + +Which is just a change to: + +```go +toProtocolLink(view, m, target, n.Path.Pos()+1, n.End()-1) +``` + +(But I'm not sure if this is the correct way to get the span of a literal, just a PoC.) + +#### Build info + +``` +golang.org/x/tools/gopls master + golang.org/x/tools/gopls@v0.1.8-0.20191113163402-bc1376d635b8 h1:xSNm5FMZDYQjehCHcVzpGm4D9oNz/+AD+C/pRROxjMk= + github.com/BurntSushi/toml@v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ= + github.com/sergi/go-diff@v1.0.0 h1:Kpca3qRNrduNnOQeazBd0ysaKrUJiIuISHxogkT9RPQ= + golang.org/x/sync@v0.0.0-20190423024810-112230192c58 h1:8gQV6CLnAEikrhgkHFbMAEhagSSnXWGV915qUMm9mrU= + golang.org/x/tools@v0.0.0-20191113163402-bc1376d635b8 h1:3xDEBhGRwlUGJue2GW3jVaqWs/HrAm+Lz4HAoQVWuJs= + golang.org/x/xerrors@v0.0.0-20190717185122-a985d3407aa7 h1:9zdDQZ7Thm29KFXgAX/+yaf3eVbP7djjWp/dXAppNCc= + honnef.co/go/tools@v0.0.1-2019.2.3 h1:3JgtbtFHMiCmsznwGVTUWbgGov+pVqnlf1dEJTNAXeM= +``` + +#### Go info + +``` +go version go1.13.4 linux/amd64 + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/jake/.cache/go-build"" +GOENV=""/home/jake/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/jake/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/jake/zikaeroh/hortbot/hortbot/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build705508798=/tmp/go-build -gno-record-gcc-switches"" +``` +",1,x tools gopls only use import text as range for textdocument documentlink responses please answer these questions before submitting your issue thanks what did you do have import statements a mix of normal imports aliased imports imports what did you expect to see links which span the package path what did you see instead the links span the entire import statement and not just the link see note how the package aliases are also underlined and even the imported package including the quotes also feels wrong i would personally prefer them to look like which is just a change to go toprotocollink view m target n path pos n end but i m not sure if this is the correct way to get the span of a literal just a poc build info golang org x tools gopls master golang org x tools gopls ad c prroxjmk github com burntsushi toml github com sergi go diff golang org x sync golang org x tools hram golang org x xerrors dxappncc honnef co go tools go info go version linux goarch gobin gocache home jake cache go build goenv home jake config go env goexe goflags gohostarch gohostos linux gonoproxy gonosumdb goos linux gopath home jake go goprivate goproxy goroot usr lib go gosumdb sum golang org gotmpdir gotooldir usr lib go pkg tool linux gccgo gccgo ar ar cc gcc cxx g cgo enabled gomod home jake zikaeroh hortbot hortbot go mod cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fmessage length fdebug prefix map tmp go tmp go build gno record gcc switches ,1 +96631,27964070311.0,IssuesEvent,2023-03-24 17:53:43,golang/go,https://api.github.com/repos/golang/go,closed,x/build/internal/task/releaselet: change the minimum Windows version in the installer,OS-Windows Builders NeedsFix release-blocker,"As proposed in #57003 and #57004, the minimum supported version of Windows will be changing for the go1.21 release. The packager configuration should reflect that change before the release. There are also various other updates that can happen to the packager script. Such as: +- Change all references of `golang.org` to `go.dev` in the packager configuration. +- Updating `DialogLeft.jpg` image as described in #57413 + +cc @golang/release ",1.0,"x/build/internal/task/releaselet: change the minimum Windows version in the installer - As proposed in #57003 and #57004, the minimum supported version of Windows will be changing for the go1.21 release. The packager configuration should reflect that change before the release. There are also various other updates that can happen to the packager script. Such as: +- Change all references of `golang.org` to `go.dev` in the packager configuration. +- Updating `DialogLeft.jpg` image as described in #57413 + +cc @golang/release ",0,x build internal task releaselet change the minimum windows version in the installer as proposed in and the minimum supported version of windows will be changing for the release the packager configuration should reflect that change before the release there are also various other updates that can happen to the packager script such as change all references of golang org to go dev in the packager configuration updating dialogleft jpg image as described in cc golang release ,0 +368846,25811084581.0,IssuesEvent,2022-12-11 21:23:31,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: better fuzzing documentation,Documentation,"The documentation was pretty sparse on fuzzing. + +First I had a tough time finding where my corpus was because no testdata dir was being generated- so I though ""aha, must be an environment variable, something like `GOFUZZCORPUS`, but. nothing. + +Then I started looking in `go help test`, took me a while to skim though and find that I needed to check out `go help testfunc` for more details only to find there was barely anything on fuzzing. + +Relevant `go help test` output: +``` +These additional files can contain test functions, benchmark functions, fuzz +tests and example functions. See 'go help testfunc' for more. +``` +Relevant `go help testfunc` output: +``` +A fuzz test is one named FuzzXxx and should have the signature, + + func FuzzXxx(f *testing.F) { ... } +// ... +The entire test file is presented as the example when it contains a single +example function, at least one other function, type, variable, or constant +declaration, and no tests, benchmarks, or fuzz tests. +``` + +There is no way to make out how the fuzzing command works from this. Please add better documentation of: +* Where the non-crashign fuzz corpus is located (GOCACHE) +* Where the crashing corpus is located +* What the differences are between both +* Fuzzing by default goes on forever +* How to add non crashing fuzz corpus to unit tests +",1.0,"cmd/go: better fuzzing documentation - The documentation was pretty sparse on fuzzing. + +First I had a tough time finding where my corpus was because no testdata dir was being generated- so I though ""aha, must be an environment variable, something like `GOFUZZCORPUS`, but. nothing. + +Then I started looking in `go help test`, took me a while to skim though and find that I needed to check out `go help testfunc` for more details only to find there was barely anything on fuzzing. + +Relevant `go help test` output: +``` +These additional files can contain test functions, benchmark functions, fuzz +tests and example functions. See 'go help testfunc' for more. +``` +Relevant `go help testfunc` output: +``` +A fuzz test is one named FuzzXxx and should have the signature, + + func FuzzXxx(f *testing.F) { ... } +// ... +The entire test file is presented as the example when it contains a single +example function, at least one other function, type, variable, or constant +declaration, and no tests, benchmarks, or fuzz tests. +``` + +There is no way to make out how the fuzzing command works from this. Please add better documentation of: +* Where the non-crashign fuzz corpus is located (GOCACHE) +* Where the crashing corpus is located +* What the differences are between both +* Fuzzing by default goes on forever +* How to add non crashing fuzz corpus to unit tests +",1,cmd go better fuzzing documentation the documentation was pretty sparse on fuzzing first i had a tough time finding where my corpus was because no testdata dir was being generated so i though aha must be an environment variable something like gofuzzcorpus but nothing then i started looking in go help test took me a while to skim though and find that i needed to check out go help testfunc for more details only to find there was barely anything on fuzzing relevant go help test output these additional files can contain test functions benchmark functions fuzz tests and example functions see go help testfunc for more relevant go help testfunc output a fuzz test is one named fuzzxxx and should have the signature func fuzzxxx f testing f the entire test file is presented as the example when it contains a single example function at least one other function type variable or constant declaration and no tests benchmarks or fuzz tests there is no way to make out how the fuzzing command works from this please add better documentation of where the non crashign fuzz corpus is located gocache where the crashing corpus is located what the differences are between both fuzzing by default goes on forever how to add non crashing fuzz corpus to unit tests ,1 +57637,14175959436.0,IssuesEvent,2020-11-12 22:32:50,golang/go,https://api.github.com/repos/golang/go,closed,math/big: panic during recursive division of very large numbers,Security,"A number of math/big.Int methods (Div, Exp, DivMod, Quo, Rem, QuoRem, Mod, ModInverse, ModSqrt, Jacobi, and GCD) can panic when provided crafted large inputs. For the panic to happen, the divisor or modulo argument must be larger than 3168 bits (on 32-bit architectures) or 6336 bits (on 64-bit architectures). Multiple math/big.Rat methods are similarly affected. + +crypto/rsa.VerifyPSS, crypto/rsa.VerifyPKCS1v15, and crypto/dsa.Verify may panic when provided crafted public keys and signatures. crypto/ecdsa and crypto/elliptic operations may only be affected if custom CurveParams with unusually large field sizes (several times larger than the largest supported curve, P-521) are in use. Using crypto/x509.Verify on a crafted X.509 certificate chain can lead to a panic, even if the certificates don’t chain to a trusted root. The chain can be delivered via a crypto/tls connection to a client, or to a server that accepts and verifies client certificates. net/http clients can be made to crash by an HTTPS server, while net/http servers that accept client certificates will recover the panic and are unaffected. + +Moreover, an application might crash invoking crypto/x509.(*CertificateRequest).CheckSignature on an X.509 certificate request or during a golang.org/x/crypto/otr conversation. Parsing a golang.org/x/crypto/openpgp Entity or verifying a signature may crash. Finally, a golang.org/x/crypto/ssh client can panic due to a malformed host key, while a server could panic if either PublicKeyCallback accepts a malformed public key, or if IsUserAuthority accepts a certificate with a malformed public key. + +Thanks to the Go Ethereum team and the OSS-Fuzz project for reporting this. Thanks to Rémy Oudompheng and Robert Griesemer for their help developing and validating the fix. + +This issue is CVE-2020-28362.",True,"math/big: panic during recursive division of very large numbers - A number of math/big.Int methods (Div, Exp, DivMod, Quo, Rem, QuoRem, Mod, ModInverse, ModSqrt, Jacobi, and GCD) can panic when provided crafted large inputs. For the panic to happen, the divisor or modulo argument must be larger than 3168 bits (on 32-bit architectures) or 6336 bits (on 64-bit architectures). Multiple math/big.Rat methods are similarly affected. + +crypto/rsa.VerifyPSS, crypto/rsa.VerifyPKCS1v15, and crypto/dsa.Verify may panic when provided crafted public keys and signatures. crypto/ecdsa and crypto/elliptic operations may only be affected if custom CurveParams with unusually large field sizes (several times larger than the largest supported curve, P-521) are in use. Using crypto/x509.Verify on a crafted X.509 certificate chain can lead to a panic, even if the certificates don’t chain to a trusted root. The chain can be delivered via a crypto/tls connection to a client, or to a server that accepts and verifies client certificates. net/http clients can be made to crash by an HTTPS server, while net/http servers that accept client certificates will recover the panic and are unaffected. + +Moreover, an application might crash invoking crypto/x509.(*CertificateRequest).CheckSignature on an X.509 certificate request or during a golang.org/x/crypto/otr conversation. Parsing a golang.org/x/crypto/openpgp Entity or verifying a signature may crash. Finally, a golang.org/x/crypto/ssh client can panic due to a malformed host key, while a server could panic if either PublicKeyCallback accepts a malformed public key, or if IsUserAuthority accepts a certificate with a malformed public key. + +Thanks to the Go Ethereum team and the OSS-Fuzz project for reporting this. Thanks to Rémy Oudompheng and Robert Griesemer for their help developing and validating the fix. + +This issue is CVE-2020-28362.",0,math big panic during recursive division of very large numbers a number of math big int methods div exp divmod quo rem quorem mod modinverse modsqrt jacobi and gcd can panic when provided crafted large inputs for the panic to happen the divisor or modulo argument must be larger than bits on bit architectures or bits on bit architectures multiple math big rat methods are similarly affected crypto rsa verifypss crypto rsa and crypto dsa verify may panic when provided crafted public keys and signatures crypto ecdsa and crypto elliptic operations may only be affected if custom curveparams with unusually large field sizes several times larger than the largest supported curve p are in use using crypto verify on a crafted x certificate chain can lead to a panic even if the certificates don’t chain to a trusted root the chain can be delivered via a crypto tls connection to a client or to a server that accepts and verifies client certificates net http clients can be made to crash by an https server while net http servers that accept client certificates will recover the panic and are unaffected moreover an application might crash invoking crypto certificaterequest checksignature on an x certificate request or during a golang org x crypto otr conversation parsing a golang org x crypto openpgp entity or verifying a signature may crash finally a golang org x crypto ssh client can panic due to a malformed host key while a server could panic if either publickeycallback accepts a malformed public key or if isuserauthority accepts a certificate with a malformed public key thanks to the go ethereum team and the oss fuzz project for reporting this thanks to rémy oudompheng and robert griesemer for their help developing and validating the fix this issue is cve ,0 +55356,7977941741.0,IssuesEvent,2018-07-17 16:44:55,golang/go,https://api.github.com/repos/golang/go,closed,doc: vet check included in gc needs to be documented,Documentation NeedsFix,"vet check seems to be included in gc by default but not documented in go1.11 release note yet (sorry, I didn't search enough to find related issue/proposal/change to link yet). + +This behavior change resulted in build-failures for codes that don't pass vet currently and could be misunderstood as a regression in go1.11. For example, with go1.11 (or tip), go test on +github.com/spf13/cobra will fail due to failure to pass vet check. + +
+$ go version +go version devel +257d6c48e0 Thu Jun 28 03:12:01 2018 +0000 linux/amd64 + +$ go test github.com/spf13/cobra +# github.com/spf13/cobra +../github.com/spf13/cobra/command_test.go:1105:3: parentPersPreArgs declared but not used +../github.com/spf13/cobra/command_test.go:1109:3: parentPersPostArgs declared but not used +vet: typecheck failures +FAIL github.com/spf13/cobra [build failed] ++ +BTW, the vet error message is confusing because the parentPersPreArgs and parentPersPostArgs in the test are 'used' (literally). But for the purpose of vet check, the vars are 'not used' because they are never read. ",1.0,"doc: vet check included in gc needs to be documented - vet check seems to be included in gc by default but not documented in go1.11 release note yet (sorry, I didn't search enough to find related issue/proposal/change to link yet). + +This behavior change resulted in build-failures for codes that don't pass vet currently and could be misunderstood as a regression in go1.11. For example, with go1.11 (or tip), go test on +github.com/spf13/cobra will fail due to failure to pass vet check. + +
+$ go version +go version devel +257d6c48e0 Thu Jun 28 03:12:01 2018 +0000 linux/amd64 + +$ go test github.com/spf13/cobra +# github.com/spf13/cobra +../github.com/spf13/cobra/command_test.go:1105:3: parentPersPreArgs declared but not used +../github.com/spf13/cobra/command_test.go:1109:3: parentPersPostArgs declared but not used +vet: typecheck failures +FAIL github.com/spf13/cobra [build failed] ++ +BTW, the vet error message is confusing because the parentPersPreArgs and parentPersPostArgs in the test are 'used' (literally). But for the purpose of vet check, the vars are 'not used' because they are never read. ",1,doc vet check included in gc needs to be documented vet check seems to be included in gc by default but not documented in release note yet sorry i didn t search enough to find related issue proposal change to link yet this behavior change resulted in build failures for codes that don t pass vet currently and could be misunderstood as a regression in for example with or tip go test on github com cobra will fail due to failure to pass vet check go version go version devel thu jun linux go test github com cobra github com cobra github com cobra command test go parentperspreargs declared but not used github com cobra command test go parentperspostargs declared but not used vet typecheck failures fail github com cobra btw the vet error message is confusing because the parentperspreargs and parentperspostargs in the test are used literally but for the purpose of vet check the vars are not used because they are never read ,1 +125083,10336369033.0,IssuesEvent,2019-09-03 12:50:07,golang/go,https://api.github.com/repos/golang/go,opened,x/tools/internal/imports: test frequently times out on `dragonfly-amd64` builder,Testing,"The test for `golang.org/x/tools/internal/imports` seems to be timing out on around 25% of runs on the `dragonfly-amd64` builder. + +Example logs: +* https://build.golang.org/log/e697ac9c8ea86c4aa83321b80d9c1371c7c630fb +* https://build.golang.org/log/7a7c78010de15f81e9b3411c020e1048006e39e2 +* https://build.golang.org/log/606423ffa1cb92cf42e35073469762d25b9e282c +* https://build.golang.org/log/ed9923ceaf868e900d12bf6e7c296d916c7f6a2c + +The `dragonfly-amd64` builder seems to be a bit underpowered in general (see also #29583 and #25796). Perhaps we should set `GO_TEST_TIMEOUT_SCALE=2` in its environment and see if that improves the situation for `x/tools`? + +CC @matloob @ianthehat @tdfbsd",1.0,"x/tools/internal/imports: test frequently times out on `dragonfly-amd64` builder - The test for `golang.org/x/tools/internal/imports` seems to be timing out on around 25% of runs on the `dragonfly-amd64` builder. + +Example logs: +* https://build.golang.org/log/e697ac9c8ea86c4aa83321b80d9c1371c7c630fb +* https://build.golang.org/log/7a7c78010de15f81e9b3411c020e1048006e39e2 +* https://build.golang.org/log/606423ffa1cb92cf42e35073469762d25b9e282c +* https://build.golang.org/log/ed9923ceaf868e900d12bf6e7c296d916c7f6a2c + +The `dragonfly-amd64` builder seems to be a bit underpowered in general (see also #29583 and #25796). Perhaps we should set `GO_TEST_TIMEOUT_SCALE=2` in its environment and see if that improves the situation for `x/tools`? + +CC @matloob @ianthehat @tdfbsd",0,x tools internal imports test frequently times out on dragonfly builder the test for golang org x tools internal imports seems to be timing out on around of runs on the dragonfly builder example logs the dragonfly builder seems to be a bit underpowered in general see also and perhaps we should set go test timeout scale in its environment and see if that improves the situation for x tools cc matloob ianthehat tdfbsd,0 +40196,6803271050.0,IssuesEvent,2017-11-02 23:51:53,golang/go,https://api.github.com/repos/golang/go,closed,net/http: clarify whether Requests can be reused,Documentation,"Re-using requests is currently unreliable. + +If that's intended, then I think it should be documented. If not intended, then I can provide steps to reproduce.",1.0,"net/http: clarify whether Requests can be reused - Re-using requests is currently unreliable. + +If that's intended, then I think it should be documented. If not intended, then I can provide steps to reproduce.",1,net http clarify whether requests can be reused re using requests is currently unreliable if that s intended then i think it should be documented if not intended then i can provide steps to reproduce ,1 +69716,17795844677.0,IssuesEvent,2021-08-31 22:05:28,golang/go,https://api.github.com/repos/golang/go,closed,x/build: upgrade the IOS version on host-ios-arm64-corellium-ios,Builders NeedsFix,"We've recently discovered that the builder used to test IOS development is running an older version of IOS. Would it be possible to update the IOS version we test against in `host-ios-arm64-corellium-ios` to IOS 14? @znly + +@golang/release +/cc @aclements ",1.0,"x/build: upgrade the IOS version on host-ios-arm64-corellium-ios - We've recently discovered that the builder used to test IOS development is running an older version of IOS. Would it be possible to update the IOS version we test against in `host-ios-arm64-corellium-ios` to IOS 14? @znly + +@golang/release +/cc @aclements ",0,x build upgrade the ios version on host ios corellium ios we ve recently discovered that the builder used to test ios development is running an older version of ios would it be possible to update the ios version we test against in host ios corellium ios to ios znly golang release cc aclements ,0 +190540,15242613860.0,IssuesEvent,2021-02-19 10:06:33,golang/go,https://api.github.com/repos/golang/go,closed,x/website: merge module doc changes as part of Go 1.16 release,Documentation NeedsFix,"1.16 introduces a `retract` directive. The new directive is not mentioned in the [Go Modules Reference](https://tip.golang.org/ref/mod#go-mod-file-grammar). The [CL adding the doc](https://go-review.googlesource.com/c/website/+/286952) will need to be merged before the 1.16 release (currently has a merge conflict). + +In 1.16, go install will accepts arguments with version suffixes (`go install pkg@version`). The [CL adding the relevant doc](https://go-review.googlesource.com/c/website/+/285452) will need to be merged before the 1.16 release (currently has a merge conflict, and unresolved comments). + +Filing an issue just to be sure this is on someone's radar. + +cc @dmitshur @bcmills ",1.0,"x/website: merge module doc changes as part of Go 1.16 release - 1.16 introduces a `retract` directive. The new directive is not mentioned in the [Go Modules Reference](https://tip.golang.org/ref/mod#go-mod-file-grammar). The [CL adding the doc](https://go-review.googlesource.com/c/website/+/286952) will need to be merged before the 1.16 release (currently has a merge conflict). + +In 1.16, go install will accepts arguments with version suffixes (`go install pkg@version`). The [CL adding the relevant doc](https://go-review.googlesource.com/c/website/+/285452) will need to be merged before the 1.16 release (currently has a merge conflict, and unresolved comments). + +Filing an issue just to be sure this is on someone's radar. + +cc @dmitshur @bcmills ",1,x website merge module doc changes as part of go release introduces a retract directive the new directive is not mentioned in the the will need to be merged before the release currently has a merge conflict in go install will accepts arguments with version suffixes go install pkg version the will need to be merged before the release currently has a merge conflict and unresolved comments filing an issue just to be sure this is on someone s radar cc dmitshur bcmills ,1 +16695,9488575748.0,IssuesEvent,2019-04-22 19:57:33,golang/go,https://api.github.com/repos/golang/go,opened,cmd/compile: apparent extraneous inlmarks,NeedsInvestigation Performance,"```go +package p + +import ""encoding/binary"" + +func f(key [4]byte, b []byte) { + k := binary.LittleEndian.Uint32(key[:]) + v := binary.LittleEndian.Uint32(b) + binary.LittleEndian.PutUint32(b, v^k) +} +``` + +generates: + +``` +"""".f STEXT nosplit size=62 args=0x20 locals=0x18 + 0x0000 00000 (x.go:5) TEXT """".f(SB), NOSPLIT|ABIInternal, $24-32 + 0x0000 00000 (x.go:5) SUBQ $24, SP + 0x0004 00004 (x.go:5) MOVQ BP, 16(SP) + 0x0009 00009 (x.go:5) LEAQ 16(SP), BP + 0x000e 00014 (x.go:5) FUNCDATA $0, gclocals·09cf9819fc716118c209c2d2155a3632(SB) + 0x000e 00014 (x.go:5) FUNCDATA $1, gclocals·69c1753bd5f81501d95132d08af04464(SB) + 0x000e 00014 (x.go:5) FUNCDATA $2, gclocals·9fb7f0986f647f17cb53dda1484e0f7a(SB) + 0x000e 00014 (x.go:6) PCDATA $0, $0 + 0x000e 00014 (x.go:6) PCDATA $1, $0 + 0x000e 00014 (x.go:6) XCHGL AX, AX + 0x000f 00015 (x.go:7) XCHGL AX, AX + 0x0010 00016 (x.go:6) MOVL """".key+32(SP), DX + 0x0014 00020 ($GOROOT/src/encoding/binary/binary.go:63) MOVQ """".b+48(SP), CX + 0x0019 00025 ($GOROOT/src/encoding/binary/binary.go:63) CMPQ CX, $3 + 0x001d 00029 ($GOROOT/src/encoding/binary/binary.go:63) JLS 51 + 0x001f 00031 (x.go:8) XCHGL AX, AX + 0x0020 00032 (x.go:8) PCDATA $0, $1 + 0x0020 00032 (x.go:8) PCDATA $1, $1 + 0x0020 00032 (x.go:8) MOVQ """".b+40(SP), AX + 0x0025 00037 (x.go:8) XORL (AX), DX + 0x0027 00039 ($GOROOT/src/encoding/binary/binary.go:72) PCDATA $0, $0 + 0x0027 00039 ($GOROOT/src/encoding/binary/binary.go:72) MOVL DX, (AX) + 0x0029 00041 (
+ TODO: https://golang.org/cl/264460: expose std via new Default function +
++ TODO: https://golang.org/cl/264460: expose std via new Default function +
+TestPacketConn seems to be flaky. It has been for a while. + +TestPacketConn typically runs in milliseconds, which makes the fact that the test +sometimes takes up to 8 seconds in some runs quite strange. + +29 March: + +--- FAIL: TestPacketConn-37 (8.73 seconds) +packetconn_test.go:101: PacketConn.WriteTo failed: write unixgram: i/o timeout + +7 May: + +go version devel +1638d2adb665 Mon May 06 17:34:17 2013 -0700 linux/386 +=== RUN TestTCPClose-4 +--- PASS: TestTCPClose-4 (0.01 seconds) +=== RUN TestPacketConn-4 +--- FAIL: TestPacketConn-4 (1.57 seconds) +packetconn_test.go:112: PacketConn.ReadFrom failed: read unixgram /tmp/nettest093076375: +i/o timeout +=== RUN TestConnAndPacketConn-4 +--- PASS: TestConnAndPacketConn-4 (0.06 seconds) + +15 May: + +go version devel +f51b5497fa4c Wed May 15 04:19:19 2013 +0800 linux/amd64 +--- FAIL: TestPacketConn-23 (4.53 seconds) +packetconn_test.go:101: PacketConn.WriteTo failed: write unixgram: i/o timeout",1.0,"net: TestPacketConn flaky -
TestPacketConn seems to be flaky. It has been for a while. + +TestPacketConn typically runs in milliseconds, which makes the fact that the test +sometimes takes up to 8 seconds in some runs quite strange. + +29 March: + +--- FAIL: TestPacketConn-37 (8.73 seconds) +packetconn_test.go:101: PacketConn.WriteTo failed: write unixgram: i/o timeout + +7 May: + +go version devel +1638d2adb665 Mon May 06 17:34:17 2013 -0700 linux/386 +=== RUN TestTCPClose-4 +--- PASS: TestTCPClose-4 (0.01 seconds) +=== RUN TestPacketConn-4 +--- FAIL: TestPacketConn-4 (1.57 seconds) +packetconn_test.go:112: PacketConn.ReadFrom failed: read unixgram /tmp/nettest093076375: +i/o timeout +=== RUN TestConnAndPacketConn-4 +--- PASS: TestConnAndPacketConn-4 (0.06 seconds) + +15 May: + +go version devel +f51b5497fa4c Wed May 15 04:19:19 2013 +0800 linux/amd64 +--- FAIL: TestPacketConn-23 (4.53 seconds) +packetconn_test.go:101: PacketConn.WriteTo failed: write unixgram: i/o timeout",0,net testpacketconn flaky testpacketconn seems to be flaky it has been for a while testpacketconn typically runs in milliseconds which makes the fact that the test sometimes takes up to seconds in some runs quite strange march fail testpacketconn seconds packetconn test go packetconn writeto failed write unixgram i o timeout may go version devel mon may linux run testtcpclose pass testtcpclose seconds run testpacketconn fail testpacketconn seconds packetconn test go packetconn readfrom failed read unixgram tmp i o timeout run testconnandpacketconn pass testconnandpacketconn seconds may go version devel wed may linux fail testpacketconn seconds packetconn test go packetconn writeto failed write unixgram i o timeout ,0 +14630,3870275812.0,IssuesEvent,2016-04-11 02:06:33,golang/go,https://api.github.com/repos/golang/go,opened,net: use IPv4/IPv6 reserved address blocks for documentation,Documentation,"There are reserved address blocks for documentation; https://tools.ietf.org/html/rfc5737 and https://tools.ietf.org/html/rfc3849. It'd be better to use them for documentation updates. + +- IPv4 address block for doc: 192.0.2.0/24 +- IPv6 address block for doc: 2001:db8::/32 (also see https://tools.ietf.org/html/rfc5952)",1.0,"net: use IPv4/IPv6 reserved address blocks for documentation - There are reserved address blocks for documentation; https://tools.ietf.org/html/rfc5737 and https://tools.ietf.org/html/rfc3849. It'd be better to use them for documentation updates. + +- IPv4 address block for doc: 192.0.2.0/24 +- IPv6 address block for doc: 2001:db8::/32 (also see https://tools.ietf.org/html/rfc5952)",1,net use reserved address blocks for documentation there are reserved address blocks for documentation and it d be better to use them for documentation updates address block for doc address block for doc also see ,1 +56257,8059339284.0,IssuesEvent,2018-08-02 21:34:55,golang/go,https://api.github.com/repos/golang/go,closed,encoding/xml: bulleted lists badly formatted in documentation,Documentation NeedsFix help wanted,"The bulleted lists in the doc comments for Marshal, Unmarshal, and perhaps others are indented in a way that confuses the formatter for golang.org/pkg. (It thinks they're code instead of prose.) + + +",1.0,"encoding/xml: bulleted lists badly formatted in documentation - The bulleted lists in the doc comments for Marshal, Unmarshal, and perhaps others are indented in a way that confuses the formatter for golang.org/pkg. (It thinks they're code instead of prose.) + + +",1,encoding xml bulleted lists badly formatted in documentation the bulleted lists in the doc comments for marshal unmarshal and perhaps others are indented in a way that confuses the formatter for golang org pkg it thinks they re code instead of prose ,1 +50170,7571077201.0,IssuesEvent,2018-04-23 11:01:45,golang/go,https://api.github.com/repos/golang/go,closed,x/crypto/ssh/agent: broken link in documentation,Documentation NeedsFix,"The following reference link in the package documentation is broken: + + [PROTOCOL.agent]: http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.bin/ssh/PROTOCOL.agent?rev=HEAD",1.0,"x/crypto/ssh/agent: broken link in documentation - The following reference link in the package documentation is broken: + + [PROTOCOL.agent]: http://cvsweb.openbsd.org/cgi-bin/cvsweb/src/usr.bin/ssh/PROTOCOL.agent?rev=HEAD",1,x crypto ssh agent broken link in documentation the following reference link in the package documentation is broken ,1 +50503,7607023924.0,IssuesEvent,2018-04-30 15:10:43,golang/go,https://api.github.com/repos/golang/go,closed,"Brand Book: Instead of the RGB color code for Pantone 669 C, the Fuchsia code is listed",Documentation,"### What did you do? + +I took a look at the Go [Brand Book](https://storage.googleapis.com/golang-assets/go-brand-book-v1.0.pdf) and saw an incorrect color code on page 16. + +### What did you expect to see? + +Under color [Pantone 669 C](https://www.pantone.com/color-finder/669-C) (under the ""More colors"" section on page 16), I expected to see the correct RGB color code, which is `63, 42, 86`. + +### What did you see instead? + +Instead, I saw the RGB code `200, 50, 98` listed underneath, which is the RGB code for Fuchsia. +",1.0,"Brand Book: Instead of the RGB color code for Pantone 669 C, the Fuchsia code is listed - ### What did you do? + +I took a look at the Go [Brand Book](https://storage.googleapis.com/golang-assets/go-brand-book-v1.0.pdf) and saw an incorrect color code on page 16. + +### What did you expect to see? + +Under color [Pantone 669 C](https://www.pantone.com/color-finder/669-C) (under the ""More colors"" section on page 16), I expected to see the correct RGB color code, which is `63, 42, 86`. + +### What did you see instead? + +Instead, I saw the RGB code `200, 50, 98` listed underneath, which is the RGB code for Fuchsia. +",1,brand book instead of the rgb color code for pantone c the fuchsia code is listed what did you do i took a look at the go and saw an incorrect color code on page what did you expect to see under color under the more colors section on page i expected to see the correct rgb color code which is what did you see instead instead i saw the rgb code listed underneath which is the rgb code for fuchsia ,1 +28559,5515129008.0,IssuesEvent,2017-03-17 16:40:47,golang/go,https://api.github.com/repos/golang/go,opened,"doc: figure out, document amd64 minimum requirements",Documentation NeedsDecision,"In https://golang.org/cl/38320, @khr adds POPCOUNT intrinsics for amd64. + +I realize that our https://golang.org/wiki/MinimumRequirements doesn't say anything about GOARCH=amd64. (only 386) + +Which version of amd64 do we assume? Decide and document. + +/cc @randall77 @ianlancetaylor @rsc @mdempsky @josharian @minux @cherrymui @aclements ",1.0,"doc: figure out, document amd64 minimum requirements - In https://golang.org/cl/38320, @khr adds POPCOUNT intrinsics for amd64. + +I realize that our https://golang.org/wiki/MinimumRequirements doesn't say anything about GOARCH=amd64. (only 386) + +Which version of amd64 do we assume? Decide and document. + +/cc @randall77 @ianlancetaylor @rsc @mdempsky @josharian @minux @cherrymui @aclements ",1,doc figure out document minimum requirements in khr adds popcount intrinsics for i realize that our doesn t say anything about goarch only which version of do we assume decide and document cc ianlancetaylor rsc mdempsky josharian minux cherrymui aclements ,1 +40847,6872828676.0,IssuesEvent,2017-11-18 01:49:30,golang/go,https://api.github.com/repos/golang/go,closed,builtin: update documentation on builtin `make`,Documentation,"Please answer these questions before submitting your issue. Thanks! + + +### What version of Go are you using (`go version`)? +1.9.2 + +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? +darwin amd64 + +### What did you do? + +If possible, provide a recipe for reproducing the error. +A complete runnable program is good. +A link on play.golang.org is best. + +read the documentation on the make builtin (https://golang.org/pkg/builtin/#make) + +### What did you expect to see? + +An explanation that specifying the capacity for a slice means that go will allocate an array big enough to hold that capacity without any resizing. +(After digging around the source code, I found this to be true) + +### What did you see instead? + +Ambiguous comment: +``` +// Slice: The size specifies the length. The capacity of the slice is +// equal to its length. A second integer argument may be provided to +// specify a different capacity; it must be no smaller than the +// length, so make([]int, 0, 10) allocates a slice of length 0 and +// capacity 10. +``` + +### Proposed Fix +Update this section of the comment to read: +``` +// Slice: The size specifies the length. The capacity of the slice is +// equal to its length. A second integer argument may be provided to +// specify a different capacity; it must be no smaller than the +// length, so make([]int, 0, 10) allocates an underlying array of size 10 +// and returns a slice of length 0 and capacity 10 that is backed by this +// underlying array. +```",1.0,"builtin: update documentation on builtin `make` - Please answer these questions before submitting your issue. Thanks! + + +### What version of Go are you using (`go version`)? +1.9.2 + +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? +darwin amd64 + +### What did you do? + +If possible, provide a recipe for reproducing the error. +A complete runnable program is good. +A link on play.golang.org is best. + +read the documentation on the make builtin (https://golang.org/pkg/builtin/#make) + +### What did you expect to see? + +An explanation that specifying the capacity for a slice means that go will allocate an array big enough to hold that capacity without any resizing. +(After digging around the source code, I found this to be true) + +### What did you see instead? + +Ambiguous comment: +``` +// Slice: The size specifies the length. The capacity of the slice is +// equal to its length. A second integer argument may be provided to +// specify a different capacity; it must be no smaller than the +// length, so make([]int, 0, 10) allocates a slice of length 0 and +// capacity 10. +``` + +### Proposed Fix +Update this section of the comment to read: +``` +// Slice: The size specifies the length. The capacity of the slice is +// equal to its length. A second integer argument may be provided to +// specify a different capacity; it must be no smaller than the +// length, so make([]int, 0, 10) allocates an underlying array of size 10 +// and returns a slice of length 0 and capacity 10 that is backed by this +// underlying array. +```",1,builtin update documentation on builtin make please answer these questions before submitting your issue thanks what version of go are you using go version does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env darwin what did you do if possible provide a recipe for reproducing the error a complete runnable program is good a link on play golang org is best read the documentation on the make builtin what did you expect to see an explanation that specifying the capacity for a slice means that go will allocate an array big enough to hold that capacity without any resizing after digging around the source code i found this to be true what did you see instead ambiguous comment slice the size specifies the length the capacity of the slice is equal to its length a second integer argument may be provided to specify a different capacity it must be no smaller than the length so make int allocates a slice of length and capacity proposed fix update this section of the comment to read slice the size specifies the length the capacity of the slice is equal to its length a second integer argument may be provided to specify a different capacity it must be no smaller than the length so make int allocates an underlying array of size and returns a slice of length and capacity that is backed by this underlying array ,1 +52820,7786242441.0,IssuesEvent,2018-06-06 18:19:10,golang/go,https://api.github.com/repos/golang/go,closed,database/sql: DB documentation should mention DB.Conn(),Documentation NeedsFix help wanted,"https://golang.org/pkg/database/sql/#DB currently states: + +> If the database has a concept of per-connection state, such state can only be reliably observed within a transaction. + +This is no longer true: DB.Conn() was added to allow one to have a per-connection state without using transactions. DB documentation should be updated.",1.0,"database/sql: DB documentation should mention DB.Conn() - https://golang.org/pkg/database/sql/#DB currently states: + +> If the database has a concept of per-connection state, such state can only be reliably observed within a transaction. + +This is no longer true: DB.Conn() was added to allow one to have a per-connection state without using transactions. DB documentation should be updated.",1,database sql db documentation should mention db conn currently states if the database has a concept of per connection state such state can only be reliably observed within a transaction this is no longer true db conn was added to allow one to have a per connection state without using transactions db documentation should be updated ,1 +97516,28310494543.0,IssuesEvent,2023-04-10 14:59:55,golang/go,https://api.github.com/repos/golang/go,reopened,all: test failures with `device not configured`,Builders NeedsInvestigation,"``` +#!watchflakes +post <- test == """" && log ~ `: device not configured` +```",1.0,"all: test failures with `device not configured` - ``` +#!watchflakes +post <- test == """" && log ~ `: device not configured` +```",0,all test failures with device not configured watchflakes post test log device not configured ,0 +5313,2921979377.0,IssuesEvent,2015-06-25 07:14:34,golang/go,https://api.github.com/repos/golang/go,closed,"os/exec: Cmd can only be executed once, but that isn't documented",Documentation,"Once an exec.Cmd has been Run (e.g. through .Run, .Output or .CombinedOutput) calling one of these run methods again will result in an error. + +1. This fact isn't documented. +2. The resulting error messages don't clearly identify what caused the problem. +3. This behaviour probably isn't necessary; for many commands it makes perfectly good sense to run them more than once. + +I'm not talking about parallel execution here, this is running, checking the output, then running again. + +Example error message from calling CombinedOutput more than once: +""exec: Stdout already set."" +http://play.golang.org/p/Aaj3Gbva_S",1.0,"os/exec: Cmd can only be executed once, but that isn't documented - Once an exec.Cmd has been Run (e.g. through .Run, .Output or .CombinedOutput) calling one of these run methods again will result in an error. + +1. This fact isn't documented. +2. The resulting error messages don't clearly identify what caused the problem. +3. This behaviour probably isn't necessary; for many commands it makes perfectly good sense to run them more than once. + +I'm not talking about parallel execution here, this is running, checking the output, then running again. + +Example error message from calling CombinedOutput more than once: +""exec: Stdout already set."" +http://play.golang.org/p/Aaj3Gbva_S",1,os exec cmd can only be executed once but that isn t documented once an exec cmd has been run e g through run output or combinedoutput calling one of these run methods again will result in an error this fact isn t documented the resulting error messages don t clearly identify what caused the problem this behaviour probably isn t necessary for many commands it makes perfectly good sense to run them more than once i m not talking about parallel execution here this is running checking the output then running again example error message from calling combinedoutput more than once exec stdout already set ,1 +16244,4030114778.0,IssuesEvent,2016-05-18 13:18:05,golang/go,https://api.github.com/repos/golang/go,closed,"doc: Clarify what code is referred in the ""Pointers vs. Values"" section of Effective Go",Documentation," +[`Append`](https://tip.golang.org/doc/effective_go.html#append) section is a few screens before [`Pointers vs. Values`](https://tip.golang.org/doc/effective_go.html#pointers_vs_values) and (1) is easy to miss. It is therefore not clear for the reader what code is referred in the comment of snippet (2) and subsequent ones. At least, that was my experience. + +I would, transform (1) into a link to `#append` (to attract reader's attention and clarify what exactly `Append` is meant) and change (2) to something like: +```diff +- // Body exactly the same as above ++ // Body is exactly the same as described in the Append section above. +``` +",1.0,"doc: Clarify what code is referred in the ""Pointers vs. Values"" section of Effective Go -  +[`Append`](https://tip.golang.org/doc/effective_go.html#append) section is a few screens before [`Pointers vs. Values`](https://tip.golang.org/doc/effective_go.html#pointers_vs_values) and (1) is easy to miss. It is therefore not clear for the reader what code is referred in the comment of snippet (2) and subsequent ones. At least, that was my experience. + +I would, transform (1) into a link to `#append` (to attract reader's attention and clarify what exactly `Append` is meant) and change (2) to something like: +```diff +- // Body exactly the same as above ++ // Body is exactly the same as described in the Append section above. +``` +",1,doc clarify what code is referred in the pointers vs values section of effective go section is a few screens before and is easy to miss it is therefore not clear for the reader what code is referred in the comment of snippet and subsequent ones at least that was my experience i would transform into a link to append to attract reader s attention and clarify what exactly append is meant and change to something like diff body exactly the same as above body is exactly the same as described in the append section above ,1 +86739,10515961460.0,IssuesEvent,2019-09-28 14:04:15,golang/go,https://api.github.com/repos/golang/go,opened,x/tour: welcome/3 slide missing instructions for installing Go,Documentation NeedsFix,"The first slide of the tour welcomes people and explains how to change slides. The second slide mentions the choice of spoken languages. The third slide strongly suggests running the tour offline. + +By the [third slide](https://tour.golang.org/welcome/3), the tour assumes users already have Go installed (and/or know how to install Go). This isn't valid for users who are being introduced to Go by being linked to the tour. It can cause unnecessary confusion as demonstrated by the experience reported in [this comment](https://github.com/golang/go/issues/24819#issuecomment-487723046). + +That slide used to have instructions for installing Go, but they were lost as part of deployment changes in [CL 141857](https://golang.org/cl/141857). /cc @andybons + +To fix this, we should include a link to https://golang.org/doc/install and/or https://golang.org/dl/ before the first mention of `go get` in the tour. It should also be helpful and a good teaching opportunity to point out where the `tour` binary ends up after `go get` runs successfully. + +This issue is factored out from #24819, which was about a formatting bug that is resolved by now.",1.0,"x/tour: welcome/3 slide missing instructions for installing Go - The first slide of the tour welcomes people and explains how to change slides. The second slide mentions the choice of spoken languages. The third slide strongly suggests running the tour offline. + +By the [third slide](https://tour.golang.org/welcome/3), the tour assumes users already have Go installed (and/or know how to install Go). This isn't valid for users who are being introduced to Go by being linked to the tour. It can cause unnecessary confusion as demonstrated by the experience reported in [this comment](https://github.com/golang/go/issues/24819#issuecomment-487723046). + +That slide used to have instructions for installing Go, but they were lost as part of deployment changes in [CL 141857](https://golang.org/cl/141857). /cc @andybons + +To fix this, we should include a link to https://golang.org/doc/install and/or https://golang.org/dl/ before the first mention of `go get` in the tour. It should also be helpful and a good teaching opportunity to point out where the `tour` binary ends up after `go get` runs successfully. + +This issue is factored out from #24819, which was about a formatting bug that is resolved by now.",1,x tour welcome slide missing instructions for installing go the first slide of the tour welcomes people and explains how to change slides the second slide mentions the choice of spoken languages the third slide strongly suggests running the tour offline by the the tour assumes users already have go installed and or know how to install go this isn t valid for users who are being introduced to go by being linked to the tour it can cause unnecessary confusion as demonstrated by the experience reported in that slide used to have instructions for installing go but they were lost as part of deployment changes in cc andybons to fix this we should include a link to and or before the first mention of go get in the tour it should also be helpful and a good teaching opportunity to point out where the tour binary ends up after go get runs successfully this issue is factored out from which was about a formatting bug that is resolved by now ,1 +90947,26225556184.0,IssuesEvent,2023-01-04 18:20:35,golang/go,https://api.github.com/repos/golang/go,closed,x/build/cmd/gomote: instruct gomote users on how to request authentication credentials,Builders NeedsInvestigation,"Once gomote users can create authentication credentials via the new path, the users should be notified via the following mediums: +- [ ] ~~Update the gomote create preamble text to include instructions on how to request credentials.~~ +- [x] Update the wiki. +- [x] Send out an email. + +This is a component of the project to revamp the security model used by gomote #47521 +@golang/release ",1.0,"x/build/cmd/gomote: instruct gomote users on how to request authentication credentials - Once gomote users can create authentication credentials via the new path, the users should be notified via the following mediums: +- [ ] ~~Update the gomote create preamble text to include instructions on how to request credentials.~~ +- [x] Update the wiki. +- [x] Send out an email. + +This is a component of the project to revamp the security model used by gomote #47521 +@golang/release ",0,x build cmd gomote instruct gomote users on how to request authentication credentials once gomote users can create authentication credentials via the new path the users should be notified via the following mediums update the gomote create preamble text to include instructions on how to request credentials update the wiki send out an email this is a component of the project to revamp the security model used by gomote golang release ,0 +35242,9552744612.0,IssuesEvent,2019-05-02 17:26:15,golang/go,https://api.github.com/repos/golang/go,closed,x/build/cmd/gopherbot: who is suppose to be congratulated?,Builders,"Does this code means as commented or not to congratulate before 2017/06/17 in UTC?? +https://go.googlesource.com/build/+/refs/heads/master/cmd/gopherbot/gopherbot.go#1051",1.0,"x/build/cmd/gopherbot: who is suppose to be congratulated? - Does this code means as commented or not to congratulate before 2017/06/17 in UTC?? +https://go.googlesource.com/build/+/refs/heads/master/cmd/gopherbot/gopherbot.go#1051",0,x build cmd gopherbot who is suppose to be congratulated does this code means as commented or not to congratulate before in utc ,0 +22020,11457418784.0,IssuesEvent,2020-02-06 23:41:55,golang/go,https://api.github.com/repos/golang/go,opened,cmd/compile: ARM's MOVWnop causes regalloc to insert unnecessary copies,Performance,"MOVWnop is a nop/copy designed to ensure type safety. It generates no code. However, it is not free; regalloc sometimes makes a copy of a value to provide to MOVWnop, since it doesn't know that MOVWnop doesn't modify its argument. + +I noticed this while tracking down regressions due to changes in rewrite rule order application. + +I don't know what the best approach to fixing it is. Suggestions? + +cc @cherrymui +",True,"cmd/compile: ARM's MOVWnop causes regalloc to insert unnecessary copies - MOVWnop is a nop/copy designed to ensure type safety. It generates no code. However, it is not free; regalloc sometimes makes a copy of a value to provide to MOVWnop, since it doesn't know that MOVWnop doesn't modify its argument. + +I noticed this while tracking down regressions due to changes in rewrite rule order application. + +I don't know what the best approach to fixing it is. Suggestions? + +cc @cherrymui +",0,cmd compile arm s movwnop causes regalloc to insert unnecessary copies movwnop is a nop copy designed to ensure type safety it generates no code however it is not free regalloc sometimes makes a copy of a value to provide to movwnop since it doesn t know that movwnop doesn t modify its argument i noticed this while tracking down regressions due to changes in rewrite rule order application i don t know what the best approach to fixing it is suggestions cc cherrymui ,0 +3007,2730806909.0,IssuesEvent,2015-04-16 16:45:15,golang/go,https://api.github.com/repos/golang/go,closed,os: document that FileMode permission bits are Unix bits,Documentation,"by **Mortdeus@gocos2d.org**: + +
It would be nice to add + +`rwx(111[7]) rw(110[6]) rx(101[5]) r(100[4]) wx(011[3]) w(010[2]) x(001[1])` + +as a godoc comment at + +https://code.google.com/p/go/source/browse/src/pkg/os/types.go#56",1.0,"os: document that FileMode permission bits are Unix bits - by **Mortdeus@gocos2d.org**: + +
It would be nice to add + +`rwx(111[7]) rw(110[6]) rx(101[5]) r(100[4]) wx(011[3]) w(010[2]) x(001[1])` + +as a godoc comment at + +https://code.google.com/p/go/source/browse/src/pkg/os/types.go#56",1,os document that filemode permission bits are unix bits by mortdeus org it would be nice to add rwx rw rx r wx w x as a godoc comment at a href ,1 +65248,16166395035.0,IssuesEvent,2021-05-01 15:32:44,golang/go,https://api.github.com/repos/golang/go,opened,x/build: Add FreeBSD 13.0 builder,Builders OS-FreeBSD new-builder,"Hi @cagedmantis, please add a FreeBSD-13.0 builder. I'm sending a CL to update the expect script for the new image. +Thanks!",2.0,"x/build: Add FreeBSD 13.0 builder - Hi @cagedmantis, please add a FreeBSD-13.0 builder. I'm sending a CL to update the expect script for the new image. +Thanks!",0,x build add freebsd builder hi cagedmantis please add a freebsd builder i m sending a cl to update the expect script for the new image thanks ,0 +24186,5037440604.0,IssuesEvent,2016-12-17 17:26:39,golang/go,https://api.github.com/repos/golang/go,opened,doc: mention that CGO_ENABLED is now sticky in 1.8,Documentation,"CGO_ENABLED is sticky in Go 1.8. Document this. + +Some discussion in: +https://github.com/golang/go/issues/18360#issuecomment-267752866 + +",1.0,"doc: mention that CGO_ENABLED is now sticky in 1.8 - CGO_ENABLED is sticky in Go 1.8. Document this. + +Some discussion in: +https://github.com/golang/go/issues/18360#issuecomment-267752866 + +",1,doc mention that cgo enabled is now sticky in cgo enabled is sticky in go document this some discussion in ,1 +43682,7058410021.0,IssuesEvent,2018-01-04 20:16:04,golang/go,https://api.github.com/repos/golang/go,closed,sync: documentation for Map is inadequate,Documentation,"What's there is correct but unhelpful. How does it differ from the map type? When should it be used? When should it not be used? What are its performance characteristics. + +I think a newcomer would find what's there inadequate to understand what it's for.",1.0,"sync: documentation for Map is inadequate - What's there is correct but unhelpful. How does it differ from the map type? When should it be used? When should it not be used? What are its performance characteristics. + +I think a newcomer would find what's there inadequate to understand what it's for.",1,sync documentation for map is inadequate what s there is correct but unhelpful how does it differ from the map type when should it be used when should it not be used what are its performance characteristics i think a newcomer would find what s there inadequate to understand what it s for ,1 +37691,18732437785.0,IssuesEvent,2021-11-04 00:12:29,golang/go,https://api.github.com/repos/golang/go,opened,cmd/compile: mark CSE'd loads as rematerializable,Performance,"CSE will unify loads from the same memory state. In computation-heavy code, such the generic code in crypto/md5, these loads can have a long lifetime, leading the loaded values being spilled to the stack. That's silly: We already have the value in memory, so we can reload it from there as needed, without using stack space. + +Perhaps we can somehow mark such loads as rematerializable, so that the register allocator knows it can re-issue the load instead of spilling. There are some non-obvious details here, like what to do if we need to recalculate the address of the load, and if the calculation of the address is more expensive than spilling the loaded value. + +But we currently generate some very silly code for crypto/md5's generic block. + +To see this, patch in https://gist.github.com/josharian/42e66bf022f32da3da0a9b1bdf0a974b into the md5 code and then observe the effect of disabling CSE for loads, for example by adding to cmpVal code like: + +``` +if len(v.Args) > 0 && v.Args[len(v.Args)-1].Type.IsMemory() { + return lt2Cmp(v.ID < w.ID) +} +``` + +The generated code goes from a morass of spills and restores to long, straightforward calculation. + +There's no way I found to tweak the code to prevent such CSEs. (Issuing irrelevant writes causes other values to get spilled, negating the benefits of preventing CSE.) + +cc @randall77 +",True,"cmd/compile: mark CSE'd loads as rematerializable - CSE will unify loads from the same memory state. In computation-heavy code, such the generic code in crypto/md5, these loads can have a long lifetime, leading the loaded values being spilled to the stack. That's silly: We already have the value in memory, so we can reload it from there as needed, without using stack space. + +Perhaps we can somehow mark such loads as rematerializable, so that the register allocator knows it can re-issue the load instead of spilling. There are some non-obvious details here, like what to do if we need to recalculate the address of the load, and if the calculation of the address is more expensive than spilling the loaded value. + +But we currently generate some very silly code for crypto/md5's generic block. + +To see this, patch in https://gist.github.com/josharian/42e66bf022f32da3da0a9b1bdf0a974b into the md5 code and then observe the effect of disabling CSE for loads, for example by adding to cmpVal code like: + +``` +if len(v.Args) > 0 && v.Args[len(v.Args)-1].Type.IsMemory() { + return lt2Cmp(v.ID < w.ID) +} +``` + +The generated code goes from a morass of spills and restores to long, straightforward calculation. + +There's no way I found to tweak the code to prevent such CSEs. (Issuing irrelevant writes causes other values to get spilled, negating the benefits of preventing CSE.) + +cc @randall77 +",0,cmd compile mark cse d loads as rematerializable cse will unify loads from the same memory state in computation heavy code such the generic code in crypto these loads can have a long lifetime leading the loaded values being spilled to the stack that s silly we already have the value in memory so we can reload it from there as needed without using stack space perhaps we can somehow mark such loads as rematerializable so that the register allocator knows it can re issue the load instead of spilling there are some non obvious details here like what to do if we need to recalculate the address of the load and if the calculation of the address is more expensive than spilling the loaded value but we currently generate some very silly code for crypto s generic block to see this patch in into the code and then observe the effect of disabling cse for loads for example by adding to cmpval code like if len v args v args type ismemory return v id w id the generated code goes from a morass of spills and restores to long straightforward calculation there s no way i found to tweak the code to prevent such cses issuing irrelevant writes causes other values to get spilled negating the benefits of preventing cse cc ,0 +15761,3974440852.0,IssuesEvent,2016-05-04 22:12:26,golang/go,https://api.github.com/repos/golang/go,closed,net/http: MethodPatch references the wrong RFC,Documentation,"Please answer these questions before submitting your issue. Thanks! + +1. What version of Go are you using (`go version`)? + +`go version go1.6.2 darwin/amd64` + +2. What operating system and processor architecture are you using (`go env`)? + +``` +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/dmaze/Diffeo/go"" +GORACE="""" +GOROOT=""/usr/local/Cellar/go/1.6.2/libexec"" +GOTOOLDIR=""/usr/local/Cellar/go/1.6.2/libexec/pkg/tool/darwin_amd64"" +GO15VENDOREXPERIMENT=""1"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +``` +3. What did you do? + +Run `godoc net/http MethodPatch`; or visited https://godoc.org/net/http#MethodPatch or http://localhost:6060/pkg/net/http#MethodPatch. + +4. What did you expect to see? + +A reference to [RFC 5789, ""PATCH Method for HTTP""](https://tools.ietf.org/html/rfc5789). + +5. What did you see instead? + +A reference to [RFC 5741, ""RFC Streams, Headers, and Boilerplates""](https://tools.ietf.org/html/rfc5741), the meta-RFC that defines the format of RFCs.",1.0,"net/http: MethodPatch references the wrong RFC - Please answer these questions before submitting your issue. Thanks! + +1. What version of Go are you using (`go version`)? + +`go version go1.6.2 darwin/amd64` + +2. What operating system and processor architecture are you using (`go env`)? + +``` +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/dmaze/Diffeo/go"" +GORACE="""" +GOROOT=""/usr/local/Cellar/go/1.6.2/libexec"" +GOTOOLDIR=""/usr/local/Cellar/go/1.6.2/libexec/pkg/tool/darwin_amd64"" +GO15VENDOREXPERIMENT=""1"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +``` +3. What did you do? + +Run `godoc net/http MethodPatch`; or visited https://godoc.org/net/http#MethodPatch or http://localhost:6060/pkg/net/http#MethodPatch. + +4. What did you expect to see? + +A reference to [RFC 5789, ""PATCH Method for HTTP""](https://tools.ietf.org/html/rfc5789). + +5. What did you see instead? + +A reference to [RFC 5741, ""RFC Streams, Headers, and Boilerplates""](https://tools.ietf.org/html/rfc5741), the meta-RFC that defines the format of RFCs.",1,net http methodpatch references the wrong rfc please answer these questions before submitting your issue thanks what version of go are you using go version go version darwin what operating system and processor architecture are you using go env goarch gobin goexe gohostarch gohostos darwin goos darwin gopath users dmaze diffeo go gorace goroot usr local cellar go libexec gotooldir usr local cellar go libexec pkg tool darwin cc clang gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fno common cxx clang cgo enabled what did you do run godoc net http methodpatch or visited or what did you expect to see a reference to what did you see instead a reference to the meta rfc that defines the format of rfcs ,1 +146202,13173719873.0,IssuesEvent,2020-08-11 20:52:30,golang/go,https://api.github.com/repos/golang/go,opened,doc: write Go 1.16 release notes,Documentation NeedsFix help wanted recurring release-blocker,"Tracking bug for writing the Go 1.16 Release Notes. + +The latest state on tip can be viewed at https://tip.golang.org/doc/go1.16 (it hasn't been created yet, so 404 at this time). + +Previously #37419, #36878, #17929, #15810, #5929, etc.",1.0,"doc: write Go 1.16 release notes - Tracking bug for writing the Go 1.16 Release Notes. + +The latest state on tip can be viewed at https://tip.golang.org/doc/go1.16 (it hasn't been created yet, so 404 at this time). + +Previously #37419, #36878, #17929, #15810, #5929, etc.",1,doc write go release notes tracking bug for writing the go release notes the latest state on tip can be viewed at it hasn t been created yet so at this time previously etc ,1 +5818,2794989869.0,IssuesEvent,2015-05-11 19:36:08,golang/go,https://api.github.com/repos/golang/go,closed,net/http: data race in TestClientTimeout_Headers when -race=true -short=false,Testing,"git rev-parse HEAD +19e81a9b3b0d103fe7a9a9605c16eb4ba1f20ed8 + +``` +================== +WARNING: DATA RACE +Write by goroutine 16: + sync.raceWrite() + /go/src/sync/race.go:41 +0x35 + sync.(*WaitGroup).Wait() + /go/src/sync/waitgroup.go:125 +0x177 + net/http/httptest.(*Server).Close() + /go/src/net/http/httptest/server.go:168 +0x83 + net/http_test.TestClientTimeout_Headers() + /go/src/net/http/client_test.go:952 +0xb1a + testing.tRunner() + /go/src/testing/testing.go:454 +0xfb + +Previous read by goroutine 22: + sync.raceRead() + /go/src/sync/race.go:37 +0x35 + sync.(*WaitGroup).Add() + /go/src/sync/waitgroup.go:63 +0xc8 + net/http/httptest.(*waitGroupHandler).ServeHTTP() + /go/src/net/http/httptest/server.go:198 +0x5f + net/http.serverHandler.ServeHTTP() + /go/src/net/http/server.go:1758 +0x209 + net/http.(*conn).serve() + /go/src/net/http/server.go:1259 +0x1161 + +Goroutine 16 (running) created at: + testing.RunTests() + /go/src/testing/testing.go:562 +0xc95 + testing.(*M).Run() + /go/src/testing/testing.go:492 +0xe7 + net/http_test.TestMain() + /go/src/net/http/main_test.go:19 +0x35 + main.main() + net/http/_test/_testmain.go:536 +0x20c + +Goroutine 22 (running) created at: + net/http.(*Server).Serve() + /go/src/net/http/server.go:1806 +0x422 +================== +PASS +Found 1 data race(s) +FAIL net/http 43.465s +```",1.0,"net/http: data race in TestClientTimeout_Headers when -race=true -short=false - git rev-parse HEAD +19e81a9b3b0d103fe7a9a9605c16eb4ba1f20ed8 + +``` +================== +WARNING: DATA RACE +Write by goroutine 16: + sync.raceWrite() + /go/src/sync/race.go:41 +0x35 + sync.(*WaitGroup).Wait() + /go/src/sync/waitgroup.go:125 +0x177 + net/http/httptest.(*Server).Close() + /go/src/net/http/httptest/server.go:168 +0x83 + net/http_test.TestClientTimeout_Headers() + /go/src/net/http/client_test.go:952 +0xb1a + testing.tRunner() + /go/src/testing/testing.go:454 +0xfb + +Previous read by goroutine 22: + sync.raceRead() + /go/src/sync/race.go:37 +0x35 + sync.(*WaitGroup).Add() + /go/src/sync/waitgroup.go:63 +0xc8 + net/http/httptest.(*waitGroupHandler).ServeHTTP() + /go/src/net/http/httptest/server.go:198 +0x5f + net/http.serverHandler.ServeHTTP() + /go/src/net/http/server.go:1758 +0x209 + net/http.(*conn).serve() + /go/src/net/http/server.go:1259 +0x1161 + +Goroutine 16 (running) created at: + testing.RunTests() + /go/src/testing/testing.go:562 +0xc95 + testing.(*M).Run() + /go/src/testing/testing.go:492 +0xe7 + net/http_test.TestMain() + /go/src/net/http/main_test.go:19 +0x35 + main.main() + net/http/_test/_testmain.go:536 +0x20c + +Goroutine 22 (running) created at: + net/http.(*Server).Serve() + /go/src/net/http/server.go:1806 +0x422 +================== +PASS +Found 1 data race(s) +FAIL net/http 43.465s +```",0,net http data race in testclienttimeout headers when race true short false git rev parse head warning data race write by goroutine sync racewrite go src sync race go sync waitgroup wait go src sync waitgroup go net http httptest server close go src net http httptest server go net http test testclienttimeout headers go src net http client test go testing trunner go src testing testing go previous read by goroutine sync raceread go src sync race go sync waitgroup add go src sync waitgroup go net http httptest waitgrouphandler servehttp go src net http httptest server go net http serverhandler servehttp go src net http server go net http conn serve go src net http server go goroutine running created at testing runtests go src testing testing go testing m run go src testing testing go net http test testmain go src net http main test go main main net http test testmain go goroutine running created at net http server serve go src net http server go pass found data race s fail net http ,0 +5991,5243488673.0,IssuesEvent,2017-01-31 20:51:23,golang/go,https://api.github.com/repos/golang/go,opened,cmd/compile: inline small static initializers,Performance,"``` +type T struct { + a, b, c, d int +} +func f(p *T) { + *p = T{1, 2, 3, 4} +} +``` +The code for `f` is: +``` +(tmp1.go:8) MOVQ """".statictmp_0(SB), AX +(tmp1.go:8) MOVQ """".statictmp_0+8(SB), CX +(tmp1.go:8) MOVQ """".statictmp_0+16(SB), DX +(tmp1.go:8) MOVQ """".statictmp_0+24(SB), BX +(tmp1.go:8) MOVQ """".p+8(FP), SI +(tmp1.go:8) MOVQ AX, (SI) +(tmp1.go:8) MOVQ CX, 8(SI) +(tmp1.go:8) MOVQ DX, 16(SI) +(tmp1.go:8) MOVQ BX, 24(SI) +``` +That's kind of dumb to copy from a statictmp. Just use `MOVQ $1, (SI)` and so forth. +",True,"cmd/compile: inline small static initializers - ``` +type T struct { + a, b, c, d int +} +func f(p *T) { + *p = T{1, 2, 3, 4} +} +``` +The code for `f` is: +``` +(tmp1.go:8) MOVQ """".statictmp_0(SB), AX +(tmp1.go:8) MOVQ """".statictmp_0+8(SB), CX +(tmp1.go:8) MOVQ """".statictmp_0+16(SB), DX +(tmp1.go:8) MOVQ """".statictmp_0+24(SB), BX +(tmp1.go:8) MOVQ """".p+8(FP), SI +(tmp1.go:8) MOVQ AX, (SI) +(tmp1.go:8) MOVQ CX, 8(SI) +(tmp1.go:8) MOVQ DX, 16(SI) +(tmp1.go:8) MOVQ BX, 24(SI) +``` +That's kind of dumb to copy from a statictmp. Just use `MOVQ $1, (SI)` and so forth. +",0,cmd compile inline small static initializers type t struct a b c d int func f p t p t the code for f is go movq statictmp sb ax go movq statictmp sb cx go movq statictmp sb dx go movq statictmp sb bx go movq p fp si go movq ax si go movq cx si go movq dx si go movq bx si that s kind of dumb to copy from a statictmp just use movq si and so forth ,0 +21584,11273806722.0,IssuesEvent,2020-01-14 17:14:08,golang/go,https://api.github.com/repos/golang/go,closed,runtime: scavenger is too eager on Darwin,NeedsFix Performance,"Currently on Darwin the scavenger is too eager and causing performance regressions. The issue mainly stems from the fact that in Go 1.14 the scavenger is paced empirically according to costs of scavenging, most of which comes from `sysUnused` which makes an `madvise` syscall on most platforms, including Darwin. + +However, the problem on Darwin is that we don't just do `MADV_FREE` anymore, we do `MADV_FREE_REUSABLE` in the `sysUnused` path and `MADV_FREE_REUSE` in the `sysUsed` path (instead of `sysUsed` being a no-op). It turns out the source of the regression is mostly the fact that `sysUsed` is actually quite expensive relative to other systems where it's just a no-op and we instead incur an implicit page fault once the memory is actually touched. The benefits of using this API outweigh the costs, since it updates process RSS counters in the kernel appropriately and `MADV_FREE_REUSABLE` is properly lazy. + +So since we don't account for `sysUsed` we end up scavenging a lot more frequently than we should to maintain the scavenger's goal of only using 1% of the CPU time of one CPU. + +The actual size of the regression can be quite large, up to 5%, as seen in #36218, so we should fix this before 1.14 goes out. + +The fix here is relatively simple: we just need to account for this extra cost somehow. We could measure it directly in the runtime but this then slows down allocation unnecessarily, and even then it's unclear how we should attribute that cost to the scavenger (maybe as a debt it needs to pay down?). Trying to account for this cost on non-Darwin platforms is also tricky because the costs aren't actually coming from `sysUsed` but from the page fault. + +Instead, I think it's a good idea to do something along the lines of what we did last release: get some empirical measurements and use that to get an order-of-magnitude approximation. In this particular case, I think we should compute an empirical ratio ""r"" of using a scavenged page and `sysUnused` and turn this into a multiplicative constant, ""1+r"" for the time spent scavenging. So for example if `sysUsed` is roughly as expensive as `sysUnused` the factor would be 2.",True,"runtime: scavenger is too eager on Darwin - Currently on Darwin the scavenger is too eager and causing performance regressions. The issue mainly stems from the fact that in Go 1.14 the scavenger is paced empirically according to costs of scavenging, most of which comes from `sysUnused` which makes an `madvise` syscall on most platforms, including Darwin. + +However, the problem on Darwin is that we don't just do `MADV_FREE` anymore, we do `MADV_FREE_REUSABLE` in the `sysUnused` path and `MADV_FREE_REUSE` in the `sysUsed` path (instead of `sysUsed` being a no-op). It turns out the source of the regression is mostly the fact that `sysUsed` is actually quite expensive relative to other systems where it's just a no-op and we instead incur an implicit page fault once the memory is actually touched. The benefits of using this API outweigh the costs, since it updates process RSS counters in the kernel appropriately and `MADV_FREE_REUSABLE` is properly lazy. + +So since we don't account for `sysUsed` we end up scavenging a lot more frequently than we should to maintain the scavenger's goal of only using 1% of the CPU time of one CPU. + +The actual size of the regression can be quite large, up to 5%, as seen in #36218, so we should fix this before 1.14 goes out. + +The fix here is relatively simple: we just need to account for this extra cost somehow. We could measure it directly in the runtime but this then slows down allocation unnecessarily, and even then it's unclear how we should attribute that cost to the scavenger (maybe as a debt it needs to pay down?). Trying to account for this cost on non-Darwin platforms is also tricky because the costs aren't actually coming from `sysUsed` but from the page fault. + +Instead, I think it's a good idea to do something along the lines of what we did last release: get some empirical measurements and use that to get an order-of-magnitude approximation. In this particular case, I think we should compute an empirical ratio ""r"" of using a scavenged page and `sysUnused` and turn this into a multiplicative constant, ""1+r"" for the time spent scavenging. So for example if `sysUsed` is roughly as expensive as `sysUnused` the factor would be 2.",0,runtime scavenger is too eager on darwin currently on darwin the scavenger is too eager and causing performance regressions the issue mainly stems from the fact that in go the scavenger is paced empirically according to costs of scavenging most of which comes from sysunused which makes an madvise syscall on most platforms including darwin however the problem on darwin is that we don t just do madv free anymore we do madv free reusable in the sysunused path and madv free reuse in the sysused path instead of sysused being a no op it turns out the source of the regression is mostly the fact that sysused is actually quite expensive relative to other systems where it s just a no op and we instead incur an implicit page fault once the memory is actually touched the benefits of using this api outweigh the costs since it updates process rss counters in the kernel appropriately and madv free reusable is properly lazy so since we don t account for sysused we end up scavenging a lot more frequently than we should to maintain the scavenger s goal of only using of the cpu time of one cpu the actual size of the regression can be quite large up to as seen in so we should fix this before goes out the fix here is relatively simple we just need to account for this extra cost somehow we could measure it directly in the runtime but this then slows down allocation unnecessarily and even then it s unclear how we should attribute that cost to the scavenger maybe as a debt it needs to pay down trying to account for this cost on non darwin platforms is also tricky because the costs aren t actually coming from sysused but from the page fault instead i think it s a good idea to do something along the lines of what we did last release get some empirical measurements and use that to get an order of magnitude approximation in this particular case i think we should compute an empirical ratio r of using a scavenged page and sysunused and turn this into a multiplicative constant r for the time spent scavenging so for example if sysused is roughly as expensive as sysunused the factor would be ,0 +215667,16614220069.0,IssuesEvent,2021-06-02 14:52:44,golang/go,https://api.github.com/repos/golang/go,closed,doc/go1.17: document time changes for Go 1.17,Documentation NeedsInvestigation help wanted release-blocker,"As of filing this issue, the [Go 1.17 draft release notes](https://tip.golang.org/doc/go1.17) contained the following HTML: + +
+ time.Time now has a GoString
+ method that will return a more useful value for times when printed with
+ the "%#v" format specifier in the fmt package.
+
+ TODO: https://golang.org/cl/264077: add Time.IsDST() to check if its Location is in Daylight Savings Time +
++ TODO: https://golang.org/cl/293349: add Time.Unix{Milli,Micro} and to-Time helpers UnixMicro, UnixMilli +
++ TODO: https://golang.org/cl/300996: support "," as separator for fractional seconds +
+
+ time.Time now has a GoString
+ method that will return a more useful value for times when printed with
+ the "%#v" format specifier in the fmt package.
+
+ TODO: https://golang.org/cl/264077: add Time.IsDST() to check if its Location is in Daylight Savings Time +
++ TODO: https://golang.org/cl/293349: add Time.Unix{Milli,Micro} and to-Time helpers UnixMicro, UnixMilli +
++ TODO: https://golang.org/cl/300996: support "," as separator for fractional seconds +
++$ go version +go version go1.17.6 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/catena/Library/Caches/go-build"" +GOENV=""/Users/catena/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/catena/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/catena/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GOVCS="""" +GOVERSION=""go1.17.6"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/catena/go/src/github.com/catenacyber/go/src/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/pp/dc1dtf9x2js3v0jx_m010nqr0000gn/T/go-build4237848497=/tmp/go-build -gno-record-gcc-switches -fno-common"" +GOROOT/bin/go version: go version go1.17.6 darwin/amd64 +GOROOT/bin/go tool compile -V: compile version go1.17.6 +uname -v: Darwin Kernel Version 21.3.0: Wed Jan 5 21:37:58 PST 2022; root:xnu-8019.80.24~20/RELEASE_X86_64 +ProductName: macOS +ProductVersion: 12.2.1 +BuildVersion: 21D62 +lldb --version: lldb-1316.0.9.41 +Apple Swift version 5.6 (swiftlang-5.6.0.323.62 clang-1316.0.20.8) +gdb --version: GNU gdb (GDB) 9.1 +
+$ go version +go version go1.17.6 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/catena/Library/Caches/go-build"" +GOENV=""/Users/catena/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/catena/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/catena/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GOVCS="""" +GOVERSION=""go1.17.6"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/catena/go/src/github.com/catenacyber/go/src/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/pp/dc1dtf9x2js3v0jx_m010nqr0000gn/T/go-build4237848497=/tmp/go-build -gno-record-gcc-switches -fno-common"" +GOROOT/bin/go version: go version go1.17.6 darwin/amd64 +GOROOT/bin/go tool compile -V: compile version go1.17.6 +uname -v: Darwin Kernel Version 21.3.0: Wed Jan 5 21:37:58 PST 2022; root:xnu-8019.80.24~20/RELEASE_X86_64 +ProductName: macOS +ProductVersion: 12.2.1 +BuildVersion: 21D62 +lldb --version: lldb-1316.0.9.41 +Apple Swift version 5.6 (swiftlang-5.6.0.323.62 clang-1316.0.20.8) +gdb --version: GNU gdb (GDB) 9.1 +
+$ go version +go version go1.13 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/1041775/Library/Caches/go-build"" +GOENV=""/Users/1041775/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/1041775/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/Cellar/go/1.13/libexec"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.13/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/1041775/projects/js-scripts/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/d6/809nhvwd23nd_wryrw60j6hdms016p/T/go-build703352534=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+docker run -p 80:80 kennethreitz/httpbin ++ +Run the following program +```go +package main + +import ( + ""bytes"" + ""io/ioutil"" + ""log"" + ""net/http"" +) + +func main() { + reqBody := ioutil.NopCloser(bytes.NewBufferString(`{}`)) + req, err := http.NewRequest(""POST"", ""http://localhost:80/post"", reqBody) + if err != nil { + log.Fatalf(""Cannot create request: %v"", err) + } + res, err := http.DefaultClient.Do(req) + if err != nil { + log.Fatalf(""Cannot do: %v"", err) + } + defer res.Body.Close() + resBody, err := ioutil.ReadAll(res.Body) + if err != nil { + log.Fatalf(""Cannot read body: %v"", err) + } + log.Printf(""Response Body: %s"", resBody) +} +``` + +### What did you expect to see? +Content-Length header is set when it is received by the server. + + +### What did you see instead? +Content-Length header is missing when it is received by the server. + +
+2019/09/14 12:55:00 Response Body: {
+ ""args"": {},
+ ""data"": ""{}"",
+ ""files"": {},
+ ""form"": {},
+ ""headers"": {
+ ""Accept-Encoding"": ""gzip"",
+ ""Host"": ""localhost:80"",
+ ""Transfer-Encoding"": ""chunked"",
+ ""User-Agent"": ""Go-http-client/1.1""
+ },
+ ""json"": {},
+ ""origin"": ""172.17.0.1"",
+ ""url"": ""http://localhost:80/post""
+}
+
+
+Versus what I would receive if I use reqBody := bytes.NewBufferString(`{}`).
+
+
+2019/09/14 12:55:22 Response Body: {
+ ""args"": {},
+ ""data"": ""{}"",
+ ""files"": {},
+ ""form"": {},
+ ""headers"": {
+ ""Accept-Encoding"": ""gzip"",
+ ""Content-Length"": ""2"",
+ ""Host"": ""localhost:80"",
+ ""User-Agent"": ""Go-http-client/1.1""
+ },
+ ""json"": {},
+ ""origin"": ""172.17.0.1"",
+ ""url"": ""http://localhost:80/post""
+}
+
+",1.0,"net/http: Content-Length is not set in outgoing request when using ioutil.NopCloser -
+
+### What version of Go are you using (`go version`)?
+
++$ go version +go version go1.13 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/1041775/Library/Caches/go-build"" +GOENV=""/Users/1041775/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/1041775/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/Cellar/go/1.13/libexec"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.13/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/1041775/projects/js-scripts/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/d6/809nhvwd23nd_wryrw60j6hdms016p/T/go-build703352534=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+docker run -p 80:80 kennethreitz/httpbin ++ +Run the following program +```go +package main + +import ( + ""bytes"" + ""io/ioutil"" + ""log"" + ""net/http"" +) + +func main() { + reqBody := ioutil.NopCloser(bytes.NewBufferString(`{}`)) + req, err := http.NewRequest(""POST"", ""http://localhost:80/post"", reqBody) + if err != nil { + log.Fatalf(""Cannot create request: %v"", err) + } + res, err := http.DefaultClient.Do(req) + if err != nil { + log.Fatalf(""Cannot do: %v"", err) + } + defer res.Body.Close() + resBody, err := ioutil.ReadAll(res.Body) + if err != nil { + log.Fatalf(""Cannot read body: %v"", err) + } + log.Printf(""Response Body: %s"", resBody) +} +``` + +### What did you expect to see? +Content-Length header is set when it is received by the server. + + +### What did you see instead? +Content-Length header is missing when it is received by the server. + +
+2019/09/14 12:55:00 Response Body: {
+ ""args"": {},
+ ""data"": ""{}"",
+ ""files"": {},
+ ""form"": {},
+ ""headers"": {
+ ""Accept-Encoding"": ""gzip"",
+ ""Host"": ""localhost:80"",
+ ""Transfer-Encoding"": ""chunked"",
+ ""User-Agent"": ""Go-http-client/1.1""
+ },
+ ""json"": {},
+ ""origin"": ""172.17.0.1"",
+ ""url"": ""http://localhost:80/post""
+}
+
+
+Versus what I would receive if I use reqBody := bytes.NewBufferString(`{}`).
+
+
+2019/09/14 12:55:22 Response Body: {
+ ""args"": {},
+ ""data"": ""{}"",
+ ""files"": {},
+ ""form"": {},
+ ""headers"": {
+ ""Accept-Encoding"": ""gzip"",
+ ""Content-Length"": ""2"",
+ ""Host"": ""localhost:80"",
+ ""User-Agent"": ""Go-http-client/1.1""
+ },
+ ""json"": {},
+ ""origin"": ""172.17.0.1"",
+ ""url"": ""http://localhost:80/post""
+}
+
+",1,net http content length is not set in outgoing request when using ioutil nopcloser what version of go are you using go version go version go version darwin does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env go env output go env goarch gobin gocache users library caches go build goenv users library application support go env goexe goflags gohostarch gohostos darwin gonoproxy gonosumdb goos darwin gopath users go goprivate goproxy goroot usr local cellar go libexec gosumdb sum golang org gotmpdir gotooldir usr local cellar go libexec pkg tool darwin gccgo gccgo ar ar cc clang cxx clang cgo enabled gomod users projects js scripts go mod cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map var folders t go tmp go build gno record gcc switches fno common what did you do if possible provide a recipe for reproducing the error a complete runnable program is good a link on play golang org is best start a httpbin server locally docker run p kennethreitz httpbin run the following program go package main import bytes io ioutil log net http func main reqbody ioutil nopcloser bytes newbufferstring req err http newrequest post reqbody if err nil log fatalf cannot create request v err res err http defaultclient do req if err nil log fatalf cannot do v err defer res body close resbody err ioutil readall res body if err nil log fatalf cannot read body v err log printf response body s resbody what did you expect to see content length header is set when it is received by the server what did you see instead content length header is missing when it is received by the server response body args data files form headers accept encoding gzip host localhost transfer encoding chunked user agent go http client json origin url versus what i would receive if i use reqbody bytes newbufferstring response body args data files form headers accept encoding gzip content length host localhost user agent go http client json origin url ,1
+87368,10544380364.0,IssuesEvent,2019-10-02 16:48:15,golang/go,https://api.github.com/repos/golang/go,closed,net/http: document Request.Host value in HTTP/2,Documentation NeedsFix,"HTTP/2 has `:authority` rather than Host, but I presume the Request.Host filed is filled in with that value for HTTP/2 requests. That should be documented.
+
+/cc @bradfitz ",1.0,"net/http: document Request.Host value in HTTP/2 - HTTP/2 has `:authority` rather than Host, but I presume the Request.Host filed is filled in with that value for HTTP/2 requests. That should be documented.
+
+/cc @bradfitz ",1,net http document request host value in http http has authority rather than host but i presume the request host filed is filled in with that value for http requests that should be documented cc bradfitz ,1
+9444,4531817403.0,IssuesEvent,2016-09-08 04:56:46,golang/go,https://api.github.com/repos/golang/go,closed,x/build/cmd/coordinator: git sync to github going slowly,Builders,"@dsnet reports that the Github sync of the code is behind.
+
+Luckily we have logs now:
+
+http://farmer.golang.org/debug/watcher/go
+```
+watcher status for repo: ""go""
+
+2016-08-31T23:18:55Z 23s ago 35360 refs to push; pushing batch
+2016-08-31T23:13:28Z 5m50s ago 35560 refs to push; pushing batch
+2016-08-31T23:07:51Z 11m27s ago 35760 refs to push; pushing batch
+2016-08-31T23:02:08Z 17m10s ago 35960 refs to push; pushing batch
+2016-08-31T22:56:29Z 22m49s ago 36160 refs to push; pushing batch
+2016-08-31T22:50:55Z 28m22s ago 36360 refs to push; pushing batch
+2016-08-31T22:45:21Z 33m56s ago 36560 refs to push; pushing batch
+2016-08-31T22:39:42Z 39m35s ago 36760 refs to push; pushing batch
+2016-08-31T22:34:05Z 45m12s ago 36960 refs to push; pushing batch
+2016-08-31T22:28:25Z 50m53s ago 37160 refs to push; pushing batch
+2016-08-31T22:22:46Z 56m32s ago 37360 refs to push; pushing batch
+2016-08-31T22:17:14Z 1h2m3s ago 37560 refs to push; pushing batch
+2016-08-31T22:11:47Z 1h7m30s ago 37760 refs to push; pushing batch
+2016-08-31T22:06:20Z 1h12m58s ago 37960 refs to push; pushing batch
+2016-08-31T22:00:52Z 1h18m26s ago 38160 refs to push; pushing batch
+2016-08-31T21:55:23Z 1h23m55s ago 38360 refs to push; pushing batch
+2016-08-31T21:49:52Z 1h29m26s ago 38560 refs to push; pushing batch
+2016-08-31T21:44:06Z 1h35m12s ago 38760 refs to push; pushing batch
+2016-08-31T21:38:27Z 1h40m50s ago 38960 refs to push; pushing batch
+2016-08-31T21:32:50Z 1h46m27s ago 39160 refs to push; pushing batch
+2016-08-31T21:27:02Z 1h52m15s ago 39360 refs to push; pushing batch
+2016-08-31T21:21:27Z 1h57m50s ago 39560 refs to push; pushing batch
+2016-08-31T21:15:48Z 2h3m29s ago 39760 refs to push; pushing batch
+2016-08-31T21:10:12Z 2h9m5s ago 39960 refs to push; pushing batch
+2016-08-31T21:04:48Z 2h14m30s ago 40160 refs to push; pushing batch
+2016-08-31T20:59:23Z 2h19m54s ago 40360 refs to push; pushing batch
+2016-08-31T20:53:44Z 2h25m33s ago 40560 refs to push; pushing batch
+2016-08-31T20:48:09Z 2h31m9s ago 40760 refs to push; pushing batch
+2016-08-31T20:42:29Z 2h36m49s ago 40960 refs to push; pushing batch
+2016-08-31T20:36:43Z 2h42m34s ago 41160 refs to push; pushing batch
+2016-08-31T20:30:55Z 2h48m22s ago 41360 refs to push; pushing batch
+2016-08-31T20:25:11Z 2h54m7s ago 41560 refs to push; pushing batch
+2016-08-31T20:19:23Z 2h59m55s ago 41760 refs to push; pushing batch
+2016-08-31T20:13:47Z 3h5m31s ago 41960 refs to push; pushing batch
+2016-08-31T20:08:12Z 3h11m5s ago 42160 refs to push; pushing batch
+2016-08-31T20:02:40Z 3h16m37s ago 42360 refs to push; pushing batch
+2016-08-31T19:56:39Z 3h22m39s ago 42560 refs to push; pushing batch
+2016-08-31T19:50:51Z 3h28m26s ago 42760 refs to push; pushing batch
+2016-08-31T19:45:20Z 3h33m57s ago 42960 refs to push; pushing batch
+2016-08-31T19:45:20Z 3h33m57s ago sync: got 0 remote refs
+2016-08-31T19:43:13Z 3h36m4s ago sync: fetching remote refs
+2016-08-31T19:43:13Z 3h36m4s ago sync: got 42960 local refs
+2016-08-31T19:43:13Z 3h36m5s ago sync: fetching local refs
+2016-08-31T19:43:13Z 3h36m5s ago syncing to github, attempt 2
+2016-08-31T19:43:08Z 3h36m10s ago git push failure
+2016-08-31T19:41:01Z 3h38m17s ago 1 refs to push; pushing batch
+2016-08-31T19:41:01Z 3h38m17s ago sync: got 43078 remote refs
+2016-08-31T19:41:00Z 3h38m18s ago sync: fetching remote refs
+2016-08-31T19:41:00Z 3h38m18s ago sync: got 42960 local refs
+```
+
+This is where things went poorly:
+
+```
+2016-08-31T19:45:20Z 3h33m57s ago sync: got 0 remote refs
+2016-08-31T19:43:13Z 3h36m4s ago sync: fetching remote refs
+```
+
+The syncer got 0 remote refs from Github, so thought it had to push all 43000 refs, and has been working on it for the past 3 hours, doing 200 at a time, and doing them very slowly.
+
+Not sure why on either part.
+
+Last time we had problems we switched from the https git transport to the native and earlier ssh transport and things got super fast. Not sure why it's slow now.
+
+/cc @dsnet @broady @quentinmit ",1.0,"x/build/cmd/coordinator: git sync to github going slowly - @dsnet reports that the Github sync of the code is behind.
+
+Luckily we have logs now:
+
+http://farmer.golang.org/debug/watcher/go
+```
+watcher status for repo: ""go""
+
+2016-08-31T23:18:55Z 23s ago 35360 refs to push; pushing batch
+2016-08-31T23:13:28Z 5m50s ago 35560 refs to push; pushing batch
+2016-08-31T23:07:51Z 11m27s ago 35760 refs to push; pushing batch
+2016-08-31T23:02:08Z 17m10s ago 35960 refs to push; pushing batch
+2016-08-31T22:56:29Z 22m49s ago 36160 refs to push; pushing batch
+2016-08-31T22:50:55Z 28m22s ago 36360 refs to push; pushing batch
+2016-08-31T22:45:21Z 33m56s ago 36560 refs to push; pushing batch
+2016-08-31T22:39:42Z 39m35s ago 36760 refs to push; pushing batch
+2016-08-31T22:34:05Z 45m12s ago 36960 refs to push; pushing batch
+2016-08-31T22:28:25Z 50m53s ago 37160 refs to push; pushing batch
+2016-08-31T22:22:46Z 56m32s ago 37360 refs to push; pushing batch
+2016-08-31T22:17:14Z 1h2m3s ago 37560 refs to push; pushing batch
+2016-08-31T22:11:47Z 1h7m30s ago 37760 refs to push; pushing batch
+2016-08-31T22:06:20Z 1h12m58s ago 37960 refs to push; pushing batch
+2016-08-31T22:00:52Z 1h18m26s ago 38160 refs to push; pushing batch
+2016-08-31T21:55:23Z 1h23m55s ago 38360 refs to push; pushing batch
+2016-08-31T21:49:52Z 1h29m26s ago 38560 refs to push; pushing batch
+2016-08-31T21:44:06Z 1h35m12s ago 38760 refs to push; pushing batch
+2016-08-31T21:38:27Z 1h40m50s ago 38960 refs to push; pushing batch
+2016-08-31T21:32:50Z 1h46m27s ago 39160 refs to push; pushing batch
+2016-08-31T21:27:02Z 1h52m15s ago 39360 refs to push; pushing batch
+2016-08-31T21:21:27Z 1h57m50s ago 39560 refs to push; pushing batch
+2016-08-31T21:15:48Z 2h3m29s ago 39760 refs to push; pushing batch
+2016-08-31T21:10:12Z 2h9m5s ago 39960 refs to push; pushing batch
+2016-08-31T21:04:48Z 2h14m30s ago 40160 refs to push; pushing batch
+2016-08-31T20:59:23Z 2h19m54s ago 40360 refs to push; pushing batch
+2016-08-31T20:53:44Z 2h25m33s ago 40560 refs to push; pushing batch
+2016-08-31T20:48:09Z 2h31m9s ago 40760 refs to push; pushing batch
+2016-08-31T20:42:29Z 2h36m49s ago 40960 refs to push; pushing batch
+2016-08-31T20:36:43Z 2h42m34s ago 41160 refs to push; pushing batch
+2016-08-31T20:30:55Z 2h48m22s ago 41360 refs to push; pushing batch
+2016-08-31T20:25:11Z 2h54m7s ago 41560 refs to push; pushing batch
+2016-08-31T20:19:23Z 2h59m55s ago 41760 refs to push; pushing batch
+2016-08-31T20:13:47Z 3h5m31s ago 41960 refs to push; pushing batch
+2016-08-31T20:08:12Z 3h11m5s ago 42160 refs to push; pushing batch
+2016-08-31T20:02:40Z 3h16m37s ago 42360 refs to push; pushing batch
+2016-08-31T19:56:39Z 3h22m39s ago 42560 refs to push; pushing batch
+2016-08-31T19:50:51Z 3h28m26s ago 42760 refs to push; pushing batch
+2016-08-31T19:45:20Z 3h33m57s ago 42960 refs to push; pushing batch
+2016-08-31T19:45:20Z 3h33m57s ago sync: got 0 remote refs
+2016-08-31T19:43:13Z 3h36m4s ago sync: fetching remote refs
+2016-08-31T19:43:13Z 3h36m4s ago sync: got 42960 local refs
+2016-08-31T19:43:13Z 3h36m5s ago sync: fetching local refs
+2016-08-31T19:43:13Z 3h36m5s ago syncing to github, attempt 2
+2016-08-31T19:43:08Z 3h36m10s ago git push failure
+2016-08-31T19:41:01Z 3h38m17s ago 1 refs to push; pushing batch
+2016-08-31T19:41:01Z 3h38m17s ago sync: got 43078 remote refs
+2016-08-31T19:41:00Z 3h38m18s ago sync: fetching remote refs
+2016-08-31T19:41:00Z 3h38m18s ago sync: got 42960 local refs
+```
+
+This is where things went poorly:
+
+```
+2016-08-31T19:45:20Z 3h33m57s ago sync: got 0 remote refs
+2016-08-31T19:43:13Z 3h36m4s ago sync: fetching remote refs
+```
+
+The syncer got 0 remote refs from Github, so thought it had to push all 43000 refs, and has been working on it for the past 3 hours, doing 200 at a time, and doing them very slowly.
+
+Not sure why on either part.
+
+Last time we had problems we switched from the https git transport to the native and earlier ssh transport and things got super fast. Not sure why it's slow now.
+
+/cc @dsnet @broady @quentinmit ",0,x build cmd coordinator git sync to github going slowly dsnet reports that the github sync of the code is behind luckily we have logs now watcher status for repo go ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago refs to push pushing batch ago sync got remote refs ago sync fetching remote refs ago sync got local refs ago sync fetching local refs ago syncing to github attempt ago git push failure ago refs to push pushing batch ago sync got remote refs ago sync fetching remote refs ago sync got local refs this is where things went poorly ago sync got remote refs ago sync fetching remote refs the syncer got remote refs from github so thought it had to push all refs and has been working on it for the past hours doing at a time and doing them very slowly not sure why on either part last time we had problems we switched from the https git transport to the native and earlier ssh transport and things got super fast not sure why it s slow now cc dsnet broady quentinmit ,0
+115586,11882665464.0,IssuesEvent,2020-03-27 14:45:32,golang/go,https://api.github.com/repos/golang/go,opened,cmd/asm: update where NOFRAME is valid,Documentation,"The current comment for `NOFRAME` in `runtime/textflag.h` says:
+```
+// TODO(mwhudson): only implemented for ppc64x at present.
+```
+It's been implemented for lots (all?) architectures since.
+Check our coverage and update (delete) this comment.
+
+@mwhudson @zhangfannie ",1.0,"cmd/asm: update where NOFRAME is valid - The current comment for `NOFRAME` in `runtime/textflag.h` says:
+```
+// TODO(mwhudson): only implemented for ppc64x at present.
+```
+It's been implemented for lots (all?) architectures since.
+Check our coverage and update (delete) this comment.
+
+@mwhudson @zhangfannie ",1,cmd asm update where noframe is valid the current comment for noframe in runtime textflag h says todo mwhudson only implemented for at present it s been implemented for lots all architectures since check our coverage and update delete this comment mwhudson zhangfannie ,1
+70633,18243693197.0,IssuesEvent,2021-10-01 15:38:20,golang/go,https://api.github.com/repos/golang/go,opened,x/build/cmd/gomote: enable Identity Aware Proxy,Builders NeedsInvestigation,"This tracks the enabling of Identity Aware Proxy for the new gomote API and its associated work.
+
+This is a component of the project to revamp the security model used by gomote #47521
+@golang/release ",1.0,"x/build/cmd/gomote: enable Identity Aware Proxy - This tracks the enabling of Identity Aware Proxy for the new gomote API and its associated work.
+
+This is a component of the project to revamp the security model used by gomote #47521
+@golang/release ",0,x build cmd gomote enable identity aware proxy this tracks the enabling of identity aware proxy for the new gomote api and its associated work this is a component of the project to revamp the security model used by gomote golang release ,0
+8843,3226051888.0,IssuesEvent,2015-10-10 00:49:18,golang/go,https://api.github.com/repos/golang/go,closed,compress/flate: Inconsistent error handling,Documentation,"The package defines a ReadError which ""reports an error encountered while reading input"" and a WriteError which ""reports an error encountered while writing output"". However, a quick peruse through the package code shows that WriteError is never used. Secondly, its use of ReadError is inconsistent.
+
+There are 3 instances where the Reader is used in inflate.go: [L635](https://github.com/golang/go/blob/b03129aa2758a337823071ffda37e49da5a814d0/src/compress/flate/inflate.go#L635), [L677](https://github.com/golang/go/blob/b03129aa2758a337823071ffda37e49da5a814d0/src/compress/flate/inflate.go#L667), and [L699](https://github.com/golang/go/blob/b03129aa2758a337823071ffda37e49da5a814d0/src/compress/flate/inflate.go#L699). The call to ReadByte lacks a the wrapper for ReadError. Interestingly, the bulk of DEFLATE compression will be done through the ReadByte call, thus, usage of ReadError seems to only occur when decoding a raw block.
+
+Should use of ReadError and WriteError be removed and marked as deprecated? Or should the library properly handle both error types? Other packages don't seem to wrap IO errors with package specific errors.",1.0,"compress/flate: Inconsistent error handling - The package defines a ReadError which ""reports an error encountered while reading input"" and a WriteError which ""reports an error encountered while writing output"". However, a quick peruse through the package code shows that WriteError is never used. Secondly, its use of ReadError is inconsistent.
+
+There are 3 instances where the Reader is used in inflate.go: [L635](https://github.com/golang/go/blob/b03129aa2758a337823071ffda37e49da5a814d0/src/compress/flate/inflate.go#L635), [L677](https://github.com/golang/go/blob/b03129aa2758a337823071ffda37e49da5a814d0/src/compress/flate/inflate.go#L667), and [L699](https://github.com/golang/go/blob/b03129aa2758a337823071ffda37e49da5a814d0/src/compress/flate/inflate.go#L699). The call to ReadByte lacks a the wrapper for ReadError. Interestingly, the bulk of DEFLATE compression will be done through the ReadByte call, thus, usage of ReadError seems to only occur when decoding a raw block.
+
+Should use of ReadError and WriteError be removed and marked as deprecated? Or should the library properly handle both error types? Other packages don't seem to wrap IO errors with package specific errors.",1,compress flate inconsistent error handling the package defines a readerror which reports an error encountered while reading input and a writeerror which reports an error encountered while writing output however a quick peruse through the package code shows that writeerror is never used secondly its use of readerror is inconsistent there are instances where the reader is used in inflate go and the call to readbyte lacks a the wrapper for readerror interestingly the bulk of deflate compression will be done through the readbyte call thus usage of readerror seems to only occur when decoding a raw block should use of readerror and writeerror be removed and marked as deprecated or should the library properly handle both error types other packages don t seem to wrap io errors with package specific errors ,1
+126941,10440858504.0,IssuesEvent,2019-09-18 09:34:14,golang/go,https://api.github.com/repos/golang/go,reopened,syscall: TestAmbientCapsUserns test failing with operation not permitted,NeedsInvestigation Testing,"
+### What version of Go are you using (`go version`)?
+
++$ go version +1.13-rc2 ++ +### Does this issue reproduce with the latest release? + +yes + +### What operating system and processor architecture are you using (`go env`)? + +Ubuntu devel, 19.10 + + + +### What did you do? + +trying to build the source code, I get + +``` +ok sync/atomic 0.047s +--- FAIL: TestAmbientCapsUserns (0.00s) + exec_linux_test.go:667: fork/exec /tmp/gotest465803457: operation not permitted +FAIL +FAIL syscall 0.033s +``` + +I suspect Ubuntu builders should ignore that test?",1.0,"syscall: TestAmbientCapsUserns test failing with operation not permitted - +### What version of Go are you using (`go version`)? + +
+$ go version +1.13-rc2 ++ +### Does this issue reproduce with the latest release? + +yes + +### What operating system and processor architecture are you using (`go env`)? + +Ubuntu devel, 19.10 + + + +### What did you do? + +trying to build the source code, I get + +``` +ok sync/atomic 0.047s +--- FAIL: TestAmbientCapsUserns (0.00s) + exec_linux_test.go:667: fork/exec /tmp/gotest465803457: operation not permitted +FAIL +FAIL syscall 0.033s +``` + +I suspect Ubuntu builders should ignore that test?",0,syscall testambientcapsuserns test failing with operation not permitted what version of go are you using go version go version does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env ubuntu devel what did you do trying to build the source code i get ok sync atomic fail testambientcapsuserns exec linux test go fork exec tmp operation not permitted fail fail syscall i suspect ubuntu builders should ignore that test ,0 +123510,12199938714.0,IssuesEvent,2020-04-30 03:08:29,golang/go,https://api.github.com/repos/golang/go,closed,debug/gosym: Table.Files doc is stale?,Documentation NeedsInvestigation,"https://golang.org/pkg/debug/gosym/#Table says: + +```go + Files map[string]*Obj // nil for Go 1.2 and later binaries +``` + +But empirically that is not true. It's populated. + +And https://golang.org/pkg/debug/gosym/#Obj.Paths says: + +> // Use the keys of Table.Files to obtain a list of source files. + +... which further suggests it's meant to be non-nil. + +/cc @randall77 @ianlancetaylor (not sure who owns this) +",1.0,"debug/gosym: Table.Files doc is stale? - https://golang.org/pkg/debug/gosym/#Table says: + +```go + Files map[string]*Obj // nil for Go 1.2 and later binaries +``` + +But empirically that is not true. It's populated. + +And https://golang.org/pkg/debug/gosym/#Obj.Paths says: + +> // Use the keys of Table.Files to obtain a list of source files. + +... which further suggests it's meant to be non-nil. + +/cc @randall77 @ianlancetaylor (not sure who owns this) +",1,debug gosym table files doc is stale says go files map obj nil for go and later binaries but empirically that is not true it s populated and says use the keys of table files to obtain a list of source files which further suggests it s meant to be non nil cc ianlancetaylor not sure who owns this ,1 +16172,4021320195.0,IssuesEvent,2016-05-16 21:30:58,golang/go,https://api.github.com/repos/golang/go,closed,doc: update docs as a followup of deprecation of 1.4 dependent code in x/tools,Documentation,"A few packages in golang.org/x/tools have been removed as part of https://groups.google.com/forum/#!topic/golang-announce/qu_rAphYdxY, and the deletion makes a few dead links on https://golang.org/doc/cmd; e.g., https://godoc.org/golang.org/x/tools/cmd/vet. It needs to be updated for avoiding confusion.",1.0,"doc: update docs as a followup of deprecation of 1.4 dependent code in x/tools - A few packages in golang.org/x/tools have been removed as part of https://groups.google.com/forum/#!topic/golang-announce/qu_rAphYdxY, and the deletion makes a few dead links on https://golang.org/doc/cmd; e.g., https://godoc.org/golang.org/x/tools/cmd/vet. It needs to be updated for avoiding confusion.",1,doc update docs as a followup of deprecation of dependent code in x tools a few packages in golang org x tools have been removed as part of and the deletion makes a few dead links on e g it needs to be updated for avoiding confusion ,1 +3198,2743660174.0,IssuesEvent,2015-04-21 23:15:17,golang/go,https://api.github.com/repos/golang/go,closed,math/big: clarify addVW and subVW preconditions,Documentation,"I'm working on an arm64 math/big implementation. + +The docs for addVW (arith.go) say: + +```go +// Argument y must be either 0 or 1. +func addVW_g(z, x []Word, y Word) (c Word) +``` + +But e.g. running `TestFloatSetPrec` sends in many values for y. The existing implementations handle them correctly. I care because my initial arm64 implementation transfers y directly to the carry flag at the start, which only works if y is 0 or 1. + +subVW does not say that y must be either 0 or 1, but in practice it appears to be, and the semantics are less clear if it is not. However, TestFunVW appears to intentionally send in y=2 to confirm that there's no bad behavior when z and x are nil. + +What preconditions do addVW and subVW actually have? + +@griesemer feel free to clarify here or just send a CL. + +(Additional docs in general in arith.go would be awesome. Right now I'm inferring shlVU and friends from the existing code.) + +",1.0,"math/big: clarify addVW and subVW preconditions - I'm working on an arm64 math/big implementation. + +The docs for addVW (arith.go) say: + +```go +// Argument y must be either 0 or 1. +func addVW_g(z, x []Word, y Word) (c Word) +``` + +But e.g. running `TestFloatSetPrec` sends in many values for y. The existing implementations handle them correctly. I care because my initial arm64 implementation transfers y directly to the carry flag at the start, which only works if y is 0 or 1. + +subVW does not say that y must be either 0 or 1, but in practice it appears to be, and the semantics are less clear if it is not. However, TestFunVW appears to intentionally send in y=2 to confirm that there's no bad behavior when z and x are nil. + +What preconditions do addVW and subVW actually have? + +@griesemer feel free to clarify here or just send a CL. + +(Additional docs in general in arith.go would be awesome. Right now I'm inferring shlVU and friends from the existing code.) + +",1,math big clarify addvw and subvw preconditions i m working on an math big implementation the docs for addvw arith go say go argument y must be either or func addvw g z x word y word c word but e g running testfloatsetprec sends in many values for y the existing implementations handle them correctly i care because my initial implementation transfers y directly to the carry flag at the start which only works if y is or subvw does not say that y must be either or but in practice it appears to be and the semantics are less clear if it is not however testfunvw appears to intentionally send in y to confirm that there s no bad behavior when z and x are nil what preconditions do addvw and subvw actually have griesemer feel free to clarify here or just send a cl additional docs in general in arith go would be awesome right now i m inferring shlvu and friends from the existing code ,1 +21592,4727222019.0,IssuesEvent,2016-10-18 12:54:20,golang/go,https://api.github.com/repos/golang/go,closed,io: PipeWriter.Write should not block when writing zero bytes,Documentation NeedsDecision,"`io.PipeWriter.Write([]byte{})` blocks when no readers are waiting at the other end of the pipe. To unblock the pipe **zero** or more bytes must be read from `io.PipeWriter.Read`. + +I expect `io.PipeWriter.Write([]byte{})` to not ever block. + +See https://groups.google.com/forum/#!topic/golang-nuts/nRPhBt0zoAM for the discussion. + +See http://play.golang.org/p/MNSyKafKYf for an example.",1.0,"io: PipeWriter.Write should not block when writing zero bytes - `io.PipeWriter.Write([]byte{})` blocks when no readers are waiting at the other end of the pipe. To unblock the pipe **zero** or more bytes must be read from `io.PipeWriter.Read`. + +I expect `io.PipeWriter.Write([]byte{})` to not ever block. + +See https://groups.google.com/forum/#!topic/golang-nuts/nRPhBt0zoAM for the discussion. + +See http://play.golang.org/p/MNSyKafKYf for an example.",1,io pipewriter write should not block when writing zero bytes io pipewriter write byte blocks when no readers are waiting at the other end of the pipe to unblock the pipe zero or more bytes must be read from io pipewriter read i expect io pipewriter write byte to not ever block see for the discussion see for an example ,1 +200715,22833841366.0,IssuesEvent,2022-07-12 14:59:22,golang/go,https://api.github.com/repos/golang/go,closed,net/http/httputil: NewSingleHostReverseProxy - omit X-Forwarded-For not working [1.18 backport],Security release-blocker CherryPickApproved,"@neild requested issue #53423 to be considered for backport to the next 1.18 minor release. + +> @gopherbot please open backport issues. +",True,"net/http/httputil: NewSingleHostReverseProxy - omit X-Forwarded-For not working [1.18 backport] - @neild requested issue #53423 to be considered for backport to the next 1.18 minor release. + +> @gopherbot please open backport issues. +",0,net http httputil newsinglehostreverseproxy omit x forwarded for not working neild requested issue to be considered for backport to the next minor release gopherbot please open backport issues ,0 +106231,11473388820.0,IssuesEvent,2020-02-09 22:51:10,golang/go,https://api.github.com/repos/golang/go,closed,wiki: SettingGOPATH (redesign),Documentation NeedsInvestigation,"suggested to overwrite that [page](https://github.com/golang/go/wiki/SettingGOPATH) + +Basic information on GOPATH is accessible by typing `go help gopath`. + +``` +$ go help gopath | head -7 +The Go path is used to resolve import statements. +It is implemented by and documented in the go/build package. + +The GOPATH environment variable lists places to look for Go code. +On Unix, the value is a colon-separated string. +On Windows, the value is a semicolon-separated string. +On Plan 9, the value is a list. +$ +``` + +The value is unset, but a default is encoded in the go compiler. + +($HOME/go on Unix, %USERPROFILE%\go on Windows, and $home/go on Plan 9) + +login shells (Unix) + +``` +$ echo ""export GOPATH=$HOME/go"" >> ~/.profile +$ +``` + +``` +% echo ""setenv GOPATH $HOME/go"" >> ~/.login +% +``` + +interactive shells (Unix) + +``` +$ echo ""export GOPATH=$HOME/go"" >> ~/.bashrc +$ +``` + +``` +% echo ""setenv GOPATH $HOME/go"" >> ~/.cshrc +% +``` + +sourced files (Unix) + +``` +$ cat gopher +# GNU Bourne-Again SHell + +export GOPATH=$HOME/go:/usr/share/gocode +$ . ~/gopher +$ +``` + +``` +% cat go-gopher +# Berkeley UNIX C shell + +setenv GOPATH $HOME/go:/usr/share/gocode +% source ~/go-gopher +% +``` + +scripts (Windows) + +``` +C:\>TYPE gopher.bat +@ECHO OFF +SET GOPATH=%USERPROFILE%\go +C:\> +``` + +``` +PS C:\> gc gopher.ps1 +$env:GOPATH = ""$HOME\go"" +PS C:\> .\gopher.ps1 +PS C:\> +``` + +sourced file (Plan 9) + +``` +% cat gopher +# Rc shell (usually a value of a single component) + +GOPATH=$home/go +% . gopher +% +``` + +using GOENV (all) + +``` +$ go version +go version go1.13.3 linux/386 +$ ed $GOROOT/src/os/file.go +17452 +406,415p +// UserConfigDir returns the default root directory to use for user-specific +// configuration data. Users should create their own application-specific +// subdirectory within this one and use that. +// +// On Unix systems, it returns $XDG_CONFIG_HOME as specified by +// https://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html if +// non-empty, else $HOME/.config. +// On Darwin, it returns $HOME/Library/Application Support. +// On Windows, it returns %AppData%. +// On Plan 9, it returns $home/lib. +q +$ +``` + +NB: The root of the Go tree cannot be included as a value in the Go path.",1.0,"wiki: SettingGOPATH (redesign) - suggested to overwrite that [page](https://github.com/golang/go/wiki/SettingGOPATH) + +Basic information on GOPATH is accessible by typing `go help gopath`. + +``` +$ go help gopath | head -7 +The Go path is used to resolve import statements. +It is implemented by and documented in the go/build package. + +The GOPATH environment variable lists places to look for Go code. +On Unix, the value is a colon-separated string. +On Windows, the value is a semicolon-separated string. +On Plan 9, the value is a list. +$ +``` + +The value is unset, but a default is encoded in the go compiler. + +($HOME/go on Unix, %USERPROFILE%\go on Windows, and $home/go on Plan 9) + +login shells (Unix) + +``` +$ echo ""export GOPATH=$HOME/go"" >> ~/.profile +$ +``` + +``` +% echo ""setenv GOPATH $HOME/go"" >> ~/.login +% +``` + +interactive shells (Unix) + +``` +$ echo ""export GOPATH=$HOME/go"" >> ~/.bashrc +$ +``` + +``` +% echo ""setenv GOPATH $HOME/go"" >> ~/.cshrc +% +``` + +sourced files (Unix) + +``` +$ cat gopher +# GNU Bourne-Again SHell + +export GOPATH=$HOME/go:/usr/share/gocode +$ . ~/gopher +$ +``` + +``` +% cat go-gopher +# Berkeley UNIX C shell + +setenv GOPATH $HOME/go:/usr/share/gocode +% source ~/go-gopher +% +``` + +scripts (Windows) + +``` +C:\>TYPE gopher.bat +@ECHO OFF +SET GOPATH=%USERPROFILE%\go +C:\> +``` + +``` +PS C:\> gc gopher.ps1 +$env:GOPATH = ""$HOME\go"" +PS C:\> .\gopher.ps1 +PS C:\> +``` + +sourced file (Plan 9) + +``` +% cat gopher +# Rc shell (usually a value of a single component) + +GOPATH=$home/go +% . gopher +% +``` + +using GOENV (all) + +``` +$ go version +go version go1.13.3 linux/386 +$ ed $GOROOT/src/os/file.go +17452 +406,415p +// UserConfigDir returns the default root directory to use for user-specific +// configuration data. Users should create their own application-specific +// subdirectory within this one and use that. +// +// On Unix systems, it returns $XDG_CONFIG_HOME as specified by +// https://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html if +// non-empty, else $HOME/.config. +// On Darwin, it returns $HOME/Library/Application Support. +// On Windows, it returns %AppData%. +// On Plan 9, it returns $home/lib. +q +$ +``` + +NB: The root of the Go tree cannot be included as a value in the Go path.",1,wiki settinggopath redesign suggested to overwrite that basic information on gopath is accessible by typing go help gopath go help gopath head the go path is used to resolve import statements it is implemented by and documented in the go build package the gopath environment variable lists places to look for go code on unix the value is a colon separated string on windows the value is a semicolon separated string on plan the value is a list the value is unset but a default is encoded in the go compiler home go on unix userprofile go on windows and home go on plan login shells unix echo export gopath home go profile echo setenv gopath home go login interactive shells unix echo export gopath home go bashrc echo setenv gopath home go cshrc sourced files unix cat gopher gnu bourne again shell export gopath home go usr share gocode gopher cat go gopher berkeley unix c shell setenv gopath home go usr share gocode source go gopher scripts windows c type gopher bat echo off set gopath userprofile go c ps c gc gopher env gopath home go ps c gopher ps c sourced file plan cat gopher rc shell usually a value of a single component gopath home go gopher using goenv all go version go version linux ed goroot src os file go userconfigdir returns the default root directory to use for user specific configuration data users should create their own application specific subdirectory within this one and use that on unix systems it returns xdg config home as specified by if non empty else home config on darwin it returns home library application support on windows it returns appdata on plan it returns home lib q nb the root of the go tree cannot be included as a value in the go path ,1 +130269,12425750074.0,IssuesEvent,2020-05-24 17:47:38,golang/go,https://api.github.com/repos/golang/go,closed,syscall/js: document more clearly how early js.Func can be released,Arch-Wasm Documentation NeedsFix OS-JS,"The documentation for [`js.Func`](https://pkg.go.dev/syscall/js#Func) currently says: + +> Func.Release must be called to free up resources when the function will not be used any more. + +> Release frees up resources allocated for the function. The function must not be invoked after calling Release. + +Based on [a comment](https://go-review.googlesource.com/c/go/+/226204/2/src/net/http/roundtrip_js.go#113) from @neelance and my understanding of the code, it seems the intention is for it to be safe to release a `js.Func` at a time when no future invocations of the `js.Func` will be made. An invocation here means the time the execution begins. So, if a `js.Func` will only be invoked once, it is safe to release a `js.Func` right away in the Go function that will be executing: + +```Go +var f js.Func +f = js.FuncOf(func(this js.Value, args []js.Value) interface{} { + f.Release() // okay, even though this Go function is still in the middle of executing + ... +``` + +I believe the documentation needs to make this more clear, so that users can rely on this behavior. + +/cc @neelance @hajimehoshi @johanbrandhorst",1.0,"syscall/js: document more clearly how early js.Func can be released - The documentation for [`js.Func`](https://pkg.go.dev/syscall/js#Func) currently says: + +> Func.Release must be called to free up resources when the function will not be used any more. + +> Release frees up resources allocated for the function. The function must not be invoked after calling Release. + +Based on [a comment](https://go-review.googlesource.com/c/go/+/226204/2/src/net/http/roundtrip_js.go#113) from @neelance and my understanding of the code, it seems the intention is for it to be safe to release a `js.Func` at a time when no future invocations of the `js.Func` will be made. An invocation here means the time the execution begins. So, if a `js.Func` will only be invoked once, it is safe to release a `js.Func` right away in the Go function that will be executing: + +```Go +var f js.Func +f = js.FuncOf(func(this js.Value, args []js.Value) interface{} { + f.Release() // okay, even though this Go function is still in the middle of executing + ... +``` + +I believe the documentation needs to make this more clear, so that users can rely on this behavior. + +/cc @neelance @hajimehoshi @johanbrandhorst",1,syscall js document more clearly how early js func can be released the documentation for currently says func release must be called to free up resources when the function will not be used any more release frees up resources allocated for the function the function must not be invoked after calling release based on from neelance and my understanding of the code it seems the intention is for it to be safe to release a js func at a time when no future invocations of the js func will be made an invocation here means the time the execution begins so if a js func will only be invoked once it is safe to release a js func right away in the go function that will be executing go var f js func f js funcof func this js value args js value interface f release okay even though this go function is still in the middle of executing i believe the documentation needs to make this more clear so that users can rely on this behavior cc neelance hajimehoshi johanbrandhorst,1 +24332,5050089162.0,IssuesEvent,2016-12-20 17:39:15,golang/go,https://api.github.com/repos/golang/go,closed,net: LookupCNAME only works for hostnames with CNAME records,Documentation NeedsFix,"### What version of Go are you using (`go version`)? + +`go version go1.7.3 linux/amd64` + +### What operating system and processor architecture are you using (`go env`)? + +```sh +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH="""" +GORACE="""" +GOROOT=""/usr/lib/google-golang"" +GOTOOLDIR=""/usr/lib/google-golang/pkg/tool/linux_amd64"" +CC=""gcc"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build668040631=/tmp/go-build -gno-record-gcc-switches"" +CXX=""g++"" +CGO_ENABLED=""1"" +``` + +### What did you do? + +```go +package main + +import ( + ""fmt"" + ""net"" +) + +func main() { + if cname, err := net.LookupCNAME(""www.google.com""); err != nil { + fmt.Printf(""lookup failed: %q\n"", err) + } else { + fmt.Printf(""lookup success: %s\n"", cname) + } +} +``` + +### What did you expect to see? + +[The documentation](https://golang.org/pkg/net/#LookupCNAME) says ""LookupCNAME returns the canonical DNS host for the given name."" To me, this means that it returns the canonical name as provided by the [POSIX `getaddrinfo()` function](http://pubs.opengroup.org/onlinepubs/9699919799/functions/getaddrinfo.html) when given the `AI_CANONNAME` flag. So I expected the following: + +`lookup success: www.google.com` + +### What did you see instead? + +`lookup failed: ""lookup www.google.com on 127.0.1.1:53: no such host""` + +It turns out that `LookupCNAME` simply resolves CNAME records, it does NOT return the canonical DNS host for the given name as documented. + +### Proposed change + +Ideally `LookupCNAME` would return the canonical hostname as provided by the POSIX `getaddrinfo()` function. + +If the intention of the `LookupCNAME` function is to only resolve CNAME records, then replace the first sentence of the documentation with: + +> LookupCNAME resolves the CNAME DNS record for the given name. It is an error if the given hostname does not have a CNAME record.",1.0,"net: LookupCNAME only works for hostnames with CNAME records - ### What version of Go are you using (`go version`)? + +`go version go1.7.3 linux/amd64` + +### What operating system and processor architecture are you using (`go env`)? + +```sh +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH="""" +GORACE="""" +GOROOT=""/usr/lib/google-golang"" +GOTOOLDIR=""/usr/lib/google-golang/pkg/tool/linux_amd64"" +CC=""gcc"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build668040631=/tmp/go-build -gno-record-gcc-switches"" +CXX=""g++"" +CGO_ENABLED=""1"" +``` + +### What did you do? + +```go +package main + +import ( + ""fmt"" + ""net"" +) + +func main() { + if cname, err := net.LookupCNAME(""www.google.com""); err != nil { + fmt.Printf(""lookup failed: %q\n"", err) + } else { + fmt.Printf(""lookup success: %s\n"", cname) + } +} +``` + +### What did you expect to see? + +[The documentation](https://golang.org/pkg/net/#LookupCNAME) says ""LookupCNAME returns the canonical DNS host for the given name."" To me, this means that it returns the canonical name as provided by the [POSIX `getaddrinfo()` function](http://pubs.opengroup.org/onlinepubs/9699919799/functions/getaddrinfo.html) when given the `AI_CANONNAME` flag. So I expected the following: + +`lookup success: www.google.com` + +### What did you see instead? + +`lookup failed: ""lookup www.google.com on 127.0.1.1:53: no such host""` + +It turns out that `LookupCNAME` simply resolves CNAME records, it does NOT return the canonical DNS host for the given name as documented. + +### Proposed change + +Ideally `LookupCNAME` would return the canonical hostname as provided by the POSIX `getaddrinfo()` function. + +If the intention of the `LookupCNAME` function is to only resolve CNAME records, then replace the first sentence of the documentation with: + +> LookupCNAME resolves the CNAME DNS record for the given name. It is an error if the given hostname does not have a CNAME record.",1,net lookupcname only works for hostnames with cname records what version of go are you using go version go version linux what operating system and processor architecture are you using go env sh goarch gobin goexe gohostarch gohostos linux goos linux gopath gorace goroot usr lib google golang gotooldir usr lib google golang pkg tool linux cc gcc gogccflags fpic pthread fmessage length fdebug prefix map tmp go tmp go build gno record gcc switches cxx g cgo enabled what did you do go package main import fmt net func main if cname err net lookupcname err nil fmt printf lookup failed q n err else fmt printf lookup success s n cname what did you expect to see says lookupcname returns the canonical dns host for the given name to me this means that it returns the canonical name as provided by the when given the ai canonname flag so i expected the following lookup success what did you see instead lookup failed lookup on no such host it turns out that lookupcname simply resolves cname records it does not return the canonical dns host for the given name as documented proposed change ideally lookupcname would return the canonical hostname as provided by the posix getaddrinfo function if the intention of the lookupcname function is to only resolve cname records then replace the first sentence of the documentation with lookupcname resolves the cname dns record for the given name it is an error if the given hostname does not have a cname record ,1 +12290,3594534024.0,IssuesEvent,2016-02-02 00:10:50,golang/go,https://api.github.com/repos/golang/go,closed,blog: /race-detector points to a dead link ,Documentation,`go get -race code.google.com/p/go.blog/support/racy` should be `go get -race golang.org/x/blog/support/racy`,1.0,blog: /race-detector points to a dead link - `go get -race code.google.com/p/go.blog/support/racy` should be `go get -race golang.org/x/blog/support/racy`,1,blog race detector points to a dead link go get race code google com p go blog support racy should be go get race golang org x blog support racy ,1 +23419,4934573006.0,IssuesEvent,2016-11-28 19:28:17,golang/go,https://api.github.com/repos/golang/go,closed,net/http: document that Etags in ServeContent must be RFC 7232 compliant,Documentation,"Change f3862742b67a84edf939f41276360ada4e7197a6 ([CL/32014](http://golang.org/cl/32014)) caused a regression in the behavior of http.ServeContent such that explicitly setting the Etag no longer caused the server to return status 304 when the Etags match. + +```go +func Test(t *testing.T) { + fs := http.FileServer(http.Dir(""/tmp"")) + h := http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { + // Delete if-modified-since header so that ETags can be used instead of the standard cache policy. + r.Header.Del(""If-Modified-Since"") + + // Set ETag to to uniquely identify the unchanged static asset. + w.Header().Set(""Etag"", ""6"") + + fs.ServeHTTP(w, r) + }) + ts := httptest.NewServer(h) + + // Ensure /tmp/test.txt exists. + if err := ioutil.WriteFile(""/tmp/test.txt"", nil, 0664); err != nil { + t.Fatal(err) + } + + var c http.Client + req, err := http.NewRequest(""GET"", ts.URL+""/test.txt"", nil) + if err != nil { + t.Fatal(err) + } + req.Header.Add(""If-None-Match"", ""6"") // Same Etag as above + resp, err := c.Do(req) + if err != nil { + t.Fatal(err) + } + if resp.StatusCode != 304 { + t.Error() + } +} +``` + +I believe this is a regression because the documentation for `ServeContent` explicitly says: +> If the caller has set w's ETag header, ServeContent uses it to handle requests using If-Range and If-None-Match. + +\cc @bradfitz ",1.0,"net/http: document that Etags in ServeContent must be RFC 7232 compliant - Change f3862742b67a84edf939f41276360ada4e7197a6 ([CL/32014](http://golang.org/cl/32014)) caused a regression in the behavior of http.ServeContent such that explicitly setting the Etag no longer caused the server to return status 304 when the Etags match. + +```go +func Test(t *testing.T) { + fs := http.FileServer(http.Dir(""/tmp"")) + h := http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { + // Delete if-modified-since header so that ETags can be used instead of the standard cache policy. + r.Header.Del(""If-Modified-Since"") + + // Set ETag to to uniquely identify the unchanged static asset. + w.Header().Set(""Etag"", ""6"") + + fs.ServeHTTP(w, r) + }) + ts := httptest.NewServer(h) + + // Ensure /tmp/test.txt exists. + if err := ioutil.WriteFile(""/tmp/test.txt"", nil, 0664); err != nil { + t.Fatal(err) + } + + var c http.Client + req, err := http.NewRequest(""GET"", ts.URL+""/test.txt"", nil) + if err != nil { + t.Fatal(err) + } + req.Header.Add(""If-None-Match"", ""6"") // Same Etag as above + resp, err := c.Do(req) + if err != nil { + t.Fatal(err) + } + if resp.StatusCode != 304 { + t.Error() + } +} +``` + +I believe this is a regression because the documentation for `ServeContent` explicitly says: +> If the caller has set w's ETag header, ServeContent uses it to handle requests using If-Range and If-None-Match. + +\cc @bradfitz ",1,net http document that etags in servecontent must be rfc compliant change caused a regression in the behavior of http servecontent such that explicitly setting the etag no longer caused the server to return status when the etags match go func test t testing t fs http fileserver http dir tmp h http handlerfunc func w http responsewriter r http request delete if modified since header so that etags can be used instead of the standard cache policy r header del if modified since set etag to to uniquely identify the unchanged static asset w header set etag fs servehttp w r ts httptest newserver h ensure tmp test txt exists if err ioutil writefile tmp test txt nil err nil t fatal err var c http client req err http newrequest get ts url test txt nil if err nil t fatal err req header add if none match same etag as above resp err c do req if err nil t fatal err if resp statuscode t error i believe this is a regression because the documentation for servecontent explicitly says if the caller has set w s etag header servecontent uses it to handle requests using if range and if none match cc bradfitz ,1 +47181,24900544238.0,IssuesEvent,2022-10-28 20:21:48,golang/go,https://api.github.com/repos/golang/go,closed,x/tools/gopls: deepCompletionState.enqueue is an allocation hotspot,gopls Tools gopls/performance,"I noticed while running `TestBenchmarkConfiguredCompletion` on k8s that `deepCompletionState.enqueue` +``` +func (s *deepCompletionState) enqueue(cand candidate) { + s.nextQueue = append(s.nextQueue, cand) +} +``` +allocates 10GB of memory because it adds 5 million completion candidates to the queue, each being an 18-word structure. This causes each call of `env.Completion` in the benchmark to take 10s. There are two calls, the warmup and the one in the b.N loop (which only reaches N=1). + +This was the command. The .go file is my favorite large file in k8s. +``` +$ go test -bench=TestBenchmarkConfiguredCompletion ./gopls/internal/regtest/bench -completion_workdir=$HOME/w/kubernetes -completion_file=../kubernetes/pkg/generated/openapi/zz_generated.openapi.go -completion_regexp=Get +``` + +Also, 2GB (and 3s CPU) are spent on this call to `Type.String` in `completer.methodsAndFields`: +``` +if typ.String() == ""*testing.F"" && addressable { + // is that a sufficient test? (or is more care needed?) + if c.fuzz(typ, mset, imp, cb, c.snapshot.FileSet()) { + return + } +} +``` +@muirdm",True,"x/tools/gopls: deepCompletionState.enqueue is an allocation hotspot - I noticed while running `TestBenchmarkConfiguredCompletion` on k8s that `deepCompletionState.enqueue` +``` +func (s *deepCompletionState) enqueue(cand candidate) { + s.nextQueue = append(s.nextQueue, cand) +} +``` +allocates 10GB of memory because it adds 5 million completion candidates to the queue, each being an 18-word structure. This causes each call of `env.Completion` in the benchmark to take 10s. There are two calls, the warmup and the one in the b.N loop (which only reaches N=1). + +This was the command. The .go file is my favorite large file in k8s. +``` +$ go test -bench=TestBenchmarkConfiguredCompletion ./gopls/internal/regtest/bench -completion_workdir=$HOME/w/kubernetes -completion_file=../kubernetes/pkg/generated/openapi/zz_generated.openapi.go -completion_regexp=Get +``` + +Also, 2GB (and 3s CPU) are spent on this call to `Type.String` in `completer.methodsAndFields`: +``` +if typ.String() == ""*testing.F"" && addressable { + // is that a sufficient test? (or is more care needed?) + if c.fuzz(typ, mset, imp, cb, c.snapshot.FileSet()) { + return + } +} +``` +@muirdm",0,x tools gopls deepcompletionstate enqueue is an allocation hotspot i noticed while running testbenchmarkconfiguredcompletion on that deepcompletionstate enqueue func s deepcompletionstate enqueue cand candidate s nextqueue append s nextqueue cand allocates of memory because it adds million completion candidates to the queue each being an word structure this causes each call of env completion in the benchmark to take there are two calls the warmup and the one in the b n loop which only reaches n this was the command the go file is my favorite large file in go test bench testbenchmarkconfiguredcompletion gopls internal regtest bench completion workdir home w kubernetes completion file kubernetes pkg generated openapi zz generated openapi go completion regexp get also and cpu are spent on this call to type string in completer methodsandfields if typ string testing f addressable is that a sufficient test or is more care needed if c fuzz typ mset imp cb c snapshot fileset return muirdm,0 +64942,8780250670.0,IssuesEvent,2018-12-19 16:48:24,golang/go,https://api.github.com/repos/golang/go,reopened,documentation: modules quick start example does not work,Documentation WaitingForInfo modules," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.11.2 linux/amd64 + ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/test/.cache/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/test/go"" +GOPROXY="""" +GORACE="""" +GOROOT=""/usr/local/go"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/tmp/scratchpad/hello/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build952622232=/tmp/go-build -gno-record-gcc-switches"" + +
+build github.com/you/hello: cannot find module for path rsc.io/quote ++",1.0,"documentation: modules quick start example does not work - + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.11.2 linux/amd64 + ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/test/.cache/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/test/go"" +GOPROXY="""" +GORACE="""" +GOROOT=""/usr/local/go"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/tmp/scratchpad/hello/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build952622232=/tmp/go-build -gno-record-gcc-switches"" + +
+build github.com/you/hello: cannot find module for path rsc.io/quote ++",1,documentation modules quick start example does not work what version of go are you using go version go version go version linux does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env go env output go env goarch gobin gocache home test cache go build goexe goflags gohostarch gohostos linux goos linux gopath home test go goproxy gorace goroot usr local go gotmpdir gotooldir usr local go pkg tool linux gccgo gccgo cc gcc cxx g cgo enabled gomod tmp scratchpad hello go mod cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map tmp go tmp go build gno record gcc switches what did you do followed the quick start example from the go wiki page link what did you expect to see it work what did you see instead error after running go build the first time build github com you hello cannot find module for path rsc io quote ,1 +94249,27152148559.0,IssuesEvent,2023-02-17 02:50:44,golang/go,https://api.github.com/repos/golang/go,closed,x/build: linux-amd64-wsl builder failing,Builders NeedsFix,"The linux-amd64-wsl builder (owned by @mengzhuo) flipped abruptly from almost always passing to almost always failing on December 13, 2022: + +
+$ go version +go version go1.21rc2 windows/amd64 ++ +### Does this issue reproduce with the latest release? +Reproducible with 1.21rc2 but not reproducible with 1.20.5. I'm not sure how to download 1.21rc1 to test that. + +### What operating system and processor architecture are you using (`go env`)? + +Windows 11 Pro Version 10.0.22621 Build 22621 + +
go env Output+$ go env +set GO111MODULE= +set GOARCH=amd64 +set GOBIN= +set GOCACHE=C:\Users\james\AppData\Local\go-build +set GOENV=C:\Users\james\AppData\Roaming\go\env +set GOEXE=.exe +set GOEXPERIMENT= +set GOFLAGS= +set GOHOSTARCH=amd64 +set GOHOSTOS=windows +set GOINSECURE= +set GOMODCACHE=C:\Users\james\go\pkg\mod +set GONOPROXY=gerrit.levenlabs.com,gitlab.com/levenlabs +set GONOSUMDB=gerrit.levenlabs.com,gitlab.com/levenlabs +set GOOS=windows +set GOPATH=C:\Users\james\go; +set GOPRIVATE=gerrit.levenlabs.com,gitlab.com/levenlabs +set GOPROXY=https://proxy.golang.org,direct +set GOROOT=C:\Program Files\Go +set GOSUMDB=sum.golang.org +set GOTMPDIR= +set GOTOOLCHAIN=auto +set GOTOOLDIR=C:\Program Files\Go\pkg\tool\windows_amd64 +set GOVCS= +set GOVERSION=go1.21rc2 +set GCCGO=gccgo +set GOAMD64=v1 +set AR=ar +set CC=gcc +set CXX=g++ +set CGO_ENABLED=1 +set GOMOD=C:\Users\james\Dropbox\aftermath\backend\go-llib\go.mod +set GOWORK= +set CGO_CFLAGS=-O2 -g +set CGO_CPPFLAGS= +set CGO_CXXFLAGS=-O2 -g +set CGO_FFLAGS=-O2 -g +set CGO_LDFLAGS=-O2 -g +set PKG_CONFIG=pkg-config +set GOGCCFLAGS=-m64 -mthreads -Wl,--no-gc-sections -fmessage-length=0 -ffile-prefix-map=C:\Users\james\AppData\Local\Temp\go-build2611928154=/tmp/go-build -gno-record-gcc-switches +
gcc -v Output+> gcc -v +Using built-in specs. +COLLECT_GCC=C:\TDM-GCC-64\bin\gcc.exe +COLLECT_LTO_WRAPPER=C:/TDM-GCC-64/bin/../libexec/gcc/x86_64-w64-mingw32/9.2.0/lto-wrapper.exe +Target: x86_64-w64-mingw32 +Configured with: ../../../src/gcc-git-9.2.0/configure --build=x86_64-w64-mingw32 --enable-targets=all --enable-languages=ada,c,c++,fortran,lto,objc,obj-c++ --enable-libgomp --enable-lto --enable-graphite --enable-cxx-flags=-DWINPTHREAD_STATIC --disable-build-with-cxx --disable-build-poststage1-with-cxx --enable-libstdcxx-debug --enable-threads=posix --enable-version-specific-runtime-libs --enable-fully-dynamic-string --enable-libstdcxx-threads --enable-libstdcxx-time --with-gnu-ld --disable-werror --disable-nls --disable-win32-registry --enable-large-address-aware --disable-rpath --disable-symvers --prefix=/mingw64tdm --with-local-prefix=/mingw64tdm --with-pkgversion=tdm64-1 --with-bugurl=http://tdm-gcc.tdragon.net/bugs +Thread model: posix +gcc version 9.2.0 (tdm64-1) +
gcc -v Output+> gcc -v +Using built-in specs. +COLLECT_GCC=C:\TDM-GCC-64\bin\gcc.exe +COLLECT_LTO_WRAPPER=C:/TDM-GCC-64/bin/../libexec/gcc/x86_64-w64-mingw32/10.3.0/lto-wrapper.exe +Target: x86_64-w64-mingw32 +Configured with: ../../../src/gcc-git-10.3.0/configure --build=x86_64-w64-mingw32 --enable-targets=all --enable-languages=ada,c,c++,fortran,jit,lto,objc,obj-c++ --enable-libgomp --enable-lto --enable-graphite --enable-cxx-flags=-DWINPTHREAD_STATIC --disable-build-with-cxx --disable-build-poststage1-with-cxx --enable-libstdcxx-debug --enable-threads=posix --enable-version-specific-runtime-libs --enable-fully-dynamic-string --enable-libstdcxx-filesystem-ts=yes --disable-libstdcxx-pch --enable-libstdcxx-threads --enable-libstdcxx-time=yes --enable-mingw-wildcard --with-gnu-ld --disable-werror --enable-nls --disable-win32-registry --enable-large-address-aware --disable-rpath --disable-symvers --prefix=/mingw64tdm --with-local-prefix=/mingw64tdm --with-pkgversion=tdm64-1 --with-bugurl=https://github.com/jmeubank/tdm-gcc/issues +Thread model: posix +Supported LTO compression algorithms: zlib zstd +gcc version 10.3.0 (tdm64-1) +
+$ go version +go version go1.21rc2 windows/amd64 ++ +### Does this issue reproduce with the latest release? +Reproducible with 1.21rc2 but not reproducible with 1.20.5. I'm not sure how to download 1.21rc1 to test that. + +### What operating system and processor architecture are you using (`go env`)? + +Windows 11 Pro Version 10.0.22621 Build 22621 + +
go env Output+$ go env +set GO111MODULE= +set GOARCH=amd64 +set GOBIN= +set GOCACHE=C:\Users\james\AppData\Local\go-build +set GOENV=C:\Users\james\AppData\Roaming\go\env +set GOEXE=.exe +set GOEXPERIMENT= +set GOFLAGS= +set GOHOSTARCH=amd64 +set GOHOSTOS=windows +set GOINSECURE= +set GOMODCACHE=C:\Users\james\go\pkg\mod +set GONOPROXY=gerrit.levenlabs.com,gitlab.com/levenlabs +set GONOSUMDB=gerrit.levenlabs.com,gitlab.com/levenlabs +set GOOS=windows +set GOPATH=C:\Users\james\go; +set GOPRIVATE=gerrit.levenlabs.com,gitlab.com/levenlabs +set GOPROXY=https://proxy.golang.org,direct +set GOROOT=C:\Program Files\Go +set GOSUMDB=sum.golang.org +set GOTMPDIR= +set GOTOOLCHAIN=auto +set GOTOOLDIR=C:\Program Files\Go\pkg\tool\windows_amd64 +set GOVCS= +set GOVERSION=go1.21rc2 +set GCCGO=gccgo +set GOAMD64=v1 +set AR=ar +set CC=gcc +set CXX=g++ +set CGO_ENABLED=1 +set GOMOD=C:\Users\james\Dropbox\aftermath\backend\go-llib\go.mod +set GOWORK= +set CGO_CFLAGS=-O2 -g +set CGO_CPPFLAGS= +set CGO_CXXFLAGS=-O2 -g +set CGO_FFLAGS=-O2 -g +set CGO_LDFLAGS=-O2 -g +set PKG_CONFIG=pkg-config +set GOGCCFLAGS=-m64 -mthreads -Wl,--no-gc-sections -fmessage-length=0 -ffile-prefix-map=C:\Users\james\AppData\Local\Temp\go-build2611928154=/tmp/go-build -gno-record-gcc-switches +
gcc -v Output+> gcc -v +Using built-in specs. +COLLECT_GCC=C:\TDM-GCC-64\bin\gcc.exe +COLLECT_LTO_WRAPPER=C:/TDM-GCC-64/bin/../libexec/gcc/x86_64-w64-mingw32/9.2.0/lto-wrapper.exe +Target: x86_64-w64-mingw32 +Configured with: ../../../src/gcc-git-9.2.0/configure --build=x86_64-w64-mingw32 --enable-targets=all --enable-languages=ada,c,c++,fortran,lto,objc,obj-c++ --enable-libgomp --enable-lto --enable-graphite --enable-cxx-flags=-DWINPTHREAD_STATIC --disable-build-with-cxx --disable-build-poststage1-with-cxx --enable-libstdcxx-debug --enable-threads=posix --enable-version-specific-runtime-libs --enable-fully-dynamic-string --enable-libstdcxx-threads --enable-libstdcxx-time --with-gnu-ld --disable-werror --disable-nls --disable-win32-registry --enable-large-address-aware --disable-rpath --disable-symvers --prefix=/mingw64tdm --with-local-prefix=/mingw64tdm --with-pkgversion=tdm64-1 --with-bugurl=http://tdm-gcc.tdragon.net/bugs +Thread model: posix +gcc version 9.2.0 (tdm64-1) +
gcc -v Output+> gcc -v +Using built-in specs. +COLLECT_GCC=C:\TDM-GCC-64\bin\gcc.exe +COLLECT_LTO_WRAPPER=C:/TDM-GCC-64/bin/../libexec/gcc/x86_64-w64-mingw32/10.3.0/lto-wrapper.exe +Target: x86_64-w64-mingw32 +Configured with: ../../../src/gcc-git-10.3.0/configure --build=x86_64-w64-mingw32 --enable-targets=all --enable-languages=ada,c,c++,fortran,jit,lto,objc,obj-c++ --enable-libgomp --enable-lto --enable-graphite --enable-cxx-flags=-DWINPTHREAD_STATIC --disable-build-with-cxx --disable-build-poststage1-with-cxx --enable-libstdcxx-debug --enable-threads=posix --enable-version-specific-runtime-libs --enable-fully-dynamic-string --enable-libstdcxx-filesystem-ts=yes --disable-libstdcxx-pch --enable-libstdcxx-threads --enable-libstdcxx-time=yes --enable-mingw-wildcard --with-gnu-ld --disable-werror --enable-nls --disable-win32-registry --enable-large-address-aware --disable-rpath --disable-symvers --prefix=/mingw64tdm --with-local-prefix=/mingw64tdm --with-pkgversion=tdm64-1 --with-bugurl=https://github.com/jmeubank/tdm-gcc/issues +Thread model: posix +Supported LTO compression algorithms: zlib zstd +gcc version 10.3.0 (tdm64-1) +
+$ go version + +go version go1.13.1 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/edkolev/Library/Caches/go-build"" +GOENV=""/Users/edkolev/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/edkolev/gocode"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/Cellar/go/1.13.1/libexec"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.13.1/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/v7/fnkk7zpd0hvdsl45hpj92cc40000gn/T/go-build203896190=/tmp/go-build -gno-record-gcc-switches -fno-common"" + + +
+$ go version + +go version go1.13.1 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/edkolev/Library/Caches/go-build"" +GOENV=""/Users/edkolev/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/edkolev/gocode"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/Cellar/go/1.13.1/libexec"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.13.1/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/v7/fnkk7zpd0hvdsl45hpj92cc40000gn/T/go-build203896190=/tmp/go-build -gno-record-gcc-switches -fno-common"" + + +
The documentation of websocket.Conn[1] does not state that it is safe to share it among +multiple goroutines. From the implementation (rio and wio mutexes), it appears that it +is safe. + +It'll be convenient if this is explicitly stated like in the case of net.Conn in +stdlib[2]. + +[1] - http://godoc.org/code.google.com/p/go.net/websocket#Conn",1.0,"x/net/websocket: Document goroutine safety of websocket.Conn -
The documentation of websocket.Conn[1] does not state that it is safe to share it among +multiple goroutines. From the implementation (rio and wio mutexes), it appears that it +is safe. + +It'll be convenient if this is explicitly stated like in the case of net.Conn in +stdlib[2]. + +[1] - http://godoc.org/code.google.com/p/go.net/websocket#Conn",1,x net websocket document goroutine safety of websocket conn the documentation of websocket conn does not state that it is safe to share it among multiple goroutines from the implementation rio and wio mutexes it appears that it is safe it ll be convenient if this is explicitly stated like in the case of net conn in stdlib a href ,1 +123286,12196303654.0,IssuesEvent,2020-04-29 18:51:02,golang/go,https://api.github.com/repos/golang/go,closed,crypto/x509/pkix: FillFromRDNSequence does not preserve multi-value RDNs,Documentation NeedsFix Unfortunate help wanted,"### What version of Go are you using (`go version`)? +This issue affects Go 1.8 and later as a consequence of https://github.com/golang/go/commit/809a1de1ac1ccc76f7a4faf630017626f2f68231 to fix [#16836](https://github.com/golang/go/issues/16836) (and #12342). + +Prior to Go 1.8 and that change, Go did not process multi-value RDNs -- it always assumed just one attribute and value (the first) per RDN. + +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? +The OS and architecture should not matter. + +### What did you do? +https://play.golang.org/p/7OIuhautCe + +### What did you expect to see? +The multi-value nature of any RDN is preserved. That is, the length of the subject (and issuer) RDNSequence before pkix.FillFromRDNSequence and after pkix.ToRDNSequence should match. + +### What did you see instead? +The multi-value nature of any RDN is not preserved by pkix.FillFromRDNSequence. That is, the length of the subject (and issuer) RDNSequence before pkix.FillFromRDNSequence and after pkix.ToRDNSequence do not match. + +As previously noted in comments on https://github.com/golang/go/commit/809a1de1ac1ccc76f7a4faf630017626f2f68231, the [original Gerrit CR](https://go-review.googlesource.com/c/go/+/30810#message-a29d12cfb3550dc2ce212ec60ddf32bf86363f13), and #12342, if this will not be fixed, then the behavior should be documented at a minimum.",1.0,"crypto/x509/pkix: FillFromRDNSequence does not preserve multi-value RDNs - ### What version of Go are you using (`go version`)? +This issue affects Go 1.8 and later as a consequence of https://github.com/golang/go/commit/809a1de1ac1ccc76f7a4faf630017626f2f68231 to fix [#16836](https://github.com/golang/go/issues/16836) (and #12342). + +Prior to Go 1.8 and that change, Go did not process multi-value RDNs -- it always assumed just one attribute and value (the first) per RDN. + +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? +The OS and architecture should not matter. + +### What did you do? +https://play.golang.org/p/7OIuhautCe + +### What did you expect to see? +The multi-value nature of any RDN is preserved. That is, the length of the subject (and issuer) RDNSequence before pkix.FillFromRDNSequence and after pkix.ToRDNSequence should match. + +### What did you see instead? +The multi-value nature of any RDN is not preserved by pkix.FillFromRDNSequence. That is, the length of the subject (and issuer) RDNSequence before pkix.FillFromRDNSequence and after pkix.ToRDNSequence do not match. + +As previously noted in comments on https://github.com/golang/go/commit/809a1de1ac1ccc76f7a4faf630017626f2f68231, the [original Gerrit CR](https://go-review.googlesource.com/c/go/+/30810#message-a29d12cfb3550dc2ce212ec60ddf32bf86363f13), and #12342, if this will not be fixed, then the behavior should be documented at a minimum.",1,crypto pkix fillfromrdnsequence does not preserve multi value rdns what version of go are you using go version this issue affects go and later as a consequence of to fix and prior to go and that change go did not process multi value rdns it always assumed just one attribute and value the first per rdn does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env the os and architecture should not matter what did you do what did you expect to see the multi value nature of any rdn is preserved that is the length of the subject and issuer rdnsequence before pkix fillfromrdnsequence and after pkix tordnsequence should match what did you see instead the multi value nature of any rdn is not preserved by pkix fillfromrdnsequence that is the length of the subject and issuer rdnsequence before pkix fillfromrdnsequence and after pkix tordnsequence do not match as previously noted in comments on the and if this will not be fixed then the behavior should be documented at a minimum ,1 +26062,7780822567.0,IssuesEvent,2018-06-05 21:19:24,golang/go,https://api.github.com/repos/golang/go,closed,x/build/maintner: refactor out gcs and api from maintnerd,Builders,"I want to create a customized maintnerd (one feature is being able to add tracked repos while the daemon is running). + +Here's a small proposal to make that more possible: + +* move all of the GCS (gcslog.go) and API functions (api.go) to a new package: ""maintnerapi"". optional: move GCS functionality into its own package. +* ~~move the protos into a subpackage (currently named ""apipb"" but maybe ""maintpb"" is better?)~~ nevermind, there's already a maintpb for storage. + +maintnerd then becomes a 500 line program that uses the maintnerapi package, which looks like this: + +``` +PACKAGE DOCUMENTATION + +package maintnerapi + import ""."" + + +FUNCTIONS + +func NewAPIService(corpus *maintner.Corpus) apipb.MaintnerServiceServer + +TYPES + +type GCSLog struct { + // contains filtered or unexported fields +} + +func NewGCSLog(ctx context.Context, bucketName string) (*GCSLog, error) + +func (gl *GCSLog) CopyFrom(src maintner.MutationSource) error + CopyFrom is only used for the one-time migrate from disk-to-GCS code + path. + +func (gl *GCSLog) GetMutations(ctx context.Context) <-chan maintner.MutationStreamEvent + +func (gl *GCSLog) Log(m *maintpb.Mutation) error + +func (gl *GCSLog) ServeJSONLogsIndex(w http.ResponseWriter, r *http.Request) + +func (gl *GCSLog) ServeLogFile(w http.ResponseWriter, r *http.Request) +```",1.0,"x/build/maintner: refactor out gcs and api from maintnerd - I want to create a customized maintnerd (one feature is being able to add tracked repos while the daemon is running). + +Here's a small proposal to make that more possible: + +* move all of the GCS (gcslog.go) and API functions (api.go) to a new package: ""maintnerapi"". optional: move GCS functionality into its own package. +* ~~move the protos into a subpackage (currently named ""apipb"" but maybe ""maintpb"" is better?)~~ nevermind, there's already a maintpb for storage. + +maintnerd then becomes a 500 line program that uses the maintnerapi package, which looks like this: + +``` +PACKAGE DOCUMENTATION + +package maintnerapi + import ""."" + + +FUNCTIONS + +func NewAPIService(corpus *maintner.Corpus) apipb.MaintnerServiceServer + +TYPES + +type GCSLog struct { + // contains filtered or unexported fields +} + +func NewGCSLog(ctx context.Context, bucketName string) (*GCSLog, error) + +func (gl *GCSLog) CopyFrom(src maintner.MutationSource) error + CopyFrom is only used for the one-time migrate from disk-to-GCS code + path. + +func (gl *GCSLog) GetMutations(ctx context.Context) <-chan maintner.MutationStreamEvent + +func (gl *GCSLog) Log(m *maintpb.Mutation) error + +func (gl *GCSLog) ServeJSONLogsIndex(w http.ResponseWriter, r *http.Request) + +func (gl *GCSLog) ServeLogFile(w http.ResponseWriter, r *http.Request) +```",0,x build maintner refactor out gcs and api from maintnerd i want to create a customized maintnerd one feature is being able to add tracked repos while the daemon is running here s a small proposal to make that more possible move all of the gcs gcslog go and api functions api go to a new package maintnerapi optional move gcs functionality into its own package move the protos into a subpackage currently named apipb but maybe maintpb is better nevermind there s already a maintpb for storage maintnerd then becomes a line program that uses the maintnerapi package which looks like this package documentation package maintnerapi import functions func newapiservice corpus maintner corpus apipb maintnerserviceserver types type gcslog struct contains filtered or unexported fields func newgcslog ctx context context bucketname string gcslog error func gl gcslog copyfrom src maintner mutationsource error copyfrom is only used for the one time migrate from disk to gcs code path func gl gcslog getmutations ctx context context chan maintner mutationstreamevent func gl gcslog log m maintpb mutation error func gl gcslog servejsonlogsindex w http responsewriter r http request func gl gcslog servelogfile w http responsewriter r http request ,0 +82651,10302240572.0,IssuesEvent,2019-08-28 16:20:35,golang/go,https://api.github.com/repos/golang/go,closed,math/big: Rat.Denom has side effects,Documentation NeedsInvestigation,"From here: https://github.com/ericlagergren/decimal/issues/138 + +My package divides `(*Rat).Num` by `(*Rat).Denom` to produce a decimal number. It turns out that `(*Rat).Denom` lazily sets its denominator, meaning it cannot be used concurrently. + +Since the receiver is `x` not `z`, I assumed that the method simply read the denominator. + +The receiver name should be updated to indicate side effects and/or the documentation for `big.Rat` should mention this side effect. I assume that the 7 years this has spent in the tree is too long to be reverted 😄. And, at any rate, not materializing the denominator can save allocations for whole numbers, which is a good thing. + +I can send a CL if you want.",1.0,"math/big: Rat.Denom has side effects - From here: https://github.com/ericlagergren/decimal/issues/138 + +My package divides `(*Rat).Num` by `(*Rat).Denom` to produce a decimal number. It turns out that `(*Rat).Denom` lazily sets its denominator, meaning it cannot be used concurrently. + +Since the receiver is `x` not `z`, I assumed that the method simply read the denominator. + +The receiver name should be updated to indicate side effects and/or the documentation for `big.Rat` should mention this side effect. I assume that the 7 years this has spent in the tree is too long to be reverted 😄. And, at any rate, not materializing the denominator can save allocations for whole numbers, which is a good thing. + +I can send a CL if you want.",1,math big rat denom has side effects from here my package divides rat num by rat denom to produce a decimal number it turns out that rat denom lazily sets its denominator meaning it cannot be used concurrently since the receiver is x not z i assumed that the method simply read the denominator the receiver name should be updated to indicate side effects and or the documentation for big rat should mention this side effect i assume that the years this has spent in the tree is too long to be reverted 😄 and at any rate not materializing the denominator can save allocations for whole numbers which is a good thing i can send a cl if you want ,1 +313224,26910885415.0,IssuesEvent,2023-02-06 23:35:34,golang/go,https://api.github.com/repos/golang/go,reopened,net/http: TestIssue4191_InfiniteGetTimeout failures,Testing NeedsFix,"``` +#!watchflakes +post <- pkg == ""net/http"" && test == ""TestIssue4191_InfiniteGetTimeout"" +``` + +Issue created automatically to collect these failures. + +Example ([log](https://build.golang.org/log/86eafcf43d85a75041c3d91b3f4f67a81290a67e)): + + 2022/10/14 13:21:56 http: TLS handshake error from 127.0.0.1:34378: EOF + 2022/10/14 13:21:56 http: TLS handshake error from 127.0.0.1:58818: EOF + 2022/10/14 13:22:06 http: TLS handshake error from 127.0.0.1:46802: EOF + 2022/10/14 13:22:08 http: TLS handshake error from 127.0.0.1:37914: write tcp 127.0.0.1:33957->127.0.0.1:37914: use of closed network connection + 2022/10/14 13:22:08 http: TLS handshake error from 127.0.0.1:55294: read tcp 127.0.0.1:32777->127.0.0.1:55294: use of closed network connection + 2022/10/14 13:22:08 http: TLS handshake error from 127.0.0.1:55306: read tcp 127.0.0.1:32777->127.0.0.1:55306: use of closed network connection + 2022/10/14 13:22:08 http: TLS handshake error from 127.0.0.1:55308: read tcp 127.0.0.1:32777->127.0.0.1:55308: use of closed network connection + 2022/10/14 13:22:08 http: TLS handshake error from 127.0.0.1:55290: read tcp 127.0.0.1:32777->127.0.0.1:55290: use of closed network connection + 2022/10/14 13:22:08 http: TLS handshake error from 127.0.0.1:55292: read tcp 127.0.0.1:32777->127.0.0.1:55292: use of closed network connection + 2022/10/14 13:22:08 http: TLS handshake error from 127.0.0.1:55300: write tcp 127.0.0.1:32777->127.0.0.1:55300: use of closed network connection + ... + --- FAIL: TestIssue4191_InfiniteGetTimeout (0.00s) + --- FAIL: TestIssue4191_InfiniteGetTimeout/h2 (1.72s) + transport_test.go:2167: increasing timeout + transport_test.go:2172: Error issuing GET: Get ""https://127.0.0.1:33957/get"": read tcp 127.0.0.1:37936->127.0.0.1:33957: i/o timeout + 2022/10/14 13:22:10 http: TLS handshake error from 127.0.0.1:43514: read tcp 127.0.0.1:32901->127.0.0.1:43514: use of closed network connection + 2022/10/14 13:22:10 http: TLS handshake error from 127.0.0.1:43516: read tcp 127.0.0.1:32901->127.0.0.1:43516: use of closed network connection + 2022/10/14 13:22:10 http: TLS handshake error from 127.0.0.1:43520: read tcp 127.0.0.1:32901->127.0.0.1:43520: use of closed network connection + 2022/10/14 13:22:10 http: TLS handshake error from 127.0.0.1:43528: read tcp 127.0.0.1:32901->127.0.0.1:43528: use of closed network connection + 2022/10/14 13:22:10 http: TLS handshake error from 127.0.0.1:43522: write tcp 127.0.0.1:32901->127.0.0.1:43522: use of closed network connection + 2022/10/14 13:22:10 http: TLS handshake error from 127.0.0.1:43512: write tcp 127.0.0.1:32901->127.0.0.1:43512: use of closed network connection + ... + 2022/10/14 13:22:39 http: TLS handshake error from 127.0.0.1:54936: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:55624: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:55618: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:55620: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:54942: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:54946: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:54948: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:55630: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:55634: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:54952: EOF + + +— [watchflakes](https://go.dev/wiki/Watchflakes) +",1.0,"net/http: TestIssue4191_InfiniteGetTimeout failures - ``` +#!watchflakes +post <- pkg == ""net/http"" && test == ""TestIssue4191_InfiniteGetTimeout"" +``` + +Issue created automatically to collect these failures. + +Example ([log](https://build.golang.org/log/86eafcf43d85a75041c3d91b3f4f67a81290a67e)): + + 2022/10/14 13:21:56 http: TLS handshake error from 127.0.0.1:34378: EOF + 2022/10/14 13:21:56 http: TLS handshake error from 127.0.0.1:58818: EOF + 2022/10/14 13:22:06 http: TLS handshake error from 127.0.0.1:46802: EOF + 2022/10/14 13:22:08 http: TLS handshake error from 127.0.0.1:37914: write tcp 127.0.0.1:33957->127.0.0.1:37914: use of closed network connection + 2022/10/14 13:22:08 http: TLS handshake error from 127.0.0.1:55294: read tcp 127.0.0.1:32777->127.0.0.1:55294: use of closed network connection + 2022/10/14 13:22:08 http: TLS handshake error from 127.0.0.1:55306: read tcp 127.0.0.1:32777->127.0.0.1:55306: use of closed network connection + 2022/10/14 13:22:08 http: TLS handshake error from 127.0.0.1:55308: read tcp 127.0.0.1:32777->127.0.0.1:55308: use of closed network connection + 2022/10/14 13:22:08 http: TLS handshake error from 127.0.0.1:55290: read tcp 127.0.0.1:32777->127.0.0.1:55290: use of closed network connection + 2022/10/14 13:22:08 http: TLS handshake error from 127.0.0.1:55292: read tcp 127.0.0.1:32777->127.0.0.1:55292: use of closed network connection + 2022/10/14 13:22:08 http: TLS handshake error from 127.0.0.1:55300: write tcp 127.0.0.1:32777->127.0.0.1:55300: use of closed network connection + ... + --- FAIL: TestIssue4191_InfiniteGetTimeout (0.00s) + --- FAIL: TestIssue4191_InfiniteGetTimeout/h2 (1.72s) + transport_test.go:2167: increasing timeout + transport_test.go:2172: Error issuing GET: Get ""https://127.0.0.1:33957/get"": read tcp 127.0.0.1:37936->127.0.0.1:33957: i/o timeout + 2022/10/14 13:22:10 http: TLS handshake error from 127.0.0.1:43514: read tcp 127.0.0.1:32901->127.0.0.1:43514: use of closed network connection + 2022/10/14 13:22:10 http: TLS handshake error from 127.0.0.1:43516: read tcp 127.0.0.1:32901->127.0.0.1:43516: use of closed network connection + 2022/10/14 13:22:10 http: TLS handshake error from 127.0.0.1:43520: read tcp 127.0.0.1:32901->127.0.0.1:43520: use of closed network connection + 2022/10/14 13:22:10 http: TLS handshake error from 127.0.0.1:43528: read tcp 127.0.0.1:32901->127.0.0.1:43528: use of closed network connection + 2022/10/14 13:22:10 http: TLS handshake error from 127.0.0.1:43522: write tcp 127.0.0.1:32901->127.0.0.1:43522: use of closed network connection + 2022/10/14 13:22:10 http: TLS handshake error from 127.0.0.1:43512: write tcp 127.0.0.1:32901->127.0.0.1:43512: use of closed network connection + ... + 2022/10/14 13:22:39 http: TLS handshake error from 127.0.0.1:54936: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:55624: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:55618: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:55620: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:54942: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:54946: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:54948: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:55630: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:55634: EOF + 2022/10/14 13:22:40 http: TLS handshake error from 127.0.0.1:54952: EOF + + +— [watchflakes](https://go.dev/wiki/Watchflakes) +",0,net http infinitegettimeout failures watchflakes post pkg net http test infinitegettimeout issue created automatically to collect these failures example http tls handshake error from eof http tls handshake error from eof http tls handshake error from eof http tls handshake error from write tcp use of closed network connection http tls handshake error from read tcp use of closed network connection http tls handshake error from read tcp use of closed network connection http tls handshake error from read tcp use of closed network connection http tls handshake error from read tcp use of closed network connection http tls handshake error from read tcp use of closed network connection http tls handshake error from write tcp use of closed network connection fail infinitegettimeout fail infinitegettimeout transport test go increasing timeout transport test go error issuing get get read tcp i o timeout http tls handshake error from read tcp use of closed network connection http tls handshake error from read tcp use of closed network connection http tls handshake error from read tcp use of closed network connection http tls handshake error from read tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from eof http tls handshake error from eof http tls handshake error from eof http tls handshake error from eof http tls handshake error from eof http tls handshake error from eof http tls handshake error from eof http tls handshake error from eof http tls handshake error from eof http tls handshake error from eof — ,0 +232842,17796845621.0,IssuesEvent,2021-08-31 23:55:58,golang/go,https://api.github.com/repos/golang/go,opened,spec: clarify sequencing of function calls within expressions,Documentation NeedsDecision,"The program below tests the order-of-evaluation semantics of `return *p, f(p)`. With gccgo, it prints 0 (i.e., evaluating `*p` before calling `f(p)`), and with cmd/compile it prints 2 (i.e., evaluating `*p` after `f(p)` returns). + +But is it allowed to print `1`? I.e., can `*p` be evaluated *in the middle* of `f(p)` being evaluated, after the `*p = 1` and before the `*p = 2`? + +The spec says simply: + +> For example, in the (function-local) assignment +> +> ``` +> y[f()], ok = g(h(), i()+x[j()], <-c), k() +> ``` +> +> the function calls and communication happen in the order `f()`, `h()`, `i()`, `j()`, `<-c`, `g()`, and `k()`. However, the order of those events compared to the evaluation and indexing of `x` and the evaluation of `y` is not specified. + +I don't think there's any other text in the spec that requires evaluation of a function call to within an expression to be handled atomically with respect to other expressions either. + +@griesemer and I agree only 0 or 2 should be allowed (i.e., 1 should not be allowed), but that the spec could be clearer about this. + +``` +package main + +func main() { + x, _ := g() + println(x) +} + +func g() (int, int) { + p := new(int) + return *p, f(p) +} + +func f(p *int) int { + *p = 1 + *p = 2 + return 0 +} +``` + +",1.0,"spec: clarify sequencing of function calls within expressions - The program below tests the order-of-evaluation semantics of `return *p, f(p)`. With gccgo, it prints 0 (i.e., evaluating `*p` before calling `f(p)`), and with cmd/compile it prints 2 (i.e., evaluating `*p` after `f(p)` returns). + +But is it allowed to print `1`? I.e., can `*p` be evaluated *in the middle* of `f(p)` being evaluated, after the `*p = 1` and before the `*p = 2`? + +The spec says simply: + +> For example, in the (function-local) assignment +> +> ``` +> y[f()], ok = g(h(), i()+x[j()], <-c), k() +> ``` +> +> the function calls and communication happen in the order `f()`, `h()`, `i()`, `j()`, `<-c`, `g()`, and `k()`. However, the order of those events compared to the evaluation and indexing of `x` and the evaluation of `y` is not specified. + +I don't think there's any other text in the spec that requires evaluation of a function call to within an expression to be handled atomically with respect to other expressions either. + +@griesemer and I agree only 0 or 2 should be allowed (i.e., 1 should not be allowed), but that the spec could be clearer about this. + +``` +package main + +func main() { + x, _ := g() + println(x) +} + +func g() (int, int) { + p := new(int) + return *p, f(p) +} + +func f(p *int) int { + *p = 1 + *p = 2 + return 0 +} +``` + +",1,spec clarify sequencing of function calls within expressions the program below tests the order of evaluation semantics of return p f p with gccgo it prints i e evaluating p before calling f p and with cmd compile it prints i e evaluating p after f p returns but is it allowed to print i e can p be evaluated in the middle of f p being evaluated after the p and before the p the spec says simply for example in the function local assignment y ok g h i x c k the function calls and communication happen in the order f h i j c g and k however the order of those events compared to the evaluation and indexing of x and the evaluation of y is not specified i don t think there s any other text in the spec that requires evaluation of a function call to within an expression to be handled atomically with respect to other expressions either griesemer and i agree only or should be allowed i e should not be allowed but that the spec could be clearer about this package main func main x g println x func g int int p new int return p f p func f p int int p p return ,1 +369550,25856303499.0,IssuesEvent,2022-12-13 14:00:58,golang/go,https://api.github.com/repos/golang/go,closed,x/sys/unix: Undocumented (possibly incorrect?) SendmsgBuffers behavior with empty iovec,Documentation help wanted NeedsInvestigation compiler/runtime," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.19.3 linux/amd64 +$ cat go.sum +golang.org/x/sys v0.2.0 h1:ljd4t30dBnAvMZaQCevtY0xLLD0A+bRZXbgLMLU1F/A= +golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/dave/.cache/go-build"" +GOENV=""/home/dave/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/dave/Source/Go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/dave/Source/Go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go-1.19"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go-1.19/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.19.3"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/dave/Source/keyholder/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build1272319925=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.19.3 linux/amd64 +$ cat go.sum +golang.org/x/sys v0.2.0 h1:ljd4t30dBnAvMZaQCevtY0xLLD0A+bRZXbgLMLU1F/A= +golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/dave/.cache/go-build"" +GOENV=""/home/dave/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/dave/Source/Go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/dave/Source/Go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go-1.19"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go-1.19/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.19.3"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/dave/Source/keyholder/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build1272319925=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.14.10 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +N/A + +### What operating system and processor architecture are you using (`go env`)? + +N/A + +### What did you do? + + + +Read the documentation for `unsafe.Pointer` + +### What did you expect to see? + +A documented method for accessing memory outside of the garbage-collected heap, such as memory allocated by C’s `malloc`. + +### What did you see instead? + +No such method.",1.0,"unsafe: document valid uses of `unsafe.Pointer` for non-Go memory - + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.14.10 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +N/A + +### What operating system and processor architecture are you using (`go env`)? + +N/A + +### What did you do? + + + +Read the documentation for `unsafe.Pointer` + +### What did you expect to see? + +A documented method for accessing memory outside of the garbage-collected heap, such as memory allocated by C’s `malloc`. + +### What did you see instead? + +No such method.",1,unsafe document valid uses of unsafe pointer for non go memory please answer these questions before submitting your issue thanks for questions please use one of our forums what version of go are you using go version go version go version linux does this issue reproduce with the latest release n a what operating system and processor architecture are you using go env n a what did you do if possible provide a recipe for reproducing the error a complete runnable program is good a link on play golang org is best read the documentation for unsafe pointer what did you expect to see a documented method for accessing memory outside of the garbage collected heap such as memory allocated by c’s malloc what did you see instead no such method ,1 +152143,13446463489.0,IssuesEvent,2020-09-08 13:00:05,golang/go,https://api.github.com/repos/golang/go,closed,"x/website: It looks like there's a copy paste error in the ""Create a Go module"" tutorial",Documentation NeedsFix,"> Create a module -- Write a small module with functions you can call from another module. +> Call your code from another module -- Add simple error handling. +> Return and handle an error -- Add simple error handling. +> Return a random greeting -- Handle data in slices (Go's dynamically-sized arrays). + +The text in the 2nd list item is a duplicate of the text in the 3rd list item.",1.0,"x/website: It looks like there's a copy paste error in the ""Create a Go module"" tutorial - > Create a module -- Write a small module with functions you can call from another module. +> Call your code from another module -- Add simple error handling. +> Return and handle an error -- Add simple error handling. +> Return a random greeting -- Handle data in slices (Go's dynamically-sized arrays). + +The text in the 2nd list item is a duplicate of the text in the 3rd list item.",1,x website it looks like there s a copy paste error in the create a go module tutorial create a module write a small module with functions you can call from another module call your code from another module add simple error handling return and handle an error add simple error handling return a random greeting handle data in slices go s dynamically sized arrays the text in the list item is a duplicate of the text in the list item ,1 +36787,17935400609.0,IssuesEvent,2021-09-10 14:44:03,golang/go,https://api.github.com/repos/golang/go,closed,strange performance regression: lookup vs rsh,Performance," + +### What version of Go are you using (`go version`)? + +
+go version go1.17 linux/amd64 + ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/user/.cache/go-build"" +GOENV=""/home/user/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/user/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/user/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.17"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/user/go/src/github.com/ethereum/go-ethereum/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build171075918=/tmp/go-build -gno-record-gcc-switches"" + +
+go version go1.17 linux/amd64 + ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/user/.cache/go-build"" +GOENV=""/home/user/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/user/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/user/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.17"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/user/go/src/github.com/ethereum/go-ethereum/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build171075918=/tmp/go-build -gno-record-gcc-switches"" + +
+go version go1.12.1 darwin/amd64 + ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/me/Library/Caches/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/me/go"" +GOPROXY="""" +GORACE="""" +GOROOT=""/Users/me/sdk/go1.12.1"" +GOTMPDIR="""" +GOTOOLDIR=""/Users/me/sdk/go1.12.1/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/me/orbital/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/sp/06p28g2d0vs7gd2vhf26wl9m0000gn/T/go-build849154512=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ grep bson go.mod +$ grep labix go.mod + labix.org/v2/mgo v0.0.0-20140701140051-000000000287 // indirect +$ go mod why labix.org/v2/mgo +# labix.org/v2/mgo +(main module does not need package labix.org/v2/mgo) +$ go mod why labix.org/v2/mgo/bson +# labix.org/v2/mgo/bson +/very/important/package +github.com/nats-io/go-nats-streaming +github.com/nats-io/go-nats-streaming.test +github.com/nats-io/nats-streaming-server/server +github.com/hashicorp/go-msgpack/codec +github.com/hashicorp/go-msgpack/codec.test +labix.org/v2/mgo/bson +$ go mod vendor +$ find vendor -name bson +$ ++ + + +### What did you expect to see? + +At least some mention of the package ""bson"" anywhere in go mod's output. + +### What did you see instead? + +Zero mention of the package ""bson"" anywhere in go mod's output.",1.0,"cmd/go: go mod why lies - + +### What version of Go are you using (`go version`)? + +
+go version go1.12.1 darwin/amd64 + ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/me/Library/Caches/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/me/go"" +GOPROXY="""" +GORACE="""" +GOROOT=""/Users/me/sdk/go1.12.1"" +GOTMPDIR="""" +GOTOOLDIR=""/Users/me/sdk/go1.12.1/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/me/orbital/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/sp/06p28g2d0vs7gd2vhf26wl9m0000gn/T/go-build849154512=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ grep bson go.mod +$ grep labix go.mod + labix.org/v2/mgo v0.0.0-20140701140051-000000000287 // indirect +$ go mod why labix.org/v2/mgo +# labix.org/v2/mgo +(main module does not need package labix.org/v2/mgo) +$ go mod why labix.org/v2/mgo/bson +# labix.org/v2/mgo/bson +/very/important/package +github.com/nats-io/go-nats-streaming +github.com/nats-io/go-nats-streaming.test +github.com/nats-io/nats-streaming-server/server +github.com/hashicorp/go-msgpack/codec +github.com/hashicorp/go-msgpack/codec.test +labix.org/v2/mgo/bson +$ go mod vendor +$ find vendor -name bson +$ ++ + + +### What did you expect to see? + +At least some mention of the package ""bson"" anywhere in go mod's output. + +### What did you see instead? + +Zero mention of the package ""bson"" anywhere in go mod's output.",1,cmd go go mod why lies what version of go are you using go version go version darwin does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env go env output go env goarch gobin gocache users me library caches go build goexe goflags gohostarch gohostos darwin goos darwin gopath users me go goproxy gorace goroot users me sdk gotmpdir gotooldir users me sdk pkg tool darwin gccgo gccgo cc clang cxx clang cgo enabled gomod users me orbital go mod cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map var folders sp t go tmp go build gno record gcc switches fno common what did you do grep bson go mod grep labix go mod labix org mgo indirect go mod why labix org mgo labix org mgo main module does not need package labix org mgo go mod why labix org mgo bson labix org mgo bson very important package github com nats io go nats streaming github com nats io go nats streaming test github com nats io nats streaming server server github com hashicorp go msgpack codec github com hashicorp go msgpack codec test labix org mgo bson go mod vendor find vendor name bson what did you expect to see at least some mention of the package bson anywhere in go mod s output what did you see instead zero mention of the package bson anywhere in go mod s output ,1 +139070,11242837453.0,IssuesEvent,2020-01-10 00:43:50,golang/go,https://api.github.com/repos/golang/go,opened,cmd/go/internal/modload: e0cf3de987e6 no longer is the latest commit on the master branch,GoCommand NeedsInvestigation Testing modules,"Both on `master` and `release-branch.go1.13`, there is a comment in query_test.go: + +https://github.com/golang/go/blob/56d6b87972c9852570fe017ac5fa153314c21992/src/cmd/go/internal/modload/query_test.go#L166-L170 + +It says that ""e0cf3de987e6 is the latest commit on the master branch"". This is no longer true, there are now three newer commits on master branch of https://vcs-test.golang.org/git/querytest repo: + +``` +querytest $ git log --oneline origin/master +ed5ffda (HEAD -> master, origin/master, origin/HEAD) after v1.9.10-pre2+metadata +42abcb6 (tag: v1.9.10-pre2+metadata) at v1.9.10-pre2+metadata +66f8cbe before v1.9.10-pre2+metadata +e0cf3de (tag: v1.9.10-pre1) at v1.9.10-pre1 +``` + +Other than the comment being wrong, this is harmless and the tests are still passing on `master` and `release-branch.go1.13`. + +However, `release-branch.go1.12` does not have [CL 186237](https://golang.org/cl/186237) applied: + +https://github.com/golang/go/blob/56d6b87972c9852570fe017ac5fa153314c21992/src/cmd/go/internal/modload/query_test.go#L166-L170 + +Which is causing the `TestQuery` test to fail on `release-branch.go1.12`: + +
+$ go version +go version go1.16.3 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What did you expect to see? + +In text/template [doc page](https://golang.org/pkg/text/template/), `define` action should be officially listed in 'Actions' section. + +### What did you see instead? + +In text/template [doc page](https://golang.org/pkg/text/template/), `define` action is described in a separate section, named [""Nested template definitions""](https://golang.org/pkg/text/template/#hdr-Nested_template_definitions), however, as an action, it's not listed in the [""Actions""](https://golang.org/pkg/text/template/#hdr-Actions) section as other actions do. It should also be there. +",1.0,"text/template: doc: `define` action is not listed and described in ""Actions"" section - + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.16.3 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What did you expect to see? + +In text/template [doc page](https://golang.org/pkg/text/template/), `define` action should be officially listed in 'Actions' section. + +### What did you see instead? + +In text/template [doc page](https://golang.org/pkg/text/template/), `define` action is described in a separate section, named [""Nested template definitions""](https://golang.org/pkg/text/template/#hdr-Nested_template_definitions), however, as an action, it's not listed in the [""Actions""](https://golang.org/pkg/text/template/#hdr-Actions) section as other actions do. It should also be there. +",1,text template doc define action is not listed and described in actions section please answer these questions before submitting your issue thanks for questions please use one of our forums what version of go are you using go version go version go version linux does this issue reproduce with the latest release yes what did you expect to see in text template define action should be officially listed in actions section what did you see instead in text template define action is described in a separate section named however as an action it s not listed in the section as other actions do it should also be there ,1 +70967,18358511454.0,IssuesEvent,2021-10-08 22:28:45,golang/go,https://api.github.com/repos/golang/go,closed,x/build/cmd/coordinator: some subrepos want to run tests in both module and GOPATH modes,Testing Builders NeedsDecision FeatureRequest,"coordinator already had support for running tests (at least trybots) in module mode, it's used for `oauth2` and `build` subrepos: + +https://github.com/golang/build/blob/34b995b40b0d31f2760a2f57b9ce74e17925702c/cmd/coordinator/coordinator.go#L2506-L2507 + +Some subrepos, such as x/tools, may want to soon start running their tests in both `GO111MODULE=on` and `GO111MODULE=off` modes, in order to make sure there are no regressions in either mode. + +We should add support for this to the coordinator. + +/cc @bradfitz @matloob",1.0,"x/build/cmd/coordinator: some subrepos want to run tests in both module and GOPATH modes - coordinator already had support for running tests (at least trybots) in module mode, it's used for `oauth2` and `build` subrepos: + +https://github.com/golang/build/blob/34b995b40b0d31f2760a2f57b9ce74e17925702c/cmd/coordinator/coordinator.go#L2506-L2507 + +Some subrepos, such as x/tools, may want to soon start running their tests in both `GO111MODULE=on` and `GO111MODULE=off` modes, in order to make sure there are no regressions in either mode. + +We should add support for this to the coordinator. + +/cc @bradfitz @matloob",0,x build cmd coordinator some subrepos want to run tests in both module and gopath modes coordinator already had support for running tests at least trybots in module mode it s used for and build subrepos some subrepos such as x tools may want to soon start running their tests in both on and off modes in order to make sure there are no regressions in either mode we should add support for this to the coordinator cc bradfitz matloob,0 +140322,12891489221.0,IssuesEvent,2020-07-13 17:49:45,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: include GOMODCACHE in documented list of environment variables,Documentation NeedsFix release-blocker,"Go 1.15 adds the `GOMODCACHE` environment variable (#34527). It's mentioned in the release notes ([CL 230537](https://golang.org/cl/230537)). Should it also be included in the list at https://tip.golang.org/cmd/go/#hdr-Environment_variables? + +/cc @jayconrod @matloob @bcmills",1.0,"cmd/go: include GOMODCACHE in documented list of environment variables - Go 1.15 adds the `GOMODCACHE` environment variable (#34527). It's mentioned in the release notes ([CL 230537](https://golang.org/cl/230537)). Should it also be included in the list at https://tip.golang.org/cmd/go/#hdr-Environment_variables? + +/cc @jayconrod @matloob @bcmills",1,cmd go include gomodcache in documented list of environment variables go adds the gomodcache environment variable it s mentioned in the release notes should it also be included in the list at cc jayconrod matloob bcmills,1 +47630,7334666905.0,IssuesEvent,2018-03-05 23:48:40,golang/go,https://api.github.com/repos/golang/go,closed,os/exec: document that you must call Wait before accessing copied output,Documentation NeedsFix help wanted,"### What version of Go are you using (`go version`)? + go version go1.10 linux/amd64 + +### Does this issue reproduce with the latest release? +The bug does not appear in 1.9.4, therefore it seems to be a regression in 1.10. + +### What operating system and processor architecture are you using (`go env`)? +
+GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/howard/.cache/go-build"" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/howard/gopath"" +GORACE="""" +GOROOT=""/home/howard/go"" +GOTMPDIR="""" +GOTOOLDIR=""/home/howard/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build479455967=/tmp/go-build -gno-record-gcc-switches"" ++ +### What did you do? + +Run the following piece of code: +
+package main
+
+import (
+ ""os/exec""
+ ""bytes""
+ ""time""
+ ""fmt""
+)
+
+func main() {
+ c := exec.Command(""/bin/bash"", ""-c"", ""echo abc && sleep 10"")
+ var outBuf bytes.Buffer
+ c.Stdout = &outBuf
+
+ if err := c.Start(); err != nil {
+ panic(err)
+ }
+
+ time.Sleep(3 * time.Second)
+ if err := c.Process.Kill(); err != nil {
+ panic(err)
+ }
+
+ fmt.Println(outBuf.Bytes())
+}
+
+
+Using previous go 1.9.4, the output correctly shows individual bytes in string `abc\n`:
+
+ [97 98 99 10]
+
+However, using go 1.10, the output shows:
+
+ [97 98 99 10 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]
+
+Oddly, if the bash command does not say `&& sleep 10`, which means the bash program exits normally before it is killed, both 1.10 and 1.9.4 will collect the correct output `[97 98 99 10]`.
+
+This is potentially a regression in 1.10.
+",1.0,"os/exec: document that you must call Wait before accessing copied output - ### What version of Go are you using (`go version`)?
+ go version go1.10 linux/amd64
+
+### Does this issue reproduce with the latest release?
+The bug does not appear in 1.9.4, therefore it seems to be a regression in 1.10.
+
+### What operating system and processor architecture are you using (`go env`)?
++GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/howard/.cache/go-build"" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/howard/gopath"" +GORACE="""" +GOROOT=""/home/howard/go"" +GOTMPDIR="""" +GOTOOLDIR=""/home/howard/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build479455967=/tmp/go-build -gno-record-gcc-switches"" ++ +### What did you do? + +Run the following piece of code: +
+package main
+
+import (
+ ""os/exec""
+ ""bytes""
+ ""time""
+ ""fmt""
+)
+
+func main() {
+ c := exec.Command(""/bin/bash"", ""-c"", ""echo abc && sleep 10"")
+ var outBuf bytes.Buffer
+ c.Stdout = &outBuf
+
+ if err := c.Start(); err != nil {
+ panic(err)
+ }
+
+ time.Sleep(3 * time.Second)
+ if err := c.Process.Kill(); err != nil {
+ panic(err)
+ }
+
+ fmt.Println(outBuf.Bytes())
+}
+
+
+Using previous go 1.9.4, the output correctly shows individual bytes in string `abc\n`:
+
+ [97 98 99 10]
+
+However, using go 1.10, the output shows:
+
+ [97 98 99 10 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]
+
+Oddly, if the bash command does not say `&& sleep 10`, which means the bash program exits normally before it is killed, both 1.10 and 1.9.4 will collect the correct output `[97 98 99 10]`.
+
+This is potentially a regression in 1.10.
+",1,os exec document that you must call wait before accessing copied output what version of go are you using go version go version linux does this issue reproduce with the latest release the bug does not appear in therefore it seems to be a regression in what operating system and processor architecture are you using go env goarch gobin gocache home howard cache go build goexe gohostarch gohostos linux goos linux gopath home howard gopath gorace goroot home howard go gotmpdir gotooldir home howard go pkg tool linux gccgo gccgo cc gcc cxx g cgo enabled cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fmessage length fdebug prefix map tmp go tmp go build gno record gcc switches what did you do run the following piece of code package main import os exec bytes time fmt func main c exec command bin bash c echo abc sleep var outbuf bytes buffer c stdout outbuf if err c start err nil panic err time sleep time second if err c process kill err nil panic err fmt println outbuf bytes using previous go the output correctly shows individual bytes in string abc n however using go the output shows oddly if the bash command does not say sleep which means the bash program exits normally before it is killed both and will collect the correct output this is potentially a regression in ,1
+250420,27086629169.0,IssuesEvent,2023-02-14 17:27:22,golang/go,https://api.github.com/repos/golang/go,closed,security: fix CVE-2022-41722 [1.19 backport],Security CherryPickApproved,"@neild requested issue #57274 to be considered for backport to the next 1.19 minor release.
+
+> @gopherbot please open backport issues. This is a security fix.
+",True,"security: fix CVE-2022-41722 [1.19 backport] - @neild requested issue #57274 to be considered for backport to the next 1.19 minor release.
+
+> @gopherbot please open backport issues. This is a security fix.
+",0,security fix cve neild requested issue to be considered for backport to the next minor release gopherbot please open backport issues this is a security fix ,0
+102258,11278105354.0,IssuesEvent,2020-01-15 05:33:39,golang/go,https://api.github.com/repos/golang/go,closed,"doc: go-spec.html missing space before . on line 2416, OperandName = identifier | QualifiedIdent.",Documentation NeedsFix,"
+
+### What version of Go are you using (`go version`)?
+
++go 1.13.5 + +(line 2416 is as of current master) + ++ +### Does this issue reproduce with the latest release? + +yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/user2/Library/Caches/go-build"" +GOENV=""/Users/user2/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/user2/A/AL3/code/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/8v/vpckwgfs4_547sb94qr9f4d40000gq/T/go-build564981435=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
+go 1.13.5 + +(line 2416 is as of current master) + ++ +### Does this issue reproduce with the latest release? + +yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/user2/Library/Caches/go-build"" +GOENV=""/Users/user2/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/user2/A/AL3/code/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/8v/vpckwgfs4_547sb94qr9f4d40000gq/T/go-build564981435=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
+go version go1.11.4 dragonfly/amd64 + ++ +### Does this issue reproduce with the latest release? + +yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+amd64 + +
+go version go1.11.4 dragonfly/amd64 + ++ +### Does this issue reproduce with the latest release? + +yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+amd64 + +
+$ go version +go version devel go1.21-c30faf9c54 Fri Jul 14 12:49:10 2023 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? +No. + + +### What operating system and processor architecture are you using (`go env`)? +Linux, amd64 + +### What did you do? + +Compile + +``` +func pack20(in *[20]uint64) uint64 { + var out uint64 + out |= 4 + out |= in[0] << 4 + out |= in[1] << 7 + out |= in[2] << 10 + out |= in[3] << 13 + out |= in[4] << 16 + out |= in[5] << 19 + out |= in[6] << 22 + out |= in[7] << 25 + out |= in[8] << 28 + out |= in[9] << 31 + out |= in[10] << 34 + out |= in[11] << 37 + out |= in[12] << 40 + out |= in[13] << 43 + out |= in[14] << 46 + out |= in[15] << 49 + out |= in[16] << 52 + out |= in[17] << 55 + out |= in[18] << 58 + out |= in[19] << 61 + return out +} +``` + + +### What did you expect to see? + +Output similar to that of Go 1.20.6: + +``` +command-line-arguments.pack20 STEXT nosplit size=233 args=0x8 locals=0x0 funcid=0x0 align=0x0 + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) TEXT command-line-arguments.pack20(SB), NOSPLIT|ABIInternal, $0-8 + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $0, gclocals·wgcWObbY2HYnK2SU/U22lA==(SB) + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $1, gclocals·J5F+7Qw7O7ve2QcWC7DpeQ==(SB) + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $5, command-line-arguments.pack20.arginfo1(SB) + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $6, command-line-arguments.pack20.argliveinfo(SB) + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) PCDATA $3, $1 + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:6) MOVQ (AX), CX + 0x0003 00003 (/home/dominikh/prj/src/example.com/foo.go:6) SHLQ $4, CX + 0x0007 00007 (/home/dominikh/prj/src/example.com/foo.go:7) MOVQ 8(AX), DX + 0x000b 00011 (/home/dominikh/prj/src/example.com/foo.go:7) SHLQ $7, DX + 0x000f 00015 (/home/dominikh/prj/src/example.com/foo.go:7) ORQ DX, CX + 0x0012 00018 (/home/dominikh/prj/src/example.com/foo.go:8) MOVQ 16(AX), DX + 0x0016 00022 (/home/dominikh/prj/src/example.com/foo.go:8) SHLQ $10, DX + 0x001a 00026 (/home/dominikh/prj/src/example.com/foo.go:8) ORQ CX, DX + 0x001d 00029 (/home/dominikh/prj/src/example.com/foo.go:9) MOVQ 24(AX), CX + 0x0021 00033 (/home/dominikh/prj/src/example.com/foo.go:9) SHLQ $13, CX + 0x0025 00037 (/home/dominikh/prj/src/example.com/foo.go:9) ORQ DX, CX + 0x0028 00040 (/home/dominikh/prj/src/example.com/foo.go:10) MOVQ 32(AX), DX + 0x002c 00044 (/home/dominikh/prj/src/example.com/foo.go:10) SHLQ $16, DX + 0x0030 00048 (/home/dominikh/prj/src/example.com/foo.go:10) ORQ CX, DX + 0x0033 00051 (/home/dominikh/prj/src/example.com/foo.go:11) MOVQ 40(AX), CX + 0x0037 00055 (/home/dominikh/prj/src/example.com/foo.go:11) SHLQ $19, CX + 0x003b 00059 (/home/dominikh/prj/src/example.com/foo.go:11) ORQ DX, CX + 0x003e 00062 (/home/dominikh/prj/src/example.com/foo.go:12) MOVQ 48(AX), DX + 0x0042 00066 (/home/dominikh/prj/src/example.com/foo.go:12) SHLQ $22, DX + 0x0046 00070 (/home/dominikh/prj/src/example.com/foo.go:12) ORQ CX, DX + 0x0049 00073 (/home/dominikh/prj/src/example.com/foo.go:13) MOVQ 56(AX), CX + 0x004d 00077 (/home/dominikh/prj/src/example.com/foo.go:13) SHLQ $25, CX + 0x0051 00081 (/home/dominikh/prj/src/example.com/foo.go:13) ORQ DX, CX + 0x0054 00084 (/home/dominikh/prj/src/example.com/foo.go:14) MOVQ 64(AX), DX + 0x0058 00088 (/home/dominikh/prj/src/example.com/foo.go:14) SHLQ $28, DX + 0x005c 00092 (/home/dominikh/prj/src/example.com/foo.go:14) ORQ CX, DX + 0x005f 00095 (/home/dominikh/prj/src/example.com/foo.go:15) MOVQ 72(AX), CX + 0x0063 00099 (/home/dominikh/prj/src/example.com/foo.go:15) SHLQ $31, CX + 0x0067 00103 (/home/dominikh/prj/src/example.com/foo.go:15) ORQ DX, CX + 0x006a 00106 (/home/dominikh/prj/src/example.com/foo.go:16) MOVQ 80(AX), DX + 0x006e 00110 (/home/dominikh/prj/src/example.com/foo.go:16) SHLQ $34, DX + 0x0072 00114 (/home/dominikh/prj/src/example.com/foo.go:16) ORQ CX, DX + 0x0075 00117 (/home/dominikh/prj/src/example.com/foo.go:17) MOVQ 88(AX), CX + 0x0079 00121 (/home/dominikh/prj/src/example.com/foo.go:17) SHLQ $37, CX + 0x007d 00125 (/home/dominikh/prj/src/example.com/foo.go:17) ORQ DX, CX + 0x0080 00128 (/home/dominikh/prj/src/example.com/foo.go:18) MOVQ 96(AX), DX + 0x0084 00132 (/home/dominikh/prj/src/example.com/foo.go:18) SHLQ $40, DX + 0x0088 00136 (/home/dominikh/prj/src/example.com/foo.go:18) ORQ CX, DX + 0x008b 00139 (/home/dominikh/prj/src/example.com/foo.go:19) MOVQ 104(AX), CX + 0x008f 00143 (/home/dominikh/prj/src/example.com/foo.go:19) SHLQ $43, CX + 0x0093 00147 (/home/dominikh/prj/src/example.com/foo.go:19) ORQ DX, CX + 0x0096 00150 (/home/dominikh/prj/src/example.com/foo.go:20) MOVQ 112(AX), DX + 0x009a 00154 (/home/dominikh/prj/src/example.com/foo.go:20) SHLQ $46, DX + 0x009e 00158 (/home/dominikh/prj/src/example.com/foo.go:20) ORQ CX, DX + 0x00a1 00161 (/home/dominikh/prj/src/example.com/foo.go:21) MOVQ 120(AX), CX + 0x00a5 00165 (/home/dominikh/prj/src/example.com/foo.go:21) SHLQ $49, CX + 0x00a9 00169 (/home/dominikh/prj/src/example.com/foo.go:21) ORQ DX, CX + 0x00ac 00172 (/home/dominikh/prj/src/example.com/foo.go:22) MOVQ 128(AX), DX + 0x00b3 00179 (/home/dominikh/prj/src/example.com/foo.go:22) SHLQ $52, DX + 0x00b7 00183 (/home/dominikh/prj/src/example.com/foo.go:22) ORQ CX, DX + 0x00ba 00186 (/home/dominikh/prj/src/example.com/foo.go:23) MOVQ 136(AX), CX + 0x00c1 00193 (/home/dominikh/prj/src/example.com/foo.go:23) SHLQ $55, CX + 0x00c5 00197 (/home/dominikh/prj/src/example.com/foo.go:23) ORQ DX, CX + 0x00c8 00200 (/home/dominikh/prj/src/example.com/foo.go:24) MOVQ 144(AX), DX + 0x00cf 00207 (/home/dominikh/prj/src/example.com/foo.go:24) SHLQ $58, DX + 0x00d3 00211 (/home/dominikh/prj/src/example.com/foo.go:24) ORQ CX, DX + 0x00d6 00214 (/home/dominikh/prj/src/example.com/foo.go:25) MOVQ 152(AX), AX + 0x00dd 00221 (/home/dominikh/prj/src/example.com/foo.go:25) SHLQ $61, AX + 0x00e1 00225 (/home/dominikh/prj/src/example.com/foo.go:25) ORQ DX, AX + 0x00e4 00228 (/home/dominikh/prj/src/example.com/foo.go:25) ORQ $4, AX + 0x00e8 00232 (/home/dominikh/prj/src/example.com/foo.go:26) RET +``` + + +### What did you see instead? + + +``` +command-line-arguments.pack20 STEXT nosplit size=314 args=0x8 locals=0x40 funcid=0x0 align=0x0 + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) TEXT command-line-arguments.pack20(SB), NOSPLIT|ABIInternal, $64-8 + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) PUSHQ BP + 0x0001 00001 (/home/dominikh/prj/src/example.com/foo.go:3) MOVQ SP, BP + 0x0004 00004 (/home/dominikh/prj/src/example.com/foo.go:3) SUBQ $56, SP + 0x0008 00008 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $0, gclocals·wgcWObbY2HYnK2SU/U22lA==(SB) + 0x0008 00008 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $1, gclocals·J5F+7Qw7O7ve2QcWC7DpeQ==(SB) + 0x0008 00008 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $5, command-line-arguments.pack20.arginfo1(SB) + 0x0008 00008 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $6, command-line-arguments.pack20.argliveinfo(SB) + 0x0008 00008 (/home/dominikh/prj/src/example.com/foo.go:3) PCDATA $3, $1 + 0x0008 00008 (/home/dominikh/prj/src/example.com/foo.go:6) MOVQ 8(AX), CX + 0x000c 00012 (/home/dominikh/prj/src/example.com/foo.go:8) MOVQ 16(AX), DX + 0x0010 00016 (/home/dominikh/prj/src/example.com/foo.go:9) MOVQ 24(AX), BX + 0x0014 00020 (/home/dominikh/prj/src/example.com/foo.go:10) MOVQ 32(AX), SI + 0x0018 00024 (/home/dominikh/prj/src/example.com/foo.go:11) MOVQ 40(AX), DI + 0x001c 00028 (/home/dominikh/prj/src/example.com/foo.go:12) MOVQ 48(AX), R8 + 0x0020 00032 (/home/dominikh/prj/src/example.com/foo.go:13) MOVQ 56(AX), R9 + 0x0024 00036 (/home/dominikh/prj/src/example.com/foo.go:14) MOVQ 64(AX), R10 + 0x0028 00040 (/home/dominikh/prj/src/example.com/foo.go:15) MOVQ 72(AX), R11 + 0x002c 00044 (/home/dominikh/prj/src/example.com/foo.go:16) MOVQ 80(AX), R12 + 0x0030 00048 (/home/dominikh/prj/src/example.com/foo.go:17) MOVQ 88(AX), R13 + 0x0034 00052 (/home/dominikh/prj/src/example.com/foo.go:18) MOVQ 96(AX), R15 + 0x0038 00056 (/home/dominikh/prj/src/example.com/foo.go:18) MOVQ R15, command-line-arguments..autotmp_3+48(SP) + 0x003d 00061 (/home/dominikh/prj/src/example.com/foo.go:19) MOVQ 104(AX), R15 + 0x0041 00065 (/home/dominikh/prj/src/example.com/foo.go:19) MOVQ R15, command-line-arguments..autotmp_4+40(SP) + 0x0046 00070 (/home/dominikh/prj/src/example.com/foo.go:20) MOVQ 112(AX), R15 + 0x004a 00074 (/home/dominikh/prj/src/example.com/foo.go:20) MOVQ R15, command-line-arguments..autotmp_5+32(SP) + 0x004f 00079 (/home/dominikh/prj/src/example.com/foo.go:21) MOVQ 120(AX), R15 + 0x0053 00083 (/home/dominikh/prj/src/example.com/foo.go:21) MOVQ R15, command-line-arguments..autotmp_6+24(SP) + 0x0058 00088 (/home/dominikh/prj/src/example.com/foo.go:22) MOVQ 128(AX), R15 + 0x005f 00095 (/home/dominikh/prj/src/example.com/foo.go:22) MOVQ R15, command-line-arguments..autotmp_7+16(SP) + 0x0064 00100 (/home/dominikh/prj/src/example.com/foo.go:23) MOVQ 136(AX), R15 + 0x006b 00107 (/home/dominikh/prj/src/example.com/foo.go:23) MOVQ R15, command-line-arguments..autotmp_8+8(SP) + 0x0070 00112 (/home/dominikh/prj/src/example.com/foo.go:24) MOVQ 144(AX), R15 + 0x0077 00119 (/home/dominikh/prj/src/example.com/foo.go:24) MOVQ R15, command-line-arguments..autotmp_9(SP) + 0x007b 00123 (/home/dominikh/prj/src/example.com/foo.go:25) MOVQ 152(AX), R15 + 0x0082 00130 (/home/dominikh/prj/src/example.com/foo.go:6) MOVQ (AX), AX + 0x0085 00133 (/home/dominikh/prj/src/example.com/foo.go:6) SHLQ $4, AX + 0x0089 00137 (/home/dominikh/prj/src/example.com/foo.go:7) SHLQ $7, CX + 0x008d 00141 (/home/dominikh/prj/src/example.com/foo.go:7) ORQ CX, AX + 0x0090 00144 (/home/dominikh/prj/src/example.com/foo.go:8) SHLQ $10, DX + 0x0094 00148 (/home/dominikh/prj/src/example.com/foo.go:8) ORQ DX, AX + 0x0097 00151 (/home/dominikh/prj/src/example.com/foo.go:9) SHLQ $13, BX + 0x009b 00155 (/home/dominikh/prj/src/example.com/foo.go:9) ORQ BX, AX + 0x009e 00158 (/home/dominikh/prj/src/example.com/foo.go:10) SHLQ $16, SI + 0x00a2 00162 (/home/dominikh/prj/src/example.com/foo.go:10) ORQ SI, AX + 0x00a5 00165 (/home/dominikh/prj/src/example.com/foo.go:11) SHLQ $19, DI + 0x00a9 00169 (/home/dominikh/prj/src/example.com/foo.go:11) ORQ DI, AX + 0x00ac 00172 (/home/dominikh/prj/src/example.com/foo.go:12) SHLQ $22, R8 + 0x00b0 00176 (/home/dominikh/prj/src/example.com/foo.go:12) ORQ R8, AX + 0x00b3 00179 (/home/dominikh/prj/src/example.com/foo.go:13) SHLQ $25, R9 + 0x00b7 00183 (/home/dominikh/prj/src/example.com/foo.go:13) ORQ R9, AX + 0x00ba 00186 (/home/dominikh/prj/src/example.com/foo.go:14) SHLQ $28, R10 + 0x00be 00190 (/home/dominikh/prj/src/example.com/foo.go:14) ORQ R10, AX + 0x00c1 00193 (/home/dominikh/prj/src/example.com/foo.go:15) SHLQ $31, R11 + 0x00c5 00197 (/home/dominikh/prj/src/example.com/foo.go:15) ORQ R11, AX + 0x00c8 00200 (/home/dominikh/prj/src/example.com/foo.go:16) SHLQ $34, R12 + 0x00cc 00204 (/home/dominikh/prj/src/example.com/foo.go:16) ORQ R12, AX + 0x00cf 00207 (/home/dominikh/prj/src/example.com/foo.go:17) SHLQ $37, R13 + 0x00d3 00211 (/home/dominikh/prj/src/example.com/foo.go:17) ORQ R13, AX + 0x00d6 00214 (/home/dominikh/prj/src/example.com/foo.go:18) MOVQ command-line-arguments..autotmp_3+48(SP), CX + 0x00db 00219 (/home/dominikh/prj/src/example.com/foo.go:18) SHLQ $40, CX + 0x00df 00223 (/home/dominikh/prj/src/example.com/foo.go:18) ORQ CX, AX + 0x00e2 00226 (/home/dominikh/prj/src/example.com/foo.go:19) MOVQ command-line-arguments..autotmp_4+40(SP), CX + 0x00e7 00231 (/home/dominikh/prj/src/example.com/foo.go:19) SHLQ $43, CX + 0x00eb 00235 (/home/dominikh/prj/src/example.com/foo.go:19) ORQ CX, AX + 0x00ee 00238 (/home/dominikh/prj/src/example.com/foo.go:20) MOVQ command-line-arguments..autotmp_5+32(SP), CX + 0x00f3 00243 (/home/dominikh/prj/src/example.com/foo.go:20) SHLQ $46, CX + 0x00f7 00247 (/home/dominikh/prj/src/example.com/foo.go:20) ORQ CX, AX + 0x00fa 00250 (/home/dominikh/prj/src/example.com/foo.go:21) MOVQ command-line-arguments..autotmp_6+24(SP), CX + 0x00ff 00255 (/home/dominikh/prj/src/example.com/foo.go:21) SHLQ $49, CX + 0x0103 00259 (/home/dominikh/prj/src/example.com/foo.go:21) ORQ CX, AX + 0x0106 00262 (/home/dominikh/prj/src/example.com/foo.go:22) MOVQ command-line-arguments..autotmp_7+16(SP), CX + 0x010b 00267 (/home/dominikh/prj/src/example.com/foo.go:22) SHLQ $52, CX + 0x010f 00271 (/home/dominikh/prj/src/example.com/foo.go:22) ORQ CX, AX + 0x0112 00274 (/home/dominikh/prj/src/example.com/foo.go:23) MOVQ command-line-arguments..autotmp_8+8(SP), CX + 0x0117 00279 (/home/dominikh/prj/src/example.com/foo.go:23) SHLQ $55, CX + 0x011b 00283 (/home/dominikh/prj/src/example.com/foo.go:23) ORQ CX, AX + 0x011e 00286 (/home/dominikh/prj/src/example.com/foo.go:24) MOVQ command-line-arguments..autotmp_9(SP), CX + 0x0122 00290 (/home/dominikh/prj/src/example.com/foo.go:24) SHLQ $58, CX + 0x0126 00294 (/home/dominikh/prj/src/example.com/foo.go:24) ORQ CX, AX + 0x0129 00297 (/home/dominikh/prj/src/example.com/foo.go:25) SHLQ $61, R15 + 0x012d 00301 (/home/dominikh/prj/src/example.com/foo.go:25) ORQ R15, AX + 0x0130 00304 (/home/dominikh/prj/src/example.com/foo.go:25) ORQ $4, AX + 0x0134 00308 (/home/dominikh/prj/src/example.com/foo.go:26) ADDQ $56, SP + 0x0138 00312 (/home/dominikh/prj/src/example.com/foo.go:26) POPQ BP + 0x0139 00313 (/home/dominikh/prj/src/example.com/foo.go:26) RET +``` + +Go 1.21 seems to be loading all of the values up front, only to spill some of them to the stack. This seems strictly worse than the old output. + +/cc @prattmic ",True,"cmd/compile: regression: unnecessary spilling to the stack - ### What version of Go are you using (`go version`)? + +
+$ go version +go version devel go1.21-c30faf9c54 Fri Jul 14 12:49:10 2023 +0000 linux/amd64 ++ +### Does this issue reproduce with the latest release? +No. + + +### What operating system and processor architecture are you using (`go env`)? +Linux, amd64 + +### What did you do? + +Compile + +``` +func pack20(in *[20]uint64) uint64 { + var out uint64 + out |= 4 + out |= in[0] << 4 + out |= in[1] << 7 + out |= in[2] << 10 + out |= in[3] << 13 + out |= in[4] << 16 + out |= in[5] << 19 + out |= in[6] << 22 + out |= in[7] << 25 + out |= in[8] << 28 + out |= in[9] << 31 + out |= in[10] << 34 + out |= in[11] << 37 + out |= in[12] << 40 + out |= in[13] << 43 + out |= in[14] << 46 + out |= in[15] << 49 + out |= in[16] << 52 + out |= in[17] << 55 + out |= in[18] << 58 + out |= in[19] << 61 + return out +} +``` + + +### What did you expect to see? + +Output similar to that of Go 1.20.6: + +``` +command-line-arguments.pack20 STEXT nosplit size=233 args=0x8 locals=0x0 funcid=0x0 align=0x0 + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) TEXT command-line-arguments.pack20(SB), NOSPLIT|ABIInternal, $0-8 + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $0, gclocals·wgcWObbY2HYnK2SU/U22lA==(SB) + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $1, gclocals·J5F+7Qw7O7ve2QcWC7DpeQ==(SB) + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $5, command-line-arguments.pack20.arginfo1(SB) + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $6, command-line-arguments.pack20.argliveinfo(SB) + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) PCDATA $3, $1 + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:6) MOVQ (AX), CX + 0x0003 00003 (/home/dominikh/prj/src/example.com/foo.go:6) SHLQ $4, CX + 0x0007 00007 (/home/dominikh/prj/src/example.com/foo.go:7) MOVQ 8(AX), DX + 0x000b 00011 (/home/dominikh/prj/src/example.com/foo.go:7) SHLQ $7, DX + 0x000f 00015 (/home/dominikh/prj/src/example.com/foo.go:7) ORQ DX, CX + 0x0012 00018 (/home/dominikh/prj/src/example.com/foo.go:8) MOVQ 16(AX), DX + 0x0016 00022 (/home/dominikh/prj/src/example.com/foo.go:8) SHLQ $10, DX + 0x001a 00026 (/home/dominikh/prj/src/example.com/foo.go:8) ORQ CX, DX + 0x001d 00029 (/home/dominikh/prj/src/example.com/foo.go:9) MOVQ 24(AX), CX + 0x0021 00033 (/home/dominikh/prj/src/example.com/foo.go:9) SHLQ $13, CX + 0x0025 00037 (/home/dominikh/prj/src/example.com/foo.go:9) ORQ DX, CX + 0x0028 00040 (/home/dominikh/prj/src/example.com/foo.go:10) MOVQ 32(AX), DX + 0x002c 00044 (/home/dominikh/prj/src/example.com/foo.go:10) SHLQ $16, DX + 0x0030 00048 (/home/dominikh/prj/src/example.com/foo.go:10) ORQ CX, DX + 0x0033 00051 (/home/dominikh/prj/src/example.com/foo.go:11) MOVQ 40(AX), CX + 0x0037 00055 (/home/dominikh/prj/src/example.com/foo.go:11) SHLQ $19, CX + 0x003b 00059 (/home/dominikh/prj/src/example.com/foo.go:11) ORQ DX, CX + 0x003e 00062 (/home/dominikh/prj/src/example.com/foo.go:12) MOVQ 48(AX), DX + 0x0042 00066 (/home/dominikh/prj/src/example.com/foo.go:12) SHLQ $22, DX + 0x0046 00070 (/home/dominikh/prj/src/example.com/foo.go:12) ORQ CX, DX + 0x0049 00073 (/home/dominikh/prj/src/example.com/foo.go:13) MOVQ 56(AX), CX + 0x004d 00077 (/home/dominikh/prj/src/example.com/foo.go:13) SHLQ $25, CX + 0x0051 00081 (/home/dominikh/prj/src/example.com/foo.go:13) ORQ DX, CX + 0x0054 00084 (/home/dominikh/prj/src/example.com/foo.go:14) MOVQ 64(AX), DX + 0x0058 00088 (/home/dominikh/prj/src/example.com/foo.go:14) SHLQ $28, DX + 0x005c 00092 (/home/dominikh/prj/src/example.com/foo.go:14) ORQ CX, DX + 0x005f 00095 (/home/dominikh/prj/src/example.com/foo.go:15) MOVQ 72(AX), CX + 0x0063 00099 (/home/dominikh/prj/src/example.com/foo.go:15) SHLQ $31, CX + 0x0067 00103 (/home/dominikh/prj/src/example.com/foo.go:15) ORQ DX, CX + 0x006a 00106 (/home/dominikh/prj/src/example.com/foo.go:16) MOVQ 80(AX), DX + 0x006e 00110 (/home/dominikh/prj/src/example.com/foo.go:16) SHLQ $34, DX + 0x0072 00114 (/home/dominikh/prj/src/example.com/foo.go:16) ORQ CX, DX + 0x0075 00117 (/home/dominikh/prj/src/example.com/foo.go:17) MOVQ 88(AX), CX + 0x0079 00121 (/home/dominikh/prj/src/example.com/foo.go:17) SHLQ $37, CX + 0x007d 00125 (/home/dominikh/prj/src/example.com/foo.go:17) ORQ DX, CX + 0x0080 00128 (/home/dominikh/prj/src/example.com/foo.go:18) MOVQ 96(AX), DX + 0x0084 00132 (/home/dominikh/prj/src/example.com/foo.go:18) SHLQ $40, DX + 0x0088 00136 (/home/dominikh/prj/src/example.com/foo.go:18) ORQ CX, DX + 0x008b 00139 (/home/dominikh/prj/src/example.com/foo.go:19) MOVQ 104(AX), CX + 0x008f 00143 (/home/dominikh/prj/src/example.com/foo.go:19) SHLQ $43, CX + 0x0093 00147 (/home/dominikh/prj/src/example.com/foo.go:19) ORQ DX, CX + 0x0096 00150 (/home/dominikh/prj/src/example.com/foo.go:20) MOVQ 112(AX), DX + 0x009a 00154 (/home/dominikh/prj/src/example.com/foo.go:20) SHLQ $46, DX + 0x009e 00158 (/home/dominikh/prj/src/example.com/foo.go:20) ORQ CX, DX + 0x00a1 00161 (/home/dominikh/prj/src/example.com/foo.go:21) MOVQ 120(AX), CX + 0x00a5 00165 (/home/dominikh/prj/src/example.com/foo.go:21) SHLQ $49, CX + 0x00a9 00169 (/home/dominikh/prj/src/example.com/foo.go:21) ORQ DX, CX + 0x00ac 00172 (/home/dominikh/prj/src/example.com/foo.go:22) MOVQ 128(AX), DX + 0x00b3 00179 (/home/dominikh/prj/src/example.com/foo.go:22) SHLQ $52, DX + 0x00b7 00183 (/home/dominikh/prj/src/example.com/foo.go:22) ORQ CX, DX + 0x00ba 00186 (/home/dominikh/prj/src/example.com/foo.go:23) MOVQ 136(AX), CX + 0x00c1 00193 (/home/dominikh/prj/src/example.com/foo.go:23) SHLQ $55, CX + 0x00c5 00197 (/home/dominikh/prj/src/example.com/foo.go:23) ORQ DX, CX + 0x00c8 00200 (/home/dominikh/prj/src/example.com/foo.go:24) MOVQ 144(AX), DX + 0x00cf 00207 (/home/dominikh/prj/src/example.com/foo.go:24) SHLQ $58, DX + 0x00d3 00211 (/home/dominikh/prj/src/example.com/foo.go:24) ORQ CX, DX + 0x00d6 00214 (/home/dominikh/prj/src/example.com/foo.go:25) MOVQ 152(AX), AX + 0x00dd 00221 (/home/dominikh/prj/src/example.com/foo.go:25) SHLQ $61, AX + 0x00e1 00225 (/home/dominikh/prj/src/example.com/foo.go:25) ORQ DX, AX + 0x00e4 00228 (/home/dominikh/prj/src/example.com/foo.go:25) ORQ $4, AX + 0x00e8 00232 (/home/dominikh/prj/src/example.com/foo.go:26) RET +``` + + +### What did you see instead? + + +``` +command-line-arguments.pack20 STEXT nosplit size=314 args=0x8 locals=0x40 funcid=0x0 align=0x0 + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) TEXT command-line-arguments.pack20(SB), NOSPLIT|ABIInternal, $64-8 + 0x0000 00000 (/home/dominikh/prj/src/example.com/foo.go:3) PUSHQ BP + 0x0001 00001 (/home/dominikh/prj/src/example.com/foo.go:3) MOVQ SP, BP + 0x0004 00004 (/home/dominikh/prj/src/example.com/foo.go:3) SUBQ $56, SP + 0x0008 00008 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $0, gclocals·wgcWObbY2HYnK2SU/U22lA==(SB) + 0x0008 00008 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $1, gclocals·J5F+7Qw7O7ve2QcWC7DpeQ==(SB) + 0x0008 00008 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $5, command-line-arguments.pack20.arginfo1(SB) + 0x0008 00008 (/home/dominikh/prj/src/example.com/foo.go:3) FUNCDATA $6, command-line-arguments.pack20.argliveinfo(SB) + 0x0008 00008 (/home/dominikh/prj/src/example.com/foo.go:3) PCDATA $3, $1 + 0x0008 00008 (/home/dominikh/prj/src/example.com/foo.go:6) MOVQ 8(AX), CX + 0x000c 00012 (/home/dominikh/prj/src/example.com/foo.go:8) MOVQ 16(AX), DX + 0x0010 00016 (/home/dominikh/prj/src/example.com/foo.go:9) MOVQ 24(AX), BX + 0x0014 00020 (/home/dominikh/prj/src/example.com/foo.go:10) MOVQ 32(AX), SI + 0x0018 00024 (/home/dominikh/prj/src/example.com/foo.go:11) MOVQ 40(AX), DI + 0x001c 00028 (/home/dominikh/prj/src/example.com/foo.go:12) MOVQ 48(AX), R8 + 0x0020 00032 (/home/dominikh/prj/src/example.com/foo.go:13) MOVQ 56(AX), R9 + 0x0024 00036 (/home/dominikh/prj/src/example.com/foo.go:14) MOVQ 64(AX), R10 + 0x0028 00040 (/home/dominikh/prj/src/example.com/foo.go:15) MOVQ 72(AX), R11 + 0x002c 00044 (/home/dominikh/prj/src/example.com/foo.go:16) MOVQ 80(AX), R12 + 0x0030 00048 (/home/dominikh/prj/src/example.com/foo.go:17) MOVQ 88(AX), R13 + 0x0034 00052 (/home/dominikh/prj/src/example.com/foo.go:18) MOVQ 96(AX), R15 + 0x0038 00056 (/home/dominikh/prj/src/example.com/foo.go:18) MOVQ R15, command-line-arguments..autotmp_3+48(SP) + 0x003d 00061 (/home/dominikh/prj/src/example.com/foo.go:19) MOVQ 104(AX), R15 + 0x0041 00065 (/home/dominikh/prj/src/example.com/foo.go:19) MOVQ R15, command-line-arguments..autotmp_4+40(SP) + 0x0046 00070 (/home/dominikh/prj/src/example.com/foo.go:20) MOVQ 112(AX), R15 + 0x004a 00074 (/home/dominikh/prj/src/example.com/foo.go:20) MOVQ R15, command-line-arguments..autotmp_5+32(SP) + 0x004f 00079 (/home/dominikh/prj/src/example.com/foo.go:21) MOVQ 120(AX), R15 + 0x0053 00083 (/home/dominikh/prj/src/example.com/foo.go:21) MOVQ R15, command-line-arguments..autotmp_6+24(SP) + 0x0058 00088 (/home/dominikh/prj/src/example.com/foo.go:22) MOVQ 128(AX), R15 + 0x005f 00095 (/home/dominikh/prj/src/example.com/foo.go:22) MOVQ R15, command-line-arguments..autotmp_7+16(SP) + 0x0064 00100 (/home/dominikh/prj/src/example.com/foo.go:23) MOVQ 136(AX), R15 + 0x006b 00107 (/home/dominikh/prj/src/example.com/foo.go:23) MOVQ R15, command-line-arguments..autotmp_8+8(SP) + 0x0070 00112 (/home/dominikh/prj/src/example.com/foo.go:24) MOVQ 144(AX), R15 + 0x0077 00119 (/home/dominikh/prj/src/example.com/foo.go:24) MOVQ R15, command-line-arguments..autotmp_9(SP) + 0x007b 00123 (/home/dominikh/prj/src/example.com/foo.go:25) MOVQ 152(AX), R15 + 0x0082 00130 (/home/dominikh/prj/src/example.com/foo.go:6) MOVQ (AX), AX + 0x0085 00133 (/home/dominikh/prj/src/example.com/foo.go:6) SHLQ $4, AX + 0x0089 00137 (/home/dominikh/prj/src/example.com/foo.go:7) SHLQ $7, CX + 0x008d 00141 (/home/dominikh/prj/src/example.com/foo.go:7) ORQ CX, AX + 0x0090 00144 (/home/dominikh/prj/src/example.com/foo.go:8) SHLQ $10, DX + 0x0094 00148 (/home/dominikh/prj/src/example.com/foo.go:8) ORQ DX, AX + 0x0097 00151 (/home/dominikh/prj/src/example.com/foo.go:9) SHLQ $13, BX + 0x009b 00155 (/home/dominikh/prj/src/example.com/foo.go:9) ORQ BX, AX + 0x009e 00158 (/home/dominikh/prj/src/example.com/foo.go:10) SHLQ $16, SI + 0x00a2 00162 (/home/dominikh/prj/src/example.com/foo.go:10) ORQ SI, AX + 0x00a5 00165 (/home/dominikh/prj/src/example.com/foo.go:11) SHLQ $19, DI + 0x00a9 00169 (/home/dominikh/prj/src/example.com/foo.go:11) ORQ DI, AX + 0x00ac 00172 (/home/dominikh/prj/src/example.com/foo.go:12) SHLQ $22, R8 + 0x00b0 00176 (/home/dominikh/prj/src/example.com/foo.go:12) ORQ R8, AX + 0x00b3 00179 (/home/dominikh/prj/src/example.com/foo.go:13) SHLQ $25, R9 + 0x00b7 00183 (/home/dominikh/prj/src/example.com/foo.go:13) ORQ R9, AX + 0x00ba 00186 (/home/dominikh/prj/src/example.com/foo.go:14) SHLQ $28, R10 + 0x00be 00190 (/home/dominikh/prj/src/example.com/foo.go:14) ORQ R10, AX + 0x00c1 00193 (/home/dominikh/prj/src/example.com/foo.go:15) SHLQ $31, R11 + 0x00c5 00197 (/home/dominikh/prj/src/example.com/foo.go:15) ORQ R11, AX + 0x00c8 00200 (/home/dominikh/prj/src/example.com/foo.go:16) SHLQ $34, R12 + 0x00cc 00204 (/home/dominikh/prj/src/example.com/foo.go:16) ORQ R12, AX + 0x00cf 00207 (/home/dominikh/prj/src/example.com/foo.go:17) SHLQ $37, R13 + 0x00d3 00211 (/home/dominikh/prj/src/example.com/foo.go:17) ORQ R13, AX + 0x00d6 00214 (/home/dominikh/prj/src/example.com/foo.go:18) MOVQ command-line-arguments..autotmp_3+48(SP), CX + 0x00db 00219 (/home/dominikh/prj/src/example.com/foo.go:18) SHLQ $40, CX + 0x00df 00223 (/home/dominikh/prj/src/example.com/foo.go:18) ORQ CX, AX + 0x00e2 00226 (/home/dominikh/prj/src/example.com/foo.go:19) MOVQ command-line-arguments..autotmp_4+40(SP), CX + 0x00e7 00231 (/home/dominikh/prj/src/example.com/foo.go:19) SHLQ $43, CX + 0x00eb 00235 (/home/dominikh/prj/src/example.com/foo.go:19) ORQ CX, AX + 0x00ee 00238 (/home/dominikh/prj/src/example.com/foo.go:20) MOVQ command-line-arguments..autotmp_5+32(SP), CX + 0x00f3 00243 (/home/dominikh/prj/src/example.com/foo.go:20) SHLQ $46, CX + 0x00f7 00247 (/home/dominikh/prj/src/example.com/foo.go:20) ORQ CX, AX + 0x00fa 00250 (/home/dominikh/prj/src/example.com/foo.go:21) MOVQ command-line-arguments..autotmp_6+24(SP), CX + 0x00ff 00255 (/home/dominikh/prj/src/example.com/foo.go:21) SHLQ $49, CX + 0x0103 00259 (/home/dominikh/prj/src/example.com/foo.go:21) ORQ CX, AX + 0x0106 00262 (/home/dominikh/prj/src/example.com/foo.go:22) MOVQ command-line-arguments..autotmp_7+16(SP), CX + 0x010b 00267 (/home/dominikh/prj/src/example.com/foo.go:22) SHLQ $52, CX + 0x010f 00271 (/home/dominikh/prj/src/example.com/foo.go:22) ORQ CX, AX + 0x0112 00274 (/home/dominikh/prj/src/example.com/foo.go:23) MOVQ command-line-arguments..autotmp_8+8(SP), CX + 0x0117 00279 (/home/dominikh/prj/src/example.com/foo.go:23) SHLQ $55, CX + 0x011b 00283 (/home/dominikh/prj/src/example.com/foo.go:23) ORQ CX, AX + 0x011e 00286 (/home/dominikh/prj/src/example.com/foo.go:24) MOVQ command-line-arguments..autotmp_9(SP), CX + 0x0122 00290 (/home/dominikh/prj/src/example.com/foo.go:24) SHLQ $58, CX + 0x0126 00294 (/home/dominikh/prj/src/example.com/foo.go:24) ORQ CX, AX + 0x0129 00297 (/home/dominikh/prj/src/example.com/foo.go:25) SHLQ $61, R15 + 0x012d 00301 (/home/dominikh/prj/src/example.com/foo.go:25) ORQ R15, AX + 0x0130 00304 (/home/dominikh/prj/src/example.com/foo.go:25) ORQ $4, AX + 0x0134 00308 (/home/dominikh/prj/src/example.com/foo.go:26) ADDQ $56, SP + 0x0138 00312 (/home/dominikh/prj/src/example.com/foo.go:26) POPQ BP + 0x0139 00313 (/home/dominikh/prj/src/example.com/foo.go:26) RET +``` + +Go 1.21 seems to be loading all of the values up front, only to spill some of them to the stack. This seems strictly worse than the old output. + +/cc @prattmic ",0,cmd compile regression unnecessary spilling to the stack what version of go are you using go version go version go version devel fri jul linux does this issue reproduce with the latest release no what operating system and processor architecture are you using go env linux what did you do compile func in var out out out in out in out in out in out in out in out in out in out in out in out in out in out in out in out in out in out in out in out in out in return out what did you expect to see output similar to that of go command line arguments stext nosplit size args locals funcid align home dominikh prj src example com foo go text command line arguments sb nosplit abiinternal home dominikh prj src example com foo go funcdata gclocals· sb home dominikh prj src example com foo go funcdata gclocals· sb home dominikh prj src example com foo go funcdata command line arguments sb home dominikh prj src example com foo go funcdata command line arguments argliveinfo sb home dominikh prj src example com foo go pcdata home dominikh prj src example com foo go movq ax cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go movq ax dx home dominikh prj src example com foo go shlq dx home dominikh prj src example com foo go orq dx cx home dominikh prj src example com foo go movq ax dx home dominikh prj src example com foo go shlq dx home dominikh prj src example com foo go orq cx dx home dominikh prj src example com foo go movq ax cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq dx cx home dominikh prj src example com foo go movq ax dx home dominikh prj src example com foo go shlq dx home dominikh prj src example com foo go orq cx dx home dominikh prj src example com foo go movq ax cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq dx cx home dominikh prj src example com foo go movq ax dx home dominikh prj src example com foo go shlq dx home dominikh prj src example com foo go orq cx dx home dominikh prj src example com foo go movq ax cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq dx cx home dominikh prj src example com foo go movq ax dx home dominikh prj src example com foo go shlq dx home dominikh prj src example com foo go orq cx dx home dominikh prj src example com foo go movq ax cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq dx cx home dominikh prj src example com foo go movq ax dx home dominikh prj src example com foo go shlq dx home dominikh prj src example com foo go orq cx dx home dominikh prj src example com foo go movq ax cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq dx cx home dominikh prj src example com foo go movq ax dx home dominikh prj src example com foo go shlq dx home dominikh prj src example com foo go orq cx dx home dominikh prj src example com foo go movq ax cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq dx cx home dominikh prj src example com foo go movq ax dx home dominikh prj src example com foo go shlq dx home dominikh prj src example com foo go orq cx dx home dominikh prj src example com foo go movq ax cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq dx cx home dominikh prj src example com foo go movq ax dx home dominikh prj src example com foo go shlq dx home dominikh prj src example com foo go orq cx dx home dominikh prj src example com foo go movq ax cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq dx cx home dominikh prj src example com foo go movq ax dx home dominikh prj src example com foo go shlq dx home dominikh prj src example com foo go orq cx dx home dominikh prj src example com foo go movq ax ax home dominikh prj src example com foo go shlq ax home dominikh prj src example com foo go orq dx ax home dominikh prj src example com foo go orq ax home dominikh prj src example com foo go ret what did you see instead command line arguments stext nosplit size args locals funcid align home dominikh prj src example com foo go text command line arguments sb nosplit abiinternal home dominikh prj src example com foo go pushq bp home dominikh prj src example com foo go movq sp bp home dominikh prj src example com foo go subq sp home dominikh prj src example com foo go funcdata gclocals· sb home dominikh prj src example com foo go funcdata gclocals· sb home dominikh prj src example com foo go funcdata command line arguments sb home dominikh prj src example com foo go funcdata command line arguments argliveinfo sb home dominikh prj src example com foo go pcdata home dominikh prj src example com foo go movq ax cx home dominikh prj src example com foo go movq ax dx home dominikh prj src example com foo go movq ax bx home dominikh prj src example com foo go movq ax si home dominikh prj src example com foo go movq ax di home dominikh prj src example com foo go movq ax home dominikh prj src example com foo go movq ax home dominikh prj src example com foo go movq ax home dominikh prj src example com foo go movq ax home dominikh prj src example com foo go movq ax home dominikh prj src example com foo go movq ax home dominikh prj src example com foo go movq ax home dominikh prj src example com foo go movq command line arguments autotmp sp home dominikh prj src example com foo go movq ax home dominikh prj src example com foo go movq command line arguments autotmp sp home dominikh prj src example com foo go movq ax home dominikh prj src example com foo go movq command line arguments autotmp sp home dominikh prj src example com foo go movq ax home dominikh prj src example com foo go movq command line arguments autotmp sp home dominikh prj src example com foo go movq ax home dominikh prj src example com foo go movq command line arguments autotmp sp home dominikh prj src example com foo go movq ax home dominikh prj src example com foo go movq command line arguments autotmp sp home dominikh prj src example com foo go movq ax home dominikh prj src example com foo go movq command line arguments autotmp sp home dominikh prj src example com foo go movq ax home dominikh prj src example com foo go movq ax ax home dominikh prj src example com foo go shlq ax home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq cx ax home dominikh prj src example com foo go shlq dx home dominikh prj src example com foo go orq dx ax home dominikh prj src example com foo go shlq bx home dominikh prj src example com foo go orq bx ax home dominikh prj src example com foo go shlq si home dominikh prj src example com foo go orq si ax home dominikh prj src example com foo go shlq di home dominikh prj src example com foo go orq di ax home dominikh prj src example com foo go shlq home dominikh prj src example com foo go orq ax home dominikh prj src example com foo go shlq home dominikh prj src example com foo go orq ax home dominikh prj src example com foo go shlq home dominikh prj src example com foo go orq ax home dominikh prj src example com foo go shlq home dominikh prj src example com foo go orq ax home dominikh prj src example com foo go shlq home dominikh prj src example com foo go orq ax home dominikh prj src example com foo go shlq home dominikh prj src example com foo go orq ax home dominikh prj src example com foo go movq command line arguments autotmp sp cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq cx ax home dominikh prj src example com foo go movq command line arguments autotmp sp cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq cx ax home dominikh prj src example com foo go movq command line arguments autotmp sp cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq cx ax home dominikh prj src example com foo go movq command line arguments autotmp sp cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq cx ax home dominikh prj src example com foo go movq command line arguments autotmp sp cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq cx ax home dominikh prj src example com foo go movq command line arguments autotmp sp cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq cx ax home dominikh prj src example com foo go movq command line arguments autotmp sp cx home dominikh prj src example com foo go shlq cx home dominikh prj src example com foo go orq cx ax home dominikh prj src example com foo go shlq home dominikh prj src example com foo go orq ax home dominikh prj src example com foo go orq ax home dominikh prj src example com foo go addq sp home dominikh prj src example com foo go popq bp home dominikh prj src example com foo go ret go seems to be loading all of the values up front only to spill some of them to the stack this seems strictly worse than the old output cc prattmic ,0 +313243,23464649324.0,IssuesEvent,2022-08-16 15:41:46,golang/go,https://api.github.com/repos/golang/go,closed,go install OR docs inconsistent to install multiple versions,Documentation,"### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.15.15 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/user/.cache/go-build"" +GOENV=""/home/user/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/user/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/user/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/opt/go/1.18"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/opt/go/1.18/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build482777503=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.15.15 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/user/.cache/go-build"" +GOENV=""/home/user/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/user/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/user/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/opt/go/1.18"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/opt/go/1.18/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build482777503=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.12.1 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/cuonglm/.cache/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/cuonglm/go"" +GOPROXY="""" +GORACE="""" +GOROOT=""/usr/local/stow/go"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/stow/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/cuonglm/sources/go/src/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build303772017=/tmp/go-build -gno-record-gcc-switches"" + +
+$ go version +go version go1.12.1 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/cuonglm/.cache/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/cuonglm/go"" +GOPROXY="""" +GORACE="""" +GOROOT=""/usr/local/stow/go"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/stow/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/cuonglm/sources/go/src/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build303772017=/tmp/go-build -gno-record-gcc-switches"" + +
Before filing a bug, please check whether it has been fixed since the +latest release. Search the issue tracker and check that you're running the +latest version of Go: + +Run "go version" and compare against +http://golang.org/doc/devel/release.html If a newer version of Go exists, +install it and retry what you did to reproduce the problem. + +Thanks. + +What does 'go version' print? + +What steps reproduce the problem? +If possible, include a link to a program on play.golang.org. + +1. +2. +3. + +What happened? + +What should have happened instead? + +Please provide any additional information below.",1.0,"database/sql: Document that prepared statements must be Close()' -
Before filing a bug, please check whether it has been fixed since the +latest release. Search the issue tracker and check that you're running the +latest version of Go: + +Run "go version" and compare against +http://golang.org/doc/devel/release.html If a newer version of Go exists, +install it and retry what you did to reproduce the problem. + +Thanks. + +What does 'go version' print? + +What steps reproduce the problem? +If possible, include a link to a program on play.golang.org. + +1. +2. +3. + +What happened? + +What should have happened instead? + +Please provide any additional information below.",1,database sql document that prepared statements must be close before filing a bug please check whether it has been fixed since the latest release search the issue tracker and check that you re running the latest version of go run quot go version quot and compare against a href if a newer version of go exists install it and retry what you did to reproduce the problem thanks what does go version print what steps reproduce the problem if possible include a link to a program on play golang org what happened what should have happened instead please provide any additional information below ,1 +4589,4467319806.0,IssuesEvent,2016-08-25 03:51:02,golang/go,https://api.github.com/repos/golang/go,closed,"cmd/compile: recognize and optimize ""in range"" booleans",Performance,"```go +package p + +func inrange(x int) bool { + return 5 <= x && x < 10 +} + +func inrange2(x int) bool { + return uint(x-5) < 5 +} +``` + +These two functions are equivalent, but the second is more efficient (it trades a subtraction for a compare-and-branch). We do this already for index-in-bounds checks. We should generally recognize integer-in-range patterns and convert them. + +We should probably do this in the SSA backend, since it'll be more general and powerful there than a limited front-end rewrite like rotation recognition. (I'm open to being convinced otherwise, though.) + +This will be helpful for #15780. It'll also help a bit with a hot line in scanobject (`arena_start <= obj && obj < arena_used`). + +/cc @brtzsnr @randall77 +",True,"cmd/compile: recognize and optimize ""in range"" booleans - ```go +package p + +func inrange(x int) bool { + return 5 <= x && x < 10 +} + +func inrange2(x int) bool { + return uint(x-5) < 5 +} +``` + +These two functions are equivalent, but the second is more efficient (it trades a subtraction for a compare-and-branch). We do this already for index-in-bounds checks. We should generally recognize integer-in-range patterns and convert them. + +We should probably do this in the SSA backend, since it'll be more general and powerful there than a limited front-end rewrite like rotation recognition. (I'm open to being convinced otherwise, though.) + +This will be helpful for #15780. It'll also help a bit with a hot line in scanobject (`arena_start <= obj && obj < arena_used`). + +/cc @brtzsnr @randall77 +",0,cmd compile recognize and optimize in range booleans go package p func inrange x int bool return x x func x int bool return uint x these two functions are equivalent but the second is more efficient it trades a subtraction for a compare and branch we do this already for index in bounds checks we should generally recognize integer in range patterns and convert them we should probably do this in the ssa backend since it ll be more general and powerful there than a limited front end rewrite like rotation recognition i m open to being convinced otherwise though this will be helpful for it ll also help a bit with a hot line in scanobject arena start obj obj arena used cc brtzsnr ,0 +15771,6037439856.0,IssuesEvent,2017-06-09 18:40:53,golang/go,https://api.github.com/repos/golang/go,closed,x/build: trybot's benchmark work doesn't chdir to package dir?,Builders HelpWanted NeedsFix,"I just say this trybot failure: + +https://storage.googleapis.com/go-build-log/f57a1818/linux-amd64_f9af06de.log + +... during benchmarking. + +I suspect that the benchmark code isn't setting the working directory appropriately. + +/cc @quentinmit ",1.0,"x/build: trybot's benchmark work doesn't chdir to package dir? - I just say this trybot failure: + +https://storage.googleapis.com/go-build-log/f57a1818/linux-amd64_f9af06de.log + +... during benchmarking. + +I suspect that the benchmark code isn't setting the working directory appropriately. + +/cc @quentinmit ",0,x build trybot s benchmark work doesn t chdir to package dir i just say this trybot failure during benchmarking i suspect that the benchmark code isn t setting the working directory appropriately cc quentinmit ,0 +79219,10114077046.0,IssuesEvent,2019-07-30 18:18:08,golang/go,https://api.github.com/repos/golang/go,closed,wiki: PerfDashboard links broken,Documentation NeedsFix,"### Wiki link + +https://github.com/golang/go/wiki/PerfDashboard + +### Which broken links + +* [in detail](https://build.golang.org/perfdetail?commit=fb3d6c1631c3f3141f33a01afb4c0a23ef0ea2cf&commit0=82f48826c6c79a3d5697d5e06cac8451f3dc3c7f&kind=builder&builder=linux-amd64-perf&benchmark=http) +* [perf detail](https://build.golang.org/perfdetail?commit=fb3d6c1631c3f3141f33a01afb4c0a23ef0ea2cf&commit0=82f48826c6c79a3d5697d5e06cac8451f3dc3c7f&kind=builder&builder=linux-amd64-perf&benchmark=http) + +### Using the perf dashboard + +When I click to the perf dashboard on https://build.golang.org/perf?page=6, I see many empty HTML rows and links that go to the code review. I am unable to find performance differences. It appears the perf dashboard may not be working as intended.",1.0,"wiki: PerfDashboard links broken - ### Wiki link + +https://github.com/golang/go/wiki/PerfDashboard + +### Which broken links + +* [in detail](https://build.golang.org/perfdetail?commit=fb3d6c1631c3f3141f33a01afb4c0a23ef0ea2cf&commit0=82f48826c6c79a3d5697d5e06cac8451f3dc3c7f&kind=builder&builder=linux-amd64-perf&benchmark=http) +* [perf detail](https://build.golang.org/perfdetail?commit=fb3d6c1631c3f3141f33a01afb4c0a23ef0ea2cf&commit0=82f48826c6c79a3d5697d5e06cac8451f3dc3c7f&kind=builder&builder=linux-amd64-perf&benchmark=http) + +### Using the perf dashboard + +When I click to the perf dashboard on https://build.golang.org/perf?page=6, I see many empty HTML rows and links that go to the code review. I am unable to find performance differences. It appears the perf dashboard may not be working as intended.",1,wiki perfdashboard links broken wiki link which broken links using the perf dashboard when i click to the perf dashboard on i see many empty html rows and links that go to the code review i am unable to find performance differences it appears the perf dashboard may not be working as intended ,1 +36305,6524965302.0,IssuesEvent,2017-08-29 14:26:27,golang/go,https://api.github.com/repos/golang/go,closed,spec: similar sounding nomenclature is confusing,Documentation,"
In the spec we use the following phrases: + +1) integer value +2) value of integer type +3) value of type int (or int8, int16, etc) +4) representable as a value of type int (or int8, int16, etc) + +They are very similar in English but mean different things in the spec: + +1) -> a (typed or untyped) constant value that is integer (1, 2.0, -4.0 + 0i) +2) -> a typed value that has one of the signed/unsigned integer types (byte, int, +uint8, etc.) +3) -> a value of a concrete type int, int8, etc. +4) -> a value that can be represented w/o loss of accuracy as a value of a specific +type + +We should clean this up, and/or introduce a section explaining the nomenclature. As is, +the English differences are small, but the spec implications are large.+",1.0,"spec: similar sounding nomenclature is confusing -
In the spec we use the following phrases: + +1) integer value +2) value of integer type +3) value of type int (or int8, int16, etc) +4) representable as a value of type int (or int8, int16, etc) + +They are very similar in English but mean different things in the spec: + +1) -> a (typed or untyped) constant value that is integer (1, 2.0, -4.0 + 0i) +2) -> a typed value that has one of the signed/unsigned integer types (byte, int, +uint8, etc.) +3) -> a value of a concrete type int, int8, etc. +4) -> a value that can be represented w/o loss of accuracy as a value of a specific +type + +We should clean this up, and/or introduce a section explaining the nomenclature. As is, +the English differences are small, but the spec implications are large.+",1,spec similar sounding nomenclature is confusing in the spec we use the following phrases integer value value of integer type value of type int or etc representable as a value of type int or etc they are very similar in english but mean different things in the spec gt a typed or untyped constant value that is integer gt a typed value that has one of the signed unsigned integer types byte int etc gt a value of a concrete type int etc gt a value that can be represented w o loss of accuracy as a value of a specific type we should clean this up and or introduce a section explaining the nomenclature as is the english differences are small but the spec implications are large ,1 +8156,6437818266.0,IssuesEvent,2017-08-11 00:52:37,golang/go,https://api.github.com/repos/golang/go,opened,cmd/compile: improve codegen for nested if statements,Performance,"As observed in CL 54651, these two semantically equivalent bits of code do not always compile equivalently: + +```go +if a { + if b { + // ... + } +} +``` + +```go +if a && b { + // ... +} +``` + +This issue is to investigate why, and if the latter is systematically better, consider improving the former. Note that 'if a && b' gets special handling at Node -> SSA time; phiopt.go does some further related cleanup, but perhaps not enough. + +cc @randall77 ",True,"cmd/compile: improve codegen for nested if statements - As observed in CL 54651, these two semantically equivalent bits of code do not always compile equivalently: + +```go +if a { + if b { + // ... + } +} +``` + +```go +if a && b { + // ... +} +``` + +This issue is to investigate why, and if the latter is systematically better, consider improving the former. Note that 'if a && b' gets special handling at Node -> SSA time; phiopt.go does some further related cleanup, but perhaps not enough. + +cc @randall77 ",0,cmd compile improve codegen for nested if statements as observed in cl these two semantically equivalent bits of code do not always compile equivalently go if a if b go if a b this issue is to investigate why and if the latter is systematically better consider improving the former note that if a b gets special handling at node ssa time phiopt go does some further related cleanup but perhaps not enough cc ,0 +35613,6485394162.0,IssuesEvent,2017-08-19 09:51:17,golang/go,https://api.github.com/repos/golang/go,opened,doc: Install from source doc at golang.org/doc inconsistent with install output,Documentation,"### What version of Go are you using (`go version`)? +go version go1.8.3 darwin/amd64 + +### Does this issue reproduce with the latest release? +Yes. + +### What operating system and processor architecture are you using (`go env`)? +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" + +### What did you do? +Installed Go from source after a `git clone` (in addition to a system Go). +```bash +$ cd ~/dev/go/src +$ ./make.bash +``` + +### What did you expect to see? +The docs at https://golang.org/doc/install/source#install says: + +> If all goes well, it will finish by printing output like: + +``` +ALL TESTS PASSED + +--- +Installed Go for linux/amd64 in /home/you/go. +Installed commands in /home/you/go/bin. +*** You need to add /home/you/go/bin to your $PATH. *** +``` +### What did you see instead? +It's really minor, but after a source install I don't see the `*** You need to add /home/you/go/bin to your $PATH. ***` line. Either there is a bug printing the line or the doc is outdated? I was making some standard library changes and building the source, but using my system go `/usr/local/bin/go` to test changes instead of the newly-built binary and wondering why the changes weren't applied :) The line helps to avoid this sort of beginner mistake, especially when you have multiple Go versions installed. + +Thanks! +",1.0,"doc: Install from source doc at golang.org/doc inconsistent with install output - ### What version of Go are you using (`go version`)? +go version go1.8.3 darwin/amd64 + +### Does this issue reproduce with the latest release? +Yes. + +### What operating system and processor architecture are you using (`go env`)? +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" + +### What did you do? +Installed Go from source after a `git clone` (in addition to a system Go). +```bash +$ cd ~/dev/go/src +$ ./make.bash +``` + +### What did you expect to see? +The docs at https://golang.org/doc/install/source#install says: + +> If all goes well, it will finish by printing output like: + +``` +ALL TESTS PASSED + +--- +Installed Go for linux/amd64 in /home/you/go. +Installed commands in /home/you/go/bin. +*** You need to add /home/you/go/bin to your $PATH. *** +``` +### What did you see instead? +It's really minor, but after a source install I don't see the `*** You need to add /home/you/go/bin to your $PATH. ***` line. Either there is a bug printing the line or the doc is outdated? I was making some standard library changes and building the source, but using my system go `/usr/local/bin/go` to test changes instead of the newly-built binary and wondering why the changes weren't applied :) The line helps to avoid this sort of beginner mistake, especially when you have multiple Go versions installed. + +Thanks! +",1,doc install from source doc at golang org doc inconsistent with install output what version of go are you using go version go version darwin does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env gohostarch gohostos darwin goos darwin what did you do installed go from source after a git clone in addition to a system go bash cd dev go src make bash what did you expect to see the docs at says if all goes well it will finish by printing output like all tests passed installed go for linux in home you go installed commands in home you go bin you need to add home you go bin to your path what did you see instead it s really minor but after a source install i don t see the you need to add home you go bin to your path line either there is a bug printing the line or the doc is outdated i was making some standard library changes and building the source but using my system go usr local bin go to test changes instead of the newly built binary and wondering why the changes weren t applied the line helps to avoid this sort of beginner mistake especially when you have multiple go versions installed thanks ,1 +302670,22837704247.0,IssuesEvent,2022-07-12 18:20:55,golang/go,https://api.github.com/repos/golang/go,closed,x/website: add a Go GC guide,Documentation NeedsFix release-blocker okay-after-beta1 website,As part of #48409 I proposed adding a new guide for the Go GC. This is an issue to track that work.,1.0,x/website: add a Go GC guide - As part of #48409 I proposed adding a new guide for the Go GC. This is an issue to track that work.,1,x website add a go gc guide as part of i proposed adding a new guide for the go gc this is an issue to track that work ,1 +65092,8787521746.0,IssuesEvent,2018-12-20 18:57:26,golang/go,https://api.github.com/repos/golang/go,closed,"os, os/signal: inconsistent documentation",Documentation NeedsFix OS-Windows,"I'm trying to define cleanup behavior in a Windows program, so I want to catch a signal, do some cleanup, and then exit the program. I don't have a Windows machine though so testing this is sort of tricky. + +The docs for `os.Interrupt` state: + +> The only signal values guaranteed to be present in the os package on all systems are Interrupt (send the process an interrupt) and Kill (force the process to exit). Interrupt is not implemented on Windows; using it with os.Process.Signal will return an error. + +However, the docs for `os/signal` state, under the Windows section: + +> On Windows a ^C (Control-C) or ^BREAK (Control-Break) normally cause the program to exit. If Notify is called for os.Interrupt, ^C or ^BREAK will cause os.Interrupt to be sent on the channel, and the program will not exit. + +I'm confused how Interrupt can be all of: + +- guaranteed to be present +- not implemented +- calling Notify() can cause it to be sent on the channel when a user hits ^BREAK + +Searching the `os` package source code for Interrupt seems to show it's only defined for unix/posix GOOS's and not for Windows. It might be nice to add a short doc to the `os` package explaining how it gets sent (if I am reading correctly, from `runtime/os_windows.go:ctrlhandler1` and `runtime/sigqueue.go:sigsend`).",1.0,"os, os/signal: inconsistent documentation - I'm trying to define cleanup behavior in a Windows program, so I want to catch a signal, do some cleanup, and then exit the program. I don't have a Windows machine though so testing this is sort of tricky. + +The docs for `os.Interrupt` state: + +> The only signal values guaranteed to be present in the os package on all systems are Interrupt (send the process an interrupt) and Kill (force the process to exit). Interrupt is not implemented on Windows; using it with os.Process.Signal will return an error. + +However, the docs for `os/signal` state, under the Windows section: + +> On Windows a ^C (Control-C) or ^BREAK (Control-Break) normally cause the program to exit. If Notify is called for os.Interrupt, ^C or ^BREAK will cause os.Interrupt to be sent on the channel, and the program will not exit. + +I'm confused how Interrupt can be all of: + +- guaranteed to be present +- not implemented +- calling Notify() can cause it to be sent on the channel when a user hits ^BREAK + +Searching the `os` package source code for Interrupt seems to show it's only defined for unix/posix GOOS's and not for Windows. It might be nice to add a short doc to the `os` package explaining how it gets sent (if I am reading correctly, from `runtime/os_windows.go:ctrlhandler1` and `runtime/sigqueue.go:sigsend`).",1,os os signal inconsistent documentation i m trying to define cleanup behavior in a windows program so i want to catch a signal do some cleanup and then exit the program i don t have a windows machine though so testing this is sort of tricky the docs for os interrupt state the only signal values guaranteed to be present in the os package on all systems are interrupt send the process an interrupt and kill force the process to exit interrupt is not implemented on windows using it with os process signal will return an error however the docs for os signal state under the windows section on windows a c control c or break control break normally cause the program to exit if notify is called for os interrupt c or break will cause os interrupt to be sent on the channel and the program will not exit i m confused how interrupt can be all of guaranteed to be present not implemented calling notify can cause it to be sent on the channel when a user hits break searching the os package source code for interrupt seems to show it s only defined for unix posix goos s and not for windows it might be nice to add a short doc to the os package explaining how it gets sent if i am reading correctly from runtime os windows go and runtime sigqueue go sigsend ,1 +4069,2814167590.0,IssuesEvent,2015-05-18 18:30:28,golang/go,https://api.github.com/repos/golang/go,closed,"spec: ""TO"" != ""T0"" in spec",Documentation,"In [this example](https://github.com/golang/go/blob/master/doc/go_spec.html#L2608): + +````go +t.x // (*t.TO).x +```` + +I think it is supposed to read: + +````go +t.x // (*t.T0).x +```` +",1.0,"spec: ""TO"" != ""T0"" in spec - In [this example](https://github.com/golang/go/blob/master/doc/go_spec.html#L2608): + +````go +t.x // (*t.TO).x +```` + +I think it is supposed to read: + +````go +t.x // (*t.T0).x +```` +",1,spec to in spec in go t x t to x i think it is supposed to read go t x t x ,1 +31246,5920374818.0,IssuesEvent,2017-05-22 20:07:23,golang/go,https://api.github.com/repos/golang/go,opened,x/tools/cmd/callgraph: usage text suggests invalid code,Documentation,"The [usage](https://github.com/golang/tools/blob/bf4b54dc687c73b6ef63de8b8abf0ad3951e3edc/cmd/callgraph/main.go#L117) text of `x/tools/cmd/callgraph` command mentions: + +> e.g. Caller.Pkg.Object.Path yields the import path of the enclosing package. +> Consult the go/ssa API documentation for details. + +> Examples: +> +> callgraph -format '{{.Caller.Pkg.Object.Path}} -> {{.Callee.Pkg.Object.Path}}' \ +> $GOROOT/src/net/http/triv.go | sort | uniq + +`Caller` is [`*ssa.Function`](https://godoc.org/golang.org/x/tools/go/ssa#Function). Its `Pkg` field is [`*ssa.Package`](https://godoc.org/golang.org/x/tools/go/ssa#Package). But `ssa.Package` struct doesn't contain either field or method named `Object`. + +So one gets the following error: + +``` +$ callgraph -format '{{.Caller.Pkg.Object.Path}} -> {{.Callee.Pkg.Object.Path}}' $(go env GOROOT)/src/net/http/triv.go | sort | uniq +callgraph: template: -format:1:9: executing ""-format"" at <.Caller.Pkg.Object.P...>: can't evaluate field Object in type *ssa.Package +``` + +I'm guessing that instead of `Caller.Pkg.Object.Path`, it should be `Caller.Pkg.Pkg.Path`: + +https://godoc.org/golang.org/x/tools/go/ssa#Package.Pkg + +That works as expected in my testing.",1.0,"x/tools/cmd/callgraph: usage text suggests invalid code - The [usage](https://github.com/golang/tools/blob/bf4b54dc687c73b6ef63de8b8abf0ad3951e3edc/cmd/callgraph/main.go#L117) text of `x/tools/cmd/callgraph` command mentions: + +> e.g. Caller.Pkg.Object.Path yields the import path of the enclosing package. +> Consult the go/ssa API documentation for details. + +> Examples: +> +> callgraph -format '{{.Caller.Pkg.Object.Path}} -> {{.Callee.Pkg.Object.Path}}' \ +> $GOROOT/src/net/http/triv.go | sort | uniq + +`Caller` is [`*ssa.Function`](https://godoc.org/golang.org/x/tools/go/ssa#Function). Its `Pkg` field is [`*ssa.Package`](https://godoc.org/golang.org/x/tools/go/ssa#Package). But `ssa.Package` struct doesn't contain either field or method named `Object`. + +So one gets the following error: + +``` +$ callgraph -format '{{.Caller.Pkg.Object.Path}} -> {{.Callee.Pkg.Object.Path}}' $(go env GOROOT)/src/net/http/triv.go | sort | uniq +callgraph: template: -format:1:9: executing ""-format"" at <.Caller.Pkg.Object.P...>: can't evaluate field Object in type *ssa.Package +``` + +I'm guessing that instead of `Caller.Pkg.Object.Path`, it should be `Caller.Pkg.Pkg.Path`: + +https://godoc.org/golang.org/x/tools/go/ssa#Package.Pkg + +That works as expected in my testing.",1,x tools cmd callgraph usage text suggests invalid code the text of x tools cmd callgraph command mentions e g caller pkg object path yields the import path of the enclosing package consult the go ssa api documentation for details examples callgraph format caller pkg object path callee pkg object path goroot src net http triv go sort uniq caller is its pkg field is but ssa package struct doesn t contain either field or method named object so one gets the following error callgraph format caller pkg object path callee pkg object path go env goroot src net http triv go sort uniq callgraph template format executing format at can t evaluate field object in type ssa package i m guessing that instead of caller pkg object path it should be caller pkg pkg path that works as expected in my testing ,1 +429278,30033557566.0,IssuesEvent,2023-06-27 11:14:00,golang/go,https://api.github.com/repos/golang/go,opened,doc: incomplete documentation for vanity import paths in combination with Go modules,Documentation,"https://go.dev/ref/mod#vcs documents the `` tag that needs to be hosted at the module path, with the concrete example of `golang.org/x/mod`. However, it doesn't document how the module path is determined, and which pages need to exist for that process. For example, a user can do `go get golang.org/x/mod/zip` in module mode. The documentation doesn't state whether `https://golang.org/x/mod/zip?go-get=1` needs to serve the meta tag or not. + +Some vanity paths, like `gioui.org` suggest that these subpages don't have to exist, and that `go get` walks up the path until it gets a successful response that specifies the module path. + +For example, `GOPROXY=direct go get gioui.org/widget/material` sends requests to the following URLs: + +``` +# get https://gioui.org/widget/material?go-get=1 +# get https://gioui.org/widget?go-get=1 +# get https://gioui.org/?go-get=1 +# get https://gioui.org/widget?go-get=1: 404 Not Found (0.198s) +# get https://gioui.org/widget/material?go-get=1: 404 Not Found (0.200s) +# get https://gioui.org/?go-get=1: 200 OK (0.201s) +``` + +Out of these, only `https://gioui.org/?go-get=1` responds with a meta tag. + +https://pkg.go.dev/cmd/go@go1.21rc2#hdr-Remote_import_paths also contains documentation on vanity import paths, but doesn't discuss module paths. It does suggest, however, that only one request — to the full import path — is being made: + +> If the import path is not a known code hosting site and also lacks a version control qualifier, the go tool attempts to fetch the import over https/http and looks for a tag in the document's HTML . + +This doesn't match the actual behavior of `go get` in module mode, but it does match `go get` in GOPATH mode. In fact, the previous example using gioui.org doesn't work in GOPATH mode, because gioui.org only serves the required meta tags for module paths, not for all possible import paths. + +``` +# get https://gioui.org/widget/material?go-get=1 +# get https://gioui.org/widget/material?go-get=1: 404 Not Found (0.192s) +package gioui.org/widget/material: unrecognized import path ""gioui.org/widget/material"": reading https://gioui.org/widget/material?go-get=1: 404 Not Found + server response: no such package +``` + +It would be nice to clarify, in the documentation, whether one can rely on the fact that `go get` walks up the import path until it finds the module path. Assuming that one can, it would also be interesting to explore whether it's acceptable to do so, as that only works for modules, not GOPATH.",1.0,"doc: incomplete documentation for vanity import paths in combination with Go modules - https://go.dev/ref/mod#vcs documents the `` tag that needs to be hosted at the module path, with the concrete example of `golang.org/x/mod`. However, it doesn't document how the module path is determined, and which pages need to exist for that process. For example, a user can do `go get golang.org/x/mod/zip` in module mode. The documentation doesn't state whether `https://golang.org/x/mod/zip?go-get=1` needs to serve the meta tag or not. + +Some vanity paths, like `gioui.org` suggest that these subpages don't have to exist, and that `go get` walks up the path until it gets a successful response that specifies the module path. + +For example, `GOPROXY=direct go get gioui.org/widget/material` sends requests to the following URLs: + +``` +# get https://gioui.org/widget/material?go-get=1 +# get https://gioui.org/widget?go-get=1 +# get https://gioui.org/?go-get=1 +# get https://gioui.org/widget?go-get=1: 404 Not Found (0.198s) +# get https://gioui.org/widget/material?go-get=1: 404 Not Found (0.200s) +# get https://gioui.org/?go-get=1: 200 OK (0.201s) +``` + +Out of these, only `https://gioui.org/?go-get=1` responds with a meta tag. + +https://pkg.go.dev/cmd/go@go1.21rc2#hdr-Remote_import_paths also contains documentation on vanity import paths, but doesn't discuss module paths. It does suggest, however, that only one request — to the full import path — is being made: + +> If the import path is not a known code hosting site and also lacks a version control qualifier, the go tool attempts to fetch the import over https/http and looks for a tag in the document's HTML . + +This doesn't match the actual behavior of `go get` in module mode, but it does match `go get` in GOPATH mode. In fact, the previous example using gioui.org doesn't work in GOPATH mode, because gioui.org only serves the required meta tags for module paths, not for all possible import paths. + +``` +# get https://gioui.org/widget/material?go-get=1 +# get https://gioui.org/widget/material?go-get=1: 404 Not Found (0.192s) +package gioui.org/widget/material: unrecognized import path ""gioui.org/widget/material"": reading https://gioui.org/widget/material?go-get=1: 404 Not Found + server response: no such package +``` + +It would be nice to clarify, in the documentation, whether one can rely on the fact that `go get` walks up the import path until it finds the module path. Assuming that one can, it would also be interesting to explore whether it's acceptable to do so, as that only works for modules, not GOPATH.",1,doc incomplete documentation for vanity import paths in combination with go modules documents the tag that needs to be hosted at the module path with the concrete example of golang org x mod however it doesn t document how the module path is determined and which pages need to exist for that process for example a user can do go get golang org x mod zip in module mode the documentation doesn t state whether needs to serve the meta tag or not some vanity paths like gioui org suggest that these subpages don t have to exist and that go get walks up the path until it gets a successful response that specifies the module path for example goproxy direct go get gioui org widget material sends requests to the following urls get get get get not found get not found get ok out of these only responds with a meta tag also contains documentation on vanity import paths but doesn t discuss module paths it does suggest however that only one request — to the full import path — is being made if the import path is not a known code hosting site and also lacks a version control qualifier the go tool attempts to fetch the import over https http and looks for a tag in the document s html this doesn t match the actual behavior of go get in module mode but it does match go get in gopath mode in fact the previous example using gioui org doesn t work in gopath mode because gioui org only serves the required meta tags for module paths not for all possible import paths get get not found package gioui org widget material unrecognized import path gioui org widget material reading not found server response no such package it would be nice to clarify in the documentation whether one can rely on the fact that go get walks up the import path until it finds the module path assuming that one can it would also be interesting to explore whether it s acceptable to do so as that only works for modules not gopath ,1 +9921,3337752428.0,IssuesEvent,2015-11-13 01:09:19,golang/go,https://api.github.com/repos/golang/go,closed,os: mention ErrInvalid for nil receivers,Documentation,"Methods on `*os.File` return `ErrInvalid` when the receiver is nil. This is, however, not documented anywhere. Usually this would be fine, if it weren't for a lot of documentation on methods saying `If there is an error, it will be of type *PathError`. + +Operating on nil `*os.File`s is a programming mistake and shouldn't be a common occurence, so it shouldn't complicate all of the documentation. However, a note in the package-level documentation could be an easy fix for a small inaccuracy in the rest of the documentation.",1.0,"os: mention ErrInvalid for nil receivers - Methods on `*os.File` return `ErrInvalid` when the receiver is nil. This is, however, not documented anywhere. Usually this would be fine, if it weren't for a lot of documentation on methods saying `If there is an error, it will be of type *PathError`. + +Operating on nil `*os.File`s is a programming mistake and shouldn't be a common occurence, so it shouldn't complicate all of the documentation. However, a note in the package-level documentation could be an easy fix for a small inaccuracy in the rest of the documentation.",1,os mention errinvalid for nil receivers methods on os file return errinvalid when the receiver is nil this is however not documented anywhere usually this would be fine if it weren t for a lot of documentation on methods saying if there is an error it will be of type patherror operating on nil os file s is a programming mistake and shouldn t be a common occurence so it shouldn t complicate all of the documentation however a note in the package level documentation could be an easy fix for a small inaccuracy in the rest of the documentation ,1 +54833,7926717247.0,IssuesEvent,2018-07-06 04:00:40,golang/go,https://api.github.com/repos/golang/go,closed,x/vgo: fix installation instructions on README,Documentation WaitingForInfo,"Please answer these questions before submitting your issue. Thanks! + + +### What version of Go are you using (`go version`)? +10.2 + +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? +OSX 17.4.0 Darwin Kernel Version 17.4.0: Sun Dec 17 09:19:54 PST 2017; root:xnu-4570.41.2~1/RELEASE_X86_64 x86_64 + +### What did you do? + +go get -u golang.org/x/vgo . + +If possible, provide a recipe for reproducing the error. +A complete runnable program is good. +A link on play.golang.org is best. + + +### What did you expect to see? + installation of vgo + +### What did you see instead? + +It hung + +### Solution + +change documentation to + +go get -u github.com/golang/vgo",1.0,"x/vgo: fix installation instructions on README - Please answer these questions before submitting your issue. Thanks! + + +### What version of Go are you using (`go version`)? +10.2 + +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? +OSX 17.4.0 Darwin Kernel Version 17.4.0: Sun Dec 17 09:19:54 PST 2017; root:xnu-4570.41.2~1/RELEASE_X86_64 x86_64 + +### What did you do? + +go get -u golang.org/x/vgo . + +If possible, provide a recipe for reproducing the error. +A complete runnable program is good. +A link on play.golang.org is best. + + +### What did you expect to see? + installation of vgo + +### What did you see instead? + +It hung + +### Solution + +change documentation to + +go get -u github.com/golang/vgo",1,x vgo fix installation instructions on readme please answer these questions before submitting your issue thanks what version of go are you using go version does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env osx darwin kernel version sun dec pst root xnu release what did you do go get u golang org x vgo if possible provide a recipe for reproducing the error a complete runnable program is good a link on play golang org is best what did you expect to see installation of vgo what did you see instead it hung solution change documentation to go get u github com golang vgo,1 +435607,30509701922.0,IssuesEvent,2023-07-18 19:46:38,golang/go,https://api.github.com/repos/golang/go,opened,x/tools/go/packages: document that different package loads lead to different type identities,Documentation NeedsFix,"When loading the same set of package twice, user-defined types are not guaranteed to have the same type identity. +This should be explicitly documented. + +See #61412 for an example where not understanding this property causes problems. + +cc: @findleyr @alandonovan ",1.0,"x/tools/go/packages: document that different package loads lead to different type identities - When loading the same set of package twice, user-defined types are not guaranteed to have the same type identity. +This should be explicitly documented. + +See #61412 for an example where not understanding this property causes problems. + +cc: @findleyr @alandonovan ",1,x tools go packages document that different package loads lead to different type identities when loading the same set of package twice user defined types are not guaranteed to have the same type identity this should be explicitly documented see for an example where not understanding this property causes problems cc findleyr alandonovan ,1 +65725,8837597166.0,IssuesEvent,2019-01-05 07:04:59,golang/go,https://api.github.com/repos/golang/go,opened,debug/gosym: mark LineTable.LineToPC and LineTable.PCToLine as deprecated,Documentation help wanted,"Both methods appear to be deprecated, according to their comments. We have a standard way of marking methods as deprecated; let's apply it here. + +This may be a good first issue for someone who wants to try out contributing. + +",1.0,"debug/gosym: mark LineTable.LineToPC and LineTable.PCToLine as deprecated - Both methods appear to be deprecated, according to their comments. We have a standard way of marking methods as deprecated; let's apply it here. + +This may be a good first issue for someone who wants to try out contributing. + +",1,debug gosym mark linetable linetopc and linetable pctoline as deprecated both methods appear to be deprecated according to their comments we have a standard way of marking methods as deprecated let s apply it here this may be a good first issue for someone who wants to try out contributing ,1 +9538,3292672628.0,IssuesEvent,2015-10-30 15:37:49,golang/go,https://api.github.com/repos/golang/go,opened,testing: document that T and B are safe for concurrent calls,Documentation,"We never documented that t.Errorf and friends are safe to call concurrently from different goroutines. + +This came up in review, with unnecessary locking around calling methods on t. +",1.0,"testing: document that T and B are safe for concurrent calls - We never documented that t.Errorf and friends are safe to call concurrently from different goroutines. + +This came up in review, with unnecessary locking around calling methods on t. +",1,testing document that t and b are safe for concurrent calls we never documented that t errorf and friends are safe to call concurrently from different goroutines this came up in review with unnecessary locking around calling methods on t ,1 +34246,6306261836.0,IssuesEvent,2017-07-21 20:31:35,golang/go,https://api.github.com/repos/golang/go,opened,unclear docs causing races in sql/driver implementations,Documentation,"### What version of Go are you using (`go version`)? + +`go version go1.8.3 darwin/amd64` + +### What did you do? + +Unlike `Conn` or `Stmt` there's no guidance on `Tx` indicating how the stdlib uses implementations. This seems to cause bugs in driver implementations, as a `Tx` is expected to handle concurrent calls from multiple goroutines unlike most of the other interfaces in the package. + +This came up as I was debugging [a panic inside of lib/pq](https://github.com/lib/pq/issues/614) and discovered it was a data race due to the authors not assuming that their `Tx` would have to deal with calls from multiple goroutines. Out of curiosity, I looked at `go-sql-driver/mysql` and the lack of a race there seems like a happy accident - the Context expiring occasionally causes [an internal error to bubble up](https://github.com/go-sql-driver/mysql/blob/a825be04c652d01442384e9dcdf2cdc3f1eda67f/packets.go#L441-L443), since the authors appear to aggressively check their invariants. + +I'm not sure whether this is a documentation problem or if there's something database/sql could do to make life easier for driver implementors. + +",1.0,"unclear docs causing races in sql/driver implementations - ### What version of Go are you using (`go version`)? + +`go version go1.8.3 darwin/amd64` + +### What did you do? + +Unlike `Conn` or `Stmt` there's no guidance on `Tx` indicating how the stdlib uses implementations. This seems to cause bugs in driver implementations, as a `Tx` is expected to handle concurrent calls from multiple goroutines unlike most of the other interfaces in the package. + +This came up as I was debugging [a panic inside of lib/pq](https://github.com/lib/pq/issues/614) and discovered it was a data race due to the authors not assuming that their `Tx` would have to deal with calls from multiple goroutines. Out of curiosity, I looked at `go-sql-driver/mysql` and the lack of a race there seems like a happy accident - the Context expiring occasionally causes [an internal error to bubble up](https://github.com/go-sql-driver/mysql/blob/a825be04c652d01442384e9dcdf2cdc3f1eda67f/packets.go#L441-L443), since the authors appear to aggressively check their invariants. + +I'm not sure whether this is a documentation problem or if there's something database/sql could do to make life easier for driver implementors. + +",1,unclear docs causing races in sql driver implementations what version of go are you using go version go version darwin what did you do unlike conn or stmt there s no guidance on tx indicating how the stdlib uses implementations this seems to cause bugs in driver implementations as a tx is expected to handle concurrent calls from multiple goroutines unlike most of the other interfaces in the package this came up as i was debugging and discovered it was a data race due to the authors not assuming that their tx would have to deal with calls from multiple goroutines out of curiosity i looked at go sql driver mysql and the lack of a race there seems like a happy accident the context expiring occasionally causes since the authors appear to aggressively check their invariants i m not sure whether this is a documentation problem or if there s something database sql could do to make life easier for driver implementors ,1 +307849,23219560099.0,IssuesEvent,2022-08-02 16:50:37,golang/go,https://api.github.com/repos/golang/go,opened,doc: write Go 1.20 release notes,Documentation NeedsFix release-blocker umbrella,"This is the tracking issue for writing the Go 1.20 Release Notes. + +When the Go 1.19 Release Notes are complete, this should be closed, and a similar issue should be made for the next release. Previous issues are #51400, #47694, #44513, etc.",1.0,"doc: write Go 1.20 release notes - This is the tracking issue for writing the Go 1.20 Release Notes. + +When the Go 1.19 Release Notes are complete, this should be closed, and a similar issue should be made for the next release. Previous issues are #51400, #47694, #44513, etc.",1,doc write go release notes this is the tracking issue for writing the go release notes when the go release notes are complete this should be closed and a similar issue should be made for the next release previous issues are etc ,1 +60541,8443339608.0,IssuesEvent,2018-10-18 15:21:18,golang/go,https://api.github.com/repos/golang/go,closed,syscall/js: unclear what the zero js.Value represents,Arch-Wasm Documentation NeedsDecision,"The godoc of [`js.Value`](https://godoc.org/syscall/js#Value) type currently says: + +> Value represents a JavaScript value. + +It's not easy to figure out what the zero value represents, even after reading the rest of `syscall/js` docs. + +This question came up when I had a function with the return types `(js.Value, error)` and I wanted to figure out what `js.Value` to return when an error happened. Typically, one returns the zero value, but it helps to understand what the zero value of that type represents. + +From looking at the implementation, I understand that the zero `js.Value` value currently represents the JavaScript number zero, is that right @neelance? I.e.: + +```Go +js.Value{} == js.ValueOf(int(0)) // true +js.Value{}.Type() == js.TypeNumber // true +``` + +It's also possible that what the zero `js.Value` value represents is considered an internal implementation detail and not meant to be a part of the public API. Hence, users shouldn't rely on it to have any well-defined and stable meaning. + +I think it would be helpful to document what the zero value represents, so people can answer this question by reading the documentation. Depending on the intention, perhaps one of these: + +```Go +// Value represents a JavaScript value. +// The zero value for a Value represents the JavaScript number 0. +type Value ... +``` + +(See https://godoc.org/math/big#Int documentation for a similar example.) + +Or (an improved version of): + +```Go +// Value represents a JavaScript value. +// +// The zero value for Value is undefined. It is not intended for direct use +// by clients, other than to signify that the value is not defined. +type Value ... +``` + +/cc @neelance",1.0,"syscall/js: unclear what the zero js.Value represents - The godoc of [`js.Value`](https://godoc.org/syscall/js#Value) type currently says: + +> Value represents a JavaScript value. + +It's not easy to figure out what the zero value represents, even after reading the rest of `syscall/js` docs. + +This question came up when I had a function with the return types `(js.Value, error)` and I wanted to figure out what `js.Value` to return when an error happened. Typically, one returns the zero value, but it helps to understand what the zero value of that type represents. + +From looking at the implementation, I understand that the zero `js.Value` value currently represents the JavaScript number zero, is that right @neelance? I.e.: + +```Go +js.Value{} == js.ValueOf(int(0)) // true +js.Value{}.Type() == js.TypeNumber // true +``` + +It's also possible that what the zero `js.Value` value represents is considered an internal implementation detail and not meant to be a part of the public API. Hence, users shouldn't rely on it to have any well-defined and stable meaning. + +I think it would be helpful to document what the zero value represents, so people can answer this question by reading the documentation. Depending on the intention, perhaps one of these: + +```Go +// Value represents a JavaScript value. +// The zero value for a Value represents the JavaScript number 0. +type Value ... +``` + +(See https://godoc.org/math/big#Int documentation for a similar example.) + +Or (an improved version of): + +```Go +// Value represents a JavaScript value. +// +// The zero value for Value is undefined. It is not intended for direct use +// by clients, other than to signify that the value is not defined. +type Value ... +``` + +/cc @neelance",1,syscall js unclear what the zero js value represents the godoc of type currently says value represents a javascript value it s not easy to figure out what the zero value represents even after reading the rest of syscall js docs this question came up when i had a function with the return types js value error and i wanted to figure out what js value to return when an error happened typically one returns the zero value but it helps to understand what the zero value of that type represents from looking at the implementation i understand that the zero js value value currently represents the javascript number zero is that right neelance i e go js value js valueof int true js value type js typenumber true it s also possible that what the zero js value value represents is considered an internal implementation detail and not meant to be a part of the public api hence users shouldn t rely on it to have any well defined and stable meaning i think it would be helpful to document what the zero value represents so people can answer this question by reading the documentation depending on the intention perhaps one of these go value represents a javascript value the zero value for a value represents the javascript number type value see documentation for a similar example or an improved version of go value represents a javascript value the zero value for value is undefined it is not intended for direct use by clients other than to signify that the value is not defined type value cc neelance,1 +19286,6705593849.0,IssuesEvent,2017-10-12 01:20:23,golang/go,https://api.github.com/repos/golang/go,closed,"x/build: build.golang.org should link to Gerrit, not GitHub commits",Builders,"The left column of build.golang.org has Git commit hashes, and it links to + + https://github.com/golang/go/commit/
go version go1.11 darwin/amd64
+
+
+### Does this issue reproduce with the latest release?
+Yes.
+
+### What operating system and processor architecture are you using (`go env`)?
+GOARCH=""amd64""
+GOBIN=""""
+GOCACHE=""/Users/rust/Library/Caches/go-build""
+GOEXE=""""
+GOFLAGS=""""
+GOHOSTARCH=""amd64""
+GOHOSTOS=""darwin""
+GOOS=""darwin""
+GOPATH=""/Users/rust/code""
+GOPROXY=""""
+GORACE=""""
+GOROOT=""/usr/local/go""
+GOTMPDIR=""""
+GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64""
+GCCGO=""gccgo""
+CC=""clang""
+CXX=""clang++""
+CGO_ENABLED=""1""
+GOMOD=""/Users/rust/code/modtest/b/go.mod""
+CGO_CFLAGS=""-g -O2""
+CGO_CPPFLAGS=""""
+CGO_CXXFLAGS=""-g -O2""
+CGO_FFLAGS=""-g -O2""
+CGO_LDFLAGS=""-g -O2""
+PKG_CONFIG=""pkg-config""
+GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/_d/8n_wrc4n32d1rgx80bn6hsl80000gn/T/go-build056371648=/tmp/go-build -gno-record-gcc-switches -fno-common""
+
+
+### What did you do?
+
+Created two modules a and b in the same directory, not on the GOPATH.
+
+Module a contains a.go, go.mod:
+~/code/modtest/a: cat a.go
+package a
+
+func Hello() string {
+ return ""Hello""
+}
+~/code/modtest/a: cat go.mod
+module a
+
+
+Module b contains b.go, go.mod:
+~/code/modtest/b: cat b.go
+package main
+
+import (
+ ""fmt""
+
+ ""a""
+)
+
+func main() {
+ fmt.Printf(""%s\n"", a.Hello())
+}
+~/code/modtest/b: cat go.mod
+module b
+
+require ../a v0.0.0
+
+
+What is the proper syntax for the line require ../a v0.0.0 in this particular case?
+The closest I found in the docs (go help modules, go help go.mod, go help mod) was from go help importpath:
+Relative import paths
+
+An import path beginning with ./ or ../ is called a relative path.
+The toolchain supports relative import paths as a shortcut in two ways.
+
+First, a relative path can be used as a shorthand on the command line.
+...
+
+Second, if you are compiling a Go program not in a work space,
+you can use a relative path in an import statement in that program
+to refer to nearby code also not in a work space.
+This makes it easy to experiment with small multipackage programs
+outside of the usual work spaces, but such programs cannot be
+installed with ""go install"" (there is no work space in which to install them),
+so they are rebuilt from scratch each time they are built.
+To avoid ambiguity, Go programs cannot use relative import paths
+within a work space.
+
+It is unclear to me if the second case is supposed to apply in this situation.
+
+### What did you expect to see?
+
+I expect this to compile and run similarly to how it works with the existing GOPATH.
+For example, copying the modules to the GOPATH gives the following:
+~/code/src: cd a
+~/code/src/a: go build
+~/code/src/a: cd ../b
+~/code/src/b: go build
+~/code/src/b: ./b
+Hello
+
+
+### What did you see instead?
+
+~/code/modtest: cd a
+~/code/modtest/a: go build
+~/code/modtest/a: cd ../b
+~/code/modtest/b: go build
+go: ../a@v0.0.0: unrecognized import path ""../a"" (https fetch: Get https://../a?go-get=1: dial tcp: lookup ..: no such host)
+go: error loading module requirements
+~/code/modtest/b:
+
+
+",1.0,"cmd/go: clarify go.mod documentation for trivial relative modules - ### What version of Go are you using (`go version`)?
+go version go1.11 darwin/amd64
+
+
+### Does this issue reproduce with the latest release?
+Yes.
+
+### What operating system and processor architecture are you using (`go env`)?
+GOARCH=""amd64""
+GOBIN=""""
+GOCACHE=""/Users/rust/Library/Caches/go-build""
+GOEXE=""""
+GOFLAGS=""""
+GOHOSTARCH=""amd64""
+GOHOSTOS=""darwin""
+GOOS=""darwin""
+GOPATH=""/Users/rust/code""
+GOPROXY=""""
+GORACE=""""
+GOROOT=""/usr/local/go""
+GOTMPDIR=""""
+GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64""
+GCCGO=""gccgo""
+CC=""clang""
+CXX=""clang++""
+CGO_ENABLED=""1""
+GOMOD=""/Users/rust/code/modtest/b/go.mod""
+CGO_CFLAGS=""-g -O2""
+CGO_CPPFLAGS=""""
+CGO_CXXFLAGS=""-g -O2""
+CGO_FFLAGS=""-g -O2""
+CGO_LDFLAGS=""-g -O2""
+PKG_CONFIG=""pkg-config""
+GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/_d/8n_wrc4n32d1rgx80bn6hsl80000gn/T/go-build056371648=/tmp/go-build -gno-record-gcc-switches -fno-common""
+
+
+### What did you do?
+
+Created two modules a and b in the same directory, not on the GOPATH.
+
+Module a contains a.go, go.mod:
+~/code/modtest/a: cat a.go
+package a
+
+func Hello() string {
+ return ""Hello""
+}
+~/code/modtest/a: cat go.mod
+module a
+
+
+Module b contains b.go, go.mod:
+~/code/modtest/b: cat b.go
+package main
+
+import (
+ ""fmt""
+
+ ""a""
+)
+
+func main() {
+ fmt.Printf(""%s\n"", a.Hello())
+}
+~/code/modtest/b: cat go.mod
+module b
+
+require ../a v0.0.0
+
+
+What is the proper syntax for the line require ../a v0.0.0 in this particular case?
+The closest I found in the docs (go help modules, go help go.mod, go help mod) was from go help importpath:
+Relative import paths
+
+An import path beginning with ./ or ../ is called a relative path.
+The toolchain supports relative import paths as a shortcut in two ways.
+
+First, a relative path can be used as a shorthand on the command line.
+...
+
+Second, if you are compiling a Go program not in a work space,
+you can use a relative path in an import statement in that program
+to refer to nearby code also not in a work space.
+This makes it easy to experiment with small multipackage programs
+outside of the usual work spaces, but such programs cannot be
+installed with ""go install"" (there is no work space in which to install them),
+so they are rebuilt from scratch each time they are built.
+To avoid ambiguity, Go programs cannot use relative import paths
+within a work space.
+
+It is unclear to me if the second case is supposed to apply in this situation.
+
+### What did you expect to see?
+
+I expect this to compile and run similarly to how it works with the existing GOPATH.
+For example, copying the modules to the GOPATH gives the following:
+~/code/src: cd a
+~/code/src/a: go build
+~/code/src/a: cd ../b
+~/code/src/b: go build
+~/code/src/b: ./b
+Hello
+
+
+### What did you see instead?
+
+~/code/modtest: cd a
+~/code/modtest/a: go build
+~/code/modtest/a: cd ../b
+~/code/modtest/b: go build
+go: ../a@v0.0.0: unrecognized import path ""../a"" (https fetch: Get https://../a?go-get=1: dial tcp: lookup ..: no such host)
+go: error loading module requirements
+~/code/modtest/b:
+
+
+",1,cmd go clarify go mod documentation for trivial relative modules what version of go are you using go version go version darwin does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env goarch gobin gocache users rust library caches go build goexe goflags gohostarch gohostos darwin goos darwin gopath users rust code goproxy gorace goroot usr local go gotmpdir gotooldir usr local go pkg tool darwin gccgo gccgo cc clang cxx clang cgo enabled gomod users rust code modtest b go mod cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map var folders d t go tmp go build gno record gcc switches fno common what did you do created two modules a and b in the same directory not on the gopath module a contains a go go mod code modtest a cat a go package a func hello string return hello code modtest a cat go mod module a module b contains b go go mod code modtest b cat b go package main import fmt a func main fmt printf s n a hello code modtest b cat go mod module b require a what is the proper syntax for the line require a in this particular case the closest i found in the docs go help modules go help go mod go help mod was from go help importpath relative import paths an import path beginning with or is called a relative path the toolchain supports relative import paths as a shortcut in two ways first a relative path can be used as a shorthand on the command line second if you are compiling a go program not in a work space you can use a relative path in an import statement in that program to refer to nearby code also not in a work space this makes it easy to experiment with small multipackage programs outside of the usual work spaces but such programs cannot be installed with go install there is no work space in which to install them so they are rebuilt from scratch each time they are built to avoid ambiguity go programs cannot use relative import paths within a work space it is unclear to me if the second case is supposed to apply in this situation what did you expect to see i expect this to compile and run similarly to how it works with the existing gopath for example copying the modules to the gopath gives the following code src cd a code src a go build code src a cd b code src b go build code src b b hello what did you see instead code modtest cd a code modtest a go build code modtest a cd b code modtest b go build go a unrecognized import path a https fetch get dial tcp lookup no such host go error loading module requirements code modtest b ,1
+94401,10821477545.0,IssuesEvent,2019-11-08 18:46:23,golang/go,https://api.github.com/repos/golang/go,closed,net: IPMask docs aren't great,Documentation NeedsFix help wanted,"The docs for `net.IPMask` say:
+
+https://golang.org/pkg/net/#IPMask
+
+> An IP mask is an IP address.
+>
+> `type IPMask []byte`
+
+That's, uh, pretty brief.
+
+We should say more because as-is my first reaction would be, ""Well, then why don't I juse use an IP address?""
+
+For Go 1.13 at least, but Go 1.12 would be fine too.
+
+/cc @ianlancetaylor @mikioh ",1.0,"net: IPMask docs aren't great - The docs for `net.IPMask` say:
+
+https://golang.org/pkg/net/#IPMask
+
+> An IP mask is an IP address.
+>
+> `type IPMask []byte`
+
+That's, uh, pretty brief.
+
+We should say more because as-is my first reaction would be, ""Well, then why don't I juse use an IP address?""
+
+For Go 1.13 at least, but Go 1.12 would be fine too.
+
+/cc @ianlancetaylor @mikioh ",1,net ipmask docs aren t great the docs for net ipmask say an ip mask is an ip address type ipmask byte that s uh pretty brief we should say more because as is my first reaction would be well then why don t i juse use an ip address for go at least but go would be fine too cc ianlancetaylor mikioh ,1
+11556,3505781112.0,IssuesEvent,2016-01-08 00:56:56,golang/go,https://api.github.com/repos/golang/go,closed,runtime: document missing GODEBUG settings,Documentation,"`src/runtime/extern.go` needs docs for some missing `GODEBUG` keys:
+
+* `h2debug` (from https://go-review.googlesource.com/#/c/17754/1/http2/http2.go@29)
+
+* `h2client=0` (from net/http) and upcoming(?) `h2server=0`?
+
+* `netdns` (documented elsewhere, but not in runtime/extern.go)
+
+/cc @ianlancetaylor ",1.0,"runtime: document missing GODEBUG settings - `src/runtime/extern.go` needs docs for some missing `GODEBUG` keys:
+
+* `h2debug` (from https://go-review.googlesource.com/#/c/17754/1/http2/http2.go@29)
+
+* `h2client=0` (from net/http) and upcoming(?) `h2server=0`?
+
+* `netdns` (documented elsewhere, but not in runtime/extern.go)
+
+/cc @ianlancetaylor ",1,runtime document missing godebug settings src runtime extern go needs docs for some missing godebug keys from from net http and upcoming netdns documented elsewhere but not in runtime extern go cc ianlancetaylor ,1
+12945,8752064186.0,IssuesEvent,2018-12-14 01:04:59,golang/go,https://api.github.com/repos/golang/go,closed,crypto/x509: CPU denial of service in chain validation,Security,"Package `crypto/x509` parses and validates X.509-encoded keys and certificates. It's supposed to handle certificate chains provided by an attacker with reasonable resource use.
+
+The `crypto/x509` package does not limit the amount of work performed for each chain verification, which might allow attackers to craft pathological inputs leading to a CPU denial of service. Go TLS servers accepting client certificates and TLS clients verifying certificates are affected.
+
+Thanks to Netflix for discovering and reporting this issue.
+
+This issue is CVE-2018-16875.",True,"crypto/x509: CPU denial of service in chain validation - Package `crypto/x509` parses and validates X.509-encoded keys and certificates. It's supposed to handle certificate chains provided by an attacker with reasonable resource use.
+
+The `crypto/x509` package does not limit the amount of work performed for each chain verification, which might allow attackers to craft pathological inputs leading to a CPU denial of service. Go TLS servers accepting client certificates and TLS clients verifying certificates are affected.
+
+Thanks to Netflix for discovering and reporting this issue.
+
+This issue is CVE-2018-16875.",0,crypto cpu denial of service in chain validation package crypto parses and validates x encoded keys and certificates it s supposed to handle certificate chains provided by an attacker with reasonable resource use the crypto package does not limit the amount of work performed for each chain verification which might allow attackers to craft pathological inputs leading to a cpu denial of service go tls servers accepting client certificates and tls clients verifying certificates are affected thanks to netflix for discovering and reporting this issue this issue is cve ,0
+42493,6986040990.0,IssuesEvent,2017-12-14 00:59:04,golang/go,https://api.github.com/repos/golang/go,closed,testing: clarity of -timeout flag,Documentation,"This is directly related to #20090, opening a new issue because I'm not sure whether closed issues are supposed to be reopened.
+
+The description of the `-timeout` flag has changed twice for Go 1.9. The first change (done by me) was intended to clarify that the timeout applies per package. The latest revision, referring to ""a test binary"", is certainly correct, but in my experience many gophers do not know that the tests from each package is executed as a separate test binary. This can be inferred from the help text, but it's not explicit and likely to be ambiguous to many.
+
+There may well be a better description than what I provided. I'd just like for the documentation to be clear without needing to understand exactly how test binaries are built and executed.
+
+Original Text:
+
+> -timeout t
+> If a test runs longer than t, panic.
+> The default is 10 minutes (10m).
+
+
+https://golang.org/cl/45816:
+
+> -timeout d
+> If the **cumulative test time for a package** runs longer than
+> duration d, panic. Timeout is disabled if set to 0.
+> The default is 10 minutes (10m).
+
+https://golang.org/cl/47571:
+
+> -timeout d
+> If **a test binary** runs longer than duration d, panic.
+> The default is 10 minutes (10m).
+
+Notes:
+* Emphasis added.
+* The ""Timeout is disabled if set to 0"" text can be ignored. It was a mistake on my part.",1.0,"testing: clarity of -timeout flag - This is directly related to #20090, opening a new issue because I'm not sure whether closed issues are supposed to be reopened.
+
+The description of the `-timeout` flag has changed twice for Go 1.9. The first change (done by me) was intended to clarify that the timeout applies per package. The latest revision, referring to ""a test binary"", is certainly correct, but in my experience many gophers do not know that the tests from each package is executed as a separate test binary. This can be inferred from the help text, but it's not explicit and likely to be ambiguous to many.
+
+There may well be a better description than what I provided. I'd just like for the documentation to be clear without needing to understand exactly how test binaries are built and executed.
+
+Original Text:
+
+> -timeout t
+> If a test runs longer than t, panic.
+> The default is 10 minutes (10m).
+
+
+https://golang.org/cl/45816:
+
+> -timeout d
+> If the **cumulative test time for a package** runs longer than
+> duration d, panic. Timeout is disabled if set to 0.
+> The default is 10 minutes (10m).
+
+https://golang.org/cl/47571:
+
+> -timeout d
+> If **a test binary** runs longer than duration d, panic.
+> The default is 10 minutes (10m).
+
+Notes:
+* Emphasis added.
+* The ""Timeout is disabled if set to 0"" text can be ignored. It was a mistake on my part.",1,testing clarity of timeout flag this is directly related to opening a new issue because i m not sure whether closed issues are supposed to be reopened the description of the timeout flag has changed twice for go the first change done by me was intended to clarify that the timeout applies per package the latest revision referring to a test binary is certainly correct but in my experience many gophers do not know that the tests from each package is executed as a separate test binary this can be inferred from the help text but it s not explicit and likely to be ambiguous to many there may well be a better description than what i provided i d just like for the documentation to be clear without needing to understand exactly how test binaries are built and executed original text timeout t if a test runs longer than t panic the default is minutes timeout d if the cumulative test time for a package runs longer than duration d panic timeout is disabled if set to the default is minutes timeout d if a test binary runs longer than duration d panic the default is minutes notes emphasis added the timeout is disabled if set to text can be ignored it was a mistake on my part ,1
+151864,12060733993.0,IssuesEvent,2020-04-15 21:51:34,golang/go,https://api.github.com/repos/golang/go,closed,x/mod/zip: frequent TestVCS failures with 'exit status 128',NeedsFix Testing modules,"```
+--- FAIL: TestVCS (0.00s)
+ --- FAIL: TestVCS/rsc.io_quote@v1.2.1 (31.77s)
+ zip_test.go:944: fetch -f --depth=1 origin refs/tags/v1.2.1:refs/tags/v1.2.1: exit status 128
+FAIL
+FAIL golang.org/x/mod/zip 37.493s
+```
+
+Some examples (a full list is hard to obtain due to #35515):
+* https://build.golang.org/log/ccfe7667f4a8078f0abb9f1690bb60b9c16b6667
+* https://build.golang.org/log/770a0e7b2932494a0088282e8c368b83d0b4b429
+* https://build.golang.org/log/8e4f13ddce054d013f61ca4107aff0aad92c2aee
+* https://build.golang.org/log/48b37e8f22936ba040107609992fb71851f7eaea
+* https://build.golang.org/log/409017b9f72dc739589429803dd6fcf3cb3fb533
+
+The specific repository that fails seems to vary from run to run. It's not clear to me whether this is a bug in `x/mod/zip`, a bug in `git`, a network issue on the `linux-amd64-longtest` builder, or unreliability in the upstream `git` servers.
+
+CC @jayconrod @matloob @andybons ",1.0,"x/mod/zip: frequent TestVCS failures with 'exit status 128' - ```
+--- FAIL: TestVCS (0.00s)
+ --- FAIL: TestVCS/rsc.io_quote@v1.2.1 (31.77s)
+ zip_test.go:944: fetch -f --depth=1 origin refs/tags/v1.2.1:refs/tags/v1.2.1: exit status 128
+FAIL
+FAIL golang.org/x/mod/zip 37.493s
+```
+
+Some examples (a full list is hard to obtain due to #35515):
+* https://build.golang.org/log/ccfe7667f4a8078f0abb9f1690bb60b9c16b6667
+* https://build.golang.org/log/770a0e7b2932494a0088282e8c368b83d0b4b429
+* https://build.golang.org/log/8e4f13ddce054d013f61ca4107aff0aad92c2aee
+* https://build.golang.org/log/48b37e8f22936ba040107609992fb71851f7eaea
+* https://build.golang.org/log/409017b9f72dc739589429803dd6fcf3cb3fb533
+
+The specific repository that fails seems to vary from run to run. It's not clear to me whether this is a bug in `x/mod/zip`, a bug in `git`, a network issue on the `linux-amd64-longtest` builder, or unreliability in the upstream `git` servers.
+
+CC @jayconrod @matloob @andybons ",0,x mod zip frequent testvcs failures with exit status fail testvcs fail testvcs rsc io quote zip test go fetch f depth origin refs tags refs tags exit status fail fail golang org x mod zip some examples a full list is hard to obtain due to the specific repository that fails seems to vary from run to run it s not clear to me whether this is a bug in x mod zip a bug in git a network issue on the linux longtest builder or unreliability in the upstream git servers cc jayconrod matloob andybons ,0
+22075,4771711930.0,IssuesEvent,2016-10-26 18:46:59,golang/go,https://api.github.com/repos/golang/go,opened,"net: no docs on ""0"" or empty name of transport service",Documentation,"#13610 and CL 17755 fixed the behavior without documentation. There is no documentation that describes what happens when the zero value of transport service in Dial, Listen, ListenPacket functions and Resolve{TCP,UDP,IP}Addr functions. I guess those two groups behave differently.",1.0,"net: no docs on ""0"" or empty name of transport service - #13610 and CL 17755 fixed the behavior without documentation. There is no documentation that describes what happens when the zero value of transport service in Dial, Listen, ListenPacket functions and Resolve{TCP,UDP,IP}Addr functions. I guess those two groups behave differently.",1,net no docs on or empty name of transport service and cl fixed the behavior without documentation there is no documentation that describes what happens when the zero value of transport service in dial listen listenpacket functions and resolve tcp udp ip addr functions i guess those two groups behave differently ,1
+6183,5309907817.0,IssuesEvent,2017-02-12 15:26:21,golang/go,https://api.github.com/repos/golang/go,closed,cmd/compile: optimize map access,Performance,"The following code is quite common in production systems:
+
+```go
+func getValueByKey(k string) Value {
+ mu.Lock()
+ v, ok := m[k]
+ if !ok {
+ v = newValue()
+ m[k] = v
+ }
+ mu.Unlock()
+ return v
+}
+```
+
+The following two optimizations may be applied by the compiler to the code:
+1) Calculate hash for `k` only once, since `k` doesn't change
+2) Move hash calculation outside the `mu` lock. This will improve scalability of the code on multi-CPU machines.
+
+cc @dr2chase , @josharian .",True,"cmd/compile: optimize map access - The following code is quite common in production systems:
+
+```go
+func getValueByKey(k string) Value {
+ mu.Lock()
+ v, ok := m[k]
+ if !ok {
+ v = newValue()
+ m[k] = v
+ }
+ mu.Unlock()
+ return v
+}
+```
+
+The following two optimizations may be applied by the compiler to the code:
+1) Calculate hash for `k` only once, since `k` doesn't change
+2) Move hash calculation outside the `mu` lock. This will improve scalability of the code on multi-CPU machines.
+
+cc @dr2chase , @josharian .",0,cmd compile optimize map access the following code is quite common in production systems go func getvaluebykey k string value mu lock v ok m if ok v newvalue m v mu unlock return v the following two optimizations may be applied by the compiler to the code calculate hash for k only once since k doesn t change move hash calculation outside the mu lock this will improve scalability of the code on multi cpu machines cc josharian ,0
+59684,14630118825.0,IssuesEvent,2020-12-23 17:04:58,golang/go,https://api.github.com/repos/golang/go,closed,x/build/env/openbsd: add OpenBSD 6.8 builder,Builders NeedsFix OS-OpenBSD new-builder,"OpenBSD 6.6 is out:
+
+https://www.openbsd.org/66.html
+
+Update our GCE builders. (rather, add a builder)
+
+Pending CL https://go-review.googlesource.com/c/build/+/176237 does most the work (but using pre-release 6.5 instead of 6.6).
+
+Just need to build it, test it (with x/build/cmd/debugnewvm) and configure it if it works.
+
+/cc @cagedmantis @dmitshur @bcmills ",2.0,"x/build/env/openbsd: add OpenBSD 6.8 builder - OpenBSD 6.6 is out:
+
+https://www.openbsd.org/66.html
+
+Update our GCE builders. (rather, add a builder)
+
+Pending CL https://go-review.googlesource.com/c/build/+/176237 does most the work (but using pre-release 6.5 instead of 6.6).
+
+Just need to build it, test it (with x/build/cmd/debugnewvm) and configure it if it works.
+
+/cc @cagedmantis @dmitshur @bcmills ",0,x build env openbsd add openbsd builder openbsd is out update our gce builders rather add a builder pending cl does most the work but using pre release instead of just need to build it test it with x build cmd debugnewvm and configure it if it works cc cagedmantis dmitshur bcmills ,0
+211587,16450014678.0,IssuesEvent,2021-05-21 03:24:00,golang/go,https://api.github.com/repos/golang/go,closed,io/fs: no examples for how to use it with the operating system,Documentation NeedsFix help wanted,"I needed to walk a directory, so I pulled up the `io/fs.WalkDir` docs, but there was nothing telling me how to get an `FS` instance for the operating system's filesystem. The only mention of `os.DirFS` is in `fs.Sub`, and I only found it because I had a hunch to search `os.`.",1.0,"io/fs: no examples for how to use it with the operating system - I needed to walk a directory, so I pulled up the `io/fs.WalkDir` docs, but there was nothing telling me how to get an `FS` instance for the operating system's filesystem. The only mention of `os.DirFS` is in `fs.Sub`, and I only found it because I had a hunch to search `os.`.",1,io fs no examples for how to use it with the operating system i needed to walk a directory so i pulled up the io fs walkdir docs but there was nothing telling me how to get an fs instance for the operating system s filesystem the only mention of os dirfs is in fs sub and i only found it because i had a hunch to search os ,1
+421490,28321443287.0,IssuesEvent,2023-04-11 01:46:24,golang/go,https://api.github.com/repos/golang/go,closed,"spec: typo ""are"" -> ""or"" in Core types",Documentation NeedsFix,"
+
+### What is the URL of the page with the issue?
+
+https://go.dev/ref/spec#Core_types
+
+### What is your user agent?
+
+
+
+Safari 16.5
+
+### Screenshot
+
+
+
++$ go version +# Doesn't matter. ++ +### Does this issue reproduce with the latest release? + + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +# Doesn't matter. +
+$ go version +# Doesn't matter. ++ +### Does this issue reproduce with the latest release? + + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +# Doesn't matter. +
+$ go version +go version go1.17.1 darwin/arm64 ++ +### Does this issue reproduce with the latest release? +yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE=""on"" +GOARCH=""arm64"" +GOBIN=""/bin"" +GOCACHE=""/Users/wang/Library/Caches/go-build"" +GOENV=""/Users/wang/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""arm64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/wang/go/pkg/mod"" +GONOPROXY=""gitlab.hexcloud.cn"" +GONOSUMDB=""gitlab.hexcloud.cn"" +GOOS=""darwin"" +GOPATH=""/Users/wang/go"" +GOPRIVATE=""gitlab.hexcloud.cn"" +GOPROXY=""https://goproxy.io,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_arm64"" +GOVCS="""" +GOVERSION=""go1.17.1"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/wang/open/source/go/src/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch arm64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/fc/5_f38pyn6k915kw7_vvfjhrc0000gn/T/go-build1773033347=/tmp/go-build -gno-record-gcc-switches -fno-common"" +GOROOT/bin/go version: go version go1.17.1 darwin/arm64 +GOROOT/bin/go tool compile -V: compile version go1.17.1 +uname -v: Darwin Kernel Version 20.6.0: Wed Jun 23 00:26:27 PDT 2021; root:xnu-7195.141.2~5/RELEASE_ARM64_T8101 +ProductName: macOS +ProductVersion: 11.5.1 +BuildVersion: 20G80 +lldb --version: lldb-1205.0.28.2 +Apple Swift version 5.4.2 (swiftlang-1205.0.28.2 clang-1205.0.19.57) +
+$ go version +go version go1.17.1 darwin/arm64 ++ +### Does this issue reproduce with the latest release? +yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE=""on"" +GOARCH=""arm64"" +GOBIN=""/bin"" +GOCACHE=""/Users/wang/Library/Caches/go-build"" +GOENV=""/Users/wang/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""arm64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/wang/go/pkg/mod"" +GONOPROXY=""gitlab.hexcloud.cn"" +GONOSUMDB=""gitlab.hexcloud.cn"" +GOOS=""darwin"" +GOPATH=""/Users/wang/go"" +GOPRIVATE=""gitlab.hexcloud.cn"" +GOPROXY=""https://goproxy.io,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_arm64"" +GOVCS="""" +GOVERSION=""go1.17.1"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/wang/open/source/go/src/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch arm64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/fc/5_f38pyn6k915kw7_vvfjhrc0000gn/T/go-build1773033347=/tmp/go-build -gno-record-gcc-switches -fno-common"" +GOROOT/bin/go version: go version go1.17.1 darwin/arm64 +GOROOT/bin/go tool compile -V: compile version go1.17.1 +uname -v: Darwin Kernel Version 20.6.0: Wed Jun 23 00:26:27 PDT 2021; root:xnu-7195.141.2~5/RELEASE_ARM64_T8101 +ProductName: macOS +ProductVersion: 11.5.1 +BuildVersion: 20G80 +lldb --version: lldb-1205.0.28.2 +Apple Swift version 5.4.2 (swiftlang-1205.0.28.2 clang-1205.0.19.57) +
The current json.RawMessage implementation defines MarshalJSON on a pointer receiver. +This causes unexpected behavior when marshalling with non-pointer-receiver objects. + +For example: +http://play.golang.org/p/Cf_6zpIKC0 + +Instead, MarshalJSON should be defined on a non-pointer receiver for json.RawMessage. +This will continue to work for existing code that uses pointer-receivers, but will +change behavior to work "correctly" on code that accidentally uses +non-pointer-receivers.",1.0,"encoding/json: RawMessage should marshal without pointer receiver -
The current json.RawMessage implementation defines MarshalJSON on a pointer receiver. +This causes unexpected behavior when marshalling with non-pointer-receiver objects. + +For example: +http://play.golang.org/p/Cf_6zpIKC0 + +Instead, MarshalJSON should be defined on a non-pointer receiver for json.RawMessage. +This will continue to work for existing code that uses pointer-receivers, but will +change behavior to work "correctly" on code that accidentally uses +non-pointer-receivers.",1,encoding json rawmessage should marshal without pointer receiver the current json rawmessage implementation defines marshaljson on a pointer receiver this causes unexpected behavior when marshalling with non pointer receiver objects for example a href instead marshaljson should be defined on a non pointer receiver for json rawmessage this will continue to work for existing code that uses pointer receivers but will change behavior to work quot correctly quot on code that accidentally uses non pointer receivers ,1 +54137,7875095915.0,IssuesEvent,2018-06-25 19:14:22,golang/go,https://api.github.com/repos/golang/go,closed,net/http: document and test behavior of ServeMux with ports,Documentation NeedsFix Testing help wanted,"Please answer these questions before submitting your issue. Thanks! + + +### What version of Go are you using (`go version`)? +1.9.2 and 1.10beta1 + +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? +``` +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/knorton/Library/Caches/go-build"" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/knorton/Documents/2018/01/underpants"" +GORACE="""" +GOROOT=""/Users/knorton/Documents/2018/01/underpants/go1.10"" +GOTMPDIR="""" +GOTOOLDIR=""/Users/knorton/Documents/2018/01/underpants/go1.10/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/9k/yc77pqm56jj79pp163xszgn00000gn/T/go-build934488457=/tmp/go-build -gno-record-gcc-switches -fno-common"" +``` + +### What did you do? + +Consider this Go program: + +``` +package main + +import ( + ""fmt"" + ""log"" + ""net/http"" +) + +func main() { + m := http.NewServeMux() + + m.HandleFunc(""localhost:8080/"", + func(w http.ResponseWriter, r *http.Request) { + fmt.Fprintln(w, ""locahost:8080"") + }) + + log.Panic(http.ListenAndServe("":8080"", m)) +} +``` +If you use Go 1.8.5: + 1. `go run example.go` + 2. Visit http://localhost:8080/ + 3. You will see the text ""localhost:8080"" display in the browser. + +If you use Go 1.10beta1 and Go 1.9.2: + 1. `go run example.go` + 2. Visit http://localhost:8080/ + 3. You will get a 404 NotFound. + +### What did you expect to see? +I expect that compiling the example in 1.9.2 should behave as it did in 1.8.5. + +More specifically, I would expect Go 1.9.2 to call the handler that I explicitly added for the host `localhost:8080`. + +### What did you see instead? +Instead, this program called with Go 1.9.2 returns a 404 instead of calling the handler that I added for the host localhost:8080. + +### More Details +This change seems to have been reviewed at: https://go-review.googlesource.com/c/go/+/38194 + +This change strips the port from the host only when it is trying to locate a handler. It does not strip the port when the user adds a handler for a host that includes a port number. As a result, trying to add handlers for hosts that include the port no longer works. + +To make matters worse, these change makes it hard to write http code for hosts with ports that works on both Go 1.9 and Go <1.9. + +In Go 1.9, the route has to be setup with `m.HandleFunc(""localhost"", ...)` +And in Go < 1.9, the route has to be setup with `m.HandleFunc(""localhost:8080"", ...)`. + +To make the code work on all versions of Go, the handler function needs to be registered for both ""localhost"" and ""localhost:8080"" + + + ",1.0,"net/http: document and test behavior of ServeMux with ports - Please answer these questions before submitting your issue. Thanks! + + +### What version of Go are you using (`go version`)? +1.9.2 and 1.10beta1 + +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? +``` +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/knorton/Library/Caches/go-build"" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/knorton/Documents/2018/01/underpants"" +GORACE="""" +GOROOT=""/Users/knorton/Documents/2018/01/underpants/go1.10"" +GOTMPDIR="""" +GOTOOLDIR=""/Users/knorton/Documents/2018/01/underpants/go1.10/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/9k/yc77pqm56jj79pp163xszgn00000gn/T/go-build934488457=/tmp/go-build -gno-record-gcc-switches -fno-common"" +``` + +### What did you do? + +Consider this Go program: + +``` +package main + +import ( + ""fmt"" + ""log"" + ""net/http"" +) + +func main() { + m := http.NewServeMux() + + m.HandleFunc(""localhost:8080/"", + func(w http.ResponseWriter, r *http.Request) { + fmt.Fprintln(w, ""locahost:8080"") + }) + + log.Panic(http.ListenAndServe("":8080"", m)) +} +``` +If you use Go 1.8.5: + 1. `go run example.go` + 2. Visit http://localhost:8080/ + 3. You will see the text ""localhost:8080"" display in the browser. + +If you use Go 1.10beta1 and Go 1.9.2: + 1. `go run example.go` + 2. Visit http://localhost:8080/ + 3. You will get a 404 NotFound. + +### What did you expect to see? +I expect that compiling the example in 1.9.2 should behave as it did in 1.8.5. + +More specifically, I would expect Go 1.9.2 to call the handler that I explicitly added for the host `localhost:8080`. + +### What did you see instead? +Instead, this program called with Go 1.9.2 returns a 404 instead of calling the handler that I added for the host localhost:8080. + +### More Details +This change seems to have been reviewed at: https://go-review.googlesource.com/c/go/+/38194 + +This change strips the port from the host only when it is trying to locate a handler. It does not strip the port when the user adds a handler for a host that includes a port number. As a result, trying to add handlers for hosts that include the port no longer works. + +To make matters worse, these change makes it hard to write http code for hosts with ports that works on both Go 1.9 and Go <1.9. + +In Go 1.9, the route has to be setup with `m.HandleFunc(""localhost"", ...)` +And in Go < 1.9, the route has to be setup with `m.HandleFunc(""localhost:8080"", ...)`. + +To make the code work on all versions of Go, the handler function needs to be registered for both ""localhost"" and ""localhost:8080"" + + + ",1,net http document and test behavior of servemux with ports please answer these questions before submitting your issue thanks what version of go are you using go version and does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env goarch gobin gocache users knorton library caches go build goexe gohostarch gohostos darwin goos darwin gopath users knorton documents underpants gorace goroot users knorton documents underpants gotmpdir gotooldir users knorton documents underpants pkg tool darwin gccgo gccgo cc clang cxx clang cgo enabled cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map var folders t go tmp go build gno record gcc switches fno common what did you do consider this go program package main import fmt log net http func main m http newservemux m handlefunc localhost func w http responsewriter r http request fmt fprintln w locahost log panic http listenandserve m if you use go go run example go visit you will see the text localhost display in the browser if you use go and go go run example go visit you will get a notfound what did you expect to see i expect that compiling the example in should behave as it did in more specifically i would expect go to call the handler that i explicitly added for the host localhost what did you see instead instead this program called with go returns a instead of calling the handler that i added for the host localhost more details this change seems to have been reviewed at this change strips the port from the host only when it is trying to locate a handler it does not strip the port when the user adds a handler for a host that includes a port number as a result trying to add handlers for hosts that include the port no longer works to make matters worse these change makes it hard to write http code for hosts with ports that works on both go and go in go the route has to be setup with m handlefunc localhost and in go the route has to be setup with m handlefunc localhost to make the code work on all versions of go the handler function needs to be registered for both localhost and localhost ,1 +98202,11047903658.0,IssuesEvent,2019-12-09 19:59:09,golang/go,https://api.github.com/repos/golang/go,closed,doc: release history webpage contains suboptimal links [1.13 backport],CherryPickApproved Documentation,"@dmitshur requested issue #35988 to be considered for backport to the next 1.13 minor release. + +> @gopherbot, could you please be so kind as to open two backport issues: one for Go 1.13 and another for Go 1.12. This is a documentation fix. +",1.0,"doc: release history webpage contains suboptimal links [1.13 backport] - @dmitshur requested issue #35988 to be considered for backport to the next 1.13 minor release. + +> @gopherbot, could you please be so kind as to open two backport issues: one for Go 1.13 and another for Go 1.12. This is a documentation fix. +",1,doc release history webpage contains suboptimal links dmitshur requested issue to be considered for backport to the next minor release gopherbot could you please be so kind as to open two backport issues one for go and another for go this is a documentation fix ,1 +135575,11011703792.0,IssuesEvent,2019-12-04 16:46:34,golang/go,https://api.github.com/repos/golang/go,closed,runtime: apparent deadlock in image/gif test on linux-ppc64-buildlet,NeedsInvestigation Testing,"There was a timeout in the `image/gif` test, but from the symptoms it looks more like a runtime bug to me: one of the threads is idle on `runtime.futex` via `runtime.mcall`, and the the other one says `goroutine running on other thread; stack unavailable`. + +That combination of symptoms is similar to #32327, although the path from `runtime.mcall` to `runtime.futex` differs. + +https://build.golang.org/log/e08f0037958f84cf1b1fe6b9f80c8208d332104c + +``` +SIGQUIT: quit +PC=0x6be3c m=0 sigcode=0 + +goroutine 0 [idle]: +runtime.futex(0x2ad150, 0x8000000002, 0x0, 0x0, 0x12000, 0x46d40, 0x46704, 0xc00035e780, 0x46d7c, 0xc0000384c8, ...) + /tmp/workdir-host-linux-ppc64-osu/go/src/runtime/sys_linux_ppc64x.s:472 +0x1c +runtime.futexsleep(0x2ad150, 0x200046708, 0xffffffffffffffff) + /tmp/workdir-host-linux-ppc64-osu/go/src/runtime/os_linux.go:44 +0x3c +runtime.lock(0x2ad150) + /tmp/workdir-host-linux-ppc64-osu/go/src/runtime/lock_futex.go:102 +0x1bc +runtime.exitsyscall0(0xc000076180) + /tmp/workdir-host-linux-ppc64-osu/go/src/runtime/proc.go:3119 +0x7c +runtime.mcall(0xc000076180) + /tmp/workdir-host-linux-ppc64-osu/go/src/runtime/asm_ppc64x.s:202 +0x58 + +goroutine 1 [chan receive, 3 minutes]: +testing.(*T).Run(0xc0000acd00, 0x18dbfc, 0x1b, 0x193748, 0x100000000000349) + /tmp/workdir-host-linux-ppc64-osu/go/src/testing/testing.go:961 +0x304 +testing.runTests.func1(0xc0000ac000) + /tmp/workdir-host-linux-ppc64-osu/go/src/testing/testing.go:1207 +0x78 +testing.tRunner(0xc0000ac000, 0xc000058d48) + /tmp/workdir-host-linux-ppc64-osu/go/src/testing/testing.go:909 +0xc8 +testing.runTests(0xc00008c080, 0x2a7dc0, 0x18, 0x18, 0x0) + /tmp/workdir-host-linux-ppc64-osu/go/src/testing/testing.go:1205 +0x27c +testing.(*M).Run(0xc0000a8000, 0x0) + /tmp/workdir-host-linux-ppc64-osu/go/src/testing/testing.go:1122 +0x158 +main.main() + _testmain.go:96 +0x130 + +goroutine 30 [running]: + goroutine running on other thread; stack unavailable +created by testing.(*T).Run + /tmp/workdir-host-linux-ppc64-osu/go/src/testing/testing.go:960 +0x2e8 + +r0 0xdd r1 0x3fffd047b228 +r2 0x8000000000 r3 0x2ad150 +r4 0x80 r5 0x2 +r6 0x0 r7 0x0 +r8 0x0 r9 0x0 +r10 0x0 r11 0x0 +r12 0x0 r13 0x0 +r14 0x1a0b0 r15 0xc000030e78 +r16 0x0 r17 0xc000025900 +r18 0x0 r19 0x1b4782 +r20 0xc000020010 r21 0x2ad840 +r22 0x0 r23 0x0 +r24 0x8 r25 0x3fff8b55a520 +r26 0x3fff8b55a578 r27 0x73 +r28 0x72 r29 0x1 +r30 0x2ad2a0 r31 0x19bbc +pc 0x6be3c ctr 0x0 +link 0x3a62c xer 0x0 +ccr 0x54400002 trap 0xc00 +*** Test killed with quit: ran too long (4m0s). +FAIL image/gif 240.002s +``` + +CC @laboger @aclements @mknyszek @randall77 ",1.0,"runtime: apparent deadlock in image/gif test on linux-ppc64-buildlet - There was a timeout in the `image/gif` test, but from the symptoms it looks more like a runtime bug to me: one of the threads is idle on `runtime.futex` via `runtime.mcall`, and the the other one says `goroutine running on other thread; stack unavailable`. + +That combination of symptoms is similar to #32327, although the path from `runtime.mcall` to `runtime.futex` differs. + +https://build.golang.org/log/e08f0037958f84cf1b1fe6b9f80c8208d332104c + +``` +SIGQUIT: quit +PC=0x6be3c m=0 sigcode=0 + +goroutine 0 [idle]: +runtime.futex(0x2ad150, 0x8000000002, 0x0, 0x0, 0x12000, 0x46d40, 0x46704, 0xc00035e780, 0x46d7c, 0xc0000384c8, ...) + /tmp/workdir-host-linux-ppc64-osu/go/src/runtime/sys_linux_ppc64x.s:472 +0x1c +runtime.futexsleep(0x2ad150, 0x200046708, 0xffffffffffffffff) + /tmp/workdir-host-linux-ppc64-osu/go/src/runtime/os_linux.go:44 +0x3c +runtime.lock(0x2ad150) + /tmp/workdir-host-linux-ppc64-osu/go/src/runtime/lock_futex.go:102 +0x1bc +runtime.exitsyscall0(0xc000076180) + /tmp/workdir-host-linux-ppc64-osu/go/src/runtime/proc.go:3119 +0x7c +runtime.mcall(0xc000076180) + /tmp/workdir-host-linux-ppc64-osu/go/src/runtime/asm_ppc64x.s:202 +0x58 + +goroutine 1 [chan receive, 3 minutes]: +testing.(*T).Run(0xc0000acd00, 0x18dbfc, 0x1b, 0x193748, 0x100000000000349) + /tmp/workdir-host-linux-ppc64-osu/go/src/testing/testing.go:961 +0x304 +testing.runTests.func1(0xc0000ac000) + /tmp/workdir-host-linux-ppc64-osu/go/src/testing/testing.go:1207 +0x78 +testing.tRunner(0xc0000ac000, 0xc000058d48) + /tmp/workdir-host-linux-ppc64-osu/go/src/testing/testing.go:909 +0xc8 +testing.runTests(0xc00008c080, 0x2a7dc0, 0x18, 0x18, 0x0) + /tmp/workdir-host-linux-ppc64-osu/go/src/testing/testing.go:1205 +0x27c +testing.(*M).Run(0xc0000a8000, 0x0) + /tmp/workdir-host-linux-ppc64-osu/go/src/testing/testing.go:1122 +0x158 +main.main() + _testmain.go:96 +0x130 + +goroutine 30 [running]: + goroutine running on other thread; stack unavailable +created by testing.(*T).Run + /tmp/workdir-host-linux-ppc64-osu/go/src/testing/testing.go:960 +0x2e8 + +r0 0xdd r1 0x3fffd047b228 +r2 0x8000000000 r3 0x2ad150 +r4 0x80 r5 0x2 +r6 0x0 r7 0x0 +r8 0x0 r9 0x0 +r10 0x0 r11 0x0 +r12 0x0 r13 0x0 +r14 0x1a0b0 r15 0xc000030e78 +r16 0x0 r17 0xc000025900 +r18 0x0 r19 0x1b4782 +r20 0xc000020010 r21 0x2ad840 +r22 0x0 r23 0x0 +r24 0x8 r25 0x3fff8b55a520 +r26 0x3fff8b55a578 r27 0x73 +r28 0x72 r29 0x1 +r30 0x2ad2a0 r31 0x19bbc +pc 0x6be3c ctr 0x0 +link 0x3a62c xer 0x0 +ccr 0x54400002 trap 0xc00 +*** Test killed with quit: ran too long (4m0s). +FAIL image/gif 240.002s +``` + +CC @laboger @aclements @mknyszek @randall77 ",0,runtime apparent deadlock in image gif test on linux buildlet there was a timeout in the image gif test but from the symptoms it looks more like a runtime bug to me one of the threads is idle on runtime futex via runtime mcall and the the other one says goroutine running on other thread stack unavailable that combination of symptoms is similar to although the path from runtime mcall to runtime futex differs sigquit quit pc m sigcode goroutine runtime futex tmp workdir host linux osu go src runtime sys linux s runtime futexsleep tmp workdir host linux osu go src runtime os linux go runtime lock tmp workdir host linux osu go src runtime lock futex go runtime tmp workdir host linux osu go src runtime proc go runtime mcall tmp workdir host linux osu go src runtime asm s goroutine testing t run tmp workdir host linux osu go src testing testing go testing runtests tmp workdir host linux osu go src testing testing go testing trunner tmp workdir host linux osu go src testing testing go testing runtests tmp workdir host linux osu go src testing testing go testing m run tmp workdir host linux osu go src testing testing go main main testmain go goroutine goroutine running on other thread stack unavailable created by testing t run tmp workdir host linux osu go src testing testing go pc ctr link xer ccr trap test killed with quit ran too long fail image gif cc laboger aclements mknyszek ,0 +69022,9239247735.0,IssuesEvent,2019-03-14 00:33:31,golang/go,https://api.github.com/repos/golang/go,closed,spec: apparent contradiction for passing of slice argument to variadic parameter,Documentation NeedsFix WaitingForInfo,"``` +Version of November 16, 2018 +``` + +Section [""Passing arguments to ... parameters""](https://golang.org/ref/spec#Passing_arguments_to_..._parameters) says: + +> If the final argument is assignable to a slice type []T, it may be passed unchanged as the value for a ...T parameter if the argument is followed by .... In this case no new slice is created. + +Notice the use of the word ""may"". This appears to contradict what I understand to be the case in practice (i.e. that it _will_ be passed unchanged, for reasons of efficiency) but also the example that follows: + +> ... who will have the same value as s with the same underlying array. + +Notice the use of the word ""will"". + +cc @griesemer + +FYI @mvdan @rogpeppe ",1.0,"spec: apparent contradiction for passing of slice argument to variadic parameter - ``` +Version of November 16, 2018 +``` + +Section [""Passing arguments to ... parameters""](https://golang.org/ref/spec#Passing_arguments_to_..._parameters) says: + +> If the final argument is assignable to a slice type []T, it may be passed unchanged as the value for a ...T parameter if the argument is followed by .... In this case no new slice is created. + +Notice the use of the word ""may"". This appears to contradict what I understand to be the case in practice (i.e. that it _will_ be passed unchanged, for reasons of efficiency) but also the example that follows: + +> ... who will have the same value as s with the same underlying array. + +Notice the use of the word ""will"". + +cc @griesemer + +FYI @mvdan @rogpeppe ",1,spec apparent contradiction for passing of slice argument to variadic parameter version of november section says if the final argument is assignable to a slice type t it may be passed unchanged as the value for a t parameter if the argument is followed by in this case no new slice is created notice the use of the word may this appears to contradict what i understand to be the case in practice i e that it will be passed unchanged for reasons of efficiency but also the example that follows who will have the same value as s with the same underlying array notice the use of the word will cc griesemer fyi mvdan rogpeppe ,1 +51981,6205858289.0,IssuesEvent,2017-07-06 17:04:59,golang/go,https://api.github.com/repos/golang/go,closed,runtime: TestRWMutex is flaky?,NeedsFix Testing,"Please answer these questions before submitting your issue. Thanks! + +#### What did you do? +If possible, provide a recipe for reproducing the error. +A complete runnable program is good. +A link on play.golang.org is best. + +```bash +for i in `seq 100`; do go test -v runtime -run ""TestRWMutex""; done +``` + +#### What did you expect to see? +PASS * 100 + +#### What did you see instead? +``` +=== RUN TestRWMutex +SIGQUIT: quit +PC=0x10625b6 m=2 sigcode=0 + +goroutine 0 [idle]: +runtime.usleep(0x8b00002710, 0x0, 0x68c71d5b2f, 0x45d964b800, 0x271000000000, 0x8bb25b57c4, 0x45d964b800, 0x3, 0x0, 0x68c71d5b2f, ...) + /Users/hiro/go/src/runtime/sys_darwin_amd64.s:323 +0x36 fp=0x700006055de0 sp=0x700006055dc0 pc=0x10625b6 +runtime.sysmon() + /Users/hiro/go/src/runtime/proc.go:3799 +0xa8 fp=0x700006055e68 sp=0x700006055de0 pc=0x1039a08 +runtime.mstart1() + /Users/hiro/go/src/runtime/proc.go:1172 +0x11e fp=0x700006055e90 sp=0x700006055e68 pc=0x103285e +runtime.mstart() + /Users/hiro/go/src/runtime/proc.go:1142 +0x64 fp=0x700006055ea8 sp=0x700006055e90 pc=0x1032734 + +goroutine 1 [chan receive]: +runtime.gopark(0x131a290, 0xc420076418, 0x1308f6e, 0xc, 0xc420051b17, 0x3) + /Users/hiro/go/src/runtime/proc.go:277 +0x12c fp=0xc420051ac8 sp=0xc420051a98 pc=0x102fa7c +runtime.goparkunlock(0xc420076418, 0x1308f6e, 0xc, 0xc4200e8017, 0x3) + /Users/hiro/go/src/runtime/proc.go:283 +0x5e fp=0xc420051b08 sp=0xc420051ac8 pc=0x102fb6e +runtime.chanrecv(0xc4200763c0, 0x0, 0xc420051b01, 0x10ebc14) + /Users/hiro/go/src/runtime/chan.go:506 +0x304 fp=0xc420051bb8 sp=0xc420051b08 pc=0x1005dc4 +runtime.chanrecv1(0xc4200763c0, 0x0) + /Users/hiro/go/src/runtime/chan.go:388 +0x2b fp=0xc420051be8 sp=0xc420051bb8 pc=0x1005a6b +testing.(*T).Run(0xc4200e2000, 0x130879c, 0xb, 0x131b2e0, 0x108f201) + /Users/hiro/go/src/testing/testing.go:801 +0x332 fp=0xc420051c98 sp=0xc420051be8 pc=0x10ebc32 +testing.runTests.func1(0xc4200e2000) + /Users/hiro/go/src/testing/testing.go:1053 +0x64 fp=0xc420051ce8 sp=0xc420051c98 pc=0x10efd04 +testing.tRunner(0xc4200e2000, 0xc420051d98) + /Users/hiro/go/src/testing/testing.go:754 +0xd0 fp=0xc420051d10 sp=0xc420051ce8 pc=0x10eb8a0 +testing.runTests(0xc42000c300, 0x1498000, 0xd7, 0xd7, 0x5f) + /Users/hiro/go/src/testing/testing.go:1051 +0x2d8 fp=0xc420051dc8 sp=0xc420051d10 pc=0x10ed688 +testing.(*M).Run(0xc420051f18, 0x12474b6) + /Users/hiro/go/src/testing/testing.go:932 +0x111 fp=0xc420051ec0 sp=0xc420051dc8 pc=0x10ec031 +runtime_test.TestMain(0xc420051f18) + /Users/hiro/go/src/runtime/crash_test.go:28 +0x2f fp=0xc420051f10 sp=0xc420051ec0 pc=0x1216c9f +main.main() + runtime/_test/_testmain.go:902 +0xdb fp=0xc420051f80 sp=0xc420051f10 pc=0x126701b +runtime.main() + /Users/hiro/go/src/runtime/proc.go:185 +0x20d fp=0xc420051fe0 sp=0xc420051f80 pc=0x102f5dd +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc420051fe8 sp=0xc420051fe0 pc=0x10612f1 + +goroutine 2 [force gc (idle)]: +runtime.gopark(0x131a290, 0x149a0c0, 0x130a49c, 0xf, 0x14, 0x1) + /Users/hiro/go/src/runtime/proc.go:277 +0x12c fp=0xc42002c768 sp=0xc42002c738 pc=0x102fa7c +runtime.goparkunlock(0x149a0c0, 0x130a49c, 0xf, 0xc420000114, 0x1) + /Users/hiro/go/src/runtime/proc.go:283 +0x5e fp=0xc42002c7a8 sp=0xc42002c768 pc=0x102fb6e +runtime.forcegchelper() + /Users/hiro/go/src/runtime/proc.go:235 +0xcc fp=0xc42002c7e0 sp=0xc42002c7a8 pc=0x102f89c +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42002c7e8 sp=0xc42002c7e0 pc=0x10612f1 +created by runtime.init.4 + /Users/hiro/go/src/runtime/proc.go:224 +0x35 + +goroutine 3 [GC sweep wait]: +runtime.gopark(0x131a290, 0x149a3c0, 0x130941f, 0xd, 0x1021014, 0x1) + /Users/hiro/go/src/runtime/proc.go:277 +0x12c fp=0xc42002cf60 sp=0xc42002cf30 pc=0x102fa7c +runtime.goparkunlock(0x149a3c0, 0x130941f, 0xd, 0x14, 0x1) + /Users/hiro/go/src/runtime/proc.go:283 +0x5e fp=0xc42002cfa0 sp=0xc42002cf60 pc=0x102fb6e +runtime.bgsweep(0xc420020070) + /Users/hiro/go/src/runtime/mgcsweep.go:52 +0xa3 fp=0xc42002cfd8 sp=0xc42002cfa0 pc=0x10210d3 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42002cfe0 sp=0xc42002cfd8 pc=0x10612f1 +created by runtime.gcenable + /Users/hiro/go/src/runtime/mgc.go:216 +0x58 + +goroutine 4 [finalizer wait]: +runtime.gopark(0x131a290, 0x14b9f10, 0x1309da5, 0xe, 0x14, 0x1) + /Users/hiro/go/src/runtime/proc.go:277 +0x12c fp=0xc42002d700 sp=0xc42002d6d0 pc=0x102fa7c +runtime.goparkunlock(0x14b9f10, 0x1309da5, 0xe, 0x14, 0x1) + /Users/hiro/go/src/runtime/proc.go:283 +0x5e fp=0xc42002d740 sp=0xc42002d700 pc=0x102fb6e +runtime.runfinq() + /Users/hiro/go/src/runtime/mfinal.go:175 +0xb8 fp=0xc42002d7e0 sp=0xc42002d740 pc=0x1017ed8 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42002d7e8 sp=0xc42002d7e0 pc=0x10612f1 +created by runtime.createfing + /Users/hiro/go/src/runtime/mfinal.go:156 +0x62 + +goroutine 5 [syscall]: +runtime.notetsleepg(0x14ba2c0, 0xffffffffffffffff, 0x0) + /Users/hiro/go/src/runtime/lock_sema.go:280 +0x4b fp=0xc42002df80 sp=0xc42002df40 pc=0x10119eb +os/signal.signal_recv(0x0) + /Users/hiro/go/src/runtime/sigqueue.go:131 +0xa7 fp=0xc42002dfa8 sp=0xc42002df80 pc=0x1045807 +os/signal.loop() + /Users/hiro/go/src/os/signal/signal_unix.go:22 +0x22 fp=0xc42002dfe0 sp=0xc42002dfa8 pc=0x10e4232 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42002dfe8 sp=0xc42002dfe0 pc=0x10612f1 +created by os/signal.init.0 + /Users/hiro/go/src/os/signal/signal_unix.go:28 +0x41 + +goroutine 6 [select, locked to thread]: +runtime.gopark(0x131a2d8, 0x0, 0x1306abf, 0x6, 0x18, 0x1) + /Users/hiro/go/src/runtime/proc.go:277 +0x12c fp=0xc42003aca0 sp=0xc42003ac70 pc=0x102fa7c +runtime.selectgo(0xc42003af50, 0xc420076180) + /Users/hiro/go/src/runtime/select.go:395 +0x1138 fp=0xc42003af18 sp=0xc42003aca0 pc=0x103fff8 +runtime.ensureSigM.func1() + /Users/hiro/go/src/runtime/signal_unix.go:511 +0x1fe fp=0xc42003afe0 sp=0xc42003af18 pc=0x105da9e +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42003afe8 sp=0xc42003afe0 pc=0x10612f1 +created by runtime.ensureSigM + /Users/hiro/go/src/runtime/signal_unix.go:494 +0xda + +goroutine 7 [chan receive]: +runtime.gopark(0x131a290, 0xc42005e358, 0x1308f6e, 0xc, 0xc420024117, 0x3) + /Users/hiro/go/src/runtime/proc.go:277 +0x12c fp=0xc42002ee80 sp=0xc42002ee50 pc=0x102fa7c +runtime.goparkunlock(0xc42005e358, 0x1308f6e, 0xc, 0x17, 0x3) + /Users/hiro/go/src/runtime/proc.go:283 +0x5e fp=0xc42002eec0 sp=0xc42002ee80 pc=0x102fb6e +runtime.chanrecv(0xc42005e300, 0x0, 0x1, 0x0) + /Users/hiro/go/src/runtime/chan.go:506 +0x304 fp=0xc42002ef70 sp=0xc42002eec0 pc=0x1005dc4 +runtime.chanrecv1(0xc42005e300, 0x0) + /Users/hiro/go/src/runtime/chan.go:388 +0x2b fp=0xc42002efa0 sp=0xc42002ef70 pc=0x1005a6b +testing.(*M).before.func1(0xc42005e300) + /Users/hiro/go/src/testing/testing.go:1111 +0x38 fp=0xc42002efd8 sp=0xc42002efa0 pc=0x10efd98 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42002efe0 sp=0xc42002efd8 pc=0x10612f1 +created by testing.(*M).before + /Users/hiro/go/src/testing/testing.go:1110 +0x191 + +goroutine 8 [chan receive]: +runtime.gopark(0x131a290, 0xc420106058, 0x1308f6e, 0xc, 0xc42002f617, 0x3) + /Users/hiro/go/src/runtime/proc.go:277 +0x12c fp=0xc42002f5e8 sp=0xc42002f5b8 pc=0x102fa7c +runtime.goparkunlock(0xc420106058, 0x1308f6e, 0xc, 0x1010f0120104017, 0x3) + /Users/hiro/go/src/runtime/proc.go:283 +0x5e fp=0xc42002f628 sp=0xc42002f5e8 pc=0x102fb6e +runtime.chanrecv(0xc420106000, 0x0, 0xc42002f701, 0x1249879) + /Users/hiro/go/src/runtime/chan.go:506 +0x304 fp=0xc42002f6d8 sp=0xc42002f628 pc=0x1005dc4 +runtime.chanrecv1(0xc420106000, 0x0) + /Users/hiro/go/src/runtime/chan.go:388 +0x2b fp=0xc42002f708 sp=0xc42002f6d8 pc=0x1005a6b +runtime_test.HammerRWMutex(0x4, 0xa, 0x3e8) + /Users/hiro/go/src/runtime/rwmutex_test.go:103 +0x1eb fp=0xc42002f770 sp=0xc42002f708 pc=0x12498ab +runtime_test.TestRWMutex(0xc4200e20f0) + /Users/hiro/go/src/runtime/rwmutex_test.go:118 +0x12f fp=0xc42002f7a8 sp=0xc42002f770 pc=0x1249a0f +testing.tRunner(0xc4200e20f0, 0x131b2e0) + /Users/hiro/go/src/testing/testing.go:754 +0xd0 fp=0xc42002f7d0 sp=0xc42002f7a8 pc=0x10eb8a0 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42002f7d8 sp=0xc42002f7d0 pc=0x10612f1 +created by testing.(*T).Run + /Users/hiro/go/src/testing/testing.go:800 +0x314 + +goroutine 50 [running]: + goroutine running on other thread; stack unavailable +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:92 +0xc1 + +goroutine 51 [running]: + goroutine running on other thread; stack unavailable +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:95 +0x105 + +goroutine 52 [runnable]: +runtime_test.reader(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:56 fp=0xc42010efc0 sp=0xc42010efb8 pc=0x12493c0 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42010efc8 sp=0xc42010efc0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:95 +0x105 + +goroutine 53 [runnable]: +runtime_test.reader(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:56 fp=0xc42010f7c0 sp=0xc42010f7b8 pc=0x12493c0 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42010f7c8 sp=0xc42010f7c0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:95 +0x105 + +goroutine 54 [running]: + goroutine running on other thread; stack unavailable +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:95 +0x105 + +goroutine 55 [running]: + goroutine running on other thread; stack unavailable +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:95 +0x105 + +goroutine 56 [runnable]: +runtime_test.writer(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:71 fp=0xc420110fc0 sp=0xc420110fb8 pc=0x1249540 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc420110fc8 sp=0xc420110fc0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:97 +0x16d + +goroutine 57 [runnable]: +runtime_test.reader(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:56 fp=0xc4201117c0 sp=0xc4201117b8 pc=0x12493c0 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc4201117c8 sp=0xc4201117c0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:99 +0x1b9 + +goroutine 58 [runnable]: +runtime_test.reader(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:56 fp=0xc420111fc0 sp=0xc420111fb8 pc=0x12493c0 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc420111fc8 sp=0xc420111fc0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:99 +0x1b9 + +goroutine 59 [runnable]: +runtime_test.reader(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:56 fp=0xc4200f47c0 sp=0xc4200f47b8 pc=0x12493c0 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc4200f47c8 sp=0xc4200f47c0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:99 +0x1b9 + +goroutine 60 [runnable]: +runtime_test.reader(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:56 fp=0xc42010afc0 sp=0xc42010afb8 pc=0x12493c0 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42010afc8 sp=0xc42010afc0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:99 +0x1b9 + +goroutine 61 [runnable]: +runtime.(*RWMutex).RUnlock(0xc420104000) + /Users/hiro/go/src/runtime/export_test.go:361 +0x3c fp=0xc42010b748 sp=0xc42010b740 pc=0x105a9bc +runtime_test.reader(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:66 +0x45 fp=0xc42010b7c0 sp=0xc42010b748 pc=0x1249405 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42010b7c8 sp=0xc42010b7c0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:99 +0x1b9 + +rax 0x4 +rbx 0x3 +rcx 0x700006055dc0 +rdx 0x0 +rdi 0x0 +rsi 0x0 +rbp 0x700006055dd0 +rsp 0x700006055dc0 +r8 0x700006055dc0 +r9 0x8 +r10 0x0 +r11 0x246 +r12 0x3b4a277fed96 +r13 0xb03 +r14 0x10326d0 +r15 0x1602620 +rip 0x10625b6 +rflags 0x247 +cs 0x7 +fs 0x0 +gs 0x0 +*** Test killed with quit: ran too long (10m0s). +FAIL runtime 600.024s +``` + +#### Does this issue reproduce with the latest release (go1.8.3)? + + +#### System details + +``` +go version devel +a89e6be5e4 Mon Jul 3 14:08:01 2017 +0000 darwin/amd64 +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/hiro/.go"" +GORACE="""" +GOROOT=""/Users/hiro/go"" +GOTOOLDIR=""/Users/hiro/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/wq/dwn8hs0x7njbzty9f68y61700000gn/T/go-build091579411=/tmp/go-build -gno-record-gcc-switches -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOROOT/bin/go version: go version devel +a89e6be5e4 Mon Jul 3 14:08:01 2017 +0000 darwin/amd64 +GOROOT/bin/go tool compile -V: compile version devel +a89e6be5e4 Mon Jul 3 14:08:01 2017 +0000 X:framepointer +uname -v: Darwin Kernel Version 16.6.0: Fri Apr 14 16:21:16 PDT 2017; root:xnu-3789.60.24~6/RELEASE_X86_64 +ProductName: Mac OS X +ProductVersion: 10.12.5 +BuildVersion: 16F73 +lldb --version: lldb-370.0.42 + Swift-3.1 +gdb --version: GNU gdb (GDB) 7.12.1 +``` + +FWIW, `sync.TestRWMutex` doesn't fail.",1.0,"runtime: TestRWMutex is flaky? - Please answer these questions before submitting your issue. Thanks! + +#### What did you do? +If possible, provide a recipe for reproducing the error. +A complete runnable program is good. +A link on play.golang.org is best. + +```bash +for i in `seq 100`; do go test -v runtime -run ""TestRWMutex""; done +``` + +#### What did you expect to see? +PASS * 100 + +#### What did you see instead? +``` +=== RUN TestRWMutex +SIGQUIT: quit +PC=0x10625b6 m=2 sigcode=0 + +goroutine 0 [idle]: +runtime.usleep(0x8b00002710, 0x0, 0x68c71d5b2f, 0x45d964b800, 0x271000000000, 0x8bb25b57c4, 0x45d964b800, 0x3, 0x0, 0x68c71d5b2f, ...) + /Users/hiro/go/src/runtime/sys_darwin_amd64.s:323 +0x36 fp=0x700006055de0 sp=0x700006055dc0 pc=0x10625b6 +runtime.sysmon() + /Users/hiro/go/src/runtime/proc.go:3799 +0xa8 fp=0x700006055e68 sp=0x700006055de0 pc=0x1039a08 +runtime.mstart1() + /Users/hiro/go/src/runtime/proc.go:1172 +0x11e fp=0x700006055e90 sp=0x700006055e68 pc=0x103285e +runtime.mstart() + /Users/hiro/go/src/runtime/proc.go:1142 +0x64 fp=0x700006055ea8 sp=0x700006055e90 pc=0x1032734 + +goroutine 1 [chan receive]: +runtime.gopark(0x131a290, 0xc420076418, 0x1308f6e, 0xc, 0xc420051b17, 0x3) + /Users/hiro/go/src/runtime/proc.go:277 +0x12c fp=0xc420051ac8 sp=0xc420051a98 pc=0x102fa7c +runtime.goparkunlock(0xc420076418, 0x1308f6e, 0xc, 0xc4200e8017, 0x3) + /Users/hiro/go/src/runtime/proc.go:283 +0x5e fp=0xc420051b08 sp=0xc420051ac8 pc=0x102fb6e +runtime.chanrecv(0xc4200763c0, 0x0, 0xc420051b01, 0x10ebc14) + /Users/hiro/go/src/runtime/chan.go:506 +0x304 fp=0xc420051bb8 sp=0xc420051b08 pc=0x1005dc4 +runtime.chanrecv1(0xc4200763c0, 0x0) + /Users/hiro/go/src/runtime/chan.go:388 +0x2b fp=0xc420051be8 sp=0xc420051bb8 pc=0x1005a6b +testing.(*T).Run(0xc4200e2000, 0x130879c, 0xb, 0x131b2e0, 0x108f201) + /Users/hiro/go/src/testing/testing.go:801 +0x332 fp=0xc420051c98 sp=0xc420051be8 pc=0x10ebc32 +testing.runTests.func1(0xc4200e2000) + /Users/hiro/go/src/testing/testing.go:1053 +0x64 fp=0xc420051ce8 sp=0xc420051c98 pc=0x10efd04 +testing.tRunner(0xc4200e2000, 0xc420051d98) + /Users/hiro/go/src/testing/testing.go:754 +0xd0 fp=0xc420051d10 sp=0xc420051ce8 pc=0x10eb8a0 +testing.runTests(0xc42000c300, 0x1498000, 0xd7, 0xd7, 0x5f) + /Users/hiro/go/src/testing/testing.go:1051 +0x2d8 fp=0xc420051dc8 sp=0xc420051d10 pc=0x10ed688 +testing.(*M).Run(0xc420051f18, 0x12474b6) + /Users/hiro/go/src/testing/testing.go:932 +0x111 fp=0xc420051ec0 sp=0xc420051dc8 pc=0x10ec031 +runtime_test.TestMain(0xc420051f18) + /Users/hiro/go/src/runtime/crash_test.go:28 +0x2f fp=0xc420051f10 sp=0xc420051ec0 pc=0x1216c9f +main.main() + runtime/_test/_testmain.go:902 +0xdb fp=0xc420051f80 sp=0xc420051f10 pc=0x126701b +runtime.main() + /Users/hiro/go/src/runtime/proc.go:185 +0x20d fp=0xc420051fe0 sp=0xc420051f80 pc=0x102f5dd +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc420051fe8 sp=0xc420051fe0 pc=0x10612f1 + +goroutine 2 [force gc (idle)]: +runtime.gopark(0x131a290, 0x149a0c0, 0x130a49c, 0xf, 0x14, 0x1) + /Users/hiro/go/src/runtime/proc.go:277 +0x12c fp=0xc42002c768 sp=0xc42002c738 pc=0x102fa7c +runtime.goparkunlock(0x149a0c0, 0x130a49c, 0xf, 0xc420000114, 0x1) + /Users/hiro/go/src/runtime/proc.go:283 +0x5e fp=0xc42002c7a8 sp=0xc42002c768 pc=0x102fb6e +runtime.forcegchelper() + /Users/hiro/go/src/runtime/proc.go:235 +0xcc fp=0xc42002c7e0 sp=0xc42002c7a8 pc=0x102f89c +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42002c7e8 sp=0xc42002c7e0 pc=0x10612f1 +created by runtime.init.4 + /Users/hiro/go/src/runtime/proc.go:224 +0x35 + +goroutine 3 [GC sweep wait]: +runtime.gopark(0x131a290, 0x149a3c0, 0x130941f, 0xd, 0x1021014, 0x1) + /Users/hiro/go/src/runtime/proc.go:277 +0x12c fp=0xc42002cf60 sp=0xc42002cf30 pc=0x102fa7c +runtime.goparkunlock(0x149a3c0, 0x130941f, 0xd, 0x14, 0x1) + /Users/hiro/go/src/runtime/proc.go:283 +0x5e fp=0xc42002cfa0 sp=0xc42002cf60 pc=0x102fb6e +runtime.bgsweep(0xc420020070) + /Users/hiro/go/src/runtime/mgcsweep.go:52 +0xa3 fp=0xc42002cfd8 sp=0xc42002cfa0 pc=0x10210d3 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42002cfe0 sp=0xc42002cfd8 pc=0x10612f1 +created by runtime.gcenable + /Users/hiro/go/src/runtime/mgc.go:216 +0x58 + +goroutine 4 [finalizer wait]: +runtime.gopark(0x131a290, 0x14b9f10, 0x1309da5, 0xe, 0x14, 0x1) + /Users/hiro/go/src/runtime/proc.go:277 +0x12c fp=0xc42002d700 sp=0xc42002d6d0 pc=0x102fa7c +runtime.goparkunlock(0x14b9f10, 0x1309da5, 0xe, 0x14, 0x1) + /Users/hiro/go/src/runtime/proc.go:283 +0x5e fp=0xc42002d740 sp=0xc42002d700 pc=0x102fb6e +runtime.runfinq() + /Users/hiro/go/src/runtime/mfinal.go:175 +0xb8 fp=0xc42002d7e0 sp=0xc42002d740 pc=0x1017ed8 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42002d7e8 sp=0xc42002d7e0 pc=0x10612f1 +created by runtime.createfing + /Users/hiro/go/src/runtime/mfinal.go:156 +0x62 + +goroutine 5 [syscall]: +runtime.notetsleepg(0x14ba2c0, 0xffffffffffffffff, 0x0) + /Users/hiro/go/src/runtime/lock_sema.go:280 +0x4b fp=0xc42002df80 sp=0xc42002df40 pc=0x10119eb +os/signal.signal_recv(0x0) + /Users/hiro/go/src/runtime/sigqueue.go:131 +0xa7 fp=0xc42002dfa8 sp=0xc42002df80 pc=0x1045807 +os/signal.loop() + /Users/hiro/go/src/os/signal/signal_unix.go:22 +0x22 fp=0xc42002dfe0 sp=0xc42002dfa8 pc=0x10e4232 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42002dfe8 sp=0xc42002dfe0 pc=0x10612f1 +created by os/signal.init.0 + /Users/hiro/go/src/os/signal/signal_unix.go:28 +0x41 + +goroutine 6 [select, locked to thread]: +runtime.gopark(0x131a2d8, 0x0, 0x1306abf, 0x6, 0x18, 0x1) + /Users/hiro/go/src/runtime/proc.go:277 +0x12c fp=0xc42003aca0 sp=0xc42003ac70 pc=0x102fa7c +runtime.selectgo(0xc42003af50, 0xc420076180) + /Users/hiro/go/src/runtime/select.go:395 +0x1138 fp=0xc42003af18 sp=0xc42003aca0 pc=0x103fff8 +runtime.ensureSigM.func1() + /Users/hiro/go/src/runtime/signal_unix.go:511 +0x1fe fp=0xc42003afe0 sp=0xc42003af18 pc=0x105da9e +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42003afe8 sp=0xc42003afe0 pc=0x10612f1 +created by runtime.ensureSigM + /Users/hiro/go/src/runtime/signal_unix.go:494 +0xda + +goroutine 7 [chan receive]: +runtime.gopark(0x131a290, 0xc42005e358, 0x1308f6e, 0xc, 0xc420024117, 0x3) + /Users/hiro/go/src/runtime/proc.go:277 +0x12c fp=0xc42002ee80 sp=0xc42002ee50 pc=0x102fa7c +runtime.goparkunlock(0xc42005e358, 0x1308f6e, 0xc, 0x17, 0x3) + /Users/hiro/go/src/runtime/proc.go:283 +0x5e fp=0xc42002eec0 sp=0xc42002ee80 pc=0x102fb6e +runtime.chanrecv(0xc42005e300, 0x0, 0x1, 0x0) + /Users/hiro/go/src/runtime/chan.go:506 +0x304 fp=0xc42002ef70 sp=0xc42002eec0 pc=0x1005dc4 +runtime.chanrecv1(0xc42005e300, 0x0) + /Users/hiro/go/src/runtime/chan.go:388 +0x2b fp=0xc42002efa0 sp=0xc42002ef70 pc=0x1005a6b +testing.(*M).before.func1(0xc42005e300) + /Users/hiro/go/src/testing/testing.go:1111 +0x38 fp=0xc42002efd8 sp=0xc42002efa0 pc=0x10efd98 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42002efe0 sp=0xc42002efd8 pc=0x10612f1 +created by testing.(*M).before + /Users/hiro/go/src/testing/testing.go:1110 +0x191 + +goroutine 8 [chan receive]: +runtime.gopark(0x131a290, 0xc420106058, 0x1308f6e, 0xc, 0xc42002f617, 0x3) + /Users/hiro/go/src/runtime/proc.go:277 +0x12c fp=0xc42002f5e8 sp=0xc42002f5b8 pc=0x102fa7c +runtime.goparkunlock(0xc420106058, 0x1308f6e, 0xc, 0x1010f0120104017, 0x3) + /Users/hiro/go/src/runtime/proc.go:283 +0x5e fp=0xc42002f628 sp=0xc42002f5e8 pc=0x102fb6e +runtime.chanrecv(0xc420106000, 0x0, 0xc42002f701, 0x1249879) + /Users/hiro/go/src/runtime/chan.go:506 +0x304 fp=0xc42002f6d8 sp=0xc42002f628 pc=0x1005dc4 +runtime.chanrecv1(0xc420106000, 0x0) + /Users/hiro/go/src/runtime/chan.go:388 +0x2b fp=0xc42002f708 sp=0xc42002f6d8 pc=0x1005a6b +runtime_test.HammerRWMutex(0x4, 0xa, 0x3e8) + /Users/hiro/go/src/runtime/rwmutex_test.go:103 +0x1eb fp=0xc42002f770 sp=0xc42002f708 pc=0x12498ab +runtime_test.TestRWMutex(0xc4200e20f0) + /Users/hiro/go/src/runtime/rwmutex_test.go:118 +0x12f fp=0xc42002f7a8 sp=0xc42002f770 pc=0x1249a0f +testing.tRunner(0xc4200e20f0, 0x131b2e0) + /Users/hiro/go/src/testing/testing.go:754 +0xd0 fp=0xc42002f7d0 sp=0xc42002f7a8 pc=0x10eb8a0 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42002f7d8 sp=0xc42002f7d0 pc=0x10612f1 +created by testing.(*T).Run + /Users/hiro/go/src/testing/testing.go:800 +0x314 + +goroutine 50 [running]: + goroutine running on other thread; stack unavailable +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:92 +0xc1 + +goroutine 51 [running]: + goroutine running on other thread; stack unavailable +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:95 +0x105 + +goroutine 52 [runnable]: +runtime_test.reader(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:56 fp=0xc42010efc0 sp=0xc42010efb8 pc=0x12493c0 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42010efc8 sp=0xc42010efc0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:95 +0x105 + +goroutine 53 [runnable]: +runtime_test.reader(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:56 fp=0xc42010f7c0 sp=0xc42010f7b8 pc=0x12493c0 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42010f7c8 sp=0xc42010f7c0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:95 +0x105 + +goroutine 54 [running]: + goroutine running on other thread; stack unavailable +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:95 +0x105 + +goroutine 55 [running]: + goroutine running on other thread; stack unavailable +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:95 +0x105 + +goroutine 56 [runnable]: +runtime_test.writer(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:71 fp=0xc420110fc0 sp=0xc420110fb8 pc=0x1249540 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc420110fc8 sp=0xc420110fc0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:97 +0x16d + +goroutine 57 [runnable]: +runtime_test.reader(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:56 fp=0xc4201117c0 sp=0xc4201117b8 pc=0x12493c0 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc4201117c8 sp=0xc4201117c0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:99 +0x1b9 + +goroutine 58 [runnable]: +runtime_test.reader(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:56 fp=0xc420111fc0 sp=0xc420111fb8 pc=0x12493c0 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc420111fc8 sp=0xc420111fc0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:99 +0x1b9 + +goroutine 59 [runnable]: +runtime_test.reader(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:56 fp=0xc4200f47c0 sp=0xc4200f47b8 pc=0x12493c0 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc4200f47c8 sp=0xc4200f47c0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:99 +0x1b9 + +goroutine 60 [runnable]: +runtime_test.reader(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:56 fp=0xc42010afc0 sp=0xc42010afb8 pc=0x12493c0 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42010afc8 sp=0xc42010afc0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:99 +0x1b9 + +goroutine 61 [runnable]: +runtime.(*RWMutex).RUnlock(0xc420104000) + /Users/hiro/go/src/runtime/export_test.go:361 +0x3c fp=0xc42010b748 sp=0xc42010b740 pc=0x105a9bc +runtime_test.reader(0xc420104000, 0x3e8, 0xc420102000, 0xc420106000) + /Users/hiro/go/src/runtime/rwmutex_test.go:66 +0x45 fp=0xc42010b7c0 sp=0xc42010b748 pc=0x1249405 +runtime.goexit() + /Users/hiro/go/src/runtime/asm_amd64.s:2337 +0x1 fp=0xc42010b7c8 sp=0xc42010b7c0 pc=0x10612f1 +created by runtime_test.HammerRWMutex + /Users/hiro/go/src/runtime/rwmutex_test.go:99 +0x1b9 + +rax 0x4 +rbx 0x3 +rcx 0x700006055dc0 +rdx 0x0 +rdi 0x0 +rsi 0x0 +rbp 0x700006055dd0 +rsp 0x700006055dc0 +r8 0x700006055dc0 +r9 0x8 +r10 0x0 +r11 0x246 +r12 0x3b4a277fed96 +r13 0xb03 +r14 0x10326d0 +r15 0x1602620 +rip 0x10625b6 +rflags 0x247 +cs 0x7 +fs 0x0 +gs 0x0 +*** Test killed with quit: ran too long (10m0s). +FAIL runtime 600.024s +``` + +#### Does this issue reproduce with the latest release (go1.8.3)? + + +#### System details + +``` +go version devel +a89e6be5e4 Mon Jul 3 14:08:01 2017 +0000 darwin/amd64 +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/hiro/.go"" +GORACE="""" +GOROOT=""/Users/hiro/go"" +GOTOOLDIR=""/Users/hiro/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/wq/dwn8hs0x7njbzty9f68y61700000gn/T/go-build091579411=/tmp/go-build -gno-record-gcc-switches -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOROOT/bin/go version: go version devel +a89e6be5e4 Mon Jul 3 14:08:01 2017 +0000 darwin/amd64 +GOROOT/bin/go tool compile -V: compile version devel +a89e6be5e4 Mon Jul 3 14:08:01 2017 +0000 X:framepointer +uname -v: Darwin Kernel Version 16.6.0: Fri Apr 14 16:21:16 PDT 2017; root:xnu-3789.60.24~6/RELEASE_X86_64 +ProductName: Mac OS X +ProductVersion: 10.12.5 +BuildVersion: 16F73 +lldb --version: lldb-370.0.42 + Swift-3.1 +gdb --version: GNU gdb (GDB) 7.12.1 +``` + +FWIW, `sync.TestRWMutex` doesn't fail.",0,runtime testrwmutex is flaky please answer these questions before submitting your issue thanks what did you do if possible provide a recipe for reproducing the error a complete runnable program is good a link on play golang org is best bash for i in seq do go test v runtime run testrwmutex done what did you expect to see pass what did you see instead run testrwmutex sigquit quit pc m sigcode goroutine runtime usleep users hiro go src runtime sys darwin s fp sp pc runtime sysmon users hiro go src runtime proc go fp sp pc runtime users hiro go src runtime proc go fp sp pc runtime mstart users hiro go src runtime proc go fp sp pc goroutine runtime gopark users hiro go src runtime proc go fp sp pc runtime goparkunlock users hiro go src runtime proc go fp sp pc runtime chanrecv users hiro go src runtime chan go fp sp pc runtime users hiro go src runtime chan go fp sp pc testing t run users hiro go src testing testing go fp sp pc testing runtests users hiro go src testing testing go fp sp pc testing trunner users hiro go src testing testing go fp sp pc testing runtests users hiro go src testing testing go fp sp pc testing m run users hiro go src testing testing go fp sp pc runtime test testmain users hiro go src runtime crash test go fp sp pc main main runtime test testmain go fp sp pc runtime main users hiro go src runtime proc go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc goroutine runtime gopark users hiro go src runtime proc go fp sp pc runtime goparkunlock users hiro go src runtime proc go fp sp pc runtime forcegchelper users hiro go src runtime proc go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by runtime init users hiro go src runtime proc go goroutine runtime gopark users hiro go src runtime proc go fp sp pc runtime goparkunlock users hiro go src runtime proc go fp sp pc runtime bgsweep users hiro go src runtime mgcsweep go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by runtime gcenable users hiro go src runtime mgc go goroutine runtime gopark users hiro go src runtime proc go fp sp pc runtime goparkunlock users hiro go src runtime proc go fp sp pc runtime runfinq users hiro go src runtime mfinal go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by runtime createfing users hiro go src runtime mfinal go goroutine runtime notetsleepg users hiro go src runtime lock sema go fp sp pc os signal signal recv users hiro go src runtime sigqueue go fp sp pc os signal loop users hiro go src os signal signal unix go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by os signal init users hiro go src os signal signal unix go goroutine runtime gopark users hiro go src runtime proc go fp sp pc runtime selectgo users hiro go src runtime select go fp sp pc runtime ensuresigm users hiro go src runtime signal unix go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by runtime ensuresigm users hiro go src runtime signal unix go goroutine runtime gopark users hiro go src runtime proc go fp sp pc runtime goparkunlock users hiro go src runtime proc go fp sp pc runtime chanrecv users hiro go src runtime chan go fp sp pc runtime users hiro go src runtime chan go fp sp pc testing m before users hiro go src testing testing go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by testing m before users hiro go src testing testing go goroutine runtime gopark users hiro go src runtime proc go fp sp pc runtime goparkunlock users hiro go src runtime proc go fp sp pc runtime chanrecv users hiro go src runtime chan go fp sp pc runtime users hiro go src runtime chan go fp sp pc runtime test hammerrwmutex users hiro go src runtime rwmutex test go fp sp pc runtime test testrwmutex users hiro go src runtime rwmutex test go fp sp pc testing trunner users hiro go src testing testing go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by testing t run users hiro go src testing testing go goroutine goroutine running on other thread stack unavailable created by runtime test hammerrwmutex users hiro go src runtime rwmutex test go goroutine goroutine running on other thread stack unavailable created by runtime test hammerrwmutex users hiro go src runtime rwmutex test go goroutine runtime test reader users hiro go src runtime rwmutex test go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by runtime test hammerrwmutex users hiro go src runtime rwmutex test go goroutine runtime test reader users hiro go src runtime rwmutex test go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by runtime test hammerrwmutex users hiro go src runtime rwmutex test go goroutine goroutine running on other thread stack unavailable created by runtime test hammerrwmutex users hiro go src runtime rwmutex test go goroutine goroutine running on other thread stack unavailable created by runtime test hammerrwmutex users hiro go src runtime rwmutex test go goroutine runtime test writer users hiro go src runtime rwmutex test go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by runtime test hammerrwmutex users hiro go src runtime rwmutex test go goroutine runtime test reader users hiro go src runtime rwmutex test go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by runtime test hammerrwmutex users hiro go src runtime rwmutex test go goroutine runtime test reader users hiro go src runtime rwmutex test go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by runtime test hammerrwmutex users hiro go src runtime rwmutex test go goroutine runtime test reader users hiro go src runtime rwmutex test go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by runtime test hammerrwmutex users hiro go src runtime rwmutex test go goroutine runtime test reader users hiro go src runtime rwmutex test go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by runtime test hammerrwmutex users hiro go src runtime rwmutex test go goroutine runtime rwmutex runlock users hiro go src runtime export test go fp sp pc runtime test reader users hiro go src runtime rwmutex test go fp sp pc runtime goexit users hiro go src runtime asm s fp sp pc created by runtime test hammerrwmutex users hiro go src runtime rwmutex test go rax rbx rcx rdx rdi rsi rbp rsp rip rflags cs fs gs test killed with quit ran too long fail runtime does this issue reproduce with the latest release system details go version devel mon jul darwin goarch gobin goexe gohostarch gohostos darwin goos darwin gopath users hiro go gorace goroot users hiro go gotooldir users hiro go pkg tool darwin gccgo gccgo cc clang gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map var folders wq t go tmp go build gno record gcc switches fno common cxx clang cgo enabled cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config goroot bin go version go version devel mon jul darwin goroot bin go tool compile v compile version devel mon jul x framepointer uname v darwin kernel version fri apr pdt root xnu release productname mac os x productversion buildversion lldb version lldb swift gdb version gnu gdb gdb fwiw sync testrwmutex doesn t fail ,0 +3737,2783007638.0,IssuesEvent,2015-05-06 21:00:15,golang/go,https://api.github.com/repos/golang/go,closed,testing: (*testing.Benchmark).Log always logs,Documentation,"With this benchmark: + +package main +import ""testing"" +func BenchmarkLog(b *testing.B) { + b.Log(""why?"") +} + +I get this output: + +$ go test -bench . +testing: warning: no tests to run +PASS +BenchmarkLog 2000000000 0.00 ns/op +--- BENCH: BenchmarkLog + issue_test.go:6: why? + issue_test.go:6: why? + issue_test.go:6: why? + issue_test.go:6: why? + issue_test.go:6: why? + issue_test.go:6: why? + +The docs say, ""The text will be printed only if the test fails or the -test.v flag is set."" + +Why is b.Log logging anyway?",1.0,"testing: (*testing.Benchmark).Log always logs - With this benchmark: + +package main +import ""testing"" +func BenchmarkLog(b *testing.B) { + b.Log(""why?"") +} + +I get this output: + +$ go test -bench . +testing: warning: no tests to run +PASS +BenchmarkLog 2000000000 0.00 ns/op +--- BENCH: BenchmarkLog + issue_test.go:6: why? + issue_test.go:6: why? + issue_test.go:6: why? + issue_test.go:6: why? + issue_test.go:6: why? + issue_test.go:6: why? + +The docs say, ""The text will be printed only if the test fails or the -test.v flag is set."" + +Why is b.Log logging anyway?",1,testing testing benchmark log always logs with this benchmark package main import testing func benchmarklog b testing b b log why i get this output go test bench testing warning no tests to run pass benchmarklog ns op bench benchmarklog issue test go why issue test go why issue test go why issue test go why issue test go why issue test go why the docs say the text will be printed only if the test fails or the test v flag is set why is b log logging anyway ,1 +442657,30849007705.0,IssuesEvent,2023-08-02 15:25:56,golang/go,https://api.github.com/repos/golang/go,closed,reflect: documentation of StructField.Offset is not clear about type embedding,Documentation help wanted NeedsInvestigation compiler/runtime,"When I read the document I think StructField.Offset means the offset of the field of caller struct, not the offset of embeded struct.But it is the offset of embeded struct. +I think the document should be updated to clear it. + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.19.2 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/a/Library/Caches/go-build"" +GOENV=""/Users/a/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/a/go/pkg/mod"" +GOOS=""darwin"" +GOPATH=""/Users/a/go"" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GOVCS="""" +GOVERSION=""go1.19.2"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/mw/884f6hx53r56gd7zxsm1h8bm0000gp/T/go-build2286547601=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
+$ go version +go version go1.19.2 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/a/Library/Caches/go-build"" +GOENV=""/Users/a/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/a/go/pkg/mod"" +GOOS=""darwin"" +GOPATH=""/Users/a/go"" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GOVCS="""" +GOVERSION=""go1.19.2"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/mw/884f6hx53r56gd7zxsm1h8bm0000gp/T/go-build2286547601=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
+$ go version +go version go1.18beta1 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE=""on"" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/bobg/.cache/go-build"" +GOENV=""/home/bobg/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/bobg/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/bobg/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/home/bobg/sdk/go1.18beta1"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/home/bobg/sdk/go1.18beta1/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.18beta1"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/bobg/go/src/github.com/bobg/modver/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build3923542930=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.18beta1 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE=""on"" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/bobg/.cache/go-build"" +GOENV=""/home/bobg/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/bobg/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/bobg/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/home/bobg/sdk/go1.18beta1"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/home/bobg/sdk/go1.18beta1/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.18beta1"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/bobg/go/src/github.com/bobg/modver/go.mod"" +GOWORK="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build3923542930=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.16.4 linux/amd64 ++ +### Does this issue reproduce with the latest release? + + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/baryshnikov/.cache/go-build"" +GOENV=""/home/baryshnikov/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/baryshnikov/Develop/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/baryshnikov/Develop/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/opt/go/latest"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/opt/go/latest/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.16.4"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build1338096382=/tmp/go-build -gno-record-gcc-switches"" + +
+package main
+
+import (
+ ""embed""
+ ""fmt""
+ ""os""
+)
+
+//go:embed assets
+var assets embed.FS
+
+func main() {
+ files := []string{
+ ""assets/root.txt"",
+ ""assets/:normal"",
+ ""assets/:alsonormal/file2.txt"",
+ }
+
+ // check in real file system
+ for _, file := range files {
+ _, err := os.Open(file)
+ if err != nil {
+ fmt.Println(""[FAILED ] failed open"", file, ""in real file system:"", err)
+ } else {
+ fmt.Println(""[SUCCESS] open"", file, ""in real file system"")
+ }
+ }
+
+ // check in embedded
+ for _, file := range files {
+ _, err := assets.Open(file)
+ if err != nil {
+ fmt.Println(""[FAILED ] failed open"", file, ""in embedded file system"", "":"", err)
+ } else {
+ fmt.Println(""[SUCCESS] open"", file, ""in embedded file system"")
+ }
+ }
+}
+
+
++$ go version +go version go1.16.4 linux/amd64 ++ +### Does this issue reproduce with the latest release? + + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/baryshnikov/.cache/go-build"" +GOENV=""/home/baryshnikov/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/baryshnikov/Develop/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/baryshnikov/Develop/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/opt/go/latest"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/opt/go/latest/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.16.4"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build1338096382=/tmp/go-build -gno-record-gcc-switches"" + +
+package main
+
+import (
+ ""embed""
+ ""fmt""
+ ""os""
+)
+
+//go:embed assets
+var assets embed.FS
+
+func main() {
+ files := []string{
+ ""assets/root.txt"",
+ ""assets/:normal"",
+ ""assets/:alsonormal/file2.txt"",
+ }
+
+ // check in real file system
+ for _, file := range files {
+ _, err := os.Open(file)
+ if err != nil {
+ fmt.Println(""[FAILED ] failed open"", file, ""in real file system:"", err)
+ } else {
+ fmt.Println(""[SUCCESS] open"", file, ""in real file system"")
+ }
+ }
+
+ // check in embedded
+ for _, file := range files {
+ _, err := assets.Open(file)
+ if err != nil {
+ fmt.Println(""[FAILED ] failed open"", file, ""in embedded file system"", "":"", err)
+ } else {
+ fmt.Println(""[SUCCESS] open"", file, ""in embedded file system"")
+ }
+ }
+}
+
+
+GOMAXPROCS set to the
+number of cores available but you can change this implementation default to your needs.
+There are two related ways to do this. Either run your job with environment
+variable GOMAXPROCS set to the number of cores to use
+or import the runtime package and call
+runtime.GOMAXPROCS(NCPU).",1.0,"doc: effective_go.html GOMAXPROCS=1 does not hold anymore with Go1.5 - [0] https://github.com/golang/go/blob/master/doc/effective_go.html#L3192-L3206
+
+states that ""The current implementation of the Go runtime will not parallelize this code by default.""
+
+as of Go 1.5 the implementation for that changed:
+https://github.com/golang/go/blob/master/doc/go1.5.html#L36-L37
+
+and ""by default, Go programs run with GOMAXPROCS set to the number of cores available"".
+the section [0] should reflect that new implementation detail with perhaps something like:
+
+The implementation of the Go runtime parallelize this code by default.
+Go programs run with GOMAXPROCS set to the
+number of cores available but you can change this implementation default to your needs.
+There are two related ways to do this. Either run your job with environment
+variable GOMAXPROCS set to the number of cores to use
+or import the runtime package and call
+runtime.GOMAXPROCS(NCPU).",1,doc effective go html gomaxprocs does not hold anymore with states that the current implementation of the go runtime will not parallelize this code by default as of go the implementation for that changed and by default go programs run with gomaxprocs set to the number of cores available the section should reflect that new implementation detail with perhaps something like the implementation of the go runtime parallelize this code by default go programs run with gomaxprocs set to the number of cores available but you can change this implementation default to your needs there are two related ways to do this either run your job with environment variable gomaxprocs set to the number of cores to use or import the runtime package and call runtime gomaxprocs ncpu ,1
+31621,8719340800.0,IssuesEvent,2018-12-08 00:11:36,golang/go,https://api.github.com/repos/golang/go,closed,x/build: windows/arm builder got misconfigured,Builders,"windows/arm builder looks misconfigured.
+
+From https://build.golang.org/log/4d354f5970ff4e883ec131851af59fcdf1556dbb
+
+```
+ERROR: Cannot find C:\Data\Go\bin\go.exe
+Set GOROOT_BOOTSTRAP to a working Go tree >= Go 1.4.
+
+build failed: make script failed: exit status 1
+```
+
+@jordanrh1, please investigate. Thank you.
+
+Alex",1.0,"x/build: windows/arm builder got misconfigured - windows/arm builder looks misconfigured.
+
+From https://build.golang.org/log/4d354f5970ff4e883ec131851af59fcdf1556dbb
+
+```
+ERROR: Cannot find C:\Data\Go\bin\go.exe
+Set GOROOT_BOOTSTRAP to a working Go tree >= Go 1.4.
+
+build failed: make script failed: exit status 1
+```
+
+@jordanrh1, please investigate. Thank you.
+
+Alex",0,x build windows arm builder got misconfigured windows arm builder looks misconfigured from error cannot find c data go bin go exe set goroot bootstrap to a working go tree go build failed make script failed exit status please investigate thank you alex,0
+28478,8150275673.0,IssuesEvent,2018-08-22 12:29:43,golang/go,https://api.github.com/repos/golang/go,closed,builders: linux-s390x-ibm has no space left on device,Builders,"Recent builds have been failing on linux-s390x-ibm with messages like
+
+```
+/var/buildlet/go-linux-s390x-bootstrap/pkg/tool/linux_s390x/link: flushing $WORK/_/data/golang/workdir/go/src/cmd/dist/_obj/exe/a.out: write $WORK/_/data/golang/workdir/go/src/cmd/dist/_obj/exe/a.out: no space left on device
+```
+
+https://build.golang.org/log/70d02de37115ec58a773a000bdb7d3ad5aa0ee11
+
+/cc @mundaym ",1.0,"builders: linux-s390x-ibm has no space left on device - Recent builds have been failing on linux-s390x-ibm with messages like
+
+```
+/var/buildlet/go-linux-s390x-bootstrap/pkg/tool/linux_s390x/link: flushing $WORK/_/data/golang/workdir/go/src/cmd/dist/_obj/exe/a.out: write $WORK/_/data/golang/workdir/go/src/cmd/dist/_obj/exe/a.out: no space left on device
+```
+
+https://build.golang.org/log/70d02de37115ec58a773a000bdb7d3ad5aa0ee11
+
+/cc @mundaym ",0,builders linux ibm has no space left on device recent builds have been failing on linux ibm with messages like var buildlet go linux bootstrap pkg tool linux link flushing work data golang workdir go src cmd dist obj exe a out write work data golang workdir go src cmd dist obj exe a out no space left on device cc mundaym ,0
+33215,6180328708.0,IssuesEvent,2017-07-03 05:06:13,golang/go,https://api.github.com/repos/golang/go,opened,Effective_GO documentation mistake,Documentation,"
+[https://golang.org/doc/effective_go.html#functions](url)
+on this code
+
+```
+func nextInt(b []byte, i int) (int, int) {
+ for ; i < len(b) && !isDigit(b[i]); i++ {
+ }
+ x := 0
+ for ; i < len(b) && isDigit(b[i]); i++ {
+ x = x*10 + int(b[i]) - '0'
+ }
+ return x, i
+}
+```
+
+
+I think
+
+```
+ for ; i < len(b) && !isDigit(b[i]); i++ {
+ }
+```
+
+is a duplication mistake",1.0,"Effective_GO documentation mistake -
+[https://golang.org/doc/effective_go.html#functions](url)
+on this code
+
+```
+func nextInt(b []byte, i int) (int, int) {
+ for ; i < len(b) && !isDigit(b[i]); i++ {
+ }
+ x := 0
+ for ; i < len(b) && isDigit(b[i]); i++ {
+ x = x*10 + int(b[i]) - '0'
+ }
+ return x, i
+}
+```
+
+
+I think
+
+```
+ for ; i < len(b) && !isDigit(b[i]); i++ {
+ }
+```
+
+is a duplication mistake",1,effective go documentation mistake url on this code func nextint b byte i int int int for i len b isdigit b i x for i len b isdigit b i x x int b return x i i think for i len b isdigit b i is a duplication mistake,1
+80625,10195250833.0,IssuesEvent,2019-08-12 17:39:48,golang/go,https://api.github.com/repos/golang/go,closed,encoding/json: Unmarshal map[string]interface{} target mishandled when passed as an interface{},Documentation,"
+
+### What version of Go are you using (`go version`)?
+
++$ go version +go version go1.12.6 linux/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN=""xxx"" +GOCACHE=""xxx"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""xxx"" +GOPROXY="""" +GORACE="""" +GOROOT=""xxx"" +GOTMPDIR="""" +GOTOOLDIR=""xxx"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build894533395=/tmp/go-build -gno-record-gcc-switches"" + +
+map1: map[key1:data1 key2:data2] +map2: map[key1:data1 key2:data2] +map3: map[key1:map[key1.1:data1 key1.2:data2]] ++ +### What did you see instead? + +Whenever the type of the unmarshal target is interface{} then a replacement value is created even if the existing entry is of type map[string]interface{} and is a suitable instance for unmarshal to use. + +The play example outputs: + +
+result: map[key2:data2] +result: map[key1:data1 key2:data2] +result: map[key1:map[key1.2:data2]] ++",1.0,"encoding/json: Unmarshal map[string]interface{} target mishandled when passed as an interface{} - + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.12.6 linux/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN=""xxx"" +GOCACHE=""xxx"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""xxx"" +GOPROXY="""" +GORACE="""" +GOROOT=""xxx"" +GOTMPDIR="""" +GOTOOLDIR=""xxx"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build894533395=/tmp/go-build -gno-record-gcc-switches"" + +
+map1: map[key1:data1 key2:data2] +map2: map[key1:data1 key2:data2] +map3: map[key1:map[key1.1:data1 key1.2:data2]] ++ +### What did you see instead? + +Whenever the type of the unmarshal target is interface{} then a replacement value is created even if the existing entry is of type map[string]interface{} and is a suitable instance for unmarshal to use. + +The play example outputs: + +
+result: map[key2:data2] +result: map[key1:data1 key2:data2] +result: map[key1:map[key1.2:data2]] ++",1,encoding json unmarshal map interface target mishandled when passed as an interface what version of go are you using go version go version go version linux does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env go env output go env goarch gobin xxx gocache xxx goexe goflags gohostarch gohostos linux goos linux gopath xxx goproxy gorace goroot xxx gotmpdir gotooldir xxx gccgo gccgo cc gcc cxx g cgo enabled gomod cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fmessage length fdebug prefix map tmp go tmp go build gno record gcc switches what did you do used a reference to the same map in multiple call to json unmarshal see what did you expect to see expected json unmarshaling into maps to merge entries between different calls to json unmarshal as indicated by the docs the play example should output map map map what did you see instead whenever the type of the unmarshal target is interface then a replacement value is created even if the existing entry is of type map interface and is a suitable instance for unmarshal to use the play example outputs result map result map result map ,1 +173137,14403476434.0,IssuesEvent,2020-12-03 16:06:12,golang/go,https://api.github.com/repos/golang/go,closed,doc/go1.16: document os/signal changes for Go 1.16,Documentation NeedsInvestigation help wanted release-blocker,"As of filing this issue, the [Go 1.16 draft release notes](https://tip.golang.org/doc/go1.16) contained the following HTML: + +
+ TODO: https://golang.org/cl/219640: add NotifyContext to cancel context using system signals +
++ TODO: https://golang.org/cl/219640: add NotifyContext to cancel context using system signals +
++ TODO: https://golang.org/cl/260637: flush ReverseProxy immediately if Content-Length is -1 +
++ TODO: https://golang.org/cl/260637: flush ReverseProxy immediately if Content-Length is -1 +
++go version go1.17.3 windows/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+set GO111MODULE= +set GOARCH=amd64 +set GOBIN= +set GOCACHE=C:\Users\heath\AppData\Local\go-build +set GOENV=C:\Users\heath\AppData\Roaming\go\env +set GOEXE=.exe +set GOEXPERIMENT= +set GOFLAGS= +set GOHOSTARCH=amd64 +set GOHOSTOS=windows +set GOINSECURE= +set GOMODCACHE=C:\Users\heath\go\pkg\mod +set GONOPROXY= +set GONOSUMDB= +set GOOS=windows +set GOPATH=C:\Users\heath\go +set GOPRIVATE= +set GOPROXY=https://proxy.golang.org,direct +set GOROOT=C:\Program Files\Go +set GOSUMDB=sum.golang.org +set GOTMPDIR= +set GOTOOLDIR=C:\Program Files\Go\pkg\tool\windows_amd64 +set GOVCS= +set GOVERSION=go1.17.3 +set GCCGO=gccgo +set AR=ar +set CC=gcc +set CXX=g++ +set CGO_ENABLED=1 +set GOMOD=NUL +set CGO_CFLAGS=-g -O2 +set CGO_CPPFLAGS= +set CGO_CXXFLAGS=-g -O2 +set CGO_FFLAGS=-g -O2 +set CGO_LDFLAGS=-g -O2 +set PKG_CONFIG=pkg-config +set GOGCCFLAGS=-m64 -mthreads -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=C:\Users\heath\AppData\Local\Temp\go-build4257983573=/tmp/go-build -gno-record-gcc-switches +
+go version go1.17.3 windows/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+set GO111MODULE= +set GOARCH=amd64 +set GOBIN= +set GOCACHE=C:\Users\heath\AppData\Local\go-build +set GOENV=C:\Users\heath\AppData\Roaming\go\env +set GOEXE=.exe +set GOEXPERIMENT= +set GOFLAGS= +set GOHOSTARCH=amd64 +set GOHOSTOS=windows +set GOINSECURE= +set GOMODCACHE=C:\Users\heath\go\pkg\mod +set GONOPROXY= +set GONOSUMDB= +set GOOS=windows +set GOPATH=C:\Users\heath\go +set GOPRIVATE= +set GOPROXY=https://proxy.golang.org,direct +set GOROOT=C:\Program Files\Go +set GOSUMDB=sum.golang.org +set GOTMPDIR= +set GOTOOLDIR=C:\Program Files\Go\pkg\tool\windows_amd64 +set GOVCS= +set GOVERSION=go1.17.3 +set GCCGO=gccgo +set AR=ar +set CC=gcc +set CXX=g++ +set CGO_ENABLED=1 +set GOMOD=NUL +set CGO_CFLAGS=-g -O2 +set CGO_CPPFLAGS= +set CGO_CXXFLAGS=-g -O2 +set CGO_FFLAGS=-g -O2 +set CGO_LDFLAGS=-g -O2 +set PKG_CONFIG=pkg-config +set GOGCCFLAGS=-m64 -mthreads -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=C:\Users\heath\AppData\Local\Temp\go-build4257983573=/tmp/go-build -gno-record-gcc-switches +
+go 1.13 + ++ +Documentation provides this example of `Unwrap` call https://github.com/golang/go/blob/master/src/errors/errors.go#L19. But this example wont work because `fmt.Errorf` returned `error` interface https://play.golang.org/p/KaQv-yJl6yy + +",1.0,"doc: errors: wrong unwrap example - + +### What version of Go are you using (`go version`)? + +
+go 1.13 + ++ +Documentation provides this example of `Unwrap` call https://github.com/golang/go/blob/master/src/errors/errors.go#L19. But this example wont work because `fmt.Errorf` returned `error` interface https://play.golang.org/p/KaQv-yJl6yy + +",1,doc errors wrong unwrap example what version of go are you using go version go documentation provides this example of unwrap call but this example wont work because fmt errorf returned error interface ,1 +97353,28210504181.0,IssuesEvent,2023-04-05 03:35:45,golang/go,https://api.github.com/repos/golang/go,closed,Testing packages.: unrecognized failures,Builders NeedsInvestigation,"``` +#!watchflakes +default <- repo == ""go"" && section == ""Testing packages."" && test == """" && !(log ~ `^Test "".*"" ran over .* limit`) +``` + +Issue created automatically to collect these failures. + +Example ([log](https://build.golang.org/log/95fa11f21bd73b56b217cfe4789cc65c57015c4d)): + + + +— [watchflakes](https://go.dev/wiki/Watchflakes) +",1.0,"Testing packages.: unrecognized failures - ``` +#!watchflakes +default <- repo == ""go"" && section == ""Testing packages."" && test == """" && !(log ~ `^Test "".*"" ran over .* limit`) +``` + +Issue created automatically to collect these failures. + +Example ([log](https://build.golang.org/log/95fa11f21bd73b56b217cfe4789cc65c57015c4d)): + + + +— [watchflakes](https://go.dev/wiki/Watchflakes) +",0,testing packages unrecognized failures watchflakes default repo go section testing packages test log test ran over limit issue created automatically to collect these failures example — ,0 +185385,15020920258.0,IssuesEvent,2021-02-01 15:14:49,golang/go,https://api.github.com/repos/golang/go,closed,x/website: tutorial function name typo,Documentation NeedsFix," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.15.7 ++ +### Does this issue reproduce with the latest release? + +This is not a 'Go' issue, but maybe a typo in the tutorial [Return greetings for multiple people](https://golang.org/doc/tutorial/greetings-multiple-people). + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +Windows , AMD Ryzen5 2600x +
+$ go version +go version go1.15.7 ++ +### Does this issue reproduce with the latest release? + +This is not a 'Go' issue, but maybe a typo in the tutorial [Return greetings for multiple people](https://golang.org/doc/tutorial/greetings-multiple-people). + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +Windows , AMD Ryzen5 2600x +
When writing to the http.ResponseWriter, the http.Response's method Write doesn't do
+what is expected.
+
+ func handler(w http.ResponseWriter, r *http.Request) {
+ resp, _ := client.Get("http://google.com/")
+ resp.Write(w)
+ }
+
+This will write resp's headers to the *body* of the handler's response, with the
+text/plain content type.
+
+A method that *copies* a Response would be helpful.",1.0,"net/http: clarify docs on ResponseWriter.Write and Response.Write - by **opennota**:
+
+When writing to the http.ResponseWriter, the http.Response's method Write doesn't do
+what is expected.
+
+ func handler(w http.ResponseWriter, r *http.Request) {
+ resp, _ := client.Get("http://google.com/")
+ resp.Write(w)
+ }
+
+This will write resp's headers to the *body* of the handler's response, with the
+text/plain content type.
+
+A method that *copies* a Response would be helpful.",1,net http clarify docs on responsewriter write and response write by opennota when writing to the http responsewriter the http response s method write doesn t do what is expected func handler w http responsewriter r http request resp client get quot a href resp write w this will write resp s headers to the body of the handler s response with the text plain content type a method that copies a response would be helpful ,1
+33114,6156817559.0,IssuesEvent,2017-06-28 17:34:19,golang/go,https://api.github.com/repos/golang/go,closed,spec: grammar mistake,Documentation,"> If map entries are created during iteration, that entry may be produced during the iteration or may be skipped.
+
+`map entries are` should be `a map entry is`.",1.0,"spec: grammar mistake - > If map entries are created during iteration, that entry may be produced during the iteration or may be skipped.
+
+`map entries are` should be `a map entry is`.",1,spec grammar mistake if map entries are created during iteration that entry may be produced during the iteration or may be skipped map entries are should be a map entry is ,1
+2239,2900205884.0,IssuesEvent,2015-06-17 15:21:30,golang/go,https://api.github.com/repos/golang/go,closed,x/build/builders: ARM builders,Builders,"This bug is about creating ARM qemu full-system-emulation environments for running Go +builds. This is part of http://golang.org/s/builderplan + +For ARM5, +The versatilepb machine (ARM5?) is quite slow can can run "make.bash" is about +25 minutes: +https://people.debian.org/~aurel32/qemu/armel/ + +We could cross-compile make.bash from x86 and just shard (a subset of?) run.bash on +qemu-system-arm -M versatilepb. + +For ARM7+, it seems qemu in recent versions supports newer CPUs and supports multiple +cores as well? That might help. + +In any case, this will be slow, and will depend on being able to shard tests out over +perhaps hundreds of CPUs (each running a full Linux kernel + tiny userspace which we +control, doing nothing but running our builders). + +It'd be nice if the tiny userspace running inside the qemu-system-arm ran Docker, so +then we'd have a snapshotting filesystem which we could send around the network, which +we'll want for sharding. + +We can use this bug to discuss and collect notes.",1.0,"x/build/builders: ARM builders -
This bug is about creating ARM qemu full-system-emulation environments for running Go +builds. This is part of http://golang.org/s/builderplan + +For ARM5, +The versatilepb machine (ARM5?) is quite slow can can run "make.bash" is about +25 minutes: +https://people.debian.org/~aurel32/qemu/armel/ + +We could cross-compile make.bash from x86 and just shard (a subset of?) run.bash on +qemu-system-arm -M versatilepb. + +For ARM7+, it seems qemu in recent versions supports newer CPUs and supports multiple +cores as well? That might help. + +In any case, this will be slow, and will depend on being able to shard tests out over +perhaps hundreds of CPUs (each running a full Linux kernel + tiny userspace which we +control, doing nothing but running our builders). + +It'd be nice if the tiny userspace running inside the qemu-system-arm ran Docker, so +then we'd have a snapshotting filesystem which we could send around the network, which +we'll want for sharding. + +We can use this bug to discuss and collect notes.",0,x build builders arm builders this bug is about creating arm qemu full system emulation environments for running go builds this is part of a href for the versatilepb machine is quite slow can can run quot make bash quot is about minutes a href we could cross compile make bash from and just shard a subset of run bash on qemu system arm m versatilepb for it seems qemu in recent versions supports newer cpus and supports multiple cores as well that might help in any case this will be slow and will depend on being able to shard tests out over perhaps hundreds of cpus each running a full linux kernel tiny userspace which we control doing nothing but running our builders it d be nice if the tiny userspace running inside the qemu system arm ran docker so then we d have a snapshotting filesystem which we could send around the network which we ll want for sharding we can use this bug to discuss and collect notes ,0 +307839,23219161876.0,IssuesEvent,2022-08-02 16:29:09,golang/go,https://api.github.com/repos/golang/go,closed,doc: write Go 1.19 release notes,Documentation NeedsFix umbrella,"Tracking bug for writing the Go 1.19 Release Notes. + +The latest state on tip can be viewed at https://tip.golang.org/doc/go1.19. + +When the Go 1.19 Release Notes are complete, this should be closed, and a similar issue should be made for the next release. Previous issues are #47694, https://github.com/golang/go/issues/44513, https://github.com/golang/go/issues/40700, https://github.com/golang/go/issues/37419, https://github.com/golang/go/issues/36878, https://github.com/golang/go/issues/17929, https://github.com/golang/go/issues/15810, https://github.com/golang/go/issues/5929, etc.",1.0,"doc: write Go 1.19 release notes - Tracking bug for writing the Go 1.19 Release Notes. + +The latest state on tip can be viewed at https://tip.golang.org/doc/go1.19. + +When the Go 1.19 Release Notes are complete, this should be closed, and a similar issue should be made for the next release. Previous issues are #47694, https://github.com/golang/go/issues/44513, https://github.com/golang/go/issues/40700, https://github.com/golang/go/issues/37419, https://github.com/golang/go/issues/36878, https://github.com/golang/go/issues/17929, https://github.com/golang/go/issues/15810, https://github.com/golang/go/issues/5929, etc.",1,doc write go release notes tracking bug for writing the go release notes the latest state on tip can be viewed at when the go release notes are complete this should be closed and a similar issue should be made for the next release previous issues are etc ,1 +136868,12736737203.0,IssuesEvent,2020-06-25 17:27:13,golang/go,https://api.github.com/repos/golang/go,closed,crypto/x509: documentation about SSL_CERT_FILE and SSL_CERT_DIR is incorrect,Documentation NeedsInvestigation," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.14 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN=""/Users/xxx/gopath/bin"" +GOCACHE=""/Users/xxx/Library/Caches/go-build"" +GOENV=""/Users/xxx/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/xxx/gopath"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/usr/local/go/src/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/2b/74fz3jhd4wz4vnbf4z7ywzww0000gp/T/go-build191944931=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ go version +go version go1.14 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN=""/Users/xxx/gopath/bin"" +GOCACHE=""/Users/xxx/Library/Caches/go-build"" +GOENV=""/Users/xxx/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/xxx/gopath"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/usr/local/go/src/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/2b/74fz3jhd4wz4vnbf4z7ywzww0000gp/T/go-build191944931=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ go version +go version go1.14.4 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +I believe go1.14.4 is the latest stable release, so yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/finnb/.cache/go-build"" +GOENV=""/home/finnb/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/finnb/go:/home/finnb/git/finnbear/mazean"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/snap/go/5830"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/snap/go/5830/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build362984802=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.14.4 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +I believe go1.14.4 is the latest stable release, so yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/finnb/.cache/go-build"" +GOENV=""/home/finnb/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/finnb/go:/home/finnb/git/finnbear/mazean"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/snap/go/5830"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/snap/go/5830/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build362984802=/tmp/go-build -gno-record-gcc-switches"" +
+https://go.dev/play/?v=gotip +devel go1.21-05293d6b49 Mon Jun 5 14:01:09 2023 +0000 ++ +### What did you do? + +https://go.dev/play/p/Sf_G8Lt9dHy?v=gotip + +``` + x := math.NaN() + y := math.Inf(-1) + + fmt.Println(min(x, y)) + fmt.Println(math.Min(x, y)) +``` +Reports different output. + +### What did you expect to see? + +I expected all output to be `NaN`. + +### What did you see instead? + +`min()`/`max()` are returning `NaN` and `math.Min()`/`math.Max()` are returning `-Inf`/`+Inf`. + +I think the output of the `math` versions is wrong as it should check for `NaN` before the infinities, but I don't have a copy of 754 right now and what min/max is under 754 is special (e.g. see minNum in IEEE 754-2008 vs. minimum & minimumNumber in IEEE 754-2019.",1.0,"math: Min()/Max() don't agree with builtin min()/max() - ### What version of Go are you using (`go version`)? + +
+https://go.dev/play/?v=gotip +devel go1.21-05293d6b49 Mon Jun 5 14:01:09 2023 +0000 ++ +### What did you do? + +https://go.dev/play/p/Sf_G8Lt9dHy?v=gotip + +``` + x := math.NaN() + y := math.Inf(-1) + + fmt.Println(min(x, y)) + fmt.Println(math.Min(x, y)) +``` +Reports different output. + +### What did you expect to see? + +I expected all output to be `NaN`. + +### What did you see instead? + +`min()`/`max()` are returning `NaN` and `math.Min()`/`math.Max()` are returning `-Inf`/`+Inf`. + +I think the output of the `math` versions is wrong as it should check for `NaN` before the infinities, but I don't have a copy of 754 right now and what min/max is under 754 is special (e.g. see minNum in IEEE 754-2008 vs. minimum & minimumNumber in IEEE 754-2019.",1,math min max don t agree with builtin min max what version of go are you using go version devel mon jun what did you do x math nan y math inf fmt println min x y fmt println math min x y reports different output what did you expect to see i expected all output to be nan what did you see instead min max are returning nan and math min math max are returning inf inf i think the output of the math versions is wrong as it should check for nan before the infinities but i don t have a copy of right now and what min max is under is special e g see minnum in ieee vs minimum minimumnumber in ieee ,1 +11042,3454718103.0,IssuesEvent,2015-12-17 16:59:58,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: docs are unclear that tests are run in parallel across packages,Documentation,"If you provide `go test` with more than one package, tests across packages are run in parallel by default (assuming you have more than one CPU). If you have tests across packages that contend for a singular resource (for example, listening on a particular TCP port) you can end up getting unexpected failures. + +The docs aren't very clear in this respect and I think some improvements can be made to them. This has bit me in the past and just came up again in the Gophers Slack community. In these cases we developers had to go to the `go` command's source code to understand what was happening. + +In my view, some of the issues: +* `go test --help` is equivalent to `go help testflag` rather than `go help test`. I tend to add `--help` by default and so I was seeing the wrong (IMO) help output. +* `go help testflag` mentions parallelism with its `-parallel` flag, but this only affects tests within a single package. The presence of this flag implies that tests that don't set `t.Parallel` will never be run in parallel, regardless of where they live. +* `go help testflag` does not mention `go help build` at all, and users might not be aware that all the flags there also apply to `go test`, in particular the `-p` flag. (`go help test` does mention build flags, however, which is good.) +* `go help build` mentions the `-p` flag, but it only talks about builds. It does not imply that the tests will also be run in parallel. I think most people assume that build and test are separate steps. I think it could also be cleaner that it's talking about packages specifically there. + +The core issue is that there are multiple levels of parallelism at play, and only one is mentioned in the test help.",1.0,"cmd/go: docs are unclear that tests are run in parallel across packages - If you provide `go test` with more than one package, tests across packages are run in parallel by default (assuming you have more than one CPU). If you have tests across packages that contend for a singular resource (for example, listening on a particular TCP port) you can end up getting unexpected failures. + +The docs aren't very clear in this respect and I think some improvements can be made to them. This has bit me in the past and just came up again in the Gophers Slack community. In these cases we developers had to go to the `go` command's source code to understand what was happening. + +In my view, some of the issues: +* `go test --help` is equivalent to `go help testflag` rather than `go help test`. I tend to add `--help` by default and so I was seeing the wrong (IMO) help output. +* `go help testflag` mentions parallelism with its `-parallel` flag, but this only affects tests within a single package. The presence of this flag implies that tests that don't set `t.Parallel` will never be run in parallel, regardless of where they live. +* `go help testflag` does not mention `go help build` at all, and users might not be aware that all the flags there also apply to `go test`, in particular the `-p` flag. (`go help test` does mention build flags, however, which is good.) +* `go help build` mentions the `-p` flag, but it only talks about builds. It does not imply that the tests will also be run in parallel. I think most people assume that build and test are separate steps. I think it could also be cleaner that it's talking about packages specifically there. + +The core issue is that there are multiple levels of parallelism at play, and only one is mentioned in the test help.",1,cmd go docs are unclear that tests are run in parallel across packages if you provide go test with more than one package tests across packages are run in parallel by default assuming you have more than one cpu if you have tests across packages that contend for a singular resource for example listening on a particular tcp port you can end up getting unexpected failures the docs aren t very clear in this respect and i think some improvements can be made to them this has bit me in the past and just came up again in the gophers slack community in these cases we developers had to go to the go command s source code to understand what was happening in my view some of the issues go test help is equivalent to go help testflag rather than go help test i tend to add help by default and so i was seeing the wrong imo help output go help testflag mentions parallelism with its parallel flag but this only affects tests within a single package the presence of this flag implies that tests that don t set t parallel will never be run in parallel regardless of where they live go help testflag does not mention go help build at all and users might not be aware that all the flags there also apply to go test in particular the p flag go help test does mention build flags however which is good go help build mentions the p flag but it only talks about builds it does not imply that the tests will also be run in parallel i think most people assume that build and test are separate steps i think it could also be cleaner that it s talking about packages specifically there the core issue is that there are multiple levels of parallelism at play and only one is mentioned in the test help ,1 +33024,6150475087.0,IssuesEvent,2017-06-27 22:42:12,golang/go,https://api.github.com/repos/golang/go,closed,cmd/compile: intermittent test failure on gonum suite with testing/quick,Documentation NeedsFix,"Please answer these questions before submitting your issue. Thanks! + +### What version of Go are you using (`go version`)? +go1.9beta2 (go version devel +eab99a8 Mon Jun 26 21:12:22 2017 +0000 darwin/amd64) + +I confirmed this bug does not exist in go1.8.3 + +### What operating system and processor architecture are you using (`go env`)? +brendan:~$ go env +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/brendan/Documents/othergo"" +GORACE="""" +GOROOT=""/Users/brendan/gover/go"" +GOTOOLDIR=""/Users/brendan/gover/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/l6/mhj4qjrj4437b_lgfz9pm1rw0000gn/T/go-build536430216=/tmp/go-build -gno-record-gcc-switches -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" + +### What did you do? + +```` +go get -u -t gonum.org/v1/gonum/blas/gonum +cd $GOPATH/src/gonum.org/v1/gonum/blas/gonum/internal/math32 +go test ./... +```` + +Approximately 1 in every 5 runs, this returns +```` +brendan:~/Documents/othergo/src/gonum.org/v1/gonum/blas/gonum/internal/math32$ go test +--- FAIL: TestHypot (0.00s) + math_test.go:46: #91: failed on input struct { X float32; Y float32 }{X:2.214908e+38, Y:-1.091827e+38} +FAIL +exit status 1 +```` + +I ran this ~20 times with go1.8.3, and never saw this test failure (plus, we've been running travis on all of our commits with go1.8.3 and have not seen this failure). + +The function in question, `math32.Hypot` calls `math32.Sqrt`, which is implemented in assembly. This can be disabled with the ""noasm"" tag, and the failure still occurs. +```` +brendan:~/Documents/othergo/src/gonum.org/v1/gonum/blas/gonum/internal/math32$ go test -tags=noasm +--- FAIL: TestHypot (0.00s) + math_test.go:46: #16: failed on input struct { X float32; Y float32 }{X:-1.917559e+38, Y:-3.838481e+36} +FAIL +exit status 1 +```` + +The release notes say there is a change to the `int64` and `uint64` random number generation, but as best as I can tell the source has not changed for `float32` generation. ",1.0,"cmd/compile: intermittent test failure on gonum suite with testing/quick - Please answer these questions before submitting your issue. Thanks! + +### What version of Go are you using (`go version`)? +go1.9beta2 (go version devel +eab99a8 Mon Jun 26 21:12:22 2017 +0000 darwin/amd64) + +I confirmed this bug does not exist in go1.8.3 + +### What operating system and processor architecture are you using (`go env`)? +brendan:~$ go env +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/brendan/Documents/othergo"" +GORACE="""" +GOROOT=""/Users/brendan/gover/go"" +GOTOOLDIR=""/Users/brendan/gover/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/l6/mhj4qjrj4437b_lgfz9pm1rw0000gn/T/go-build536430216=/tmp/go-build -gno-record-gcc-switches -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" + +### What did you do? + +```` +go get -u -t gonum.org/v1/gonum/blas/gonum +cd $GOPATH/src/gonum.org/v1/gonum/blas/gonum/internal/math32 +go test ./... +```` + +Approximately 1 in every 5 runs, this returns +```` +brendan:~/Documents/othergo/src/gonum.org/v1/gonum/blas/gonum/internal/math32$ go test +--- FAIL: TestHypot (0.00s) + math_test.go:46: #91: failed on input struct { X float32; Y float32 }{X:2.214908e+38, Y:-1.091827e+38} +FAIL +exit status 1 +```` + +I ran this ~20 times with go1.8.3, and never saw this test failure (plus, we've been running travis on all of our commits with go1.8.3 and have not seen this failure). + +The function in question, `math32.Hypot` calls `math32.Sqrt`, which is implemented in assembly. This can be disabled with the ""noasm"" tag, and the failure still occurs. +```` +brendan:~/Documents/othergo/src/gonum.org/v1/gonum/blas/gonum/internal/math32$ go test -tags=noasm +--- FAIL: TestHypot (0.00s) + math_test.go:46: #16: failed on input struct { X float32; Y float32 }{X:-1.917559e+38, Y:-3.838481e+36} +FAIL +exit status 1 +```` + +The release notes say there is a change to the `int64` and `uint64` random number generation, but as best as I can tell the source has not changed for `float32` generation. ",1,cmd compile intermittent test failure on gonum suite with testing quick please answer these questions before submitting your issue thanks what version of go are you using go version go version devel mon jun darwin i confirmed this bug does not exist in what operating system and processor architecture are you using go env brendan go env goarch gobin goexe gohostarch gohostos darwin goos darwin gopath users brendan documents othergo gorace goroot users brendan gover go gotooldir users brendan gover go pkg tool darwin gccgo gccgo cc clang gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map var folders t go tmp go build gno record gcc switches fno common cxx clang cgo enabled cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config what did you do go get u t gonum org gonum blas gonum cd gopath src gonum org gonum blas gonum internal go test approximately in every runs this returns brendan documents othergo src gonum org gonum blas gonum internal go test fail testhypot math test go failed on input struct x y x y fail exit status i ran this times with and never saw this test failure plus we ve been running travis on all of our commits with and have not seen this failure the function in question hypot calls sqrt which is implemented in assembly this can be disabled with the noasm tag and the failure still occurs brendan documents othergo src gonum org gonum blas gonum internal go test tags noasm fail testhypot math test go failed on input struct x y x y fail exit status the release notes say there is a change to the and random number generation but as best as i can tell the source has not changed for generation ,1 +24919,5111745995.0,IssuesEvent,2017-01-06 08:06:48,golang/go,https://api.github.com/repos/golang/go,opened,doc: explain vendoring,Documentation,"[How to Write Go Code](https://golang.org/doc/code.html#remote) should mention vendoring feature under ""Remote packages"" section. + +We also need to replace all the mentions of GO15VENDOREXPERIMENT on the wiki with the proper official document.",1.0,"doc: explain vendoring - [How to Write Go Code](https://golang.org/doc/code.html#remote) should mention vendoring feature under ""Remote packages"" section. + +We also need to replace all the mentions of GO15VENDOREXPERIMENT on the wiki with the proper official document.",1,doc explain vendoring should mention vendoring feature under remote packages section we also need to replace all the mentions of on the wiki with the proper official document ,1 +34264,6307134167.0,IssuesEvent,2017-07-21 23:26:50,golang/go,https://api.github.com/repos/golang/go,closed,doc: add VS Code editor guide,DevExp Documentation,"This is a tracking bug for https://github.com/golang/go/issues/20398 VSCode Go. + +The brief info card for VSCode Go: + +``` +VSCode Go +https://github.com/Microsoft/vscode-go + +An extension for VS Code which provides support for the Go language. + +Editing +Formatting on save (gofmt), automatic imports, identifier completion, vetting on save, linting on save. + +Navigation +Godoc lookup, jumping to definition and referrers, looking up for interface implementations, searching for callers and callees. + +Testing and Debugging +Running package tests, running single test case, generating test cases from package/file/function, Delve debugger integration. +``` + +The screencasts to be done: +- Linting on save +- Searching for callers and callees +- Running package tests +- Generating test cases",1.0,"doc: add VS Code editor guide - This is a tracking bug for https://github.com/golang/go/issues/20398 VSCode Go. + +The brief info card for VSCode Go: + +``` +VSCode Go +https://github.com/Microsoft/vscode-go + +An extension for VS Code which provides support for the Go language. + +Editing +Formatting on save (gofmt), automatic imports, identifier completion, vetting on save, linting on save. + +Navigation +Godoc lookup, jumping to definition and referrers, looking up for interface implementations, searching for callers and callees. + +Testing and Debugging +Running package tests, running single test case, generating test cases from package/file/function, Delve debugger integration. +``` + +The screencasts to be done: +- Linting on save +- Searching for callers and callees +- Running package tests +- Generating test cases",1,doc add vs code editor guide this is a tracking bug for vscode go the brief info card for vscode go vscode go an extension for vs code which provides support for the go language editing formatting on save gofmt automatic imports identifier completion vetting on save linting on save navigation godoc lookup jumping to definition and referrers looking up for interface implementations searching for callers and callees testing and debugging running package tests running single test case generating test cases from package file function delve debugger integration the screencasts to be done linting on save searching for callers and callees running package tests generating test cases,1 +61738,8554322590.0,IssuesEvent,2018-11-08 05:42:37,golang/go,https://api.github.com/repos/golang/go,closed,time: document that a marshaled time does not include location name,Documentation Proposal Proposal-Accepted help wanted,"As is, `time.Time` is not transmittable/storable on its own where it will preserve its location. All of the Marshal/Unmarshal implementations and all the supported string formats encode only the offset or the timezone abbreviation. When parsed or unmarshalled, you often end up with a `time.Time` in a fixed offset, rather than the original location. In particular, this can lead to unexpected results when performing some operations around Daylight Savings Time because the fixed offset `time.Time` may or may not observe DST when the original location-laden `time.Time` would have. Depending on the server location, it's also possible to end up applying DST when it shouldn't apply because of `time.Parse`'s behavior to use `time.Local` if the local offset matches the parsed timestamp. + +As a hallmark example of the problem here is to ask: what month will it be if you add 2840 hours to the reference time used for string formatting? See: https://play.golang.org/p/XQiDRKpKtSa + +Overall, this subtlety breaks assumptions that encoded timestamps convey all the information on the original `time.Time`, and that a decoded `time.Time` will behave consistently no matter where it's decoded. While a workaround is possible by always separately storing/transmitting the location string in addition to the timestamp, the time package could make that more transparent or at least alert users that the encode/decode may behave unexpectedly with regard to precise timezone rules. + +The proposal is to do one or more of the following options. Note that as the author here, my current thinking is option 2 plus option 5 would be the best way forward, but I've listed more possibilities for completeness. + +1. Add the IANA location to what `MarshalBinary` and `UnmarshalBinary` do + +This will allow `gob` to losslessly transmit timestamps that will behave the same after encoding/decoding. There are a couple considerations that may rule out this idea: + +- The change might be backward incompatible. I'm not sure if there are Go programs relying on the fact that currently the encoding format results in fixed-offset times after decode. +- The ""improved"" parser would still need to handle encoded data from before the change +- The IANA information might not be useful on systems that don't have tzdata (noting #21881) + + +2. Add a Format/Parse directive that includes the IANA location string + +This idea is less transparent than the Binary/Gob approach because it requires specifically using a format that includes location. This means it's backward compatible and introduces minimal additional API surface. This possibility still must tackle the problem of how to proceed on systems without available tzdata. + +3. Add an exported struct field to `time.Time` to toggle encoding behavior + +Because the current JSON/text encoding mechanisms for `time.Time` specify RFC3339, they cannot be changed outright to include the actual location. However, a field could be added to time.Time to alter the encoding behavior. Because the default state of this field could be to encode as the existing format, backward compatibility would be preserved. The decoding routines would need to account for all possible formats and could set that field as necessary. + +The two major downsides to this approach I can think of: + +- Additional memory required by `time.Time` objects +- That `==` comparisons would include this field, which seems beyond its intended purpose + +4. Break compatibility in Go2 and include the IANA location in all `Marshal`/`Unmarshal` encodings + +The big benefit here would be to make `time.Time`, as an implementation of package `encoding`'s interfaces, to be more true to those interfaces. While package `encoding` doesn't currently specify whether or not implementations must _completely_ represent the receiver's contents, one might assume they do since generally the process is often treated such that `x = decode(encode(x))`. + +5. Document this behavior + +It's worth warning people that existing encoding methods do not preserve the full location information and that if the program needs to do calendrical operations which may be affected by changes like DST, to transmit/store both the encoded `time.Time` and its location separately. In particular, since the docs don't specify any format or specifics about the data, one might assume the binary/Gob encoding preserves the full state of the `time.Time`, when it actually doesn't. While technically this fact is implied for the JSON/text encodings, it's probably a common misconception that the offset in RFC3339 adequately represents location via the offset. + +edit: added some formatting",1.0,"time: document that a marshaled time does not include location name - As is, `time.Time` is not transmittable/storable on its own where it will preserve its location. All of the Marshal/Unmarshal implementations and all the supported string formats encode only the offset or the timezone abbreviation. When parsed or unmarshalled, you often end up with a `time.Time` in a fixed offset, rather than the original location. In particular, this can lead to unexpected results when performing some operations around Daylight Savings Time because the fixed offset `time.Time` may or may not observe DST when the original location-laden `time.Time` would have. Depending on the server location, it's also possible to end up applying DST when it shouldn't apply because of `time.Parse`'s behavior to use `time.Local` if the local offset matches the parsed timestamp. + +As a hallmark example of the problem here is to ask: what month will it be if you add 2840 hours to the reference time used for string formatting? See: https://play.golang.org/p/XQiDRKpKtSa + +Overall, this subtlety breaks assumptions that encoded timestamps convey all the information on the original `time.Time`, and that a decoded `time.Time` will behave consistently no matter where it's decoded. While a workaround is possible by always separately storing/transmitting the location string in addition to the timestamp, the time package could make that more transparent or at least alert users that the encode/decode may behave unexpectedly with regard to precise timezone rules. + +The proposal is to do one or more of the following options. Note that as the author here, my current thinking is option 2 plus option 5 would be the best way forward, but I've listed more possibilities for completeness. + +1. Add the IANA location to what `MarshalBinary` and `UnmarshalBinary` do + +This will allow `gob` to losslessly transmit timestamps that will behave the same after encoding/decoding. There are a couple considerations that may rule out this idea: + +- The change might be backward incompatible. I'm not sure if there are Go programs relying on the fact that currently the encoding format results in fixed-offset times after decode. +- The ""improved"" parser would still need to handle encoded data from before the change +- The IANA information might not be useful on systems that don't have tzdata (noting #21881) + + +2. Add a Format/Parse directive that includes the IANA location string + +This idea is less transparent than the Binary/Gob approach because it requires specifically using a format that includes location. This means it's backward compatible and introduces minimal additional API surface. This possibility still must tackle the problem of how to proceed on systems without available tzdata. + +3. Add an exported struct field to `time.Time` to toggle encoding behavior + +Because the current JSON/text encoding mechanisms for `time.Time` specify RFC3339, they cannot be changed outright to include the actual location. However, a field could be added to time.Time to alter the encoding behavior. Because the default state of this field could be to encode as the existing format, backward compatibility would be preserved. The decoding routines would need to account for all possible formats and could set that field as necessary. + +The two major downsides to this approach I can think of: + +- Additional memory required by `time.Time` objects +- That `==` comparisons would include this field, which seems beyond its intended purpose + +4. Break compatibility in Go2 and include the IANA location in all `Marshal`/`Unmarshal` encodings + +The big benefit here would be to make `time.Time`, as an implementation of package `encoding`'s interfaces, to be more true to those interfaces. While package `encoding` doesn't currently specify whether or not implementations must _completely_ represent the receiver's contents, one might assume they do since generally the process is often treated such that `x = decode(encode(x))`. + +5. Document this behavior + +It's worth warning people that existing encoding methods do not preserve the full location information and that if the program needs to do calendrical operations which may be affected by changes like DST, to transmit/store both the encoded `time.Time` and its location separately. In particular, since the docs don't specify any format or specifics about the data, one might assume the binary/Gob encoding preserves the full state of the `time.Time`, when it actually doesn't. While technically this fact is implied for the JSON/text encodings, it's probably a common misconception that the offset in RFC3339 adequately represents location via the offset. + +edit: added some formatting",1,time document that a marshaled time does not include location name as is time time is not transmittable storable on its own where it will preserve its location all of the marshal unmarshal implementations and all the supported string formats encode only the offset or the timezone abbreviation when parsed or unmarshalled you often end up with a time time in a fixed offset rather than the original location in particular this can lead to unexpected results when performing some operations around daylight savings time because the fixed offset time time may or may not observe dst when the original location laden time time would have depending on the server location it s also possible to end up applying dst when it shouldn t apply because of time parse s behavior to use time local if the local offset matches the parsed timestamp as a hallmark example of the problem here is to ask what month will it be if you add hours to the reference time used for string formatting see overall this subtlety breaks assumptions that encoded timestamps convey all the information on the original time time and that a decoded time time will behave consistently no matter where it s decoded while a workaround is possible by always separately storing transmitting the location string in addition to the timestamp the time package could make that more transparent or at least alert users that the encode decode may behave unexpectedly with regard to precise timezone rules the proposal is to do one or more of the following options note that as the author here my current thinking is option plus option would be the best way forward but i ve listed more possibilities for completeness add the iana location to what marshalbinary and unmarshalbinary do this will allow gob to losslessly transmit timestamps that will behave the same after encoding decoding there are a couple considerations that may rule out this idea the change might be backward incompatible i m not sure if there are go programs relying on the fact that currently the encoding format results in fixed offset times after decode the improved parser would still need to handle encoded data from before the change the iana information might not be useful on systems that don t have tzdata noting add a format parse directive that includes the iana location string this idea is less transparent than the binary gob approach because it requires specifically using a format that includes location this means it s backward compatible and introduces minimal additional api surface this possibility still must tackle the problem of how to proceed on systems without available tzdata add an exported struct field to time time to toggle encoding behavior because the current json text encoding mechanisms for time time specify they cannot be changed outright to include the actual location however a field could be added to time time to alter the encoding behavior because the default state of this field could be to encode as the existing format backward compatibility would be preserved the decoding routines would need to account for all possible formats and could set that field as necessary the two major downsides to this approach i can think of additional memory required by time time objects that comparisons would include this field which seems beyond its intended purpose break compatibility in and include the iana location in all marshal unmarshal encodings the big benefit here would be to make time time as an implementation of package encoding s interfaces to be more true to those interfaces while package encoding doesn t currently specify whether or not implementations must completely represent the receiver s contents one might assume they do since generally the process is often treated such that x decode encode x document this behavior it s worth warning people that existing encoding methods do not preserve the full location information and that if the program needs to do calendrical operations which may be affected by changes like dst to transmit store both the encoded time time and its location separately in particular since the docs don t specify any format or specifics about the data one might assume the binary gob encoding preserves the full state of the time time when it actually doesn t while technically this fact is implied for the json text encodings it s probably a common misconception that the offset in adequately represents location via the offset edit added some formatting,1 +20058,4488308326.0,IssuesEvent,2016-08-30 06:40:11,golang/go,https://api.github.com/repos/golang/go,opened,doc: document assembly calling convention,Documentation,"We should probably specify the Go calling convention in doc/asm.html, at least to a degree. + +Might be especially useful as a reference when we get around to changing it. + +@cherrymui @dr2chase @nigeltao + +",1.0,"doc: document assembly calling convention - We should probably specify the Go calling convention in doc/asm.html, at least to a degree. + +Might be especially useful as a reference when we get around to changing it. + +@cherrymui @dr2chase @nigeltao + +",1,doc document assembly calling convention we should probably specify the go calling convention in doc asm html at least to a degree might be especially useful as a reference when we get around to changing it cherrymui nigeltao ,1 +54912,7930420940.0,IssuesEvent,2018-07-06 18:46:41,golang/go,https://api.github.com/repos/golang/go,closed,doc: update the Go faq about versioning,Documentation,"At the moment the Go faq says : + +https://golang.org/doc/faq#get_version + +> Work is underway on an experimental package management tool, dep, to learn more about how tooling can help package management. More information can be found in the dep FAQ. + +I believe it should be updated to mention `vgo`",1.0,"doc: update the Go faq about versioning - At the moment the Go faq says : + +https://golang.org/doc/faq#get_version + +> Work is underway on an experimental package management tool, dep, to learn more about how tooling can help package management. More information can be found in the dep FAQ. + +I believe it should be updated to mention `vgo`",1,doc update the go faq about versioning at the moment the go faq says work is underway on an experimental package management tool dep to learn more about how tooling can help package management more information can be found in the dep faq i believe it should be updated to mention vgo ,1 +39209,6730303586.0,IssuesEvent,2017-10-18 00:01:21,golang/go,https://api.github.com/repos/golang/go,closed,"spec: document package unsafe's path is ""unsafe""",Documentation NeedsFix,"The Go spec mentions package unsafe's package name is `unsafe`, but it never documents the package path that users can import to use it. Intuitively it's `""unsafe""`, but as package paths are formally distinct from package names, we should still explicitly document that.",1.0,"spec: document package unsafe's path is ""unsafe"" - The Go spec mentions package unsafe's package name is `unsafe`, but it never documents the package path that users can import to use it. Intuitively it's `""unsafe""`, but as package paths are formally distinct from package names, we should still explicitly document that.",1,spec document package unsafe s path is unsafe the go spec mentions package unsafe s package name is unsafe but it never documents the package path that users can import to use it intuitively it s unsafe but as package paths are formally distinct from package names we should still explicitly document that ,1 +28991,5560226550.0,IssuesEvent,2017-03-24 18:52:48,golang/go,https://api.github.com/repos/golang/go,closed,spec: does not cover the case where a map composite literal contains multiple copies of the same key at runtime,Documentation,"Please answer these questions before submitting your issue. Thanks! + +### What version of Go are you using (`go version`)? +[November 18, 2016](https://golang.org/ref/spec) + +### What operating system and processor architecture are you using (`go env`)? +N/A + +### What did you do? +The Go spec states ""For map literals, all elements must have a key. It is an error to specify multiple elements with the same field name or constant key value."", however, it is silent as to what happens whem multiple elements with the same non-constant key value are present, as in this link: https://play.golang.org/p/53kQ9rF8a2 + +As you can see, it appears that the later one wins in this example, but I don't know if this always holds.",1.0,"spec: does not cover the case where a map composite literal contains multiple copies of the same key at runtime - Please answer these questions before submitting your issue. Thanks! + +### What version of Go are you using (`go version`)? +[November 18, 2016](https://golang.org/ref/spec) + +### What operating system and processor architecture are you using (`go env`)? +N/A + +### What did you do? +The Go spec states ""For map literals, all elements must have a key. It is an error to specify multiple elements with the same field name or constant key value."", however, it is silent as to what happens whem multiple elements with the same non-constant key value are present, as in this link: https://play.golang.org/p/53kQ9rF8a2 + +As you can see, it appears that the later one wins in this example, but I don't know if this always holds.",1,spec does not cover the case where a map composite literal contains multiple copies of the same key at runtime please answer these questions before submitting your issue thanks what version of go are you using go version what operating system and processor architecture are you using go env n a what did you do the go spec states for map literals all elements must have a key it is an error to specify multiple elements with the same field name or constant key value however it is silent as to what happens whem multiple elements with the same non constant key value are present as in this link as you can see it appears that the later one wins in this example but i don t know if this always holds ,1 +89067,25572078865.0,IssuesEvent,2022-11-30 18:33:00,golang/go,https://api.github.com/repos/golang/go,closed,x/build/cmd/relui: create proof of concept for release automation,Builders NeedsFix,"As part of an effort to improve the reliability and reduce the complexity of Go releases, we should automate more of the release process. + +A possible solution is a hosted release management tool (relui) that is responsible for the scheduling and operating of the release, much as `releasebot` handles this process on the CLI. We can improve the observability of the process by using a persistent web UI for coordinating releases. + +As a proof of concept, relui acts as the coordinator (and currently the task executor) for release tasks. + +### Rough Architecture +For the proof of concept, there will be a single application for both starting and running workflows. However, careful API boundaries should be maintained between the scheduler process and the runner processes to allow for separation in the future. + +In general, the runner process should only know how to execute specific tasks without broader context, and report back to the scheduler. Tasks should have an associated type, and the runner should decide whether or not it has an implementation for a given task type. + +Tasks, or BuildableTasks, have a shared configuration. All tasks have a type, a name, an optional task name to depend on, and an artifact URL. If a task depends on another named task, it will be provided with that task's artifact URL upon starting. + +Finally, workflows should be described through a configuration, in order to allow us to share steps between workflows, and separate concerns between the implementation and the definition of all steps that must be completed for a release. This is especially important for steps that may need to run on different platforms (outside of our tooling on GCP, such as the signing process). + +### Rough initial workflow for a local workstation release: + +**Clone repo @ ref** +In: +- Repo +- Ref + +Out: +- Tarball of Go src +- Tarball URI + +**Run make.bash** +In: +- Tarball URI of Go Src +Out: +- Tarball URI of Go src after make + +**Build Race Detector** +In: +- Tarball URI of Go src after make +Out: +- Tarball URI of Go src after race build + +**Clean (version.cache, pkg/bootstrap, race for other GOOS/GOARCH, pkg/GOOS_GOOARCH/cmd)** +In: +- Tarball URI of Go src after race build +Out: +- Tarball URI of Go src after cleanup + +**Run all.bash** +In: +- Tarball URI of Go Src after cleanup +Out: +- Tarball URI of Go src after all.bash + +**Finalize** +In: +- Tarball URI of Go Src after cleanup (not all.bash) +Out: +- Tarball URI of binary release + +## Tasks (remaining as of 2020-10-05) + +- [ ] Subscribe to a PubSub Topic +- [ ] Publish status upon accepting a task +- [ ] Run FetchGitSource task +- [ ] Create Status API +- [ ] Datastore Integration + +### relworker + +#### (bootstrap worker) Subscribe to a PubSub Topic + +A worker can connect to PubSub and subscribe to the configured topic. Messages should be subscribed to using the [Receive API](https://pkg.go.dev/cloud.google.com/go/pubsub#Subscription.Receive), which handles spawning goroutines for handling the message, as well as auto-extending the Ack deadline while a message is being processed. + +For now, we can just log that we got the message,can handle it, and Ack it. + +See: https://pkg.go.dev/cloud.google.com/go/pubsub#Subscription.Receive + + +#### Publish status on accepting a task + +When the worker picks up a task, it should update the status of the task in relui as started. + + +#### Run FetchGitSource task + +The FetchGitSource task should fetch the specified Git repo at the configured ref. The source should be tarred, record the artifact URL to relui, and mark the task as complete. + +On gitiles, there is an +archive URL for this task: + +Web: https://go.googlesource.com/go/+archive/refs/heads/master + +Archive: https://go.googlesource.com/go/+archive/refs/heads/master.tar.gz + + +#### Handle non-transient errors on FetchGitSource + +If a permanent error occurs when executing a task, the message should be ACK’d to prevent retries, and a terminal status for the task should be reported back to relui. + + +### relui + + +#### Create Status API (gRPC server) + +A worker can communicate the status of a task back to the coordinator as it progresses on a task. The initial API should at least be able to mark a task as started. + +1. Host gRPC and HTTPS on the same port (with some caveats) + 1. See caveats here: https://github.com/grpc/grpc-go/issues/2662#issuecomment-468497692 +2. Host gRPC on same service but different port as HTTPS relui web +3. Use separate instances of relui for gRPC + + +#### Datastore integration + +Currently, relui commits state to disk. It should have a persistent database for handling multiple instances, like Datastore. + +/cc @dmitshur @cagedmantis @andybons + +",1.0,"x/build/cmd/relui: create proof of concept for release automation - As part of an effort to improve the reliability and reduce the complexity of Go releases, we should automate more of the release process. + +A possible solution is a hosted release management tool (relui) that is responsible for the scheduling and operating of the release, much as `releasebot` handles this process on the CLI. We can improve the observability of the process by using a persistent web UI for coordinating releases. + +As a proof of concept, relui acts as the coordinator (and currently the task executor) for release tasks. + +### Rough Architecture +For the proof of concept, there will be a single application for both starting and running workflows. However, careful API boundaries should be maintained between the scheduler process and the runner processes to allow for separation in the future. + +In general, the runner process should only know how to execute specific tasks without broader context, and report back to the scheduler. Tasks should have an associated type, and the runner should decide whether or not it has an implementation for a given task type. + +Tasks, or BuildableTasks, have a shared configuration. All tasks have a type, a name, an optional task name to depend on, and an artifact URL. If a task depends on another named task, it will be provided with that task's artifact URL upon starting. + +Finally, workflows should be described through a configuration, in order to allow us to share steps between workflows, and separate concerns between the implementation and the definition of all steps that must be completed for a release. This is especially important for steps that may need to run on different platforms (outside of our tooling on GCP, such as the signing process). + +### Rough initial workflow for a local workstation release: + +**Clone repo @ ref** +In: +- Repo +- Ref + +Out: +- Tarball of Go src +- Tarball URI + +**Run make.bash** +In: +- Tarball URI of Go Src +Out: +- Tarball URI of Go src after make + +**Build Race Detector** +In: +- Tarball URI of Go src after make +Out: +- Tarball URI of Go src after race build + +**Clean (version.cache, pkg/bootstrap, race for other GOOS/GOARCH, pkg/GOOS_GOOARCH/cmd)** +In: +- Tarball URI of Go src after race build +Out: +- Tarball URI of Go src after cleanup + +**Run all.bash** +In: +- Tarball URI of Go Src after cleanup +Out: +- Tarball URI of Go src after all.bash + +**Finalize** +In: +- Tarball URI of Go Src after cleanup (not all.bash) +Out: +- Tarball URI of binary release + +## Tasks (remaining as of 2020-10-05) + +- [ ] Subscribe to a PubSub Topic +- [ ] Publish status upon accepting a task +- [ ] Run FetchGitSource task +- [ ] Create Status API +- [ ] Datastore Integration + +### relworker + +#### (bootstrap worker) Subscribe to a PubSub Topic + +A worker can connect to PubSub and subscribe to the configured topic. Messages should be subscribed to using the [Receive API](https://pkg.go.dev/cloud.google.com/go/pubsub#Subscription.Receive), which handles spawning goroutines for handling the message, as well as auto-extending the Ack deadline while a message is being processed. + +For now, we can just log that we got the message,can handle it, and Ack it. + +See: https://pkg.go.dev/cloud.google.com/go/pubsub#Subscription.Receive + + +#### Publish status on accepting a task + +When the worker picks up a task, it should update the status of the task in relui as started. + + +#### Run FetchGitSource task + +The FetchGitSource task should fetch the specified Git repo at the configured ref. The source should be tarred, record the artifact URL to relui, and mark the task as complete. + +On gitiles, there is an +archive URL for this task: + +Web: https://go.googlesource.com/go/+archive/refs/heads/master + +Archive: https://go.googlesource.com/go/+archive/refs/heads/master.tar.gz + + +#### Handle non-transient errors on FetchGitSource + +If a permanent error occurs when executing a task, the message should be ACK’d to prevent retries, and a terminal status for the task should be reported back to relui. + + +### relui + + +#### Create Status API (gRPC server) + +A worker can communicate the status of a task back to the coordinator as it progresses on a task. The initial API should at least be able to mark a task as started. + +1. Host gRPC and HTTPS on the same port (with some caveats) + 1. See caveats here: https://github.com/grpc/grpc-go/issues/2662#issuecomment-468497692 +2. Host gRPC on same service but different port as HTTPS relui web +3. Use separate instances of relui for gRPC + + +#### Datastore integration + +Currently, relui commits state to disk. It should have a persistent database for handling multiple instances, like Datastore. + +/cc @dmitshur @cagedmantis @andybons + +",0,x build cmd relui create proof of concept for release automation as part of an effort to improve the reliability and reduce the complexity of go releases we should automate more of the release process a possible solution is a hosted release management tool relui that is responsible for the scheduling and operating of the release much as releasebot handles this process on the cli we can improve the observability of the process by using a persistent web ui for coordinating releases as a proof of concept relui acts as the coordinator and currently the task executor for release tasks rough architecture for the proof of concept there will be a single application for both starting and running workflows however careful api boundaries should be maintained between the scheduler process and the runner processes to allow for separation in the future in general the runner process should only know how to execute specific tasks without broader context and report back to the scheduler tasks should have an associated type and the runner should decide whether or not it has an implementation for a given task type tasks or buildabletasks have a shared configuration all tasks have a type a name an optional task name to depend on and an artifact url if a task depends on another named task it will be provided with that task s artifact url upon starting finally workflows should be described through a configuration in order to allow us to share steps between workflows and separate concerns between the implementation and the definition of all steps that must be completed for a release this is especially important for steps that may need to run on different platforms outside of our tooling on gcp such as the signing process rough initial workflow for a local workstation release clone repo ref in repo ref out tarball of go src tarball uri run make bash in tarball uri of go src out tarball uri of go src after make build race detector in tarball uri of go src after make out tarball uri of go src after race build clean version cache pkg bootstrap race for other goos goarch pkg goos gooarch cmd in tarball uri of go src after race build out tarball uri of go src after cleanup run all bash in tarball uri of go src after cleanup out tarball uri of go src after all bash finalize in tarball uri of go src after cleanup not all bash out tarball uri of binary release tasks remaining as of subscribe to a pubsub topic publish status upon accepting a task run fetchgitsource task create status api datastore integration relworker bootstrap worker subscribe to a pubsub topic a worker can connect to pubsub and subscribe to the configured topic messages should be subscribed to using the which handles spawning goroutines for handling the message as well as auto extending the ack deadline while a message is being processed for now we can just log that we got the message can handle it and ack it see publish status on accepting a task when the worker picks up a task it should update the status of the task in relui as started run fetchgitsource task the fetchgitsource task should fetch the specified git repo at the configured ref the source should be tarred record the artifact url to relui and mark the task as complete on gitiles there is an archive url for this task web archive handle non transient errors on fetchgitsource if a permanent error occurs when executing a task the message should be ack’d to prevent retries and a terminal status for the task should be reported back to relui relui create status api grpc server a worker can communicate the status of a task back to the coordinator as it progresses on a task the initial api should at least be able to mark a task as started host grpc and https on the same port with some caveats see caveats here host grpc on same service but different port as https relui web use separate instances of relui for grpc datastore integration currently relui commits state to disk it should have a persistent database for handling multiple instances like datastore cc dmitshur cagedmantis andybons ,0 +45100,7158495178.0,IssuesEvent,2018-01-27 01:13:00,golang/go,https://api.github.com/repos/golang/go,closed,os: document that StartProcess inherits the caller's thread state,Documentation,"One of the new features of the Go 1.10 runtime is that `LockOSThread` can be used to reliably modify OS thread state. One of the main points of doing this was to make it possible to start a new process with a modified thread state, but right now we don't document that new processes created with, e.g., `os.StartProcess` will actually inherit the caller's thread state. This has [led to confusion](https://github.com/golang/go/issues/20395#issuecomment-360810662) and we should document this.",1.0,"os: document that StartProcess inherits the caller's thread state - One of the new features of the Go 1.10 runtime is that `LockOSThread` can be used to reliably modify OS thread state. One of the main points of doing this was to make it possible to start a new process with a modified thread state, but right now we don't document that new processes created with, e.g., `os.StartProcess` will actually inherit the caller's thread state. This has [led to confusion](https://github.com/golang/go/issues/20395#issuecomment-360810662) and we should document this.",1,os document that startprocess inherits the caller s thread state one of the new features of the go runtime is that lockosthread can be used to reliably modify os thread state one of the main points of doing this was to make it possible to start a new process with a modified thread state but right now we don t document that new processes created with e g os startprocess will actually inherit the caller s thread state this has and we should document this ,1 +219252,16823886235.0,IssuesEvent,2021-06-17 15:58:56,golang/go,https://api.github.com/repos/golang/go,closed,"cmd/go: on malformed ""go mod edit -go"", suggest current version of go, not hardcoded 1.12",Documentation NeedsFix help wanted modules," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version devel +0f897f916a Tue May 28 02:52:39 2019 +0000 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +n/a, `go mod edit` suggests `-go 1.12` on go1.12.5. + +### What did you do? + + + +I wasn't sure if there was a way to `go mod edit` to put the `go 1.12` directive in the ""right"" place in 1.12, prior to #31960 on tip, so I ran with a garbage argument to `-go`. This command has the same output in 1.12 and tip: + +``` +$ go mod edit -go=x +go mod: invalid -go option; expecting something like ""-go 1.12"" +``` + +### What did you expect to see? + +I expected the output to suggest `-go 1.13` when running with tip. + +### What did you see instead? + +It suggested `-go 1.12`, which seems odd given that I am running what is going to be 1.13. + +I suppose there's an argument to suggest 1.12 as a ""downgrading"" case when go.mod already provides `go 1.13`, but the argument to use `-go 1.13` to upgrade from a `go 1.12` in go.mod seems just as valid.",1.0,"cmd/go: on malformed ""go mod edit -go"", suggest current version of go, not hardcoded 1.12 - + +### What version of Go are you using (`go version`)? + +
+$ go version +go version devel +0f897f916a Tue May 28 02:52:39 2019 +0000 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +n/a, `go mod edit` suggests `-go 1.12` on go1.12.5. + +### What did you do? + + + +I wasn't sure if there was a way to `go mod edit` to put the `go 1.12` directive in the ""right"" place in 1.12, prior to #31960 on tip, so I ran with a garbage argument to `-go`. This command has the same output in 1.12 and tip: + +``` +$ go mod edit -go=x +go mod: invalid -go option; expecting something like ""-go 1.12"" +``` + +### What did you expect to see? + +I expected the output to suggest `-go 1.13` when running with tip. + +### What did you see instead? + +It suggested `-go 1.12`, which seems odd given that I am running what is going to be 1.13. + +I suppose there's an argument to suggest 1.12 as a ""downgrading"" case when go.mod already provides `go 1.13`, but the argument to use `-go 1.13` to upgrade from a `go 1.12` in go.mod seems just as valid.",1,cmd go on malformed go mod edit go suggest current version of go not hardcoded what version of go are you using go version go version go version devel tue may darwin does this issue reproduce with the latest release n a go mod edit suggests go on what did you do if possible provide a recipe for reproducing the error a complete runnable program is good a link on play golang org is best i wasn t sure if there was a way to go mod edit to put the go directive in the right place in prior to on tip so i ran with a garbage argument to go this command has the same output in and tip go mod edit go x go mod invalid go option expecting something like go what did you expect to see i expected the output to suggest go when running with tip what did you see instead it suggested go which seems odd given that i am running what is going to be i suppose there s an argument to suggest as a downgrading case when go mod already provides go but the argument to use go to upgrade from a go in go mod seems just as valid ,1 +20660,6910073803.0,IssuesEvent,2017-11-28 00:11:15,golang/go,https://api.github.com/repos/golang/go,opened,x/build: FreeBSD images don't shut down nicely,Builders HelpWanted OS-FreeBSD,"I noticed while testing my images for #19303 and #22854 that our FreeBSD images (at least 10.3) don't have shutdown in their path: + +``` +2017/11/28 00:06:26 About to hit http://10.240.0.22 to see if buildlet is up yet... +2017/11/28 00:06:27 buildlet probe: 200 OK +2017/11/28 00:06:27 WorkDir: /tmp/workdir,
+$ go version +go version go1.20.5 darwin/arm64 ++ +### Does this issue reproduce at the latest version of golang.org/x/vuln? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +
+$ go version +go version go1.20.5 darwin/arm64 ++ +### Does this issue reproduce at the latest version of golang.org/x/vuln? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env + +
+$ go version +go version go1.17.1 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Reproduces with + +
+$ gotip version +go version devel go1.18-771b8ea4f4c Sun Sep 19 02:43:09 2021 +0000 linux/amd64 ++ +### What operating system and processor architecture are you using (`go env`)? + +
+GOARCH=arm64 ++ +### What did you do? + +```go +func rotxor1(x, y uint64) uint64 { + y = (y << 7) | (y >> 57) + return x ^ y +} + +func rotxor2(x, y uint64) uint64 { + return x ^ bits.RotateLeft64(y, 7) +} +``` + +### What did you expect to see? + +Would have been nice to see a fused rotate-xor (#48002), but at least the generated asm should be the same. + +### What did you see instead? + +For rotxor1: + + MOVD """".y+8(FP), R0 + ROR $57, R0, R0 + MOVD """".x(FP), R1 + EOR R0, R1, R0 + +For rotxor2: + + MOVD """".y+8(FP), R0 + MOVD $-7, R1 + ROR R1, R0, R0 + MOVD """".x(FP), R1 + EOR R0, R1, R0 + +The compiler inserts a mov and allocates a register for the shift constant when the intrinsic is used. This is a regression introduced in Go 1.12. It's not limited to these tiny functions: I spotted this when inspecting the generated asm for SipHash.",True,"cmd/compile: suboptimal bits.Rotate* on arm64 - ### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.17.1 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Reproduces with + +
+$ gotip version +go version devel go1.18-771b8ea4f4c Sun Sep 19 02:43:09 2021 +0000 linux/amd64 ++ +### What operating system and processor architecture are you using (`go env`)? + +
+GOARCH=arm64 ++ +### What did you do? + +```go +func rotxor1(x, y uint64) uint64 { + y = (y << 7) | (y >> 57) + return x ^ y +} + +func rotxor2(x, y uint64) uint64 { + return x ^ bits.RotateLeft64(y, 7) +} +``` + +### What did you expect to see? + +Would have been nice to see a fused rotate-xor (#48002), but at least the generated asm should be the same. + +### What did you see instead? + +For rotxor1: + + MOVD """".y+8(FP), R0 + ROR $57, R0, R0 + MOVD """".x(FP), R1 + EOR R0, R1, R0 + +For rotxor2: + + MOVD """".y+8(FP), R0 + MOVD $-7, R1 + ROR R1, R0, R0 + MOVD """".x(FP), R1 + EOR R0, R1, R0 + +The compiler inserts a mov and allocates a register for the shift constant when the intrinsic is used. This is a regression introduced in Go 1.12. It's not limited to these tiny functions: I spotted this when inspecting the generated asm for SipHash.",0,cmd compile suboptimal bits rotate on what version of go are you using go version go version go version linux does this issue reproduce with the latest release reproduces with gotip version go version devel sun sep linux what operating system and processor architecture are you using go env goarch what did you do go func x y y y return x y func x y return x bits y what did you expect to see would have been nice to see a fused rotate xor but at least the generated asm should be the same what did you see instead for movd y fp ror movd x fp eor for movd y fp movd ror movd x fp eor the compiler inserts a mov and allocates a register for the shift constant when the intrinsic is used this is a regression introduced in go it s not limited to these tiny functions i spotted this when inspecting the generated asm for siphash ,0 +94104,27114348085.0,IssuesEvent,2023-02-15 17:25:15,golang/go,https://api.github.com/repos/golang/go,closed,x/build: `linux-arm.*-aws` TryBots are often stragglers,Builders NeedsInvestigation,"On several CLs lately, I've seen nearly all of the builders complete within 10 minutes or so, but the `linux-arm-aws` and `linux-arm64-aws` TryBots always seem to take 15 minutes or more. + +It appears that these builders aren't currently sharded at all: +https://cs.opensource.google/go/x/build/+/master:dashboard/builders.go;l=2417;drc=9ca9dc28e477c63197a65122b31a98146c49d07d +https://cs.opensource.google/go/x/build/+/master:dashboard/builders.go;l=2434;drc=9ca9dc28e477c63197a65122b31a98146c49d07d + +Is there something we can do to bring the latency for these builders up to par with the other TryBots? (Perhaps enable sharding?) + +(CC @prattmic, who I think has done some recent latency measurements)",1.0,"x/build: `linux-arm.*-aws` TryBots are often stragglers - On several CLs lately, I've seen nearly all of the builders complete within 10 minutes or so, but the `linux-arm-aws` and `linux-arm64-aws` TryBots always seem to take 15 minutes or more. + +It appears that these builders aren't currently sharded at all: +https://cs.opensource.google/go/x/build/+/master:dashboard/builders.go;l=2417;drc=9ca9dc28e477c63197a65122b31a98146c49d07d +https://cs.opensource.google/go/x/build/+/master:dashboard/builders.go;l=2434;drc=9ca9dc28e477c63197a65122b31a98146c49d07d + +Is there something we can do to bring the latency for these builders up to par with the other TryBots? (Perhaps enable sharding?) + +(CC @prattmic, who I think has done some recent latency measurements)",0,x build linux arm aws trybots are often stragglers on several cls lately i ve seen nearly all of the builders complete within minutes or so but the linux arm aws and linux aws trybots always seem to take minutes or more it appears that these builders aren t currently sharded at all is there something we can do to bring the latency for these builders up to par with the other trybots perhaps enable sharding cc prattmic who i think has done some recent latency measurements ,0 +3403,2762330881.0,IssuesEvent,2015-04-28 22:00:15,golang/go,https://api.github.com/repos/golang/go,closed,net/http: No easy way to get a server-side Request for testing.,Documentation,"(net/http).Request is populated vastly differently on the client and server sides. +That's probably not fixable, given Go1 compatibility. + +But it causes problems when testing http handlers - httptest.ResponseRecorder needs a Request to go with it, and the obvious candidate (http.NewRequest) generates the client-side version, not the server-side version. + +You can get the server-side version by setting up an httptest.Server and making a request to it, but that involves a lot of boilerplate and some syscalls. + +It would be nice if there were a way (in the http or httptest package) to get a Request in the server-side format without having to go through the whole HTTP stack with a real server. + +",1.0,"net/http: No easy way to get a server-side Request for testing. - (net/http).Request is populated vastly differently on the client and server sides. +That's probably not fixable, given Go1 compatibility. + +But it causes problems when testing http handlers - httptest.ResponseRecorder needs a Request to go with it, and the obvious candidate (http.NewRequest) generates the client-side version, not the server-side version. + +You can get the server-side version by setting up an httptest.Server and making a request to it, but that involves a lot of boilerplate and some syscalls. + +It would be nice if there were a way (in the http or httptest package) to get a Request in the server-side format without having to go through the whole HTTP stack with a real server. + +",1,net http no easy way to get a server side request for testing net http request is populated vastly differently on the client and server sides that s probably not fixable given compatibility but it causes problems when testing http handlers httptest responserecorder needs a request to go with it and the obvious candidate http newrequest generates the client side version not the server side version you can get the server side version by setting up an httptest server and making a request to it but that involves a lot of boilerplate and some syscalls it would be nice if there were a way in the http or httptest package to get a request in the server side format without having to go through the whole http stack with a real server ,1 +256512,19425201120.0,IssuesEvent,2021-12-21 03:55:10,golang/go,https://api.github.com/repos/golang/go,closed,net/http: broken link to ResponseWriter trailers example,Documentation NeedsFix," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.17.3 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/reilly/Library/Caches/go-build"" +GOENV=""/Users/reilly/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/reilly/go/pkg/mod"" +GONOPROXY=""github.com/EverlongProject"" +GONOSUMDB=""github.com/EverlongProject"" +GOOS=""darwin"" +GOPATH=""/Users/reilly/go"" +GOPRIVATE=""github.com/EverlongProject"" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GOVCS="""" +GOVERSION=""go1.17.3"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/gz/4ytqr0r12q1fbx8ct_w3k_880000gn/T/go-build2936231312=/tmp/go-build -gno-record-gcc-switches -fno-common"" +GOROOT/bin/go version: go version go1.17.3 darwin/amd64 +GOROOT/bin/go tool compile -V: compile version go1.17.3 +uname -v: Darwin Kernel Version 21.2.0: Sun Nov 28 20:28:54 PST 2021; root:xnu-8019.61.5~1/RELEASE_X86_64 +ProductName: macOS +ProductVersion: 12.1 +BuildVersion: 21C52 +lldb --version: lldb-1300.0.42.3 +Swift version 5.5.2-dev +
+$ go version +go version go1.17.3 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/reilly/Library/Caches/go-build"" +GOENV=""/Users/reilly/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/reilly/go/pkg/mod"" +GONOPROXY=""github.com/EverlongProject"" +GONOSUMDB=""github.com/EverlongProject"" +GOOS=""darwin"" +GOPATH=""/Users/reilly/go"" +GOPRIVATE=""github.com/EverlongProject"" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GOVCS="""" +GOVERSION=""go1.17.3"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/gz/4ytqr0r12q1fbx8ct_w3k_880000gn/T/go-build2936231312=/tmp/go-build -gno-record-gcc-switches -fno-common"" +GOROOT/bin/go version: go version go1.17.3 darwin/amd64 +GOROOT/bin/go tool compile -V: compile version go1.17.3 +uname -v: Darwin Kernel Version 21.2.0: Sun Nov 28 20:28:54 PST 2021; root:xnu-8019.61.5~1/RELEASE_X86_64 +ProductName: macOS +ProductVersion: 12.1 +BuildVersion: 21C52 +lldb --version: lldb-1300.0.42.3 +Swift version 5.5.2-dev +
+$ go version +go version go1.14.2 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What did you do? + +Read the documentation for [`strings.FieldsFunc`](https://golang.org/pkg/strings/#FieldsFunc) + +### What did you see? + +I see that the documentation is out of date with respect to the following note. + +> FieldsFunc makes no guarantees about the order in which it calls f(c). If f does +not return consistent results for a given c, FieldsFunc may crash. + +This was appropriate when `FieldsForFunc` was using a two-pass logic. However, when the function was optimized to address #19789, this note is not correct anymore. The new implementation does only one-pass over the input. Hence, we can safely remove this note. +",1.0,"strings, bytes: divergent documentation for FieldsFunc functions - ### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.14.2 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What did you do? + +Read the documentation for [`strings.FieldsFunc`](https://golang.org/pkg/strings/#FieldsFunc) + +### What did you see? + +I see that the documentation is out of date with respect to the following note. + +> FieldsFunc makes no guarantees about the order in which it calls f(c). If f does +not return consistent results for a given c, FieldsFunc may crash. + +This was appropriate when `FieldsForFunc` was using a two-pass logic. However, when the function was optimized to address #19789, this note is not correct anymore. The new implementation does only one-pass over the input. Hence, we can safely remove this note. +",1,strings bytes divergent documentation for fieldsfunc functions what version of go are you using go version go version go version linux does this issue reproduce with the latest release yes what did you do read the documentation for what did you see i see that the documentation is out of date with respect to the following note fieldsfunc makes no guarantees about the order in which it calls f c if f does not return consistent results for a given c fieldsfunc may crash this was appropriate when fieldsforfunc was using a two pass logic however when the function was optimized to address this note is not correct anymore the new implementation does only one pass over the input hence we can safely remove this note ,1 +81733,10255495303.0,IssuesEvent,2019-08-21 15:31:54,golang/go,https://api.github.com/repos/golang/go,closed,x/website: documents link is not aligned on tip.golang.org/doc/go1.6+,Documentation NeedsFix help wanted,"### What did you do? +visit one of: +https://tip.golang.org/doc/go1.6 +... +https://tip.golang.org/doc/go1.13 + +### What did you expect to see? +see behavior on everything pre go1.6 docs + +### What did you see instead? + + +",1.0,"x/website: documents link is not aligned on tip.golang.org/doc/go1.6+ - ### What did you do? +visit one of: +https://tip.golang.org/doc/go1.6 +... +https://tip.golang.org/doc/go1.13 + +### What did you expect to see? +see behavior on everything pre go1.6 docs + +### What did you see instead? + + +",1,x website documents link is not aligned on tip golang org doc what did you do visit one of what did you expect to see see behavior on everything pre docs what did you see instead ,1 +30369,8526642622.0,IssuesEvent,2018-11-02 16:53:21,golang/go,https://api.github.com/repos/golang/go,closed,x/build: trybots not running due to maintner resource temporarily unavailable errors,Builders,"Trybots aren't running because maintner isn't noticing that there's new stuff on Gerrit, due to: + +``` +2018/02/02 20:07:17 Temporary error from gerrit go.googlesource.com/example: running git remote -v in /cache/go.googlesource.com%2Fexample: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 gerrit go.googlesource.com/time: init: running git remote -v in /cache/go.googlesource.com%2Ftime: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Ftime: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 Temporary error from gerrit go.googlesource.com/time: running git remote -v in /cache/go.googlesource.com%2Ftime: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 gerrit go.googlesource.com/build: init: running git remote -v in /cache/go.googlesource.com%2Fbuild: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Fbuild: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 Temporary error from gerrit go.googlesource.com/build: running git remote -v in /cache/go.googlesource.com%2Fbuild: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 gerrit code.googlesource.com/gocloud: init: running git remote -v in /cache/code.googlesource.com%2Fgocloud: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/code.googlesource.com%2Fgocloud: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 Temporary error from gerrit code.googlesource.com/gocloud: running git remote -v in /cache/code.googlesource.com%2Fgocloud: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:19 gerrit go.googlesource.com/gddo: init: running git remote -v in /cache/go.googlesource.com%2Fgddo: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:19 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Fgddo: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:19 Temporary error from gerrit go.googlesource.com/gddo: running git remote -v in /cache/go.googlesource.com%2Fgddo: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 gerrit go.googlesource.com/scratch: init: running git remote -v in /cache/go.googlesource.com%2Fscratch: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Fscratch: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 Temporary error from gerrit go.googlesource.com/scratch: running git remote -v in /cache/go.googlesource.com%2Fscratch: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 gerrit go.googlesource.com/proposal: init: running git remote -v in /cache/go.googlesource.com%2Fproposal: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Fproposal: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 Temporary error from gerrit go.googlesource.com/proposal: running git remote -v in /cache/go.googlesource.com%2Fproposal: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 gerrit go.googlesource.com/tour: init: running git remote -v in /cache/go.googlesource.com%2Ftour: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Ftour: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 Temporary error from gerrit go.googlesource.com/tour: running git remote -v in /cache/go.googlesource.com%2Ftour: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:21 gerrit go.googlesource.com/oauth2: init: running git remote -v in /cache/go.googlesource.com%2Foauth2: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:21 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Foauth2: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:21 Temporary error from gerrit go.googlesource.com/oauth2: running git remote -v in /cache/go.googlesource.com%2Foauth2: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:21 gerrit go.googlesource.com/exp: init: running git remote -v in /cache/go.googlesource.com%2Fexp: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:21 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Fexp: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:21 Temporary error from gerrit go.googlesource.com/exp: running git remote -v in /cache/go.googlesource.com%2Fexp: fork/exec /usr/bin/git: resource temporarily unavailable^C +``` + +This smells just like #23686 in a different binary. + +Both of these were just updated for the LetsEncrypt ACME changes. + +So what changed in the meantime? + +What resource isn't available? + +/cc @andybons @ianlancetaylor ",1.0,"x/build: trybots not running due to maintner resource temporarily unavailable errors - Trybots aren't running because maintner isn't noticing that there's new stuff on Gerrit, due to: + +``` +2018/02/02 20:07:17 Temporary error from gerrit go.googlesource.com/example: running git remote -v in /cache/go.googlesource.com%2Fexample: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 gerrit go.googlesource.com/time: init: running git remote -v in /cache/go.googlesource.com%2Ftime: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Ftime: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 Temporary error from gerrit go.googlesource.com/time: running git remote -v in /cache/go.googlesource.com%2Ftime: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 gerrit go.googlesource.com/build: init: running git remote -v in /cache/go.googlesource.com%2Fbuild: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Fbuild: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 Temporary error from gerrit go.googlesource.com/build: running git remote -v in /cache/go.googlesource.com%2Fbuild: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 gerrit code.googlesource.com/gocloud: init: running git remote -v in /cache/code.googlesource.com%2Fgocloud: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/code.googlesource.com%2Fgocloud: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:18 Temporary error from gerrit code.googlesource.com/gocloud: running git remote -v in /cache/code.googlesource.com%2Fgocloud: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:19 gerrit go.googlesource.com/gddo: init: running git remote -v in /cache/go.googlesource.com%2Fgddo: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:19 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Fgddo: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:19 Temporary error from gerrit go.googlesource.com/gddo: running git remote -v in /cache/go.googlesource.com%2Fgddo: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 gerrit go.googlesource.com/scratch: init: running git remote -v in /cache/go.googlesource.com%2Fscratch: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Fscratch: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 Temporary error from gerrit go.googlesource.com/scratch: running git remote -v in /cache/go.googlesource.com%2Fscratch: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 gerrit go.googlesource.com/proposal: init: running git remote -v in /cache/go.googlesource.com%2Fproposal: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Fproposal: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 Temporary error from gerrit go.googlesource.com/proposal: running git remote -v in /cache/go.googlesource.com%2Fproposal: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 gerrit go.googlesource.com/tour: init: running git remote -v in /cache/go.googlesource.com%2Ftour: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Ftour: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:20 Temporary error from gerrit go.googlesource.com/tour: running git remote -v in /cache/go.googlesource.com%2Ftour: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:21 gerrit go.googlesource.com/oauth2: init: running git remote -v in /cache/go.googlesource.com%2Foauth2: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:21 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Foauth2: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:21 Temporary error from gerrit go.googlesource.com/oauth2: running git remote -v in /cache/go.googlesource.com%2Foauth2: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:21 gerrit go.googlesource.com/exp: init: running git remote -v in /cache/go.googlesource.com%2Fexp: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:21 IS TEMP ERROR? *errors.errorString running git remote -v in /cache/go.googlesource.com%2Fexp: fork/exec /usr/bin/git: resource temporarily unavailable +2018/02/02 20:07:21 Temporary error from gerrit go.googlesource.com/exp: running git remote -v in /cache/go.googlesource.com%2Fexp: fork/exec /usr/bin/git: resource temporarily unavailable^C +``` + +This smells just like #23686 in a different binary. + +Both of these were just updated for the LetsEncrypt ACME changes. + +So what changed in the meantime? + +What resource isn't available? + +/cc @andybons @ianlancetaylor ",0,x build trybots not running due to maintner resource temporarily unavailable errors trybots aren t running because maintner isn t noticing that there s new stuff on gerrit due to temporary error from gerrit go googlesource com example running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable gerrit go googlesource com time init running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable is temp error errors errorstring running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable temporary error from gerrit go googlesource com time running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable gerrit go googlesource com build init running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable is temp error errors errorstring running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable temporary error from gerrit go googlesource com build running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable gerrit code googlesource com gocloud init running git remote v in cache code googlesource com fork exec usr bin git resource temporarily unavailable is temp error errors errorstring running git remote v in cache code googlesource com fork exec usr bin git resource temporarily unavailable temporary error from gerrit code googlesource com gocloud running git remote v in cache code googlesource com fork exec usr bin git resource temporarily unavailable gerrit go googlesource com gddo init running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable is temp error errors errorstring running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable temporary error from gerrit go googlesource com gddo running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable gerrit go googlesource com scratch init running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable is temp error errors errorstring running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable temporary error from gerrit go googlesource com scratch running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable gerrit go googlesource com proposal init running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable is temp error errors errorstring running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable temporary error from gerrit go googlesource com proposal running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable gerrit go googlesource com tour init running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable is temp error errors errorstring running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable temporary error from gerrit go googlesource com tour running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable gerrit go googlesource com init running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable is temp error errors errorstring running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable temporary error from gerrit go googlesource com running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable gerrit go googlesource com exp init running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable is temp error errors errorstring running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable temporary error from gerrit go googlesource com exp running git remote v in cache go googlesource com fork exec usr bin git resource temporarily unavailable c this smells just like in a different binary both of these were just updated for the letsencrypt acme changes so what changed in the meantime what resource isn t available cc andybons ianlancetaylor ,0 +264940,20049473500.0,IssuesEvent,2022-02-03 03:21:56,golang/go,https://api.github.com/repos/golang/go,closed,"net/netip: ParsePrefix documentation typo ""2001::db8::/32""",Documentation NeedsFix," + +### What version of Go are you using (`go version`)? + +
+$ go version +go1.18beta2 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +Not applicable + +### What did you do? + +Read docs/code + +### What did you expect to see? + +Valid CIDR notation + +### What did you see instead? + +Invalid CIDR notation + +""2001::db8::/32"" includes an invalid IPv6 address. The double colon may appear only once. This code panics: + +
+package main
+
+import (
+ ""net/netip""
+)
+
+// This playground uses a development build of Go:
+// devel go1.18-41f485b9a7 Mon Jan 31 13:43:52 2022 +0000
+
+func main() {
+ _ = netip.MustParsePrefix(""2001::db8::/32"")
+}
+
+
+https://github.com/golang/go/blob/41f485b9a7d8fd647c415be1d11b612063dff21c/src/net/netip/netip.go#L1291
+",1.0,"net/netip: ParsePrefix documentation typo ""2001::db8::/32"" -
+
+### What version of Go are you using (`go version`)?
+
++$ go version +go1.18beta2 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +Not applicable + +### What did you do? + +Read docs/code + +### What did you expect to see? + +Valid CIDR notation + +### What did you see instead? + +Invalid CIDR notation + +""2001::db8::/32"" includes an invalid IPv6 address. The double colon may appear only once. This code panics: + +
+package main
+
+import (
+ ""net/netip""
+)
+
+// This playground uses a development build of Go:
+// devel go1.18-41f485b9a7 Mon Jan 31 13:43:52 2022 +0000
+
+func main() {
+ _ = netip.MustParsePrefix(""2001::db8::/32"")
+}
+
+
+https://github.com/golang/go/blob/41f485b9a7d8fd647c415be1d11b612063dff21c/src/net/netip/netip.go#L1291
+",1,net netip parseprefix documentation typo please answer these questions before submitting your issue thanks what version of go are you using go version go version does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env not applicable what did you do read docs code what did you expect to see valid cidr notation what did you see instead invalid cidr notation includes an invalid address the double colon may appear only once this code panics package main import net netip this playground uses a development build of go devel mon jan func main netip mustparseprefix ,1
+111723,9539999734.0,IssuesEvent,2019-04-30 18:22:35,golang/go,https://api.github.com/repos/golang/go,closed,"encoding/gob: test frequently failing with ""signal: killed"" in longtest builder",NeedsInvestigation Soon Testing release-blocker,"The `encoding/gob` test is frequently failing in the `longtest` builder with output like:
+
+```
+signal: killed
+FAIL encoding/gob 13.202s
+```
+
+(That's the entire output.)
+
+First example I saw was in https://build.golang.org/log/608043bae4b6ccc72e79f266fd92fa51410517b1, but the failure mode doesn't obviously relate to the associated CL (https://golang.org/cl/172418).
+
+I haven't been able to replicate the failure locally so far. I don't know whether the failure is due to recent changes in the compiler (@mdempsky, @cuonglm) or in `cmd/go` (myself and @jayconrod).
+
+The transition from passing to failure was partially masked by #31263.",1.0,"encoding/gob: test frequently failing with ""signal: killed"" in longtest builder - The `encoding/gob` test is frequently failing in the `longtest` builder with output like:
+
+```
+signal: killed
+FAIL encoding/gob 13.202s
+```
+
+(That's the entire output.)
+
+First example I saw was in https://build.golang.org/log/608043bae4b6ccc72e79f266fd92fa51410517b1, but the failure mode doesn't obviously relate to the associated CL (https://golang.org/cl/172418).
+
+I haven't been able to replicate the failure locally so far. I don't know whether the failure is due to recent changes in the compiler (@mdempsky, @cuonglm) or in `cmd/go` (myself and @jayconrod).
+
+The transition from passing to failure was partially masked by #31263.",0,encoding gob test frequently failing with signal killed in longtest builder the encoding gob test is frequently failing in the longtest builder with output like signal killed fail encoding gob that s the entire output first example i saw was in but the failure mode doesn t obviously relate to the associated cl i haven t been able to replicate the failure locally so far i don t know whether the failure is due to recent changes in the compiler mdempsky cuonglm or in cmd go myself and jayconrod the transition from passing to failure was partially masked by ,0
+84561,7926455140.0,IssuesEvent,2018-07-06 02:14:23,golang/go,https://api.github.com/repos/golang/go,closed,net/http: TestServerShutdownStateNew is flaky,NeedsFix Testing,"Two recent failures on linux-amd64-longtest:
+
+https://build.golang.org/log/ef73c0ec3463104a804cba25d4b550a403db26b9
+https://build.golang.org/log/6e2a1f6b524c1c8d2f794bce1bae272c87a62ef7
+
+```
+--- FAIL: TestServerShutdownStateNew (2.00s)
+ serve_test.go:5603: shutdown too soon after 49.41µs
+ serve_test.go:5617: timeout waiting for Read to unblock
+FAIL
+FAIL net/http 37.294s
+```
+
+The test accepts shutdowns between 0.5x and 1.5x the expected amount, which is 5s. The result of not even a millisecond seems to point that the test completely breaks, as opposed to this being a timing issue. Looking into it.
+
+/cc @bradfitz ",1.0,"net/http: TestServerShutdownStateNew is flaky - Two recent failures on linux-amd64-longtest:
+
+https://build.golang.org/log/ef73c0ec3463104a804cba25d4b550a403db26b9
+https://build.golang.org/log/6e2a1f6b524c1c8d2f794bce1bae272c87a62ef7
+
+```
+--- FAIL: TestServerShutdownStateNew (2.00s)
+ serve_test.go:5603: shutdown too soon after 49.41µs
+ serve_test.go:5617: timeout waiting for Read to unblock
+FAIL
+FAIL net/http 37.294s
+```
+
+The test accepts shutdowns between 0.5x and 1.5x the expected amount, which is 5s. The result of not even a millisecond seems to point that the test completely breaks, as opposed to this being a timing issue. Looking into it.
+
+/cc @bradfitz ",0,net http testservershutdownstatenew is flaky two recent failures on linux longtest fail testservershutdownstatenew serve test go shutdown too soon after serve test go timeout waiting for read to unblock fail fail net http the test accepts shutdowns between and the expected amount which is the result of not even a millisecond seems to point that the test completely breaks as opposed to this being a timing issue looking into it cc bradfitz ,0
+193595,15381051584.0,IssuesEvent,2021-03-02 22:02:12,golang/go,https://api.github.com/repos/golang/go,closed,x/website: various mistakes in documentation on modules,Documentation NeedsFix,"I read the new documentation on modules (which is great, btw) and took notes of mistakes I encountered.
+
+https://golang.org/doc/modules/gomod-ref
+
+1. Contradiction: The description for 'replacement-path' says:
+
+ ""[...] If this is a module path, you must specify a \_replacement-version\_ value. [...]""
+ But the following example shows the replacement of a module path without a replacement version value:
+ ""`replace example.com/othermodule => example.com/myfork/othermodule`""
+
+2. Section 'exclude', description of 'module-version"":
+
+ ""If this version number is omitted, all versions of the module are replaced with the content on the right side of the arrow.""
+
+ But an 'exclude' directive doesn't have an arrow. This sentence seems to be copy&pasted from the 'replace' directive and wrong.
+
+3. Contradiction:
+
+ ""These directives are ignored in modules that depend on the current module.""
+ vs. later
+ ""These directives are ignored in modules that are dependencies of the current module.""
+ Which one is it?
+
+4. Formatting: In the first example one line is not correctly indented.
+
+5. Formatting: ""\_replacement-version\_"", ""\_replacement-path\_"". The underscores are probably not intended, but unsupported Markdown syntax.
+
+https://golang.org/doc/tutorial/create-module
+
+6. ""This tutorial's sequence includes six brief topics [...]""
+
+ Followed by a numbered list of seven topics. s/six/seven/
+
+https://golang.org/doc/tutorial/call-module-code
+
+7. Broken link: ""Here, the replace directive [...]""
+
+8. Broken tutorial: ""In the hello directory, run go build to make Go locate the module and add it as a dependency to the go.mod file.""
+
+ Starting with Go 1.16 'go build' doesn't add dependencies anymore, which breaks this tutorial (similar to #43672).
+
+https://golang.org/doc/tutorial/getting-started
+
+9. Outdated description: ""3. On the Doc tab, under Index, [...]""
+
+ The former Doc tab is a menu item named 'Documentation' on the left side now.
+
+https://golang.org/doc/modules/managing-dependencies
+
+
+10. Broken link: ""See package discovery.""
+
+11. Typo: ""One you've discovered"" s/One/Once/
+
+https://golang.org/doc/modules/version-numbers
+
+12. Typo: ""For more, see Managingdependencies."" (missing space)
+
+https://golang.org/doc/modules/publishing
+
+13. Typo: ""6. [...] with 1nformation about [...]""
+
+ s/1nformation/information/
+
+14. Broken links: ""go get command"" (twice)
+
+ here: ""[ ... ] and run the go get command [...]"",
+ and here: ""They can run the go get command [...]
+
+https://golang.org/doc/modules/major-version
+
+15. Invalid syntax:
+
+ ""Old import statement: `import example.com/mymodule/package1`
+ New import statement: `import example.com/mymodule/v2/package1`""
+
+ Package paths must be in quotes.
+
+General
+
+16. The anchors on most pages under doc/modules have temporary names: #tmp_0, #tmp_1, etc.
+
+",1.0,"x/website: various mistakes in documentation on modules - I read the new documentation on modules (which is great, btw) and took notes of mistakes I encountered.
+
+https://golang.org/doc/modules/gomod-ref
+
+1. Contradiction: The description for 'replacement-path' says:
+
+ ""[...] If this is a module path, you must specify a \_replacement-version\_ value. [...]""
+ But the following example shows the replacement of a module path without a replacement version value:
+ ""`replace example.com/othermodule => example.com/myfork/othermodule`""
+
+2. Section 'exclude', description of 'module-version"":
+
+ ""If this version number is omitted, all versions of the module are replaced with the content on the right side of the arrow.""
+
+ But an 'exclude' directive doesn't have an arrow. This sentence seems to be copy&pasted from the 'replace' directive and wrong.
+
+3. Contradiction:
+
+ ""These directives are ignored in modules that depend on the current module.""
+ vs. later
+ ""These directives are ignored in modules that are dependencies of the current module.""
+ Which one is it?
+
+4. Formatting: In the first example one line is not correctly indented.
+
+5. Formatting: ""\_replacement-version\_"", ""\_replacement-path\_"". The underscores are probably not intended, but unsupported Markdown syntax.
+
+https://golang.org/doc/tutorial/create-module
+
+6. ""This tutorial's sequence includes six brief topics [...]""
+
+ Followed by a numbered list of seven topics. s/six/seven/
+
+https://golang.org/doc/tutorial/call-module-code
+
+7. Broken link: ""Here, the replace directive [...]""
+
+8. Broken tutorial: ""In the hello directory, run go build to make Go locate the module and add it as a dependency to the go.mod file.""
+
+ Starting with Go 1.16 'go build' doesn't add dependencies anymore, which breaks this tutorial (similar to #43672).
+
+https://golang.org/doc/tutorial/getting-started
+
+9. Outdated description: ""3. On the Doc tab, under Index, [...]""
+
+ The former Doc tab is a menu item named 'Documentation' on the left side now.
+
+https://golang.org/doc/modules/managing-dependencies
+
+
+10. Broken link: ""See package discovery.""
+
+11. Typo: ""One you've discovered"" s/One/Once/
+
+https://golang.org/doc/modules/version-numbers
+
+12. Typo: ""For more, see Managingdependencies."" (missing space)
+
+https://golang.org/doc/modules/publishing
+
+13. Typo: ""6. [...] with 1nformation about [...]""
+
+ s/1nformation/information/
+
+14. Broken links: ""go get command"" (twice)
+
+ here: ""[ ... ] and run the go get command [...]"",
+ and here: ""They can run the go get command [...]
+
+https://golang.org/doc/modules/major-version
+
+15. Invalid syntax:
+
+ ""Old import statement: `import example.com/mymodule/package1`
+ New import statement: `import example.com/mymodule/v2/package1`""
+
+ Package paths must be in quotes.
+
+General
+
+16. The anchors on most pages under doc/modules have temporary names: #tmp_0, #tmp_1, etc.
+
+",1,x website various mistakes in documentation on modules i read the new documentation on modules which is great btw and took notes of mistakes i encountered contradiction the description for replacement path says if this is a module path you must specify a replacement version value but the following example shows the replacement of a module path without a replacement version value replace example com othermodule example com myfork othermodule section exclude description of module version if this version number is omitted all versions of the module are replaced with the content on the right side of the arrow but an exclude directive doesn t have an arrow this sentence seems to be copy pasted from the replace directive and wrong contradiction these directives are ignored in modules that depend on the current module vs later these directives are ignored in modules that are dependencies of the current module which one is it formatting in the first example one line is not correctly indented formatting replacement version replacement path the underscores are probably not intended but unsupported markdown syntax this tutorial s sequence includes six brief topics followed by a numbered list of seven topics s six seven broken link here the replace directive broken tutorial in the hello directory run go build to make go locate the module and add it as a dependency to the go mod file starting with go go build doesn t add dependencies anymore which breaks this tutorial similar to outdated description on the doc tab under index the former doc tab is a menu item named documentation on the left side now broken link see package discovery typo one you ve discovered s one once typo for more see managingdependencies missing space typo with about s information broken links go get command twice here and run the go get command and here they can run the go get command invalid syntax old import statement import example com mymodule new import statement import example com mymodule package paths must be in quotes general the anchors on most pages under doc modules have temporary names tmp tmp etc ,1
+57036,8137873918.0,IssuesEvent,2018-08-20 13:14:43,golang/go,https://api.github.com/repos/golang/go,closed,net/http: imprecise description of the return values of HTTP serve functions,Documentation,"### What version of Go are you using (`go version`)?
+
+go version go1.10.3 darwin/amd64
+
+In `net.http` package, there are following fucntions/methods related to serve HTTP:
+
+1. [http.Serve](https://golang.org/pkg/net/http/#Serve)
+1. [http.ListenAndServe](https://golang.org/pkg/net/http/#ListenAndServe)
+1. [http.ListenAndServeTLS](https://golang.org/pkg/net/http/#ListenAndServeTLS)
+1. [http.Server.Serve](https://golang.org/pkg/net/http/#Server.Serve)
+1. [http.Server.ListenAndServe](https://golang.org/pkg/net/http/#Server.ListenAndServe)
+1. [http.Server.ListenAndServeTLS](https://golang.org/pkg/net/http/#Server.ListenAndServeTLS)
+
+Except the first one, all docs for those functiosn/methods say something like `always returns a non-nil error`. But if such a function/method is terminated by a signal which is a common way to terminate a HTTP server, it will not return. For example, consider the following go code `http.go`:
+
+```go
+package main
+
+import (
+ ""log""
+ ""net/http""
+)
+
+func main() {
+ var srv http.Server
+ srv.Addr = "":12345""
+
+ if err := srv.ListenAndServe(); err != http.ErrServerClosed {
+ log.Printf(""http error: %s"", err)
+ }
+}
+```
+
+A `SIGINT` signal will terminate the program and `http.ListenAndServe` will not return.
+```
+➜ local go run http.go
+^Csignal: interrupt
+```
+Only if `srv` is teriminated by [Server.Shutdown](https://golang.org/pkg/net/http/#Server.Shutdown), ` srv.ListenAndServe` will return.
+
+I think that the descripion `always returns a non-nil error` should mention this behaviour. Otherwise, people will tend to write [the following code](https://github.com/coreos/etcd/blob/master/contrib/raftexample/raft.go#L467):
+
+```go
+ err = (&http.Server{Handler: rc.transport.Handler()}).Serve(ln)
+ select {
+ case <-rc.httpstopc:
+ default:
+ log.Fatalf(""raftexample: Failed to serve rafthttp (%v)"", err)
+ }
+```
+They are hoping that `Serve` will return. But it will not since `Shutdown` is not used in a way descripted in `Shutdown`'s example code.
+
+
+",1.0,"net/http: imprecise description of the return values of HTTP serve functions - ### What version of Go are you using (`go version`)?
+
+go version go1.10.3 darwin/amd64
+
+In `net.http` package, there are following fucntions/methods related to serve HTTP:
+
+1. [http.Serve](https://golang.org/pkg/net/http/#Serve)
+1. [http.ListenAndServe](https://golang.org/pkg/net/http/#ListenAndServe)
+1. [http.ListenAndServeTLS](https://golang.org/pkg/net/http/#ListenAndServeTLS)
+1. [http.Server.Serve](https://golang.org/pkg/net/http/#Server.Serve)
+1. [http.Server.ListenAndServe](https://golang.org/pkg/net/http/#Server.ListenAndServe)
+1. [http.Server.ListenAndServeTLS](https://golang.org/pkg/net/http/#Server.ListenAndServeTLS)
+
+Except the first one, all docs for those functiosn/methods say something like `always returns a non-nil error`. But if such a function/method is terminated by a signal which is a common way to terminate a HTTP server, it will not return. For example, consider the following go code `http.go`:
+
+```go
+package main
+
+import (
+ ""log""
+ ""net/http""
+)
+
+func main() {
+ var srv http.Server
+ srv.Addr = "":12345""
+
+ if err := srv.ListenAndServe(); err != http.ErrServerClosed {
+ log.Printf(""http error: %s"", err)
+ }
+}
+```
+
+A `SIGINT` signal will terminate the program and `http.ListenAndServe` will not return.
+```
+➜ local go run http.go
+^Csignal: interrupt
+```
+Only if `srv` is teriminated by [Server.Shutdown](https://golang.org/pkg/net/http/#Server.Shutdown), ` srv.ListenAndServe` will return.
+
+I think that the descripion `always returns a non-nil error` should mention this behaviour. Otherwise, people will tend to write [the following code](https://github.com/coreos/etcd/blob/master/contrib/raftexample/raft.go#L467):
+
+```go
+ err = (&http.Server{Handler: rc.transport.Handler()}).Serve(ln)
+ select {
+ case <-rc.httpstopc:
+ default:
+ log.Fatalf(""raftexample: Failed to serve rafthttp (%v)"", err)
+ }
+```
+They are hoping that `Serve` will return. But it will not since `Shutdown` is not used in a way descripted in `Shutdown`'s example code.
+
+
+",1,net http imprecise description of the return values of http serve functions what version of go are you using go version go version darwin in net http package there are following fucntions methods related to serve http except the first one all docs for those functiosn methods say something like always returns a non nil error but if such a function method is terminated by a signal which is a common way to terminate a http server it will not return for example consider the following go code http go go package main import log net http func main var srv http server srv addr if err srv listenandserve err http errserverclosed log printf http error s err a sigint signal will terminate the program and http listenandserve will not return ➜ local go run http go csignal interrupt only if srv is teriminated by srv listenandserve will return i think that the descripion always returns a non nil error should mention this behaviour otherwise people will tend to write go err http server handler rc transport handler serve ln select case rc httpstopc default log fatalf raftexample failed to serve rafthttp v err they are hoping that serve will return but it will not since shutdown is not used in a way descripted in shutdown s example code ,1
+52208,7752878849.0,IssuesEvent,2018-05-30 21:48:36,golang/go,https://api.github.com/repos/golang/go,closed,blog: one sentence typo of blog go-maps-in-action,Documentation NeedsFix help wanted,"in blog
+
+https://blog.golang.org/go-maps-in-action
+
+section `Iteration order`
+
+>When iterating over a map with a range loop, the iteration order is not specified and is not guaranteed to be the same from one iteration to the next. Since Go 1 the runtime randomizes map iteration order, as programmers relied on the stable iteration order of the previous implementation. If you require a stable iteration order you must maintain a separate data structure that specifies that order. This example uses a separate sorted slice of keys to print a map[int]string in key order:
+
+may be the sentence should be below
+
+```
+Since Go in the runtime randomizes map iteration order
+```",1.0,"blog: one sentence typo of blog go-maps-in-action - in blog
+
+https://blog.golang.org/go-maps-in-action
+
+section `Iteration order`
+
+>When iterating over a map with a range loop, the iteration order is not specified and is not guaranteed to be the same from one iteration to the next. Since Go 1 the runtime randomizes map iteration order, as programmers relied on the stable iteration order of the previous implementation. If you require a stable iteration order you must maintain a separate data structure that specifies that order. This example uses a separate sorted slice of keys to print a map[int]string in key order:
+
+may be the sentence should be below
+
+```
+Since Go in the runtime randomizes map iteration order
+```",1,blog one sentence typo of blog go maps in action in blog section iteration order when iterating over a map with a range loop the iteration order is not specified and is not guaranteed to be the same from one iteration to the next since go the runtime randomizes map iteration order as programmers relied on the stable iteration order of the previous implementation if you require a stable iteration order you must maintain a separate data structure that specifies that order this example uses a separate sorted slice of keys to print a map string in key order may be the sentence should be below since go in the runtime randomizes map iteration order ,1
+350441,24985036169.0,IssuesEvent,2022-11-02 14:30:44,golang/go,https://api.github.com/repos/golang/go,closed,doc: add guidelines for comment directives,Documentation NeedsInvestigation Tools,"This issue shares some resemblance with https://github.com/golang/go/issues/13560. It is about properly documenting a pretty widespread convention regarding comment text.
+
+In Go, `//go:` is reserved for the Go toolchain. This is documented at https://golang.org/cmd/compile/.
+
+It is unofficially encouraged that other Go tools use a similar ""namespace"" prefix for their comment directives. For example, `//gccgo:` or `//llgo:` for other compilers, `//lint:` for staticcheck, `//go-sumtype:` for another tool, and so on. See https://groups.google.com/g/golang-dev/c/r4rdPdsH1Fg/m/tNZazPenX5cJ, as well as those two tools or others for examples out in the wild.
+
+I think we should more formally define what this format should look like, so that one can programmatically tell if a comment line is a directive. For example, one could imagine `^[a-z-]+:` as a regular expression.
+
+This would help tools which use directives be more consistent, as well as tools which want to inspect all comments and directives in source code. For example, gofumpt does this now, and it [takes some effort](https://github.com/mvdan/gofumpt/blob/eb0da8cc37e367dd519fd5ce98361f758a8b0508/format/format.go#L213-L225) to tell if a comment is a directive.
+
+I don't really mind where this is documented, as long as it's somewhere relatively authoritative. The wording doesn't have to be strong - after all, a Go comment can contain any plaintext. But it should still encourage tools to follow the format, for the sake of consistency.",1.0,"doc: add guidelines for comment directives - This issue shares some resemblance with https://github.com/golang/go/issues/13560. It is about properly documenting a pretty widespread convention regarding comment text.
+
+In Go, `//go:` is reserved for the Go toolchain. This is documented at https://golang.org/cmd/compile/.
+
+It is unofficially encouraged that other Go tools use a similar ""namespace"" prefix for their comment directives. For example, `//gccgo:` or `//llgo:` for other compilers, `//lint:` for staticcheck, `//go-sumtype:` for another tool, and so on. See https://groups.google.com/g/golang-dev/c/r4rdPdsH1Fg/m/tNZazPenX5cJ, as well as those two tools or others for examples out in the wild.
+
+I think we should more formally define what this format should look like, so that one can programmatically tell if a comment line is a directive. For example, one could imagine `^[a-z-]+:` as a regular expression.
+
+This would help tools which use directives be more consistent, as well as tools which want to inspect all comments and directives in source code. For example, gofumpt does this now, and it [takes some effort](https://github.com/mvdan/gofumpt/blob/eb0da8cc37e367dd519fd5ce98361f758a8b0508/format/format.go#L213-L225) to tell if a comment is a directive.
+
+I don't really mind where this is documented, as long as it's somewhere relatively authoritative. The wording doesn't have to be strong - after all, a Go comment can contain any plaintext. But it should still encourage tools to follow the format, for the sake of consistency.",1,doc add guidelines for comment directives this issue shares some resemblance with it is about properly documenting a pretty widespread convention regarding comment text in go go is reserved for the go toolchain this is documented at it is unofficially encouraged that other go tools use a similar namespace prefix for their comment directives for example gccgo or llgo for other compilers lint for staticcheck go sumtype for another tool and so on see as well as those two tools or others for examples out in the wild i think we should more formally define what this format should look like so that one can programmatically tell if a comment line is a directive for example one could imagine as a regular expression this would help tools which use directives be more consistent as well as tools which want to inspect all comments and directives in source code for example gofumpt does this now and it to tell if a comment is a directive i don t really mind where this is documented as long as it s somewhere relatively authoritative the wording doesn t have to be strong after all a go comment can contain any plaintext but it should still encourage tools to follow the format for the sake of consistency ,1
+49548,26202662882.0,IssuesEvent,2023-01-03 19:04:19,golang/go,https://api.github.com/repos/golang/go,closed,x/net/http2: WINDOW_UPDATE sent rate too high and can't be configured,Performance help wanted NeedsFix,"### What version of Go are you using (`go version`)?
+
+golang:1.10.0 linux
+
+### Does this issue reproduce with the latest release?
+
+Yes
+
+### What operating system and processor architecture are you using (`go env`)?
+
+container: rhel
+kubenet:
+
+### What did you do?
+
+Currently golang http2 stack will send WINDOW_UPDATE back when receive a request with data.
+It means a client will recevie a response and WINDOW_UPDATE when it send a request with data to golang http2 server.
+sent one 'request' package and got two 'reponse' package, that will impact client performance in a high load traffic.
+In fact, golang stack use 2^31 as default window size for connection. It is very big and updated too frequently is unnecessary.
+
+### What did you expect to see?
+
+Change this behavior or make it configurable like other language http2 stack.
+I think c++/java popular http2 stack have a configurable rate (default is 50%) used for sending WINDOS_UPDATE frame when the rate of left size/total is less than it.
+
+### What did you see instead?
+
+",True,"x/net/http2: WINDOW_UPDATE sent rate too high and can't be configured - ### What version of Go are you using (`go version`)?
+
+golang:1.10.0 linux
+
+### Does this issue reproduce with the latest release?
+
+Yes
+
+### What operating system and processor architecture are you using (`go env`)?
+
+container: rhel
+kubenet:
+
+### What did you do?
+
+Currently golang http2 stack will send WINDOW_UPDATE back when receive a request with data.
+It means a client will recevie a response and WINDOW_UPDATE when it send a request with data to golang http2 server.
+sent one 'request' package and got two 'reponse' package, that will impact client performance in a high load traffic.
+In fact, golang stack use 2^31 as default window size for connection. It is very big and updated too frequently is unnecessary.
+
+### What did you expect to see?
+
+Change this behavior or make it configurable like other language http2 stack.
+I think c++/java popular http2 stack have a configurable rate (default is 50%) used for sending WINDOS_UPDATE frame when the rate of left size/total is less than it.
+
+### What did you see instead?
+
+",0,x net window update sent rate too high and can t be configured what version of go are you using go version golang linux does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env container rhel kubenet what did you do currently golang stack will send window update back when receive a request with data it means a client will recevie a response and window update when it send a request with data to golang server sent one request package and got two reponse package that will impact client performance in a high load traffic in fact golang stack use as default window size for connection it is very big and updated too frequently is unnecessary what did you expect to see change this behavior or make it configurable like other language stack i think c java popular stack have a configurable rate default is used for sending windos update frame when the rate of left size total is less than it what did you see instead ,0
+35089,6412119574.0,IssuesEvent,2017-08-08 01:48:27,golang/go,https://api.github.com/repos/golang/go,closed,flag: global Usage func disregards FlagSet.SetOutput,Documentation NeedsDecision,"### What version of Go are you using (`go version`)?
+```
+go version go1.8.2 darwin/amd64
+```
+
+### What operating system and processor architecture are you using (`go env`)?
+```
+GOARCH=""amd64""
+GOBIN=""""
+GOEXE=""""
+GOHOSTARCH=""amd64""
+GOHOSTOS=""darwin""
+GOOS=""darwin""
+GOPATH=""/Users/vpoturaev/golang""
+GORACE=""""
+GOROOT=""/usr/local/Cellar/go/1.8.2/libexec""
+GOTOOLDIR=""/usr/local/Cellar/go/1.8.2/libexec/pkg/tool/darwin_amd64""
+GCCGO=""gccgo""
+CC=""clang""
+GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/p5/fnl90gfx5_5f9599s3hpthfw0000gq/T/go-build760766867=/tmp/go-build -gno-record-gcc-switches -fno-common""
+CXX=""clang++""
+CGO_ENABLED=""1""
+PKG_CONFIG=""pkg-config""
+CGO_CFLAGS=""-g -O2""
+CGO_CPPFLAGS=""""
+CGO_CXXFLAGS=""-g -O2""
+CGO_FFLAGS=""-g -O2""
+CGO_LDFLAGS=""-g -O2""
+```
+
+### What did you do?
+```go
+package main
+
+import (
+ ""flag""
+ ""io/ioutil""
+ ""os""
+)
+
+func main() {
+ var i int
+ flag.IntVar(&i, ""i"", 2, ""sample int"")
+ flag.CommandLine.SetOutput(ioutil.Discard)
+ os.Args = []string{""app"", ""-i=1"", ""-unknown""}
+ flag.Parse()
+}
+```
+https://play.golang.org/p/05pwqQu-3-
+### What did you expect to see?
+
+No output
+
+### What did you see instead?
+
+STDERR:
+```
+Usage of app:
+```
+
+`/usr/local/Cellar/go/1.8.2/libexec/src/flag/flag.go`
+```go
+var Usage = func() {
+ fmt.Fprintf(os.Stderr, ""Usage of %s:\n"", os.Args[0])
+ PrintDefaults()
+}
+```
+`Usage` function disregards `f.Out()` in favour of `os.Stderr`.
+
+The correct code should be:
+```go
+var Usage = func() {
+ fmt.Fprintf(f.out(), ""Usage of %s:\n"", os.Args[0])
+ PrintDefaults()
+}
+```",1.0,"flag: global Usage func disregards FlagSet.SetOutput - ### What version of Go are you using (`go version`)?
+```
+go version go1.8.2 darwin/amd64
+```
+
+### What operating system and processor architecture are you using (`go env`)?
+```
+GOARCH=""amd64""
+GOBIN=""""
+GOEXE=""""
+GOHOSTARCH=""amd64""
+GOHOSTOS=""darwin""
+GOOS=""darwin""
+GOPATH=""/Users/vpoturaev/golang""
+GORACE=""""
+GOROOT=""/usr/local/Cellar/go/1.8.2/libexec""
+GOTOOLDIR=""/usr/local/Cellar/go/1.8.2/libexec/pkg/tool/darwin_amd64""
+GCCGO=""gccgo""
+CC=""clang""
+GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/p5/fnl90gfx5_5f9599s3hpthfw0000gq/T/go-build760766867=/tmp/go-build -gno-record-gcc-switches -fno-common""
+CXX=""clang++""
+CGO_ENABLED=""1""
+PKG_CONFIG=""pkg-config""
+CGO_CFLAGS=""-g -O2""
+CGO_CPPFLAGS=""""
+CGO_CXXFLAGS=""-g -O2""
+CGO_FFLAGS=""-g -O2""
+CGO_LDFLAGS=""-g -O2""
+```
+
+### What did you do?
+```go
+package main
+
+import (
+ ""flag""
+ ""io/ioutil""
+ ""os""
+)
+
+func main() {
+ var i int
+ flag.IntVar(&i, ""i"", 2, ""sample int"")
+ flag.CommandLine.SetOutput(ioutil.Discard)
+ os.Args = []string{""app"", ""-i=1"", ""-unknown""}
+ flag.Parse()
+}
+```
+https://play.golang.org/p/05pwqQu-3-
+### What did you expect to see?
+
+No output
+
+### What did you see instead?
+
+STDERR:
+```
+Usage of app:
+```
+
+`/usr/local/Cellar/go/1.8.2/libexec/src/flag/flag.go`
+```go
+var Usage = func() {
+ fmt.Fprintf(os.Stderr, ""Usage of %s:\n"", os.Args[0])
+ PrintDefaults()
+}
+```
+`Usage` function disregards `f.Out()` in favour of `os.Stderr`.
+
+The correct code should be:
+```go
+var Usage = func() {
+ fmt.Fprintf(f.out(), ""Usage of %s:\n"", os.Args[0])
+ PrintDefaults()
+}
+```",1,flag global usage func disregards flagset setoutput what version of go are you using go version go version darwin what operating system and processor architecture are you using go env goarch gobin goexe gohostarch gohostos darwin goos darwin gopath users vpoturaev golang gorace goroot usr local cellar go libexec gotooldir usr local cellar go libexec pkg tool darwin gccgo gccgo cc clang gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map var folders t go tmp go build gno record gcc switches fno common cxx clang cgo enabled pkg config pkg config cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g what did you do go package main import flag io ioutil os func main var i int flag intvar i i sample int flag commandline setoutput ioutil discard os args string app i unknown flag parse what did you expect to see no output what did you see instead stderr usage of app usr local cellar go libexec src flag flag go go var usage func fmt fprintf os stderr usage of s n os args printdefaults usage function disregards f out in favour of os stderr the correct code should be go var usage func fmt fprintf f out usage of s n os args printdefaults ,1
+47491,5895124924.0,IssuesEvent,2017-05-18 05:34:32,golang/go,https://api.github.com/repos/golang/go,closed,net: TestInterfaceHardwareAddrWithGetmac fails if Hyper-V bridges are present,HelpWanted NeedsFix OS-Windows Testing,"Please answer these questions before submitting your issue. Thanks!
+
+### What version of Go are you using (`go version`)?
+
+`go version devel +ec091b6 Mon Mar 13 23:43:16 2017 +0000 windows/amd64`
+
+### What operating system and processor architecture are you using (`go env`)?
+
+```
+set GOARCH=amd64
+set GOBIN=
+set GOEXE=.exe
+set GOHOSTARCH=amd64
+set GOHOSTOS=windows
+set GOOS=windows
+set GOPATH=C:\dev\gopath
+set GORACE=
+set GOROOT=C:\gotip
+set GOTOOLDIR=C:\gotip\pkg\tool\windows_amd64
+set GCCGO=gccgo
+set CC=gcc
+set GOGCCFLAGS=-m64 -mthreads -fmessage-length=0 -fdebug-prefix-map=C:\cygwin\tmp\go-build067613091=/tmp/go-build -gno-record-gcc-switches
+set CXX=g++
+set CGO_ENABLED=1
+set CGO_CFLAGS=-g -O2
+set CGO_CPPFLAGS=
+set CGO_CXXFLAGS=-g -O2
+set CGO_FFLAGS=-g -O2
+set CGO_LDFLAGS=-g -O2
+set PKG_CONFIG=pkg-config
+```
+
+### What did you do?
+
+`all.bat`
+
+### What did you expect to see?
+
+Test success
+
+### What did you see instead?
+
+Test failure:
+
+```
+--- FAIL: TestInterfaceHardwareAddrWithGetmac (1.22s)
+ net_windows_test.go:599: getmac lists ""Ethernet 3"", but it could not be found among Go interfaces map[vEthernet (DockerNAT):0x:1x:5x:1x:7x:1x vEthernet (Hyper-V Bridge):1x:1x:0x:0x:6x:7x Teredo Tunneling Pseudo-Interface:00:00:00:00:00:00:00:e0 isatap.fritz.box:00:00:00:00:00:00:00:e0 isatap.{1XXX5XXX-DXXX-4XXX-9XXX-CXXX1XXX4XXX}:00:00:00:00:00:00:00:e0]
+FAIL
+FAIL net 6.980s
+```
+
+I guess it's a similar problem as in https://github.com/golang/go/issues/14130#issuecomment-181284033 although that was closed already.
+
+For me ""Ethernet 3"" does appear in the output of `getmac /fo list /v`, but, it does not appear in `ipconfig`.
+
+I assume it's caused by the presence of a Hyper-V bridge, that's the only unusual thing about my network configuration.
+
+```
+C:\>getmac /fo list /v
+
+Connection Name: vEthernet (Hyper-V Bridge)
+Network Adapter: Hyper-V Virtual Ethernet Adapter #2
+Physical Address: 1X-1X-0X-0X-6X-7X
+Transport Name: \Device\Tcpip_{2XXXAXXX-3XXX-4XXX-AXXX-4XXX4XXX7XXX}
+
+Connection Name: vEthernet (DockerNAT)
+Network Adapter: Hyper-V Virtual Ethernet Adapter #3
+Physical Address: 0X-1X-5X-1X-7X-1X
+Transport Name: \Device\Tcpip_{1XXX5XXX-DXXX-4XXX-9XXX-CXXX1XXX4XXX}
+
+Connection Name: Ethernet 3
+Network Adapter: Realtek PCIe GBE Family Controller
+Physical Address: 1X-1X-0X-0X-6X-7X
+Transport Name: N/A
+
+C:\>ipconfig
+
+Windows IP Configuration
+
+
+Ethernet adapter vEthernet (DockerNAT):
+
+ Connection-specific DNS Suffix . :
+ IPv4 Address. . . . . . . . . . . : 10.0.X.X
+ Subnet Mask . . . . . . . . . . . : 255.255.255.0
+ Default Gateway . . . . . . . . . :
+
+Ethernet adapter vEthernet (Hyper-V Bridge):
+
+ Connection-specific DNS Suffix . : fritz.box
+ IPv6 Address. . . . . . . . . . . : 2XXX:eXXX:3XXX...
+ Temporary IPv6 Address. . . . . . : 2XXX:eXXX:3XXX...
+ Temporary IPv6 Address. . . . . . : 2XXX:eXXX:3XXX...
+ Link-local IPv6 Address . . . . . : fe80::[...]%4
+ IPv4 Address. . . . . . . . . . . : 172.30.X.X
+ Subnet Mask . . . . . . . . . . . : 255.255.255.0
+ Default Gateway . . . . . . . . . : fe80::[...]%4
+ 172.30.X.X
+
+Tunnel adapter Teredo Tunneling Pseudo-Interface:
+
+ Media State . . . . . . . . . . . : Media disconnected
+ Connection-specific DNS Suffix . :
+
+Tunnel adapter isatap.fritz.box:
+
+ Media State . . . . . . . . . . . : Media disconnected
+ Connection-specific DNS Suffix . : fritz.box
+
+Tunnel adapter isatap.{1XXX5XXX-DXXX-4XXX-9XXX-CXXX1XXX4XXX}:
+
+ Media State . . . . . . . . . . . : Media disconnected
+ Connection-specific DNS Suffix . :
+```",1.0,"net: TestInterfaceHardwareAddrWithGetmac fails if Hyper-V bridges are present - Please answer these questions before submitting your issue. Thanks!
+
+### What version of Go are you using (`go version`)?
+
+`go version devel +ec091b6 Mon Mar 13 23:43:16 2017 +0000 windows/amd64`
+
+### What operating system and processor architecture are you using (`go env`)?
+
+```
+set GOARCH=amd64
+set GOBIN=
+set GOEXE=.exe
+set GOHOSTARCH=amd64
+set GOHOSTOS=windows
+set GOOS=windows
+set GOPATH=C:\dev\gopath
+set GORACE=
+set GOROOT=C:\gotip
+set GOTOOLDIR=C:\gotip\pkg\tool\windows_amd64
+set GCCGO=gccgo
+set CC=gcc
+set GOGCCFLAGS=-m64 -mthreads -fmessage-length=0 -fdebug-prefix-map=C:\cygwin\tmp\go-build067613091=/tmp/go-build -gno-record-gcc-switches
+set CXX=g++
+set CGO_ENABLED=1
+set CGO_CFLAGS=-g -O2
+set CGO_CPPFLAGS=
+set CGO_CXXFLAGS=-g -O2
+set CGO_FFLAGS=-g -O2
+set CGO_LDFLAGS=-g -O2
+set PKG_CONFIG=pkg-config
+```
+
+### What did you do?
+
+`all.bat`
+
+### What did you expect to see?
+
+Test success
+
+### What did you see instead?
+
+Test failure:
+
+```
+--- FAIL: TestInterfaceHardwareAddrWithGetmac (1.22s)
+ net_windows_test.go:599: getmac lists ""Ethernet 3"", but it could not be found among Go interfaces map[vEthernet (DockerNAT):0x:1x:5x:1x:7x:1x vEthernet (Hyper-V Bridge):1x:1x:0x:0x:6x:7x Teredo Tunneling Pseudo-Interface:00:00:00:00:00:00:00:e0 isatap.fritz.box:00:00:00:00:00:00:00:e0 isatap.{1XXX5XXX-DXXX-4XXX-9XXX-CXXX1XXX4XXX}:00:00:00:00:00:00:00:e0]
+FAIL
+FAIL net 6.980s
+```
+
+I guess it's a similar problem as in https://github.com/golang/go/issues/14130#issuecomment-181284033 although that was closed already.
+
+For me ""Ethernet 3"" does appear in the output of `getmac /fo list /v`, but, it does not appear in `ipconfig`.
+
+I assume it's caused by the presence of a Hyper-V bridge, that's the only unusual thing about my network configuration.
+
+```
+C:\>getmac /fo list /v
+
+Connection Name: vEthernet (Hyper-V Bridge)
+Network Adapter: Hyper-V Virtual Ethernet Adapter #2
+Physical Address: 1X-1X-0X-0X-6X-7X
+Transport Name: \Device\Tcpip_{2XXXAXXX-3XXX-4XXX-AXXX-4XXX4XXX7XXX}
+
+Connection Name: vEthernet (DockerNAT)
+Network Adapter: Hyper-V Virtual Ethernet Adapter #3
+Physical Address: 0X-1X-5X-1X-7X-1X
+Transport Name: \Device\Tcpip_{1XXX5XXX-DXXX-4XXX-9XXX-CXXX1XXX4XXX}
+
+Connection Name: Ethernet 3
+Network Adapter: Realtek PCIe GBE Family Controller
+Physical Address: 1X-1X-0X-0X-6X-7X
+Transport Name: N/A
+
+C:\>ipconfig
+
+Windows IP Configuration
+
+
+Ethernet adapter vEthernet (DockerNAT):
+
+ Connection-specific DNS Suffix . :
+ IPv4 Address. . . . . . . . . . . : 10.0.X.X
+ Subnet Mask . . . . . . . . . . . : 255.255.255.0
+ Default Gateway . . . . . . . . . :
+
+Ethernet adapter vEthernet (Hyper-V Bridge):
+
+ Connection-specific DNS Suffix . : fritz.box
+ IPv6 Address. . . . . . . . . . . : 2XXX:eXXX:3XXX...
+ Temporary IPv6 Address. . . . . . : 2XXX:eXXX:3XXX...
+ Temporary IPv6 Address. . . . . . : 2XXX:eXXX:3XXX...
+ Link-local IPv6 Address . . . . . : fe80::[...]%4
+ IPv4 Address. . . . . . . . . . . : 172.30.X.X
+ Subnet Mask . . . . . . . . . . . : 255.255.255.0
+ Default Gateway . . . . . . . . . : fe80::[...]%4
+ 172.30.X.X
+
+Tunnel adapter Teredo Tunneling Pseudo-Interface:
+
+ Media State . . . . . . . . . . . : Media disconnected
+ Connection-specific DNS Suffix . :
+
+Tunnel adapter isatap.fritz.box:
+
+ Media State . . . . . . . . . . . : Media disconnected
+ Connection-specific DNS Suffix . : fritz.box
+
+Tunnel adapter isatap.{1XXX5XXX-DXXX-4XXX-9XXX-CXXX1XXX4XXX}:
+
+ Media State . . . . . . . . . . . : Media disconnected
+ Connection-specific DNS Suffix . :
+```",0,net testinterfacehardwareaddrwithgetmac fails if hyper v bridges are present please answer these questions before submitting your issue thanks what version of go are you using go version go version devel mon mar windows what operating system and processor architecture are you using go env set goarch set gobin set goexe exe set gohostarch set gohostos windows set goos windows set gopath c dev gopath set gorace set goroot c gotip set gotooldir c gotip pkg tool windows set gccgo gccgo set cc gcc set gogccflags mthreads fmessage length fdebug prefix map c cygwin tmp go tmp go build gno record gcc switches set cxx g set cgo enabled set cgo cflags g set cgo cppflags set cgo cxxflags g set cgo fflags g set cgo ldflags g set pkg config pkg config what did you do all bat what did you expect to see test success what did you see instead test failure fail testinterfacehardwareaddrwithgetmac net windows test go getmac lists ethernet but it could not be found among go interfaces map fail fail net i guess it s a similar problem as in although that was closed already for me ethernet does appear in the output of getmac fo list v but it does not appear in ipconfig i assume it s caused by the presence of a hyper v bridge that s the only unusual thing about my network configuration c getmac fo list v connection name vethernet hyper v bridge network adapter hyper v virtual ethernet adapter physical address transport name device tcpip axxx connection name vethernet dockernat network adapter hyper v virtual ethernet adapter physical address transport name device tcpip dxxx connection name ethernet network adapter realtek pcie gbe family controller physical address transport name n a c ipconfig windows ip configuration ethernet adapter vethernet dockernat connection specific dns suffix address x x subnet mask default gateway ethernet adapter vethernet hyper v bridge connection specific dns suffix fritz box address exxx temporary address exxx temporary address exxx link local address address x x subnet mask default gateway x x tunnel adapter teredo tunneling pseudo interface media state media disconnected connection specific dns suffix tunnel adapter isatap fritz box media state media disconnected connection specific dns suffix fritz box tunnel adapter isatap dxxx media state media disconnected connection specific dns suffix ,0
+340752,30540418448.0,IssuesEvent,2023-07-19 20:52:15,golang/go,https://api.github.com/repos/golang/go,closed,net: TestInterfaceArrivalAndDepartureZoneCache is broken on linux-arm64 [1.19 backport],Testing CherryPickApproved,"@heschi requested issue #61414 to be considered for backport to the next 1.19 minor release.
+
+> @gopherbot please backport
+",1.0,"net: TestInterfaceArrivalAndDepartureZoneCache is broken on linux-arm64 [1.19 backport] - @heschi requested issue #61414 to be considered for backport to the next 1.19 minor release.
+
+> @gopherbot please backport
+",0,net testinterfacearrivalanddeparturezonecache is broken on linux heschi requested issue to be considered for backport to the next minor release gopherbot please backport ,0
+92420,26681829578.0,IssuesEvent,2023-01-26 18:20:26,golang/go,https://api.github.com/repos/golang/go,closed,x/build/perfdata/db: unrecognized failures,Builders NeedsInvestigation,"```
+#!watchflakes
+post <- pkg == ""golang.org/x/build/perfdata/db"" && test == """"
+```
+
+Issue created automatically to collect these failures.
+
+Example ([log](https://build.golang.org/log/682b81e72837eb8390949271d8a208541d6765cb)):
+
+ signal: segmentation fault
+
+
+— [watchflakes](https://go.dev/wiki/Watchflakes)
+",1.0,"x/build/perfdata/db: unrecognized failures - ```
+#!watchflakes
+post <- pkg == ""golang.org/x/build/perfdata/db"" && test == """"
+```
+
+Issue created automatically to collect these failures.
+
+Example ([log](https://build.golang.org/log/682b81e72837eb8390949271d8a208541d6765cb)):
+
+ signal: segmentation fault
+
+
+— [watchflakes](https://go.dev/wiki/Watchflakes)
+",0,x build perfdata db unrecognized failures watchflakes post pkg golang org x build perfdata db test issue created automatically to collect these failures example signal segmentation fault — ,0
+53016,13101393788.0,IssuesEvent,2020-08-04 03:36:09,golang/go,https://api.github.com/repos/golang/go,opened,x/build/cmd/release: evaluate builders used for upcoming major Go release,Builders recurring release-blocker,"At the start of each code freeze, we should evaluate the builders used to make the upcoming major Go release, and confirm they are the most appropriate choice out of what is available.
+
+The start of a code freeze is a safe time to introduce a builder change, as it will be tested during pre-release versions, starting with beta 1 and onwards.
+
+Making this a release blocker for Go 1.16 (and not okay after beta 1—it needs to be done before). Once completed, this issue should be moved to the next major release milestone.
+
+/cc @golang/osp-team",1.0,"x/build/cmd/release: evaluate builders used for upcoming major Go release - At the start of each code freeze, we should evaluate the builders used to make the upcoming major Go release, and confirm they are the most appropriate choice out of what is available.
+
+The start of a code freeze is a safe time to introduce a builder change, as it will be tested during pre-release versions, starting with beta 1 and onwards.
+
+Making this a release blocker for Go 1.16 (and not okay after beta 1—it needs to be done before). Once completed, this issue should be moved to the next major release milestone.
+
+/cc @golang/osp-team",0,x build cmd release evaluate builders used for upcoming major go release at the start of each code freeze we should evaluate the builders used to make the upcoming major go release and confirm they are the most appropriate choice out of what is available the start of a code freeze is a safe time to introduce a builder change as it will be tested during pre release versions starting with beta and onwards making this a release blocker for go and not okay after beta —it needs to be done before once completed this issue should be moved to the next major release milestone cc golang osp team,0
+211099,16419425204.0,IssuesEvent,2021-05-19 10:43:22,golang/go,https://api.github.com/repos/golang/go,closed,@mislav Documentation changes are fine.,Documentation,"@mislav Documentation changes are fine.
+
+@dawidgolunski As far as I can tell `exec.LookPath` on Windows does not search the directory from which the application loaded at all. It searches the current directory, then the directories on the environment variable `path`.
+
+I could imagine a `exec.LookPathStrict` proposal. Do you want to write one (https://golang.org/s/proposal)? It could perhaps ignore `.` or any relative directory on the `PATH`/`path`.
+
+_Originally posted by @ianlancetaylor in https://github.com/golang/go/issues/38736#issuecomment-718870248_",1.0,"@mislav Documentation changes are fine. - @mislav Documentation changes are fine.
+
+@dawidgolunski As far as I can tell `exec.LookPath` on Windows does not search the directory from which the application loaded at all. It searches the current directory, then the directories on the environment variable `path`.
+
+I could imagine a `exec.LookPathStrict` proposal. Do you want to write one (https://golang.org/s/proposal)? It could perhaps ignore `.` or any relative directory on the `PATH`/`path`.
+
+_Originally posted by @ianlancetaylor in https://github.com/golang/go/issues/38736#issuecomment-718870248_",1, mislav documentation changes are fine mislav documentation changes are fine dawidgolunski as far as i can tell exec lookpath on windows does not search the directory from which the application loaded at all it searches the current directory then the directories on the environment variable path i could imagine a exec lookpathstrict proposal do you want to write one it could perhaps ignore or any relative directory on the path path originally posted by ianlancetaylor in ,1
+20416,4543340215.0,IssuesEvent,2016-09-10 03:01:53,golang/go,https://api.github.com/repos/golang/go,closed,x/crypto/scrypt: fix scrypt example,Documentation HelpWanted,"The scrypt code example doesn't work, as `scrypt.Key` also returns an error.
+
+`dk := scrypt.Key([]byte(""some password""), salt, 16384, 8, 1, 32)`
+-->
+`dk, err := scrypt.Key([]byte(""some password""), salt, 16384, 8, 1, 32)`
+
+https://github.com/golang/crypto/blob/05d11b2ca14108dfc7f74f4f66b28c7fe92e1fd0/scrypt/scrypt.go#L221",1.0,"x/crypto/scrypt: fix scrypt example - The scrypt code example doesn't work, as `scrypt.Key` also returns an error.
+
+`dk := scrypt.Key([]byte(""some password""), salt, 16384, 8, 1, 32)`
+-->
+`dk, err := scrypt.Key([]byte(""some password""), salt, 16384, 8, 1, 32)`
+
+https://github.com/golang/crypto/blob/05d11b2ca14108dfc7f74f4f66b28c7fe92e1fd0/scrypt/scrypt.go#L221",1,x crypto scrypt fix scrypt example the scrypt code example doesn t work as scrypt key also returns an error dk scrypt key byte some password salt dk err scrypt key byte some password salt ,1
+16867,9541583752.0,IssuesEvent,2019-04-30 22:57:52,golang/go,https://api.github.com/repos/golang/go,closed,net/http: consider adding configurable buffer sizes to Transport,FeatureRequest NeedsDecision Performance,"### What version of Go are you using (`go version`)?
+go version devel +6e3a2b3 Tue Nov 7 15:04:53 2017 +0200 linux/amd64
+
+### Does this issue reproduce with the latest release?
+Yes
+
+### What operating system and processor architecture are you using (`go env`)?
+```
+GOARCH=""amd64""
+GOBIN=""""
+GOCACHE=""/home/nsoffer/.cache/go-build""
+GOEXE=""""
+GOHOSTARCH=""amd64""
+GOHOSTOS=""linux""
+GOOS=""linux""
+GOPATH=""/home/nsoffer/go""
+GORACE=""""
+GOROOT=""/home/nsoffer/src/go""
+GOTMPDIR=""""
+GOTOOLDIR=""/home/nsoffer/src/go/pkg/tool/linux_amd64""
+GCCGO=""gccgo""
+CC=""gcc""
+CXX=""gcc++""
+CGO_ENABLED=""1""
+CGO_CFLAGS=""-g -O2""
+CGO_CPPFLAGS=""""
+CGO_CXXFLAGS=""-g -O2""
+CGO_FFLAGS=""-g -O2""
+CGO_LDFLAGS=""-g -O2""
+PKG_CONFIG=""pkg-config""
+GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build316051983=/tmp/go-build -gno-record-gcc-switches""
+```
+
+### What did you do?
+Test uploading files over https, note low throughput compared with similar Python program.
+For example programs and benchmarks, see
+https://github.com/nirs/http-bench/tree/go-bufsize
+
+### What did you expect to see?
+Being able to control buffer size used by http.Client, similar to the way you can control the buffer size in ``io.CopyBuffer``.
+
+### What did you see instead?
+Hardcoded value hidden deep in the code and my free time being wasted locating it :).
+
+For example, here is output from strace:
+```
+[pid 32264] read(3, ""\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0""..., 4096) = 4096
+[pid 32264] write(4, ""\27\3\3\20\30\0\0\0\0\0\3l\""w\201\360W\307F=\215Zj&\6hj\253\343\20EN""..., 4125) = 4125
+```
+### Use case
+
+An example use case is uploading vm images to storage, for example, [ovirt-imageio](https://github.com/ovirt/ovirt-imageio).
+
+### Initial proposal
+
+Add Transport.WriteBufSize and Transport.ReadBufSize:
+https://go-review.googlesource.com/#/c/go/+/76410/
+
+Example usage:
+```
+t := &http.Transport{WriteBufSize: 128*1024}
+client := &http.Client{Transport: t}
+```
+
+I tested the maximum benefit of this change by uploading data from
+/dev/zero to a server discarding the data. Here is an example upload
+using the default buffer size:
+
+```
+$ time ./upload 10 https://localhost:8000/
+Uploaded 10.00g in 25.13 seconds (407.49m/s)
+
+real 0m25.135s
+user 0m5.167s
+sys 0m11.643s
+```
+With this change, using 128k buffer size:
+```
+$ time ./upload 10 https://localhost:8000/
+Uploaded 10.00g in 7.93 seconds (1291.51m/s)
+
+real 0m7.935s
+user 0m4.517s
+sys 0m2.603s
+```
+
+Tested on Lenovo T450s
+Intel(R) Core(TM) i7-5600U CPU @ 2.60GHz
+
+In real world usage the difference will be smaller, depending on the
+local and remote storage and the network.
+
+Similar enhancement was added lately to Python, see:
+https://github.com/python/cpython/commit/ad455cd9243319b896c86074ffeb3bf78a82f4ec ",True,"net/http: consider adding configurable buffer sizes to Transport - ### What version of Go are you using (`go version`)?
+go version devel +6e3a2b3 Tue Nov 7 15:04:53 2017 +0200 linux/amd64
+
+### Does this issue reproduce with the latest release?
+Yes
+
+### What operating system and processor architecture are you using (`go env`)?
+```
+GOARCH=""amd64""
+GOBIN=""""
+GOCACHE=""/home/nsoffer/.cache/go-build""
+GOEXE=""""
+GOHOSTARCH=""amd64""
+GOHOSTOS=""linux""
+GOOS=""linux""
+GOPATH=""/home/nsoffer/go""
+GORACE=""""
+GOROOT=""/home/nsoffer/src/go""
+GOTMPDIR=""""
+GOTOOLDIR=""/home/nsoffer/src/go/pkg/tool/linux_amd64""
+GCCGO=""gccgo""
+CC=""gcc""
+CXX=""gcc++""
+CGO_ENABLED=""1""
+CGO_CFLAGS=""-g -O2""
+CGO_CPPFLAGS=""""
+CGO_CXXFLAGS=""-g -O2""
+CGO_FFLAGS=""-g -O2""
+CGO_LDFLAGS=""-g -O2""
+PKG_CONFIG=""pkg-config""
+GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build316051983=/tmp/go-build -gno-record-gcc-switches""
+```
+
+### What did you do?
+Test uploading files over https, note low throughput compared with similar Python program.
+For example programs and benchmarks, see
+https://github.com/nirs/http-bench/tree/go-bufsize
+
+### What did you expect to see?
+Being able to control buffer size used by http.Client, similar to the way you can control the buffer size in ``io.CopyBuffer``.
+
+### What did you see instead?
+Hardcoded value hidden deep in the code and my free time being wasted locating it :).
+
+For example, here is output from strace:
+```
+[pid 32264] read(3, ""\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0""..., 4096) = 4096
+[pid 32264] write(4, ""\27\3\3\20\30\0\0\0\0\0\3l\""w\201\360W\307F=\215Zj&\6hj\253\343\20EN""..., 4125) = 4125
+```
+### Use case
+
+An example use case is uploading vm images to storage, for example, [ovirt-imageio](https://github.com/ovirt/ovirt-imageio).
+
+### Initial proposal
+
+Add Transport.WriteBufSize and Transport.ReadBufSize:
+https://go-review.googlesource.com/#/c/go/+/76410/
+
+Example usage:
+```
+t := &http.Transport{WriteBufSize: 128*1024}
+client := &http.Client{Transport: t}
+```
+
+I tested the maximum benefit of this change by uploading data from
+/dev/zero to a server discarding the data. Here is an example upload
+using the default buffer size:
+
+```
+$ time ./upload 10 https://localhost:8000/
+Uploaded 10.00g in 25.13 seconds (407.49m/s)
+
+real 0m25.135s
+user 0m5.167s
+sys 0m11.643s
+```
+With this change, using 128k buffer size:
+```
+$ time ./upload 10 https://localhost:8000/
+Uploaded 10.00g in 7.93 seconds (1291.51m/s)
+
+real 0m7.935s
+user 0m4.517s
+sys 0m2.603s
+```
+
+Tested on Lenovo T450s
+Intel(R) Core(TM) i7-5600U CPU @ 2.60GHz
+
+In real world usage the difference will be smaller, depending on the
+local and remote storage and the network.
+
+Similar enhancement was added lately to Python, see:
+https://github.com/python/cpython/commit/ad455cd9243319b896c86074ffeb3bf78a82f4ec ",0,net http consider adding configurable buffer sizes to transport what version of go are you using go version go version devel tue nov linux does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env goarch gobin gocache home nsoffer cache go build goexe gohostarch gohostos linux goos linux gopath home nsoffer go gorace goroot home nsoffer src go gotmpdir gotooldir home nsoffer src go pkg tool linux gccgo gccgo cc gcc cxx gcc cgo enabled cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fmessage length fdebug prefix map tmp go tmp go build gno record gcc switches what did you do test uploading files over https note low throughput compared with similar python program for example programs and benchmarks see what did you expect to see being able to control buffer size used by http client similar to the way you can control the buffer size in io copybuffer what did you see instead hardcoded value hidden deep in the code and my free time being wasted locating it for example here is output from strace read write w use case an example use case is uploading vm images to storage for example initial proposal add transport writebufsize and transport readbufsize example usage t http transport writebufsize client http client transport t i tested the maximum benefit of this change by uploading data from dev zero to a server discarding the data here is an example upload using the default buffer size time upload uploaded in seconds s real user sys with this change using buffer size time upload uploaded in seconds s real user sys tested on lenovo intel r core tm cpu in real world usage the difference will be smaller depending on the local and remote storage and the network similar enhancement was added lately to python see ,0
+36722,9881724655.0,IssuesEvent,2019-06-24 15:15:18,golang/go,https://api.github.com/repos/golang/go,closed,x/build/cmd/gopherbot: remove NeedsDecision on proposals,Builders NeedsFix,"Per @golang/proposal-review, the bot should remove NeedsDecision on proposals. It's redundant and messes with searches.",1.0,"x/build/cmd/gopherbot: remove NeedsDecision on proposals - Per @golang/proposal-review, the bot should remove NeedsDecision on proposals. It's redundant and messes with searches.",0,x build cmd gopherbot remove needsdecision on proposals per golang proposal review the bot should remove needsdecision on proposals it s redundant and messes with searches ,0
+270091,20573993202.0,IssuesEvent,2022-03-04 01:08:59,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: add proper documentation for workspace mode,Documentation NeedsFix GoCommand,"Add full docs for each of the go work subcommands, a doc for getting started on workspace mode, and a reference-style document.",1.0,"cmd/go: add proper documentation for workspace mode - Add full docs for each of the go work subcommands, a doc for getting started on workspace mode, and a reference-style document.",1,cmd go add proper documentation for workspace mode add full docs for each of the go work subcommands a doc for getting started on workspace mode and a reference style document ,1
+23667,4964368251.0,IssuesEvent,2016-12-03 18:48:50,golang/go,https://api.github.com/repos/golang/go,opened,net: can Conn.Close block?,Documentation NeedsDecision,"The documentation for `net.Conn.Close` is:
+> Close closes the connection. Any blocked Read or Write operations will be unblocked and return errors.
+
+However, it does not mention anything about whether `Close` itself can block.
+
+Some `net.Conn` implementations have an implicit write buffer. Thus, when `Close` is called, it still needs to flush the buffer before returning. This means that `Close` is effectively an operation that involves IO. Since it involves IO, this means that `Close` may have to wait until the recipient acknowledges the incoming data (which could potentially be forever if the receiver's read buffer is full).
+
+If we extend the documentation for `net.Conn.Close`, would the following be reasonable?
+> Close closes the connection. Any blocked Read or Write operations will be unblocked and return errors. Close itself may block while it is flushing any internal write buffers, but must return an error when a previously set deadline has been exceeded.
+
+\cc @bradfitz @mikioh ",1.0,"net: can Conn.Close block? - The documentation for `net.Conn.Close` is:
+> Close closes the connection. Any blocked Read or Write operations will be unblocked and return errors.
+
+However, it does not mention anything about whether `Close` itself can block.
+
+Some `net.Conn` implementations have an implicit write buffer. Thus, when `Close` is called, it still needs to flush the buffer before returning. This means that `Close` is effectively an operation that involves IO. Since it involves IO, this means that `Close` may have to wait until the recipient acknowledges the incoming data (which could potentially be forever if the receiver's read buffer is full).
+
+If we extend the documentation for `net.Conn.Close`, would the following be reasonable?
+> Close closes the connection. Any blocked Read or Write operations will be unblocked and return errors. Close itself may block while it is flushing any internal write buffers, but must return an error when a previously set deadline has been exceeded.
+
+\cc @bradfitz @mikioh ",1,net can conn close block the documentation for net conn close is close closes the connection any blocked read or write operations will be unblocked and return errors however it does not mention anything about whether close itself can block some net conn implementations have an implicit write buffer thus when close is called it still needs to flush the buffer before returning this means that close is effectively an operation that involves io since it involves io this means that close may have to wait until the recipient acknowledges the incoming data which could potentially be forever if the receiver s read buffer is full if we extend the documentation for net conn close would the following be reasonable close closes the connection any blocked read or write operations will be unblocked and return errors close itself may block while it is flushing any internal write buffers but must return an error when a previously set deadline has been exceeded cc bradfitz mikioh ,1
+32555,6086436434.0,IssuesEvent,2017-06-18 01:00:11,golang/go,https://api.github.com/repos/golang/go,closed,Website. Documentation,Documentation,"Please clarify the language for Go comments, Git comments in
+*Contribution Guide*
+https://golang.org/doc/contribute.html
+
+In my point of view, the Go project expected - English language.",1.0,"Website. Documentation - Please clarify the language for Go comments, Git comments in
+*Contribution Guide*
+https://golang.org/doc/contribute.html
+
+In my point of view, the Go project expected - English language.",1,website documentation please clarify the language for go comments git comments in contribution guide in my point of view the go project expected english language ,1
+387185,26715071814.0,IssuesEvent,2023-01-28 11:53:30,golang/go,https://api.github.com/repos/golang/go,closed,doc: clarify fetching Go 1.4 from git,Documentation help wanted NeedsFix,"A decision seems to have been made to no longer provide version controlled 1.4.x source code for doing a clean Go bootstrap on macOS. Is this true? You need a special tarball? How should the the current state of affairs for source code bootstrapping be characterized?
+
+I think the comment that kinda shook me was:
+@ianlancetaylor
+`I suppose I am mildly in favor of doing a 1.4.4 release for better Darwin support going forward.`
+
+Currently to get close to a clean bootstrap you have to download a special tarball. A doc change was made to fix the bootstrap issue. But on my system that *special version* of 1.4.3 builds but doesn't pass tests. It will build 10.2 however.
+
+**What really gets me in the craw is the atavistic reversion to a tarball instead of using git and version control.**
+
+Yes, I know I could have used my existing Go 10.1 to compile 10.2. Is that what everyone else does now?
+
+Perhaps the pain level of maintaining the 1.4 bootstrap has been reached? Maybe it is time to retire the 1.4 bootstrap and just use archived binaries of previous versions of Go? I think there is some risk and complexity with that approach too, but it's a valid approach, and I could live with it. Whatever the decision is, it should be an explicit decision, not something the team slumps into because no one wants to maintain the bootstrap anymore.
+
+tl;dr version below.
+I recently got a new MacBook Pro. Previously I was running macOS 10.10 on my beloved MBP 17"" but the new laptop came with High Sierra, macOS 10.13.5 and the Go team had just issued 10.2. Time to update. I am a build from source kinda guy so I did the `git pull` and `all.bash`.
+
+ Building Go cmd/dist using /Volumes/std/usr/leb/go1.4.
+ failed MSpanList_Insert 0x783000 0xffd30d60dd0 0x0
+ fatal error: MSpanList_Insert
+
+Check to see if there is a newer bootstrap version. There is a 1.4.3. Get that. Build it. Same thing.
+
+Look around, it's a High Sierra issue and Go issue 16352 seems to have the answers.
+
+https://github.com/golang/go/issues/16352
+https://github.com/golang/go/issues/17335
+https://github.com/golang/go/issues/17182
+
+So now I need to download a tarball to bootstrap? That's what the doc says. Oh, they fixed it with a tarball and a doc change.
+
+ To build a bootstrap toolchain from source, use either the git branch release-branch.go1.4 or
+ go1.4-bootstrap-20171003.tar.gz, which contains the Go 1.4 source code plus accumulated fixes to keep
+ the tools running on newer operating systems.
+
+Download the tarball. Have some kind of issue but I update Xcode and all is OK. At least it builds this time but now it fails with a timezone issue.
+
+ ok text/template/parse 0.015s
+ --- FAIL: TestParseInLocation-11 (0.00s)
+ format_test.go:202: ParseInLocation(Feb 01 2013 AST, Baghdad) = 2013-02-01 00:00:00 +0000 AST, want 2013-02-01 00:00:00 +0300 +03
+
+Check that error out. It's a known issue because the timezone data changed and the test isn't fixed in the tarball.
+
+https://github.com/golang/go/issues/19457
+
+I replace the `TestParseInLocation in the tarball with the one from 10.2 and it works.
+
+**Wow this was painful and when building 10.2 I still get an error on my machine.**
+
+ --- FAIL: TestRespectSetgidDir (0.00s)
+ build_test.go:225:
+ moveOrCopyFile(""/var/folders/95/zwjzrdwc8xj7yg001s6slck80000gn/T/SetGroupID592840517/setgid"",
+ ""/var/folders/95/zwjzrdwc8xj7yg001s6slck80000gn/T/pkgfile074436576""): want ""cp
+ /var/folders/95/zwjzrdwc8xj7yg001s6slck80000gn/T/pkgfile074436576
+ /var/folders/95/zwjzrdwc8xj7yg001s6slck80000gn/T/SetGroupID592840517/setgid"", got ""mv
+ /var/folders/95/zwjzrdwc8xj7yg001s6slck80000gn/T/pkgfile074436576
+ /var/folders/95/zwjzrdwc8xj7yg001s6slck80000gn/T/SetGroupID592840517/setgid""
+ FAIL
+ FAIL cmd/go/internal/work 0.025s
+
+which is also supposedly fixed but has been failing on my previous laptop even with 10.10. I will try to figure out what is going on with that. Maybe something to do with being a member of multiple groups? IDK. That's a different issue and I get the feeling it may be specific to my setup.",1.0,"doc: clarify fetching Go 1.4 from git - A decision seems to have been made to no longer provide version controlled 1.4.x source code for doing a clean Go bootstrap on macOS. Is this true? You need a special tarball? How should the the current state of affairs for source code bootstrapping be characterized?
+
+I think the comment that kinda shook me was:
+@ianlancetaylor
+`I suppose I am mildly in favor of doing a 1.4.4 release for better Darwin support going forward.`
+
+Currently to get close to a clean bootstrap you have to download a special tarball. A doc change was made to fix the bootstrap issue. But on my system that *special version* of 1.4.3 builds but doesn't pass tests. It will build 10.2 however.
+
+**What really gets me in the craw is the atavistic reversion to a tarball instead of using git and version control.**
+
+Yes, I know I could have used my existing Go 10.1 to compile 10.2. Is that what everyone else does now?
+
+Perhaps the pain level of maintaining the 1.4 bootstrap has been reached? Maybe it is time to retire the 1.4 bootstrap and just use archived binaries of previous versions of Go? I think there is some risk and complexity with that approach too, but it's a valid approach, and I could live with it. Whatever the decision is, it should be an explicit decision, not something the team slumps into because no one wants to maintain the bootstrap anymore.
+
+tl;dr version below.
+I recently got a new MacBook Pro. Previously I was running macOS 10.10 on my beloved MBP 17"" but the new laptop came with High Sierra, macOS 10.13.5 and the Go team had just issued 10.2. Time to update. I am a build from source kinda guy so I did the `git pull` and `all.bash`.
+
+ Building Go cmd/dist using /Volumes/std/usr/leb/go1.4.
+ failed MSpanList_Insert 0x783000 0xffd30d60dd0 0x0
+ fatal error: MSpanList_Insert
+
+Check to see if there is a newer bootstrap version. There is a 1.4.3. Get that. Build it. Same thing.
+
+Look around, it's a High Sierra issue and Go issue 16352 seems to have the answers.
+
+https://github.com/golang/go/issues/16352
+https://github.com/golang/go/issues/17335
+https://github.com/golang/go/issues/17182
+
+So now I need to download a tarball to bootstrap? That's what the doc says. Oh, they fixed it with a tarball and a doc change.
+
+ To build a bootstrap toolchain from source, use either the git branch release-branch.go1.4 or
+ go1.4-bootstrap-20171003.tar.gz, which contains the Go 1.4 source code plus accumulated fixes to keep
+ the tools running on newer operating systems.
+
+Download the tarball. Have some kind of issue but I update Xcode and all is OK. At least it builds this time but now it fails with a timezone issue.
+
+ ok text/template/parse 0.015s
+ --- FAIL: TestParseInLocation-11 (0.00s)
+ format_test.go:202: ParseInLocation(Feb 01 2013 AST, Baghdad) = 2013-02-01 00:00:00 +0000 AST, want 2013-02-01 00:00:00 +0300 +03
+
+Check that error out. It's a known issue because the timezone data changed and the test isn't fixed in the tarball.
+
+https://github.com/golang/go/issues/19457
+
+I replace the `TestParseInLocation in the tarball with the one from 10.2 and it works.
+
+**Wow this was painful and when building 10.2 I still get an error on my machine.**
+
+ --- FAIL: TestRespectSetgidDir (0.00s)
+ build_test.go:225:
+ moveOrCopyFile(""/var/folders/95/zwjzrdwc8xj7yg001s6slck80000gn/T/SetGroupID592840517/setgid"",
+ ""/var/folders/95/zwjzrdwc8xj7yg001s6slck80000gn/T/pkgfile074436576""): want ""cp
+ /var/folders/95/zwjzrdwc8xj7yg001s6slck80000gn/T/pkgfile074436576
+ /var/folders/95/zwjzrdwc8xj7yg001s6slck80000gn/T/SetGroupID592840517/setgid"", got ""mv
+ /var/folders/95/zwjzrdwc8xj7yg001s6slck80000gn/T/pkgfile074436576
+ /var/folders/95/zwjzrdwc8xj7yg001s6slck80000gn/T/SetGroupID592840517/setgid""
+ FAIL
+ FAIL cmd/go/internal/work 0.025s
+
+which is also supposedly fixed but has been failing on my previous laptop even with 10.10. I will try to figure out what is going on with that. Maybe something to do with being a member of multiple groups? IDK. That's a different issue and I get the feeling it may be specific to my setup.",1,doc clarify fetching go from git a decision seems to have been made to no longer provide version controlled x source code for doing a clean go bootstrap on macos is this true you need a special tarball how should the the current state of affairs for source code bootstrapping be characterized i think the comment that kinda shook me was ianlancetaylor i suppose i am mildly in favor of doing a release for better darwin support going forward currently to get close to a clean bootstrap you have to download a special tarball a doc change was made to fix the bootstrap issue but on my system that special version of builds but doesn t pass tests it will build however what really gets me in the craw is the atavistic reversion to a tarball instead of using git and version control yes i know i could have used my existing go to compile is that what everyone else does now perhaps the pain level of maintaining the bootstrap has been reached maybe it is time to retire the bootstrap and just use archived binaries of previous versions of go i think there is some risk and complexity with that approach too but it s a valid approach and i could live with it whatever the decision is it should be an explicit decision not something the team slumps into because no one wants to maintain the bootstrap anymore tl dr version below i recently got a new macbook pro previously i was running macos on my beloved mbp but the new laptop came with high sierra macos and the go team had just issued time to update i am a build from source kinda guy so i did the git pull and all bash building go cmd dist using volumes std usr leb failed mspanlist insert fatal error mspanlist insert check to see if there is a newer bootstrap version there is a get that build it same thing look around it s a high sierra issue and go issue seems to have the answers so now i need to download a tarball to bootstrap that s what the doc says oh they fixed it with a tarball and a doc change to build a bootstrap toolchain from source use either the git branch release branch or bootstrap tar gz which contains the go source code plus accumulated fixes to keep the tools running on newer operating systems download the tarball have some kind of issue but i update xcode and all is ok at least it builds this time but now it fails with a timezone issue ok text template parse fail testparseinlocation format test go parseinlocation feb ast baghdad ast want check that error out it s a known issue because the timezone data changed and the test isn t fixed in the tarball i replace the testparseinlocation in the tarball with the one from and it works wow this was painful and when building i still get an error on my machine fail testrespectsetgiddir build test go moveorcopyfile var folders t setgid var folders t want cp var folders t var folders t setgid got mv var folders t var folders t setgid fail fail cmd go internal work which is also supposedly fixed but has been failing on my previous laptop even with i will try to figure out what is going on with that maybe something to do with being a member of multiple groups idk that s a different issue and i get the feeling it may be specific to my setup ,1
+182564,14917832723.0,IssuesEvent,2021-01-22 20:33:34,golang/go,https://api.github.com/repos/golang/go,closed,x/tools/gopls: include a link to useful docs in the workspace load error notification,Documentation Tools gopls,"+$ go version +1.17.5 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/hlushch/Library/Caches/go-build"" +GOENV=""/Users/hlushch/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/hlushch/Projects/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/hlushch/Projects/go/"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/Cellar/go/1.17.5/libexec"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.17.5/libexec/pkg/tool/darwin_amd64"" +GOVCS="""" +GOVERSION=""go1.17.5"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/nz/cqlmbdfs23schf6ndmr7gz440000gn/T/go-build2546855830=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ go version +1.17.5 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/hlushch/Library/Caches/go-build"" +GOENV=""/Users/hlushch/Library/Application Support/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/hlushch/Projects/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/hlushch/Projects/go/"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/Cellar/go/1.17.5/libexec"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.17.5/libexec/pkg/tool/darwin_amd64"" +GOVCS="""" +GOVERSION=""go1.17.5"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/nz/cqlmbdfs23schf6ndmr7gz440000gn/T/go-build2546855830=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+ TODO: https://golang.org/cl/264397: validate patterns in Match, Glob +
++ TODO: https://golang.org/cl/264397: validate patterns in Match, Glob +
++ TODO: https://golang.org/cl/264397: validate patterns in Match, Glob +
++ TODO: https://golang.org/cl/264397: validate patterns in Match, Glob +
++❯ gopls version +golang.org/x/tools/gopls v0.3.4 + golang.org/x/tools/gopls@v0.3.4 h1:4GC7q/pXQ/tsxHBGVdsMdlB4gCxVC06m/7rIXg1Px4E= ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+❯ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/james/.cache/go-build"" +GOENV=""/home/james/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/james/go:/home/james/godev"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build613753881=/tmp/go-build -gno-record-gcc-switches"" +
+❯ gopls version +golang.org/x/tools/gopls v0.3.4 + golang.org/x/tools/gopls@v0.3.4 h1:4GC7q/pXQ/tsxHBGVdsMdlB4gCxVC06m/7rIXg1Px4E= ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+❯ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/james/.cache/go-build"" +GOENV=""/home/james/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/james/go:/home/james/godev"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build613753881=/tmp/go-build -gno-record-gcc-switches"" +
What does 'go version' print?
+
+Found with go-1.2rc3, present in go-1.3, and still present in the default branch as of
+20272:90616fa61ef4.
+
+What steps reproduce the problem?
+
+Setting a ReadTimeout or WriteTimeout on an http.Server and then hijacking a http.conn
+(passed as the ResponseWriter) from a request handler leaves the deadlines set on the
+connection.
+
+This causes unexpected read and write behavior, requiring an unnatural removal of the
+deadlines after hijacking. I found this while implementing the server half of the HTML5
+EventSource API, and it also affects any other hijack users (e.g. go.net's websocket
+package does not have code to clear deadlines when it takes over a connection; I have
+not tested it though.)
+
+A simplified example of the issue is here (probably useful to derive a regression test
+from): http://play.golang.org/p/bRyjSayMJN
+
+Adding these two lines fixes the issue:
+
+diff -r 90616fa61ef4 src/pkg/net/http/server.go
+--- a/src/pkg/net/http/server.go Fri Jun 27 18:30:09 2014 -0700
++++ b/src/pkg/net/http/server.go Fri Jun 27 22:43:18 2014 -0700
+@@ -128,18 +128,20 @@
+ func (c *conn) hijack() (rwc net.Conn, buf *bufio.ReadWriter, err error) {
+ c.mu.Lock()
+ defer c.mu.Unlock()
+ if c.hijackedv {
+ return nil, nil, ErrHijacked
+ }
+ if c.closeNotifyc != nil {
+ return nil, nil, errors.New("http: Hijack is incompatible with use of CloseNotifier")
+ }
++ c.rwc.SetReadDeadline(time.Time{})
++ c.rwc.SetWriteDeadline(time.Time{})
+ c.hijackedv = true
+ rwc = c.rwc
+ buf = c.buf
+ c.rwc = nil
+ c.buf = nil
+ c.setState(rwc, StateHijacked)
+ return
+ }",1.0,"net/http: document that conn.Hijack might have left-over read/write timeouts on net.Conn - What does 'go version' print?
+
+Found with go-1.2rc3, present in go-1.3, and still present in the default branch as of
+20272:90616fa61ef4.
+
+What steps reproduce the problem?
+
+Setting a ReadTimeout or WriteTimeout on an http.Server and then hijacking a http.conn
+(passed as the ResponseWriter) from a request handler leaves the deadlines set on the
+connection.
+
+This causes unexpected read and write behavior, requiring an unnatural removal of the
+deadlines after hijacking. I found this while implementing the server half of the HTML5
+EventSource API, and it also affects any other hijack users (e.g. go.net's websocket
+package does not have code to clear deadlines when it takes over a connection; I have
+not tested it though.)
+
+A simplified example of the issue is here (probably useful to derive a regression test
+from): http://play.golang.org/p/bRyjSayMJN
+
+Adding these two lines fixes the issue:
+
+diff -r 90616fa61ef4 src/pkg/net/http/server.go
+--- a/src/pkg/net/http/server.go Fri Jun 27 18:30:09 2014 -0700
++++ b/src/pkg/net/http/server.go Fri Jun 27 22:43:18 2014 -0700
+@@ -128,18 +128,20 @@
+ func (c *conn) hijack() (rwc net.Conn, buf *bufio.ReadWriter, err error) {
+ c.mu.Lock()
+ defer c.mu.Unlock()
+ if c.hijackedv {
+ return nil, nil, ErrHijacked
+ }
+ if c.closeNotifyc != nil {
+ return nil, nil, errors.New("http: Hijack is incompatible with use of CloseNotifier")
+ }
++ c.rwc.SetReadDeadline(time.Time{})
++ c.rwc.SetWriteDeadline(time.Time{})
+ c.hijackedv = true
+ rwc = c.rwc
+ buf = c.buf
+ c.rwc = nil
+ c.buf = nil
+ c.setState(rwc, StateHijacked)
+ return
+ }",1,net http document that conn hijack might have left over read write timeouts on net conn what does go version print found with go present in go and still present in the default branch as of what steps reproduce the problem setting a readtimeout or writetimeout on an http server and then hijacking a http conn passed as the responsewriter from a request handler leaves the deadlines set on the connection this causes unexpected read and write behavior requiring an unnatural removal of the deadlines after hijacking i found this while implementing the server half of the eventsource api and it also affects any other hijack users e g go net s websocket package does not have code to clear deadlines when it takes over a connection i have not tested it though a simplified example of the issue is here probably useful to derive a regression test from a href adding these two lines fixes the issue diff r src pkg net http server go a src pkg net http server go fri jun b src pkg net http server go fri jun func c conn hijack rwc net conn buf bufio readwriter err error c mu lock defer c mu unlock if c hijackedv return nil nil errhijacked if c closenotifyc nil return nil nil errors new quot http hijack is incompatible with use of closenotifier quot c rwc setreaddeadline time time c rwc setwritedeadline time time c hijackedv true rwc c rwc buf c buf c rwc nil c buf nil c setstate rwc statehijacked return ,1
+0,2489415033.0,IssuesEvent,2015-01-01 01:50:25,golang/go,https://api.github.com/repos/golang/go,closed,go.tools/go/vet: excessive imports,helpwanted performance release-none repo-tools,"Profiling vet on a large corpus shows about >10% time spent in syscalls initiated by +gcimporter.(*parser).next. Many of these reads are avoidable; there is high import +overlap across packages, particularly within a given project. + +Concretely, instrumenting calls to Import (in gcimporter.go) and then running 'go vet' +on camlistore yields these top duplicate imports: + + 153 fmt.a + 147 testing.a + 120 io.a + 119 strings.a + 113 os.a + 108 bytes.a + 99 time.a + 97 errors.a + 82 io/ioutil.a + 80 log.a + 76 sync.a + 70 strconv.a + 64 net/http.a + 56 path/filepath.a + 51 camlistore.org/pkg/blob.a + 44 runtime.a + 39 sort.a + 39 flag.a + 35 reflect.a + 35 net/url.a + +These 20 account for 1627 of the 2750 import reads. + +Hacking in a quick LRU that simply caches the raw data in the files cuts 'go vet' user +time for camlistore by ~10%. I'm not sure that that is the right long-term approach, +though.",True,"go.tools/go/vet: excessive imports -
Profiling vet on a large corpus shows about >10% time spent in syscalls initiated by +gcimporter.(*parser).next. Many of these reads are avoidable; there is high import +overlap across packages, particularly within a given project. + +Concretely, instrumenting calls to Import (in gcimporter.go) and then running 'go vet' +on camlistore yields these top duplicate imports: + + 153 fmt.a + 147 testing.a + 120 io.a + 119 strings.a + 113 os.a + 108 bytes.a + 99 time.a + 97 errors.a + 82 io/ioutil.a + 80 log.a + 76 sync.a + 70 strconv.a + 64 net/http.a + 56 path/filepath.a + 51 camlistore.org/pkg/blob.a + 44 runtime.a + 39 sort.a + 39 flag.a + 35 reflect.a + 35 net/url.a + +These 20 account for 1627 of the 2750 import reads. + +Hacking in a quick LRU that simply caches the raw data in the files cuts 'go vet' user +time for camlistore by ~10%. I'm not sure that that is the right long-term approach, +though.",0,go tools go vet excessive imports profiling vet on a large corpus shows about gt time spent in syscalls initiated by gcimporter parser next many of these reads are avoidable there is high import overlap across packages particularly within a given project concretely instrumenting calls to import in gcimporter go and then running go vet on camlistore yields these top duplicate imports fmt a testing a io a strings a os a bytes a time a errors a io ioutil a log a sync a strconv a net http a path filepath a camlistore org pkg blob a runtime a sort a flag a reflect a net url a these account for of the import reads hacking in a quick lru that simply caches the raw data in the files cuts go vet user time for camlistore by i m not sure that that is the right long term approach though ,0 +5946,2993245496.0,IssuesEvent,2015-07-22 01:25:45,golang/go,https://api.github.com/repos/golang/go,closed,doc: clarify that new methods may be added to standard library types,Documentation,"Currently the go1compat document states that exported structs in the standard library may add new fields, but it doesn't mention that they may add new methods too. To date, every Go release has added new methods to existing types. + +For selector expressions, the risk of ambiguity from new methods is the same as for new fields. But if a new method is added to a standard type that's embedded in a user type, it could cause that user type to no longer satisfy existing interfaces due to ambiguity, which is a risk unique to adding new methods.",1.0,"doc: clarify that new methods may be added to standard library types - Currently the go1compat document states that exported structs in the standard library may add new fields, but it doesn't mention that they may add new methods too. To date, every Go release has added new methods to existing types. + +For selector expressions, the risk of ambiguity from new methods is the same as for new fields. But if a new method is added to a standard type that's embedded in a user type, it could cause that user type to no longer satisfy existing interfaces due to ambiguity, which is a risk unique to adding new methods.",1,doc clarify that new methods may be added to standard library types currently the document states that exported structs in the standard library may add new fields but it doesn t mention that they may add new methods too to date every go release has added new methods to existing types for selector expressions the risk of ambiguity from new methods is the same as for new fields but if a new method is added to a standard type that s embedded in a user type it could cause that user type to no longer satisfy existing interfaces due to ambiguity which is a risk unique to adding new methods ,1 +80005,10149101863.0,IssuesEvent,2019-08-05 14:33:13,golang/go,https://api.github.com/repos/golang/go,opened,doc: add Unicode 11 support to Go 1.13 release notes,Documentation NeedsFix release-blocker,"Tracking issue for Unicode 11 support: #27945 +APIs changed: + +``` +pkg unicode, const Version = ""11.0.0"" +pkg unicode, var Dogra *RangeTable +pkg unicode, var Gunjala_Gondi *RangeTable +pkg unicode, var Hanifi_Rohingya *RangeTable +pkg unicode, var Makasar *RangeTable +pkg unicode, var Medefaidrin *RangeTable +pkg unicode, var Old_Sogdian *RangeTable +pkg unicode, var Sogdian *RangeTable +``` + +/cc @mpvl ",1.0,"doc: add Unicode 11 support to Go 1.13 release notes - Tracking issue for Unicode 11 support: #27945 +APIs changed: + +``` +pkg unicode, const Version = ""11.0.0"" +pkg unicode, var Dogra *RangeTable +pkg unicode, var Gunjala_Gondi *RangeTable +pkg unicode, var Hanifi_Rohingya *RangeTable +pkg unicode, var Makasar *RangeTable +pkg unicode, var Medefaidrin *RangeTable +pkg unicode, var Old_Sogdian *RangeTable +pkg unicode, var Sogdian *RangeTable +``` + +/cc @mpvl ",1,doc add unicode support to go release notes tracking issue for unicode support apis changed pkg unicode const version pkg unicode var dogra rangetable pkg unicode var gunjala gondi rangetable pkg unicode var hanifi rohingya rangetable pkg unicode var makasar rangetable pkg unicode var medefaidrin rangetable pkg unicode var old sogdian rangetable pkg unicode var sogdian rangetable cc mpvl ,1 +32656,6101589302.0,IssuesEvent,2017-06-20 14:53:48,golang/go,https://api.github.com/repos/golang/go,closed,Website documentation,Documentation,"If we open exaple on page https://golang.org/pkg/go/parser/ and run in play. +### what you see? + +open example_test.go: No such file or directory + +### What did you expect to see? + +The result of snippet code + + +",1.0,"Website documentation - If we open exaple on page https://golang.org/pkg/go/parser/ and run in play. +### what you see? + +open example_test.go: No such file or directory + +### What did you expect to see? + +The result of snippet code + + +",1,website documentation if we open exaple on page and run in play what you see open example test go no such file or directory what did you expect to see the result of snippet code ,1 +70345,9403660307.0,IssuesEvent,2019-04-09 02:25:58,golang/go,https://api.github.com/repos/golang/go,closed,spec: poorly documented slice definition syntax,Documentation WaitingForInfo," + +### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.11.1 linux/amd64 ++But also on Windows and in Go 1.12 + +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/felian/.cache/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/felian/go_code"" +GOPROXY="""" +GORACE="""" +GOROOT=""/usr/local/go"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build955872785=/tmp/go-build -gno-record-gcc-switches"" + +
package main
+import ""fmt""
+func main() { fmt.Println([]int{1, 2, 3, 7: 3, 6, 7}) }
+fmt.Println([20]int{1, 2, 3, 7: 11, 12, 13: 10})
+fmt.Println([30]int{1, 2, 3, 7: 11, 12, 13: 10, 18: 11, 25})
+
+
+### What did you expect to see?
+
+This syntax should be well documented or invalid.
+
+I found one example of this after ""Examples of valid array, slice, and map literals:"" in [language specification](https://golang.org/ref/spec). But it seems not enough.
+
+### What did you see instead?
+
+This syntax is valid and seems poorly documented.
+
+Thanks for directions to @irwinnoteam2009",1.0,"spec: poorly documented slice definition syntax -
+
+### What version of Go are you using (`go version`)?
+
++$ go version +go version go1.11.1 linux/amd64 ++But also on Windows and in Go 1.12 + +### Does this issue reproduce with the latest release? + +Yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/felian/.cache/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/felian/go_code"" +GOPROXY="""" +GORACE="""" +GOROOT=""/usr/local/go"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build955872785=/tmp/go-build -gno-record-gcc-switches"" + +
package main
+import ""fmt""
+func main() { fmt.Println([]int{1, 2, 3, 7: 3, 6, 7}) }
+fmt.Println([20]int{1, 2, 3, 7: 11, 12, 13: 10})
+fmt.Println([30]int{1, 2, 3, 7: 11, 12, 13: 10, 18: 11, 25})
+
+
+### What did you expect to see?
+
+This syntax should be well documented or invalid.
+
+I found one example of this after ""Examples of valid array, slice, and map literals:"" in [language specification](https://golang.org/ref/spec). But it seems not enough.
+
+### What did you see instead?
+
+This syntax is valid and seems poorly documented.
+
+Thanks for directions to @irwinnoteam2009",1,spec poorly documented slice definition syntax what version of go are you using go version go version go version linux but also on windows and in go does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env go env output go env goarch gobin gocache home felian cache go build goexe goflags gohostarch gohostos linux goos linux gopath home felian go code goproxy gorace goroot usr local go gotmpdir gotooldir usr local go pkg tool linux gccgo gccgo cc gcc cxx g cgo enabled gomod cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fmessage length fdebug prefix map tmp go tmp go build gno record gcc switches what did you do if possible provide a recipe for reproducing the error a complete runnable program is good a link on play golang org is best package main import fmt func main fmt println int also works nicely with arrays and with multiple fmt println int fmt println int what did you expect to see this syntax should be well documented or invalid i found one example of this after examples of valid array slice and map literals in but it seems not enough what did you see instead this syntax is valid and seems poorly documented thanks for directions to ,1
+295328,22207963410.0,IssuesEvent,2022-06-07 16:23:52,golang/go,https://api.github.com/repos/golang/go,closed,go/doc: find a better home for Go documentation features like section headings,Documentation NeedsFix,"[fluhus/godoc-tricks](https://github.com/fluhus/godoc-tricks) describes several extended tricks for the Godoc renderer that remain relevant for https://pkg.go.dev. Particularly notable is the technique described as [Titles](https://pkg.go.dev/github.com/fluhus/godoc-tricks#Titles), which can be thought of as naive section headings as demonstrated below with the word ""Limitations"":
+
+```go
+// CreditCard models a lender-backed payment instrument.
+//
+// Limitations
+//
+// The type provides no native validation against its issuer. It is a dumb data type.
+type CreditCard struct{}
+```
+
+To date this technique is not substantively mentioned in any of the following:
+
+* https://blog.golang.org/godoc
+* https://golang.org/pkg/go/doc/ (minor prosaic allusion)
+
+Considering its utility for information presentation, anchoring, etc., I propose the feature earn proper documentation. I tried to search for an existing bug for this, but the closest thing I could find was https://github.com/golang/go/issues/18342. The correct approach would probably involve amending the previous documents somehow (or maybe another).",1.0,"go/doc: find a better home for Go documentation features like section headings - [fluhus/godoc-tricks](https://github.com/fluhus/godoc-tricks) describes several extended tricks for the Godoc renderer that remain relevant for https://pkg.go.dev. Particularly notable is the technique described as [Titles](https://pkg.go.dev/github.com/fluhus/godoc-tricks#Titles), which can be thought of as naive section headings as demonstrated below with the word ""Limitations"":
+
+```go
+// CreditCard models a lender-backed payment instrument.
+//
+// Limitations
+//
+// The type provides no native validation against its issuer. It is a dumb data type.
+type CreditCard struct{}
+```
+
+To date this technique is not substantively mentioned in any of the following:
+
+* https://blog.golang.org/godoc
+* https://golang.org/pkg/go/doc/ (minor prosaic allusion)
+
+Considering its utility for information presentation, anchoring, etc., I propose the feature earn proper documentation. I tried to search for an existing bug for this, but the closest thing I could find was https://github.com/golang/go/issues/18342. The correct approach would probably involve amending the previous documents somehow (or maybe another).",1,go doc find a better home for go documentation features like section headings describes several extended tricks for the godoc renderer that remain relevant for particularly notable is the technique described as which can be thought of as naive section headings as demonstrated below with the word limitations go creditcard models a lender backed payment instrument limitations the type provides no native validation against its issuer it is a dumb data type type creditcard struct to date this technique is not substantively mentioned in any of the following minor prosaic allusion considering its utility for information presentation anchoring etc i propose the feature earn proper documentation i tried to search for an existing bug for this but the closest thing i could find was the correct approach would probably involve amending the previous documents somehow or maybe another ,1
+173274,14406753531.0,IssuesEvent,2020-12-03 20:43:06,golang/go,https://api.github.com/repos/golang/go,closed,doc/go1.16: document compiler changes for Go 1.16,Documentation NeedsInvestigation release-blocker,"As of filing this issue, the [Go 1.16 draft release notes](https://tip.golang.org/doc/go1.16) contained the following HTML:
+
++ TODO +
+ +--- + +Per [golang.org/s/release](https://golang.org/s/release), it's a release blocker for Go 1.16 Beta 1 to have a complete draft of the eventual release notes, and so the TODO needs to be resolved. (If there aren't noteworthy compiler changes in Go 1.16, the section should be removed.) + +A sequence of steps to resolve this issue may be: + +1. Come up with a draft release note entry in this issue, then move the issue to NeedsFix state. +2. Send a CL with ""doc/go1.16:"" [prefix](https://go-review.googlesource.com/q/project:go+doc/go1.16) and include ""For #40700. Fixes #{this issue}."" in the body.",1.0,"doc/go1.16: document compiler changes for Go 1.16 - As of filing this issue, the [Go 1.16 draft release notes](https://tip.golang.org/doc/go1.16) contained the following HTML: + ++ TODO +
+ +--- + +Per [golang.org/s/release](https://golang.org/s/release), it's a release blocker for Go 1.16 Beta 1 to have a complete draft of the eventual release notes, and so the TODO needs to be resolved. (If there aren't noteworthy compiler changes in Go 1.16, the section should be removed.) + +A sequence of steps to resolve this issue may be: + +1. Come up with a draft release note entry in this issue, then move the issue to NeedsFix state. +2. Send a CL with ""doc/go1.16:"" [prefix](https://go-review.googlesource.com/q/project:go+doc/go1.16) and include ""For #40700. Fixes #{this issue}."" in the body.",1,doc document compiler changes for go as of filing this issue the contained the following html compiler todo per it s a release blocker for go beta to have a complete draft of the eventual release notes and so the todo needs to be resolved if there aren t noteworthy compiler changes in go the section should be removed a sequence of steps to resolve this issue may be come up with a draft release note entry in this issue then move the issue to needsfix state send a cl with doc and include for fixes this issue in the body ,1 +6395,5408708840.0,IssuesEvent,2017-03-01 01:02:42,golang/go,https://api.github.com/repos/golang/go,closed,runtime: convT2E called for function value ,Performance,"Go 1.8 amd64 linux when running the below program `convT2E` is called for `BenchmarkEfaceFnVal` but not for `BenchmarkEfaceFn`. + +**Program:** +```Go +package main + +import ""testing"" + +func efaceFn(v interface{}) { + return +} + +func BenchmarkEfaceFnVal(b *testing.B) { + b.ReportAllocs() + + efaceFnVal := efaceFn + for i := 0; i < b.N; i++ { + efaceFnVal(0x1) + } +} + +func BenchmarkEfaceFn(b *testing.B) { + b.ReportAllocs() + + for i := 0; i < b.N; i++ { + efaceFn(0x1) + } +} +``` + +**Result:** + +| Name | Iterations | ns/op | B/op | allocs/op | +| -- | -- | -- | -- | -- | +| BenchmarkEfaceFnVal-24 | 20000000 | 60.8 ns/op | 8 B/op | 1 allocs/op | +| BenchmarkEfaceFn-24 | 2000000000 | 0.48 ns/op | 0 B/op | 0 allocs/op | + +",True,"runtime: convT2E called for function value - Go 1.8 amd64 linux when running the below program `convT2E` is called for `BenchmarkEfaceFnVal` but not for `BenchmarkEfaceFn`. + +**Program:** +```Go +package main + +import ""testing"" + +func efaceFn(v interface{}) { + return +} + +func BenchmarkEfaceFnVal(b *testing.B) { + b.ReportAllocs() + + efaceFnVal := efaceFn + for i := 0; i < b.N; i++ { + efaceFnVal(0x1) + } +} + +func BenchmarkEfaceFn(b *testing.B) { + b.ReportAllocs() + + for i := 0; i < b.N; i++ { + efaceFn(0x1) + } +} +``` + +**Result:** + +| Name | Iterations | ns/op | B/op | allocs/op | +| -- | -- | -- | -- | -- | +| BenchmarkEfaceFnVal-24 | 20000000 | 60.8 ns/op | 8 B/op | 1 allocs/op | +| BenchmarkEfaceFn-24 | 2000000000 | 0.48 ns/op | 0 B/op | 0 allocs/op | + +",0,runtime called for function value go linux when running the below program is called for benchmarkefacefnval but not for benchmarkefacefn program go package main import testing func efacefn v interface return func benchmarkefacefnval b testing b b reportallocs efacefnval efacefn for i i b n i efacefnval func benchmarkefacefn b testing b b reportallocs for i i b n i efacefn result name iterations ns op b op allocs op benchmarkefacefnval ns op b op allocs op benchmarkefacefn ns op b op allocs op ,0 +33957,6276688397.0,IssuesEvent,2017-07-18 10:10:22,golang/go,https://api.github.com/repos/golang/go,closed,x/review/git-codereview: -trybot option not documented,Documentation,"Please answer these questions before submitting your issue. Thanks! +1. What version of Go are you using (`go version`)? - + `go version go1.6 darwin/amd64` +2. What operating system and processor architecture are you using (`go env`)? + +``` +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/.../Source/go"" +GORACE="""" +GOROOT=""/usr/local/Cellar/go/1.6/libexec"" +GOTOOLDIR=""/usr/local/Cellar/go/1.6/libexec/pkg/tool/darwin_amd64"" +GO15VENDOREXPERIMENT=""1"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +``` +1. What did you do? + `go codereview mail -h` describes an option, `-trybot`, but neither `go codereview help` nor https://godoc.org/golang.org/x/review/git-codereview describes the option +2. What did you expect to see? + Something telling me what the `-trybot` option does (esp. if I can use it). +3. What did you see instead? + Nothing telling me what `-trybot` does. +",1.0,"x/review/git-codereview: -trybot option not documented - Please answer these questions before submitting your issue. Thanks! +1. What version of Go are you using (`go version`)? - + `go version go1.6 darwin/amd64` +2. What operating system and processor architecture are you using (`go env`)? + +``` +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/.../Source/go"" +GORACE="""" +GOROOT=""/usr/local/Cellar/go/1.6/libexec"" +GOTOOLDIR=""/usr/local/Cellar/go/1.6/libexec/pkg/tool/darwin_amd64"" +GO15VENDOREXPERIMENT=""1"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +``` +1. What did you do? + `go codereview mail -h` describes an option, `-trybot`, but neither `go codereview help` nor https://godoc.org/golang.org/x/review/git-codereview describes the option +2. What did you expect to see? + Something telling me what the `-trybot` option does (esp. if I can use it). +3. What did you see instead? + Nothing telling me what `-trybot` does. +",1,x review git codereview trybot option not documented please answer these questions before submitting your issue thanks what version of go are you using go version go version darwin what operating system and processor architecture are you using go env goarch gobin goexe gohostarch gohostos darwin goos darwin gopath users source go gorace goroot usr local cellar go libexec gotooldir usr local cellar go libexec pkg tool darwin cc clang gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fno common cxx clang cgo enabled what did you do go codereview mail h describes an option trybot but neither go codereview help nor describes the option what did you expect to see something telling me what the trybot option does esp if i can use it what did you see instead nothing telling me what trybot does ,1 +49159,6015199229.0,IssuesEvent,2017-06-07 00:56:33,golang/go,https://api.github.com/repos/golang/go,closed,runtime: spurious error in TestPanicRace,HelpWanted Testing,"Saw on the trybots for CL 45018: + +--- FAIL: TestPanicRace (0.00s) + crash_test.go:584: program exited successfully, should have failed + crash_test.go:587: + crash_test.go:596: did not find expected string ""panic: crash"" + crash_test.go:596: did not find expected string ""PanicRace"" + crash_test.go:596: did not find expected string ""created by "" + +I don't think this has anything to do with my CL, it only does additional compile-time checks, and those checks are not enabled on this builder. Flaky test? + +https://storage.googleapis.com/go-build-log/6c7e4f31/linux-amd64_b2988fea.log +",1.0,"runtime: spurious error in TestPanicRace - Saw on the trybots for CL 45018: + +--- FAIL: TestPanicRace (0.00s) + crash_test.go:584: program exited successfully, should have failed + crash_test.go:587: + crash_test.go:596: did not find expected string ""panic: crash"" + crash_test.go:596: did not find expected string ""PanicRace"" + crash_test.go:596: did not find expected string ""created by "" + +I don't think this has anything to do with my CL, it only does additional compile-time checks, and those checks are not enabled on this builder. Flaky test? + +https://storage.googleapis.com/go-build-log/6c7e4f31/linux-amd64_b2988fea.log +",0,runtime spurious error in testpanicrace saw on the trybots for cl fail testpanicrace crash test go program exited successfully should have failed crash test go crash test go did not find expected string panic crash crash test go did not find expected string panicrace crash test go did not find expected string created by i don t think this has anything to do with my cl it only does additional compile time checks and those checks are not enabled on this builder flaky test ,0 +55774,8029919049.0,IssuesEvent,2018-07-27 17:43:34,golang/go,https://api.github.com/repos/golang/go,closed,syscall: improve NewCallback documentation and panic message,Documentation OS-Windows help wanted,"### What version of Go are you using (`go version`)? +Tip (commit 65d55a13a92a3) + +### Does this issue reproduce with the latest release? +Yes. + +`syscall.NewCallback` (and `syscall.NewCallbackCDecl`) don't describe what's expected of the type of their argument beyond ""it must be a function"". But they do have requirements. For example, if you pass a function with no argument and no results, they panic with ""compileCallback: function must have one output parameter"". I don't actually know what this means a priori, and the `NewCallback` documentation doesn't tell me. The term ""output parameter"" doesn't appear in the Go spec, and it could (and does in this case) mean a result value, or it could mean a C-style output parameter which is actually an input argument that points to where to put the result. + +We should document `NewCallback*`'s requirements and clarify the panic message for when they're violated. + +/cc @alexbrainman ",1.0,"syscall: improve NewCallback documentation and panic message - ### What version of Go are you using (`go version`)? +Tip (commit 65d55a13a92a3) + +### Does this issue reproduce with the latest release? +Yes. + +`syscall.NewCallback` (and `syscall.NewCallbackCDecl`) don't describe what's expected of the type of their argument beyond ""it must be a function"". But they do have requirements. For example, if you pass a function with no argument and no results, they panic with ""compileCallback: function must have one output parameter"". I don't actually know what this means a priori, and the `NewCallback` documentation doesn't tell me. The term ""output parameter"" doesn't appear in the Go spec, and it could (and does in this case) mean a result value, or it could mean a C-style output parameter which is actually an input argument that points to where to put the result. + +We should document `NewCallback*`'s requirements and clarify the panic message for when they're violated. + +/cc @alexbrainman ",1,syscall improve newcallback documentation and panic message what version of go are you using go version tip commit does this issue reproduce with the latest release yes syscall newcallback and syscall newcallbackcdecl don t describe what s expected of the type of their argument beyond it must be a function but they do have requirements for example if you pass a function with no argument and no results they panic with compilecallback function must have one output parameter i don t actually know what this means a priori and the newcallback documentation doesn t tell me the term output parameter doesn t appear in the go spec and it could and does in this case mean a result value or it could mean a c style output parameter which is actually an input argument that points to where to put the result we should document newcallback s requirements and clarify the panic message for when they re violated cc alexbrainman ,1 +321237,23847309952.0,IssuesEvent,2022-09-06 14:55:24,golang/go,https://api.github.com/repos/golang/go,closed,x/tools/gopls: The analyzers documentation doesn't mention some analyzers,Documentation gopls Tools," +### gopls version + + + + +### What did you do? +I read x/tools/gopls/doc/analyzers.md to try to find the setting that would turn off useless messages labelled QF1003. + + +### What did you expect to see? + +Some mention of QF1003, or a hint about where to find information about it. + +### What did you see instead? + +nothing. + +### Editor and settings +",1.0,"x/tools/gopls: The analyzers documentation doesn't mention some analyzers - +### gopls version + + + + +### What did you do? +I read x/tools/gopls/doc/analyzers.md to try to find the setting that would turn off useless messages labelled QF1003. + + +### What did you expect to see? + +Some mention of QF1003, or a hint about where to find information about it. + +### What did you see instead? + +nothing. + +### Editor and settings +",1,x tools gopls the analyzers documentation doesn t mention some analyzers gopls version build info golang org x tools gopls master golang org x tools gopls devel github com burntsushi toml github com google go cmp github com sergi go diff golang org x mod dev kqgndtypbw o golang org x sync golang org x sys rm golang org x text golang org x tools devel golang org x xerrors d honnef co go tools mvdan cc gofumpt mvdan cc xurls tzxjvaj go what did you do i read x tools gopls doc analyzers md to try to find the setting that would turn off useless messages labelled what did you expect to see some mention of or a hint about where to find information about it what did you see instead nothing editor and settings ,1 +26838,7874781602.0,IssuesEvent,2018-06-25 18:11:58,golang/go,https://api.github.com/repos/golang/go,opened,x/build: add js/wasm Chrome/Firefox capable trybot,Arch-Wasm Builders NeedsDecision,"Follow on from https://github.com/golang/go/issues/26015#issuecomment-400029578 + +With a Chrome and/or Firefox capable trybot we'd be able to do more interesting WASM tests in a headless browser-based JS VM, and so have access to the DOM etc. + +This issue is to decide whether or not such a trybot would be useful and therefore worth the effort.",1.0,"x/build: add js/wasm Chrome/Firefox capable trybot - Follow on from https://github.com/golang/go/issues/26015#issuecomment-400029578 + +With a Chrome and/or Firefox capable trybot we'd be able to do more interesting WASM tests in a headless browser-based JS VM, and so have access to the DOM etc. + +This issue is to decide whether or not such a trybot would be useful and therefore worth the effort.",0,x build add js wasm chrome firefox capable trybot follow on from with a chrome and or firefox capable trybot we d be able to do more interesting wasm tests in a headless browser based js vm and so have access to the dom etc this issue is to decide whether or not such a trybot would be useful and therefore worth the effort ,0 +385257,26627505520.0,IssuesEvent,2023-01-24 15:30:33,golang/go,https://api.github.com/repos/golang/go,closed,"x/website: Fuzzing documentation image has transparent background, works poorly with dark mode",Documentation NeedsFix website,"The fuzzing page, https://tip.golang.org/security/fuzz/, has an image describing different components involved. It however has a transparent background, and with the page supporting dark mode, the image gets very tricky to read: + + +I'm not sure if having a opaque white background would be problematic, but that seems to be the easiest solution.",1.0,"x/website: Fuzzing documentation image has transparent background, works poorly with dark mode - The fuzzing page, https://tip.golang.org/security/fuzz/, has an image describing different components involved. It however has a transparent background, and with the page supporting dark mode, the image gets very tricky to read: + + +I'm not sure if having a opaque white background would be problematic, but that seems to be the easiest solution.",1,x website fuzzing documentation image has transparent background works poorly with dark mode the fuzzing page has an image describing different components involved it however has a transparent background and with the page supporting dark mode the image gets very tricky to read i m not sure if having a opaque white background would be problematic but that seems to be the easiest solution ,1 +3636,3973715029.0,IssuesEvent,2016-05-04 19:34:37,golang/go,https://api.github.com/repos/golang/go,opened,cmd/compile: precalculate constant square roots,Performance,"Low priority, but probably also an easy ssa rule. + +```go +package x + +import ""math"" + +func root2() float64 { + return math.Sqrt(2) +} +``` + +yields (amd64): + +``` +"""".root2 t=1 size=32 args=0x8 locals=0x0 + 0x0000 00000 (/Volumes/Data/src/go.tip/src/sqrt.go:5) TEXT """".root2(SB), $0-8 + 0x0000 00000 (/Volumes/Data/src/go.tip/src/sqrt.go:5) NOP + 0x0000 00000 (/Volumes/Data/src/go.tip/src/sqrt.go:5) NOP + 0x0000 00000 (/Volumes/Data/src/go.tip/src/sqrt.go:5) FUNCDATA $0, gclocals·5184031d3a32a42d85027f073f873668(SB) + 0x0000 00000 (/Volumes/Data/src/go.tip/src/sqrt.go:5) FUNCDATA $1, gclocals·33cdeccccebe80329f1fdbee7f5874cb(SB) + 0x0000 00000 (/Volumes/Data/src/go.tip/src/sqrt.go:6) MOVSD $f64.4000000000000000(SB), X0 + 0x0008 00008 (/Volumes/Data/src/go.tip/src/sqrt.go:6) SQRTSD X0, X0 + 0x000c 00012 (/Volumes/Data/src/go.tip/src/sqrt.go:6) MOVSD X0, """".~r0+8(FP) + 0x0012 00018 (/Volumes/Data/src/go.tip/src/sqrt.go:6) RET +``` + +But sqrt(2) is a constant. + +cc @randall77 @brtzsnr +",True,"cmd/compile: precalculate constant square roots - Low priority, but probably also an easy ssa rule. + +```go +package x + +import ""math"" + +func root2() float64 { + return math.Sqrt(2) +} +``` + +yields (amd64): + +``` +"""".root2 t=1 size=32 args=0x8 locals=0x0 + 0x0000 00000 (/Volumes/Data/src/go.tip/src/sqrt.go:5) TEXT """".root2(SB), $0-8 + 0x0000 00000 (/Volumes/Data/src/go.tip/src/sqrt.go:5) NOP + 0x0000 00000 (/Volumes/Data/src/go.tip/src/sqrt.go:5) NOP + 0x0000 00000 (/Volumes/Data/src/go.tip/src/sqrt.go:5) FUNCDATA $0, gclocals·5184031d3a32a42d85027f073f873668(SB) + 0x0000 00000 (/Volumes/Data/src/go.tip/src/sqrt.go:5) FUNCDATA $1, gclocals·33cdeccccebe80329f1fdbee7f5874cb(SB) + 0x0000 00000 (/Volumes/Data/src/go.tip/src/sqrt.go:6) MOVSD $f64.4000000000000000(SB), X0 + 0x0008 00008 (/Volumes/Data/src/go.tip/src/sqrt.go:6) SQRTSD X0, X0 + 0x000c 00012 (/Volumes/Data/src/go.tip/src/sqrt.go:6) MOVSD X0, """".~r0+8(FP) + 0x0012 00018 (/Volumes/Data/src/go.tip/src/sqrt.go:6) RET +``` + +But sqrt(2) is a constant. + +cc @randall77 @brtzsnr +",0,cmd compile precalculate constant square roots low priority but probably also an easy ssa rule go package x import math func return math sqrt yields t size args locals volumes data src go tip src sqrt go text sb volumes data src go tip src sqrt go nop volumes data src go tip src sqrt go nop volumes data src go tip src sqrt go funcdata gclocals· sb volumes data src go tip src sqrt go funcdata gclocals· sb volumes data src go tip src sqrt go movsd sb volumes data src go tip src sqrt go sqrtsd volumes data src go tip src sqrt go movsd fp volumes data src go tip src sqrt go ret but sqrt is a constant cc brtzsnr ,0 +50208,6065411421.0,IssuesEvent,2017-06-14 16:09:35,golang/go,https://api.github.com/repos/golang/go,closed,runtime/pprof: TestMutexProfile flakiness,Testing,"On the builders, I see TestMutexProfile occasionally failing with +``` +--- FAIL: TestMutexProfile (0.01s) + pprof_test.go:532: expected 6 lines, got 3 ""--- mutex:\ncycles/second=2362842166\nsampling period=1"" + --- mutex: + cycles/second=2362842166 + sampling period=1 +FAIL +FAIL runtime/pprof 1.298s +``` + +Maybe freebsd only? + +@pjweinb + +Some builder logs: +https://build.golang.org/log/c625cca078dac40bc5f1f50b62891c04b52308c5 +https://build.golang.org/log/118de984fc0903fe93c3e677962cd7965637a2a3",1.0,"runtime/pprof: TestMutexProfile flakiness - On the builders, I see TestMutexProfile occasionally failing with +``` +--- FAIL: TestMutexProfile (0.01s) + pprof_test.go:532: expected 6 lines, got 3 ""--- mutex:\ncycles/second=2362842166\nsampling period=1"" + --- mutex: + cycles/second=2362842166 + sampling period=1 +FAIL +FAIL runtime/pprof 1.298s +``` + +Maybe freebsd only? + +@pjweinb + +Some builder logs: +https://build.golang.org/log/c625cca078dac40bc5f1f50b62891c04b52308c5 +https://build.golang.org/log/118de984fc0903fe93c3e677962cd7965637a2a3",0,runtime pprof testmutexprofile flakiness on the builders i see testmutexprofile occasionally failing with fail testmutexprofile pprof test go expected lines got mutex ncycles second nsampling period mutex cycles second sampling period fail fail runtime pprof maybe freebsd only pjweinb some builder logs ,0 +85647,24647589337.0,IssuesEvent,2022-10-17 15:55:53,golang/go,https://api.github.com/repos/golang/go,closed,net/http: TestIssue4191_InfiniteGetTimeout is flaky again on the freebsd/arm builder,OS-FreeBSD Builders,"``` +ok net 13.891s +2022/10/14 23:31:37 http: TLS handshake error from 127.0.0.1:42528: read tcp 127.0.0.1:42527->127.0.0.1:42528: read: connection reset by peer +2022/10/14 23:31:37 http2: server: error reading preface from client 127.0.0.1:42531: local error: tls: bad record MAC +2022/10/14 23:31:40 http: TLS handshake error from 127.0.0.1:42548: read tcp 127.0.0.1:42547->127.0.0.1:42548: read: connection reset by peer +--- FAIL: TestIssue4191_InfiniteGetTimeout (0.00s) + --- FAIL: TestIssue4191_InfiniteGetTimeout/h1 (1.77s) + transport_test.go:2170: increasing timeout + transport_test.go:2175: Error issuing GET: Get ""https://127.0.0.1:42527/get"": write tcp 127.0.0.1:42531->127.0.0.1:42527: i/o timeout +2022/10/14 23:31:47 http2: server: error reading preface from client 127.0.0.1:42638: bogus greeting ""CONNECT golang.fake.tld:"" +2022/10/14 23:31:48 http2: server: error reading preface from client 127.0.0.1:42647: bogus greeting ""CONNECT golang.fake.tld:"" +2022/10/14 23:31:49 http: TLS handshake error from 127.0.0.1:42694: write tcp 127.0.0.1:42693->127.0.0.1:42694: i/o timeout +2022/10/14 23:31:50 http: TLS handshake error from 127.0.0.1:42698: write tcp 127.0.0.1:42697->127.0.0.1:42698: i/o timeout +2022/10/14 23:31:50 http: TLS handshake error from 127.0.0.1:42700: write tcp 127.0.0.1:42699->127.0.0.1:42700: i/o timeout +2022/10/14 23:31:50 http: TLS handshake error from 127.0.0.1:42704: write tcp 127.0.0.1:42703->127.0.0.1:42704: i/o timeout +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42863: read tcp 127.0.0.1:42858->127.0.0.1:42863: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42868: write tcp 127.0.0.1:42858->127.0.0.1:42868: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42860: write tcp 127.0.0.1:42858->127.0.0.1:42860: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42859: write tcp 127.0.0.1:42858->127.0.0.1:42859: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42875: write tcp 127.0.0.1:42869->127.0.0.1:42875: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42877: write tcp 127.0.0.1:42869->127.0.0.1:42877: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42873: write tcp 127.0.0.1:42869->127.0.0.1:42873: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42878: write tcp 127.0.0.1:42869->127.0.0.1:42878: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42879: write tcp 127.0.0.1:42869->127.0.0.1:42879: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42871: write tcp 127.0.0.1:42869->127.0.0.1:42871: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42874: write tcp 127.0.0.1:42869->127.0.0.1:42874: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42862: write tcp 127.0.0.1:42858->127.0.0.1:42862: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42876: write tcp 127.0.0.1:42869->127.0.0.1:42876: use of closed network connection +2022/10/14 23:32:04 http: TLS handshake error from 127.0.0.1:42956: EOF +2022/10/14 23:32:04 http: TLS handshake error from 127.0.0.1:42958: EOF +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43076: EOF +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43079: read tcp 127.0.0.1:43078->127.0.0.1:43079: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43083: read tcp 127.0.0.1:43075->127.0.0.1:43083: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43077: read tcp 127.0.0.1:43075->127.0.0.1:43077: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43082: read tcp 127.0.0.1:43078->127.0.0.1:43082: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43084: read tcp 127.0.0.1:43078->127.0.0.1:43084: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43085: read tcp 127.0.0.1:43075->127.0.0.1:43085: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43087: read tcp 127.0.0.1:43075->127.0.0.1:43087: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43086: read tcp 127.0.0.1:43078->127.0.0.1:43086: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43088: read tcp 127.0.0.1:43078->127.0.0.1:43088: read: connection reset by peer +FAIL +FAIL net/http 91.402s +``` + +https://build.golang.org/log/b40a6e5b2861f487c38fae158286aac8f1120768",1.0,"net/http: TestIssue4191_InfiniteGetTimeout is flaky again on the freebsd/arm builder - ``` +ok net 13.891s +2022/10/14 23:31:37 http: TLS handshake error from 127.0.0.1:42528: read tcp 127.0.0.1:42527->127.0.0.1:42528: read: connection reset by peer +2022/10/14 23:31:37 http2: server: error reading preface from client 127.0.0.1:42531: local error: tls: bad record MAC +2022/10/14 23:31:40 http: TLS handshake error from 127.0.0.1:42548: read tcp 127.0.0.1:42547->127.0.0.1:42548: read: connection reset by peer +--- FAIL: TestIssue4191_InfiniteGetTimeout (0.00s) + --- FAIL: TestIssue4191_InfiniteGetTimeout/h1 (1.77s) + transport_test.go:2170: increasing timeout + transport_test.go:2175: Error issuing GET: Get ""https://127.0.0.1:42527/get"": write tcp 127.0.0.1:42531->127.0.0.1:42527: i/o timeout +2022/10/14 23:31:47 http2: server: error reading preface from client 127.0.0.1:42638: bogus greeting ""CONNECT golang.fake.tld:"" +2022/10/14 23:31:48 http2: server: error reading preface from client 127.0.0.1:42647: bogus greeting ""CONNECT golang.fake.tld:"" +2022/10/14 23:31:49 http: TLS handshake error from 127.0.0.1:42694: write tcp 127.0.0.1:42693->127.0.0.1:42694: i/o timeout +2022/10/14 23:31:50 http: TLS handshake error from 127.0.0.1:42698: write tcp 127.0.0.1:42697->127.0.0.1:42698: i/o timeout +2022/10/14 23:31:50 http: TLS handshake error from 127.0.0.1:42700: write tcp 127.0.0.1:42699->127.0.0.1:42700: i/o timeout +2022/10/14 23:31:50 http: TLS handshake error from 127.0.0.1:42704: write tcp 127.0.0.1:42703->127.0.0.1:42704: i/o timeout +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42863: read tcp 127.0.0.1:42858->127.0.0.1:42863: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42868: write tcp 127.0.0.1:42858->127.0.0.1:42868: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42860: write tcp 127.0.0.1:42858->127.0.0.1:42860: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42859: write tcp 127.0.0.1:42858->127.0.0.1:42859: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42875: write tcp 127.0.0.1:42869->127.0.0.1:42875: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42877: write tcp 127.0.0.1:42869->127.0.0.1:42877: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42873: write tcp 127.0.0.1:42869->127.0.0.1:42873: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42878: write tcp 127.0.0.1:42869->127.0.0.1:42878: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42879: write tcp 127.0.0.1:42869->127.0.0.1:42879: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42871: write tcp 127.0.0.1:42869->127.0.0.1:42871: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42874: write tcp 127.0.0.1:42869->127.0.0.1:42874: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42862: write tcp 127.0.0.1:42858->127.0.0.1:42862: use of closed network connection +2022/10/14 23:32:01 http: TLS handshake error from 127.0.0.1:42876: write tcp 127.0.0.1:42869->127.0.0.1:42876: use of closed network connection +2022/10/14 23:32:04 http: TLS handshake error from 127.0.0.1:42956: EOF +2022/10/14 23:32:04 http: TLS handshake error from 127.0.0.1:42958: EOF +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43076: EOF +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43079: read tcp 127.0.0.1:43078->127.0.0.1:43079: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43083: read tcp 127.0.0.1:43075->127.0.0.1:43083: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43077: read tcp 127.0.0.1:43075->127.0.0.1:43077: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43082: read tcp 127.0.0.1:43078->127.0.0.1:43082: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43084: read tcp 127.0.0.1:43078->127.0.0.1:43084: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43085: read tcp 127.0.0.1:43075->127.0.0.1:43085: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43087: read tcp 127.0.0.1:43075->127.0.0.1:43087: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43086: read tcp 127.0.0.1:43078->127.0.0.1:43086: read: connection reset by peer +2022/10/14 23:32:13 http: TLS handshake error from 127.0.0.1:43088: read tcp 127.0.0.1:43078->127.0.0.1:43088: read: connection reset by peer +FAIL +FAIL net/http 91.402s +``` + +https://build.golang.org/log/b40a6e5b2861f487c38fae158286aac8f1120768",0,net http infinitegettimeout is flaky again on the freebsd arm builder ok net http tls handshake error from read tcp read connection reset by peer server error reading preface from client local error tls bad record mac http tls handshake error from read tcp read connection reset by peer fail infinitegettimeout fail infinitegettimeout transport test go increasing timeout transport test go error issuing get get write tcp i o timeout server error reading preface from client bogus greeting connect golang fake tld server error reading preface from client bogus greeting connect golang fake tld http tls handshake error from write tcp i o timeout http tls handshake error from write tcp i o timeout http tls handshake error from write tcp i o timeout http tls handshake error from write tcp i o timeout http tls handshake error from read tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from eof http tls handshake error from eof http tls handshake error from eof http tls handshake error from read tcp read connection reset by peer http tls handshake error from read tcp read connection reset by peer http tls handshake error from read tcp read connection reset by peer http tls handshake error from read tcp read connection reset by peer http tls handshake error from read tcp read connection reset by peer http tls handshake error from read tcp read connection reset by peer http tls handshake error from read tcp read connection reset by peer http tls handshake error from read tcp read connection reset by peer http tls handshake error from read tcp read connection reset by peer fail fail net http ,0 +81979,10265943341.0,IssuesEvent,2019-08-22 20:08:58,golang/go,https://api.github.com/repos/golang/go,closed,"os, syscall: changes to os.Err* and syscall.Errno not mentioned in release notes and syscall package docs",Documentation NeedsFix release-blocker,"The changes made to the `os` and `syscall` package for #30322 are not mentioned in the Go 1.13 release notes, nor in the documentation for `syscall.Errno` or the `syscall` package. + +Because users in general cannot redefine the error behavior of the errors defined by their dependencies, as a user I would not expect `syscall.Errno` errors to be defined as equivalent to errors defined in the higher-level `os` package. As noted in #32463 and #33411, the fact that they are has significant, non-trivial implications. + +If `errors.Is` is now recommended and supported for checking the properties of `syscall.Errno` errors, the `syscall.Errno` documentation and the Go 1.13 release notes should be updated to mention that. + +CC @neild @jba @mpvl @rsc @andybons @ianlancetaylor ",1.0,"os, syscall: changes to os.Err* and syscall.Errno not mentioned in release notes and syscall package docs - The changes made to the `os` and `syscall` package for #30322 are not mentioned in the Go 1.13 release notes, nor in the documentation for `syscall.Errno` or the `syscall` package. + +Because users in general cannot redefine the error behavior of the errors defined by their dependencies, as a user I would not expect `syscall.Errno` errors to be defined as equivalent to errors defined in the higher-level `os` package. As noted in #32463 and #33411, the fact that they are has significant, non-trivial implications. + +If `errors.Is` is now recommended and supported for checking the properties of `syscall.Errno` errors, the `syscall.Errno` documentation and the Go 1.13 release notes should be updated to mention that. + +CC @neild @jba @mpvl @rsc @andybons @ianlancetaylor ",1,os syscall changes to os err and syscall errno not mentioned in release notes and syscall package docs the changes made to the os and syscall package for are not mentioned in the go release notes nor in the documentation for syscall errno or the syscall package because users in general cannot redefine the error behavior of the errors defined by their dependencies as a user i would not expect syscall errno errors to be defined as equivalent to errors defined in the higher level os package as noted in and the fact that they are has significant non trivial implications if errors is is now recommended and supported for checking the properties of syscall errno errors the syscall errno documentation and the go release notes should be updated to mention that cc neild jba mpvl rsc andybons ianlancetaylor ,1 +22096,4772943492.0,IssuesEvent,2016-10-26 22:25:48,golang/go,https://api.github.com/repos/golang/go,closed,net/http: ambiguous sentence in docs for Response.ParseForm,Documentation NeedsFix,"Please answer these questions before submitting your issue. Thanks! + +1 What version of Go are you using (`go version`)? + +go1.6.2 + +2 What operating system and processor architecture are you using (`go env`)? + +``` +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/cjohnson/Documents/Code/Golang"" +GORACE="""" +GOROOT=""/usr/local/Cellar/go/1.6.2/libexec"" +GOTOOLDIR=""/usr/local/Cellar/go/1.6.2/libexec/pkg/tool/darwin_amd64"" +GO15VENDOREXPERIMENT=""1"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +``` + +3 What did you do? + +```shell +$ go doc http.ParseForm +func (r *Request) ParseForm() error + ParseForm parses the raw query from the URL and updates r.Form. + + For POST or PUT requests, it also parses the request body as a form and put + the results into both r.PostForm and r.Form. POST and PUT body parameters + take precedence over URL query string values in r.Form. + + If the request Body's size has not already been limited by MaxBytesReader, + the size is capped at 10MB. + + ParseMultipartForm calls ParseForm automatically. It is idempotent. +``` + +4 What did you expect to see? + +Grammatically unambiguous documentation. + +5 What did you see instead? + +In ""It is idempotent,"" ""it"" ambiguously refers to `ParseForm` or `ParseMultipartForm` or both. + +I think it should be `ParseForm`, but I'm not sure. Maybe both?",1.0,"net/http: ambiguous sentence in docs for Response.ParseForm - Please answer these questions before submitting your issue. Thanks! + +1 What version of Go are you using (`go version`)? + +go1.6.2 + +2 What operating system and processor architecture are you using (`go env`)? + +``` +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/cjohnson/Documents/Code/Golang"" +GORACE="""" +GOROOT=""/usr/local/Cellar/go/1.6.2/libexec"" +GOTOOLDIR=""/usr/local/Cellar/go/1.6.2/libexec/pkg/tool/darwin_amd64"" +GO15VENDOREXPERIMENT=""1"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +``` + +3 What did you do? + +```shell +$ go doc http.ParseForm +func (r *Request) ParseForm() error + ParseForm parses the raw query from the URL and updates r.Form. + + For POST or PUT requests, it also parses the request body as a form and put + the results into both r.PostForm and r.Form. POST and PUT body parameters + take precedence over URL query string values in r.Form. + + If the request Body's size has not already been limited by MaxBytesReader, + the size is capped at 10MB. + + ParseMultipartForm calls ParseForm automatically. It is idempotent. +``` + +4 What did you expect to see? + +Grammatically unambiguous documentation. + +5 What did you see instead? + +In ""It is idempotent,"" ""it"" ambiguously refers to `ParseForm` or `ParseMultipartForm` or both. + +I think it should be `ParseForm`, but I'm not sure. Maybe both?",1,net http ambiguous sentence in docs for response parseform please answer these questions before submitting your issue thanks what version of go are you using go version what operating system and processor architecture are you using go env goarch gobin goexe gohostarch gohostos darwin goos darwin gopath users cjohnson documents code golang gorace goroot usr local cellar go libexec gotooldir usr local cellar go libexec pkg tool darwin cc clang gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fno common cxx clang cgo enabled what did you do shell go doc http parseform func r request parseform error parseform parses the raw query from the url and updates r form for post or put requests it also parses the request body as a form and put the results into both r postform and r form post and put body parameters take precedence over url query string values in r form if the request body s size has not already been limited by maxbytesreader the size is capped at parsemultipartform calls parseform automatically it is idempotent what did you expect to see grammatically unambiguous documentation what did you see instead in it is idempotent it ambiguously refers to parseform or parsemultipartform or both i think it should be parseform but i m not sure maybe both ,1 +77383,9993917866.0,IssuesEvent,2019-07-11 16:21:52,golang/go,https://api.github.com/repos/golang/go,closed,x/tools/gopls: handle 404-ing links in documentLink,Documentation gopls,"Related to discussion on https://github.com/microsoft/vscode-go/issues/2614. +Would it be reasonable to test that a link is valid in `textDocument/documentLink`?",1.0,"x/tools/gopls: handle 404-ing links in documentLink - Related to discussion on https://github.com/microsoft/vscode-go/issues/2614. +Would it be reasonable to test that a link is valid in `textDocument/documentLink`?",1,x tools gopls handle ing links in documentlink related to discussion on would it be reasonable to test that a link is valid in textdocument documentlink ,1 +75882,7495377306.0,IssuesEvent,2018-04-07 20:08:16,golang/go,https://api.github.com/repos/golang/go,closed,cmd/go: TestLocalImportsEasy flake,OS-Windows Testing help wanted,"https://build.golang.org/log/cadb4ff3677483c2818a2ec0fa8a3d6a08f73f6a + +``` +--- FAIL: TestLocalImportsEasy (0.58s) + go_test.go:1162: running testgo [build -o ./easy.exe testdata\local\easy.go] + go_test.go:1163: remove ./easy.exe: Access is denied. +FAIL +FAIL cmd/go 165.352s +``` + +Looks like something like this happened before: https://github.com/golang/go/issues/11217 + +The fix there was to make sure that executable filenames are distinct. From a quick glance, it appears to me that `testLocalEasy` is called from two locations in cmd/go/go_test.go, and it appears superficially that both locations would end up using `easy.exe`. Similarly so for `testLocalEasySub`, `testLocalHard`, and maybe others. Maybe the same fix is called for here? + +cc @alexbrainman @ianlancetaylor +",1.0,"cmd/go: TestLocalImportsEasy flake - https://build.golang.org/log/cadb4ff3677483c2818a2ec0fa8a3d6a08f73f6a + +``` +--- FAIL: TestLocalImportsEasy (0.58s) + go_test.go:1162: running testgo [build -o ./easy.exe testdata\local\easy.go] + go_test.go:1163: remove ./easy.exe: Access is denied. +FAIL +FAIL cmd/go 165.352s +``` + +Looks like something like this happened before: https://github.com/golang/go/issues/11217 + +The fix there was to make sure that executable filenames are distinct. From a quick glance, it appears to me that `testLocalEasy` is called from two locations in cmd/go/go_test.go, and it appears superficially that both locations would end up using `easy.exe`. Similarly so for `testLocalEasySub`, `testLocalHard`, and maybe others. Maybe the same fix is called for here? + +cc @alexbrainman @ianlancetaylor +",0,cmd go testlocalimportseasy flake fail testlocalimportseasy go test go running testgo go test go remove easy exe access is denied fail fail cmd go looks like something like this happened before the fix there was to make sure that executable filenames are distinct from a quick glance it appears to me that testlocaleasy is called from two locations in cmd go go test go and it appears superficially that both locations would end up using easy exe similarly so for testlocaleasysub testlocalhard and maybe others maybe the same fix is called for here cc alexbrainman ianlancetaylor ,0 +38930,6714864270.0,IssuesEvent,2017-10-13 18:39:20,golang/go,https://api.github.com/repos/golang/go,reopened,database/sql: unclear docs for Tx cause races in sql/driver implementations,Documentation NeedsFix,"### What version of Go are you using (`go version`)? + +`go version go1.8.3 darwin/amd64` + +### What did you do? + +Unlike `Conn` or `Stmt` there's no guidance on `Tx` indicating how the stdlib uses implementations. This seems to cause bugs in driver implementations, as a `Tx` is expected to handle concurrent calls from multiple goroutines unlike most of the other interfaces in the package. + +This came up as I was debugging [a panic inside of lib/pq](https://github.com/lib/pq/issues/614) and discovered it was a data race due to the authors not assuming that their `Tx` would have to deal with calls from multiple goroutines (the repro is [here](https://gist.github.com/blinsay/044f39176eeab7f3020d1b527df5bdd7). It slowly adjusts timeouts to try and make the Context time out as results are coming back). Out of curiosity, I looked at `go-sql-driver/mysql` and the lack of a race there seems like a happy accident - the Context expiring occasionally causes [an internal error to bubble up](https://github.com/go-sql-driver/mysql/blob/a825be04c652d01442384e9dcdf2cdc3f1eda67f/packets.go#L441-L443), since the authors appear to aggressively check their invariants. + +I'm not sure whether this is a documentation problem or if there's something database/sql could do to make life easier for driver implementors. + +",1.0,"database/sql: unclear docs for Tx cause races in sql/driver implementations - ### What version of Go are you using (`go version`)? + +`go version go1.8.3 darwin/amd64` + +### What did you do? + +Unlike `Conn` or `Stmt` there's no guidance on `Tx` indicating how the stdlib uses implementations. This seems to cause bugs in driver implementations, as a `Tx` is expected to handle concurrent calls from multiple goroutines unlike most of the other interfaces in the package. + +This came up as I was debugging [a panic inside of lib/pq](https://github.com/lib/pq/issues/614) and discovered it was a data race due to the authors not assuming that their `Tx` would have to deal with calls from multiple goroutines (the repro is [here](https://gist.github.com/blinsay/044f39176eeab7f3020d1b527df5bdd7). It slowly adjusts timeouts to try and make the Context time out as results are coming back). Out of curiosity, I looked at `go-sql-driver/mysql` and the lack of a race there seems like a happy accident - the Context expiring occasionally causes [an internal error to bubble up](https://github.com/go-sql-driver/mysql/blob/a825be04c652d01442384e9dcdf2cdc3f1eda67f/packets.go#L441-L443), since the authors appear to aggressively check their invariants. + +I'm not sure whether this is a documentation problem or if there's something database/sql could do to make life easier for driver implementors. + +",1,database sql unclear docs for tx cause races in sql driver implementations what version of go are you using go version go version darwin what did you do unlike conn or stmt there s no guidance on tx indicating how the stdlib uses implementations this seems to cause bugs in driver implementations as a tx is expected to handle concurrent calls from multiple goroutines unlike most of the other interfaces in the package this came up as i was debugging and discovered it was a data race due to the authors not assuming that their tx would have to deal with calls from multiple goroutines the repro is it slowly adjusts timeouts to try and make the context time out as results are coming back out of curiosity i looked at go sql driver mysql and the lack of a race there seems like a happy accident the context expiring occasionally causes since the authors appear to aggressively check their invariants i m not sure whether this is a documentation problem or if there s something database sql could do to make life easier for driver implementors ,1 +5156,2909691363.0,IssuesEvent,2015-06-21 00:25:37,golang/go,https://api.github.com/repos/golang/go,closed,misc/ios: document ideviceinfo,Documentation,detect.go shells out to a command named ideviceinfo. It's not clear how to install this binary and where it comes from. Document the installation steps or give a link to an equivalent doc.,1.0,misc/ios: document ideviceinfo - detect.go shells out to a command named ideviceinfo. It's not clear how to install this binary and where it comes from. Document the installation steps or give a link to an equivalent doc.,1,misc ios document ideviceinfo detect go shells out to a command named ideviceinfo it s not clear how to install this binary and where it comes from document the installation steps or give a link to an equivalent doc ,1 +47788,12122394376.0,IssuesEvent,2020-04-22 10:53:48,golang/go,https://api.github.com/repos/golang/go,closed,cmd/api: tests timing out on plan9-arm builder,Builders NeedsInvestigation OS-Plan9 Testing,"[CL 224619](https://go-review.googlesource.com/c/go/+/224619) slowed the cmd/api tests on plan9_arm from best-case about 1 minute to best-case about 3 minutes, and worst-case timing out after 13 minutes, for example [here](https://build.golang.org/log/f4704e4e0bc49d1d31c722b21e994e3b614eb947 +). + +The CL added code to the cmd/api test to ""warm up the import cache"" by starting 31 `go list -deps -json std` commands in parallel. Each of these 31 commands walks the source and package trees doing a 'stat' (twice) on each of 2562 files, and opens and reads every source file at least twice (once partially, once fully). This is quite hard work on a diskless Raspberry Pi 3 with 1GB of RAM. In the instances where the test times out, it appears the OS has started swapping (to the same file server which holds the source tree -- swapping to SDcard is not really practical). + +The `dist test` command doesn't run cmd/api itself on Plan 9 platforms, because it takes too long. Can I suggest skipping the cmd/api test on plan9_arm for the same reason? + +Alternatively, perhaps a radical idea: instead of forking off separate `go list` commands, burdening the OS with 31 independent garbage-collected address spaces, and producing json text to be re-read and parsed, would it be feasible to do the tree walks internally as goroutines?",1.0,"cmd/api: tests timing out on plan9-arm builder - [CL 224619](https://go-review.googlesource.com/c/go/+/224619) slowed the cmd/api tests on plan9_arm from best-case about 1 minute to best-case about 3 minutes, and worst-case timing out after 13 minutes, for example [here](https://build.golang.org/log/f4704e4e0bc49d1d31c722b21e994e3b614eb947 +). + +The CL added code to the cmd/api test to ""warm up the import cache"" by starting 31 `go list -deps -json std` commands in parallel. Each of these 31 commands walks the source and package trees doing a 'stat' (twice) on each of 2562 files, and opens and reads every source file at least twice (once partially, once fully). This is quite hard work on a diskless Raspberry Pi 3 with 1GB of RAM. In the instances where the test times out, it appears the OS has started swapping (to the same file server which holds the source tree -- swapping to SDcard is not really practical). + +The `dist test` command doesn't run cmd/api itself on Plan 9 platforms, because it takes too long. Can I suggest skipping the cmd/api test on plan9_arm for the same reason? + +Alternatively, perhaps a radical idea: instead of forking off separate `go list` commands, burdening the OS with 31 independent garbage-collected address spaces, and producing json text to be re-read and parsed, would it be feasible to do the tree walks internally as goroutines?",0,cmd api tests timing out on arm builder slowed the cmd api tests on arm from best case about minute to best case about minutes and worst case timing out after minutes for example the cl added code to the cmd api test to warm up the import cache by starting go list deps json std commands in parallel each of these commands walks the source and package trees doing a stat twice on each of files and opens and reads every source file at least twice once partially once fully this is quite hard work on a diskless raspberry pi with of ram in the instances where the test times out it appears the os has started swapping to the same file server which holds the source tree swapping to sdcard is not really practical the dist test command doesn t run cmd api itself on plan platforms because it takes too long can i suggest skipping the cmd api test on arm for the same reason alternatively perhaps a radical idea instead of forking off separate go list commands burdening the os with independent garbage collected address spaces and producing json text to be re read and parsed would it be feasible to do the tree walks internally as goroutines ,0 +3801,4052397921.0,IssuesEvent,2016-05-24 02:17:22,golang/go,https://api.github.com/repos/golang/go,opened,cmd/compile: pointless strength reduction,Performance,"``` +var t [256]byte + +func f(b *[16]byte) { + for i, v := range b { + b[i] = t[v] + } +} +``` +compiles to: +``` + 0x000f 00015 (tmp1.go:7) MOVBLZX (AX), DX + 0x0012 00018 (tmp1.go:7) LEAQ """".t(SB), BX + 0x0019 00025 (tmp1.go:7) MOVBLZX (BX)(DX*1), DX + 0x001d 00029 (tmp1.go:7) MOVQ """".b+8(FP), BX + 0x0022 00034 (tmp1.go:7) MOVB DL, (BX)(CX*1) + 0x0025 00037 (tmp1.go:6) INCQ AX + 0x0028 00040 (tmp1.go:6) INCQ CX + 0x002b 00043 (tmp1.go:6) CMPQ CX, $16 + 0x002f 00047 (tmp1.go:6) JLT $0, 15 +``` +It looks like we strength-reduced the index into `b` into a pointer increment. But the terminating condition still uses the integer, so we end up having 2 induction variables instead of one. We should either compute the terminating condition using an end pointer (and throw away the induction variable CX), or throw away the pointer induction variable (AX) and use an indexed load. + +@brtzsnr ",True,"cmd/compile: pointless strength reduction - ``` +var t [256]byte + +func f(b *[16]byte) { + for i, v := range b { + b[i] = t[v] + } +} +``` +compiles to: +``` + 0x000f 00015 (tmp1.go:7) MOVBLZX (AX), DX + 0x0012 00018 (tmp1.go:7) LEAQ """".t(SB), BX + 0x0019 00025 (tmp1.go:7) MOVBLZX (BX)(DX*1), DX + 0x001d 00029 (tmp1.go:7) MOVQ """".b+8(FP), BX + 0x0022 00034 (tmp1.go:7) MOVB DL, (BX)(CX*1) + 0x0025 00037 (tmp1.go:6) INCQ AX + 0x0028 00040 (tmp1.go:6) INCQ CX + 0x002b 00043 (tmp1.go:6) CMPQ CX, $16 + 0x002f 00047 (tmp1.go:6) JLT $0, 15 +``` +It looks like we strength-reduced the index into `b` into a pointer increment. But the terminating condition still uses the integer, so we end up having 2 induction variables instead of one. We should either compute the terminating condition using an end pointer (and throw away the induction variable CX), or throw away the pointer induction variable (AX) and use an indexed load. + +@brtzsnr ",0,cmd compile pointless strength reduction var t byte func f b byte for i v range b b t compiles to go movblzx ax dx go leaq t sb bx go movblzx bx dx dx go movq b fp bx go movb dl bx cx go incq ax go incq cx go cmpq cx go jlt it looks like we strength reduced the index into b into a pointer increment but the terminating condition still uses the integer so we end up having induction variables instead of one we should either compute the terminating condition using an end pointer and throw away the induction variable cx or throw away the pointer induction variable ax and use an indexed load brtzsnr ,0 +23200,4893247064.0,IssuesEvent,2016-11-18 22:25:54,golang/go,https://api.github.com/repos/golang/go,opened,net: document net.Conn operation after deadline is exceeded,Documentation,"The current phrasing on `net.Conn.SetDeadline` is: +> A deadline is an absolute time after which I/O operations fail with a timeout (see type Error) instead of blocking. The deadline applies to all future and pending I/O, not just the immediately following call to Read or Write. +> +> An idle timeout can be implemented by repeatedly extending the deadline after successful Read or Write calls. +> +> A zero value for t means I/O operations will not time out. + +I'm debugging some non-compliant implementations of `net.Conn` due to the clarification made in ([CL/30164](http://golang.org/cl/30164)). While fixing them, I noticed another discrepancy of some `net.Conn` implementations as compared to `net.TCPConn` and would like some clarification on expected behavior. + +The `net.TCPConn` implementation allows a deadline to be exceeded, which unblocks any pending IO operations. However, it also allows the user to extend the deadline to be in the future, essentially allowing IO operations to function again. + +In some of the implementations I'm fixing, once the deadline has been exceeded, the underlying connection is destroyed and it does not matter if the deadline is set to be in the future again; all IO operations henceforth are dead. + +Is ""refreshable"" deadlines an expected behavior of `net.Conn`? Does any logic in the standard library depend on it? + +/cc @bradfitz ",1.0,"net: document net.Conn operation after deadline is exceeded - The current phrasing on `net.Conn.SetDeadline` is: +> A deadline is an absolute time after which I/O operations fail with a timeout (see type Error) instead of blocking. The deadline applies to all future and pending I/O, not just the immediately following call to Read or Write. +> +> An idle timeout can be implemented by repeatedly extending the deadline after successful Read or Write calls. +> +> A zero value for t means I/O operations will not time out. + +I'm debugging some non-compliant implementations of `net.Conn` due to the clarification made in ([CL/30164](http://golang.org/cl/30164)). While fixing them, I noticed another discrepancy of some `net.Conn` implementations as compared to `net.TCPConn` and would like some clarification on expected behavior. + +The `net.TCPConn` implementation allows a deadline to be exceeded, which unblocks any pending IO operations. However, it also allows the user to extend the deadline to be in the future, essentially allowing IO operations to function again. + +In some of the implementations I'm fixing, once the deadline has been exceeded, the underlying connection is destroyed and it does not matter if the deadline is set to be in the future again; all IO operations henceforth are dead. + +Is ""refreshable"" deadlines an expected behavior of `net.Conn`? Does any logic in the standard library depend on it? + +/cc @bradfitz ",1,net document net conn operation after deadline is exceeded the current phrasing on net conn setdeadline is a deadline is an absolute time after which i o operations fail with a timeout see type error instead of blocking the deadline applies to all future and pending i o not just the immediately following call to read or write an idle timeout can be implemented by repeatedly extending the deadline after successful read or write calls a zero value for t means i o operations will not time out i m debugging some non compliant implementations of net conn due to the clarification made in while fixing them i noticed another discrepancy of some net conn implementations as compared to net tcpconn and would like some clarification on expected behavior the net tcpconn implementation allows a deadline to be exceeded which unblocks any pending io operations however it also allows the user to extend the deadline to be in the future essentially allowing io operations to function again in some of the implementations i m fixing once the deadline has been exceeded the underlying connection is destroyed and it does not matter if the deadline is set to be in the future again all io operations henceforth are dead is refreshable deadlines an expected behavior of net conn does any logic in the standard library depend on it cc bradfitz ,1 +298132,25791134303.0,IssuesEvent,2022-12-10 04:57:40,golang/go,https://api.github.com/repos/golang/go,closed,x/net/http2: data race in TestCanonicalHeaderCacheGrowth,Testing NeedsFix,"``` +#!watchflakes +post <- pkg == ""x/net/http2"" && test == ""TestCanonicalHeaderCacheGrowth"" && `DATA RACE` +``` + +https://build.golang.org/log/9f76836a9c3da1bd2d60e0e4b5274e6d253febaa: +``` +================== +WARNING: DATA RACE +Write at 0x000001a1e0cc by goroutine 67: + golang.org/x/net/http2.disableGoroutineTracking() + C:/workdir/gopath/src/golang.org/x/net/http2/server_test.go:3502 +0x64 + golang.org/x/net/http2.TestCanonicalHeaderCacheGrowth() + C:/workdir/gopath/src/golang.org/x/net/http2/server_test.go:4550 +0x9b + testing.tRunner() + C:/workdir/go/src/testing/testing.go:1439 +0x213 + testing.(*T).Run.func1() + C:/workdir/go/src/testing/testing.go:1486 +0x47 + +Previous read at 0x000001a1e0cc by goroutine 248: + golang.org/x/net/http2.goroutineLock.checkNotOn() + C:/workdir/gopath/src/golang.org/x/net/http2/gotrack.go:41 +0xaa + golang.org/x/net/http2.(*serverConn).writeFrameFromHandler() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:1134 +0x75 + golang.org/x/net/http2.(*serverConn).writeHeaders() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2331 +0x116 + golang.org/x/net/http2.(*responseWriterState).writeChunk() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2617 +0x10f2 + golang.org/x/net/http2.chunkWriter.Write() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2520 +0xb5 + golang.org/x/net/http2.(*responseWriter).FlushError() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2790 +0xbb + golang.org/x/net/http2.(*responseWriter).Flush() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2774 +0x78 + golang.org/x/net/http2.(*responseWriter).handlerDone() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2952 +0x6e + golang.org/x/net/http2.(*serverConn).runHandler.func1() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2303 +0x3de + runtime.deferreturn() + C:/workdir/go/src/runtime/panic.go:436 +0x32 + golang.org/x/net/http2.(*serverConn).processHeaders.func1() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2018 +0x64 + +Goroutine 67 (running) created at: + testing.(*T).Run() + C:/workdir/go/src/testing/testing.go:1486 +0x724 + testing.runTests.func1() + C:/workdir/go/src/testing/testing.go:1839 +0x99 + testing.tRunner() + C:/workdir/go/src/testing/testing.go:1439 +0x213 + testing.runTests() + C:/workdir/go/src/testing/testing.go:1837 +0x7e4 + testing.(*M).Run() + C:/workdir/go/src/testing/testing.go:1719 +0xa71 + main.main() + _testmain.go:767 +0x2e4 + +Goroutine 248 (finished) created at: + golang.org/x/net/http2.(*serverConn).processHeaders() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2018 +0xd39 + golang.org/x/net/http2.(*serverConn).processFrame() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:1518 +0x635 + golang.org/x/net/http2.(*serverConn).processFrameFromReader() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:1461 +0x2ed + golang.org/x/net/http2.(*serverConn).serve() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:952 +0x15ea + golang.org/x/net/http2.(*Server).ServeConn() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:531 +0x1771 + golang.org/x/net/http2.ConfigureServer.func1() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:321 +0x124 + net/http.(*conn).serve() + C:/workdir/go/src/net/http/server.go:1874 +0x1c56 + net/http.(*Server).Serve.func3() + C:/workdir/go/src/net/http/server.go:3071 +0x58 +================== +--- FAIL: TestCanonicalHeaderCacheGrowth (86.60s) + testing.go:1312: race detected during execution of test +FAIL +FAIL golang.org/x/net/http2 111.467s +```",1.0,"x/net/http2: data race in TestCanonicalHeaderCacheGrowth - ``` +#!watchflakes +post <- pkg == ""x/net/http2"" && test == ""TestCanonicalHeaderCacheGrowth"" && `DATA RACE` +``` + +https://build.golang.org/log/9f76836a9c3da1bd2d60e0e4b5274e6d253febaa: +``` +================== +WARNING: DATA RACE +Write at 0x000001a1e0cc by goroutine 67: + golang.org/x/net/http2.disableGoroutineTracking() + C:/workdir/gopath/src/golang.org/x/net/http2/server_test.go:3502 +0x64 + golang.org/x/net/http2.TestCanonicalHeaderCacheGrowth() + C:/workdir/gopath/src/golang.org/x/net/http2/server_test.go:4550 +0x9b + testing.tRunner() + C:/workdir/go/src/testing/testing.go:1439 +0x213 + testing.(*T).Run.func1() + C:/workdir/go/src/testing/testing.go:1486 +0x47 + +Previous read at 0x000001a1e0cc by goroutine 248: + golang.org/x/net/http2.goroutineLock.checkNotOn() + C:/workdir/gopath/src/golang.org/x/net/http2/gotrack.go:41 +0xaa + golang.org/x/net/http2.(*serverConn).writeFrameFromHandler() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:1134 +0x75 + golang.org/x/net/http2.(*serverConn).writeHeaders() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2331 +0x116 + golang.org/x/net/http2.(*responseWriterState).writeChunk() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2617 +0x10f2 + golang.org/x/net/http2.chunkWriter.Write() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2520 +0xb5 + golang.org/x/net/http2.(*responseWriter).FlushError() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2790 +0xbb + golang.org/x/net/http2.(*responseWriter).Flush() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2774 +0x78 + golang.org/x/net/http2.(*responseWriter).handlerDone() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2952 +0x6e + golang.org/x/net/http2.(*serverConn).runHandler.func1() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2303 +0x3de + runtime.deferreturn() + C:/workdir/go/src/runtime/panic.go:436 +0x32 + golang.org/x/net/http2.(*serverConn).processHeaders.func1() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2018 +0x64 + +Goroutine 67 (running) created at: + testing.(*T).Run() + C:/workdir/go/src/testing/testing.go:1486 +0x724 + testing.runTests.func1() + C:/workdir/go/src/testing/testing.go:1839 +0x99 + testing.tRunner() + C:/workdir/go/src/testing/testing.go:1439 +0x213 + testing.runTests() + C:/workdir/go/src/testing/testing.go:1837 +0x7e4 + testing.(*M).Run() + C:/workdir/go/src/testing/testing.go:1719 +0xa71 + main.main() + _testmain.go:767 +0x2e4 + +Goroutine 248 (finished) created at: + golang.org/x/net/http2.(*serverConn).processHeaders() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:2018 +0xd39 + golang.org/x/net/http2.(*serverConn).processFrame() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:1518 +0x635 + golang.org/x/net/http2.(*serverConn).processFrameFromReader() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:1461 +0x2ed + golang.org/x/net/http2.(*serverConn).serve() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:952 +0x15ea + golang.org/x/net/http2.(*Server).ServeConn() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:531 +0x1771 + golang.org/x/net/http2.ConfigureServer.func1() + C:/workdir/gopath/src/golang.org/x/net/http2/server.go:321 +0x124 + net/http.(*conn).serve() + C:/workdir/go/src/net/http/server.go:1874 +0x1c56 + net/http.(*Server).Serve.func3() + C:/workdir/go/src/net/http/server.go:3071 +0x58 +================== +--- FAIL: TestCanonicalHeaderCacheGrowth (86.60s) + testing.go:1312: race detected during execution of test +FAIL +FAIL golang.org/x/net/http2 111.467s +```",0,x net data race in testcanonicalheadercachegrowth watchflakes post pkg x net test testcanonicalheadercachegrowth data race warning data race write at by goroutine golang org x net disablegoroutinetracking c workdir gopath src golang org x net server test go golang org x net testcanonicalheadercachegrowth c workdir gopath src golang org x net server test go testing trunner c workdir go src testing testing go testing t run c workdir go src testing testing go previous read at by goroutine golang org x net goroutinelock checknoton c workdir gopath src golang org x net gotrack go golang org x net serverconn writeframefromhandler c workdir gopath src golang org x net server go golang org x net serverconn writeheaders c workdir gopath src golang org x net server go golang org x net responsewriterstate writechunk c workdir gopath src golang org x net server go golang org x net chunkwriter write c workdir gopath src golang org x net server go golang org x net responsewriter flusherror c workdir gopath src golang org x net server go golang org x net responsewriter flush c workdir gopath src golang org x net server go golang org x net responsewriter handlerdone c workdir gopath src golang org x net server go golang org x net serverconn runhandler c workdir gopath src golang org x net server go runtime deferreturn c workdir go src runtime panic go golang org x net serverconn processheaders c workdir gopath src golang org x net server go goroutine running created at testing t run c workdir go src testing testing go testing runtests c workdir go src testing testing go testing trunner c workdir go src testing testing go testing runtests c workdir go src testing testing go testing m run c workdir go src testing testing go main main testmain go goroutine finished created at golang org x net serverconn processheaders c workdir gopath src golang org x net server go golang org x net serverconn processframe c workdir gopath src golang org x net server go golang org x net serverconn processframefromreader c workdir gopath src golang org x net server go golang org x net serverconn serve c workdir gopath src golang org x net server go golang org x net server serveconn c workdir gopath src golang org x net server go golang org x net configureserver c workdir gopath src golang org x net server go net http conn serve c workdir go src net http server go net http server serve c workdir go src net http server go fail testcanonicalheadercachegrowth testing go race detected during execution of test fail fail golang org x net ,0 +85860,10466780926.0,IssuesEvent,2019-09-21 21:47:14,golang/go,https://api.github.com/repos/golang/go,closed,strings: EqualFold doc could be clearer,Documentation NeedsFix help wanted,"The doc for EqualFold says: + +> EqualFold reports whether s and t, interpreted as UTF-8 strings, are equal under Unicode case-folding. + +I have been using Go for over five years now and had no idea what ""Unicode case-folding"" was until about three minutes ago. Previously I had implemented this by calling `strings.ToLower` on each side, which is slow and unnecessary. More commonly I believe the EqualFold functionality is known as ""case insensitive matching."" Users who are searching the strings documentation for the phrase ""case insensitive"" will find nothing, when they should be finding this function. + +Scanning Github this seems like a common mistake: + +https://github.com/sachin-varade/network/blob/5d4ab4a3757603b8c0ba9a9df7bc9e0ff92ad102/app/utils/setup/chaincode/processors/read_ledger.go#L172 +https://github.com/projectriri/bot-gateway/blob/d4402bd4ac0d4478bd86e585ca83e9d3fc1c140e/converters/cqhttp-ubm-conv/cqhttp-ubm-conv.go#L79 + +Several Go vetters/linters have checks for this construction that suggest using EqualFold instead: + +https://github.com/dominikh/go-tools/blob/1da3061645b400d55be4855f104d8a68ca0a61e5/staticcheck/testdata/src/CheckToLowerToUpperComparison/CheckToLowerToUpperComparison.go + +StackOverflow answers suggesting the use of EqualFold have 35,000 views and 10,000 views, respectively. + +https://stackoverflow.com/q/24836044/329700 +https://stackoverflow.com/q/30196780/329700",1.0,"strings: EqualFold doc could be clearer - The doc for EqualFold says: + +> EqualFold reports whether s and t, interpreted as UTF-8 strings, are equal under Unicode case-folding. + +I have been using Go for over five years now and had no idea what ""Unicode case-folding"" was until about three minutes ago. Previously I had implemented this by calling `strings.ToLower` on each side, which is slow and unnecessary. More commonly I believe the EqualFold functionality is known as ""case insensitive matching."" Users who are searching the strings documentation for the phrase ""case insensitive"" will find nothing, when they should be finding this function. + +Scanning Github this seems like a common mistake: + +https://github.com/sachin-varade/network/blob/5d4ab4a3757603b8c0ba9a9df7bc9e0ff92ad102/app/utils/setup/chaincode/processors/read_ledger.go#L172 +https://github.com/projectriri/bot-gateway/blob/d4402bd4ac0d4478bd86e585ca83e9d3fc1c140e/converters/cqhttp-ubm-conv/cqhttp-ubm-conv.go#L79 + +Several Go vetters/linters have checks for this construction that suggest using EqualFold instead: + +https://github.com/dominikh/go-tools/blob/1da3061645b400d55be4855f104d8a68ca0a61e5/staticcheck/testdata/src/CheckToLowerToUpperComparison/CheckToLowerToUpperComparison.go + +StackOverflow answers suggesting the use of EqualFold have 35,000 views and 10,000 views, respectively. + +https://stackoverflow.com/q/24836044/329700 +https://stackoverflow.com/q/30196780/329700",1,strings equalfold doc could be clearer the doc for equalfold says equalfold reports whether s and t interpreted as utf strings are equal under unicode case folding i have been using go for over five years now and had no idea what unicode case folding was until about three minutes ago previously i had implemented this by calling strings tolower on each side which is slow and unnecessary more commonly i believe the equalfold functionality is known as case insensitive matching users who are searching the strings documentation for the phrase case insensitive will find nothing when they should be finding this function scanning github this seems like a common mistake several go vetters linters have checks for this construction that suggest using equalfold instead stackoverflow answers suggesting the use of equalfold have views and views respectively ,1 +44357,23597209460.0,IssuesEvent,2022-08-23 20:30:12,golang/go,https://api.github.com/repos/golang/go,closed,strconv: optimize Parse for []byte arguments,Performance NeedsDecision,"In 2016, #2632 was closed with the [explanation that](https://github.com/golang/go/issues/2632#issuecomment-252725945): +> I still think we might be able to do something to make these conversions free and avoid 2x API bloat everywhere. I'd rather hold out for that. People who are super-sensitive to these allocations today can easily copy+modify the current code and ship that in their programs. + +In summary, it's argued that 1) the compiler should address this, and 2) people can vendor and modify the `strconv` package. + +It's been 4 years since the issue was closed (and 9 years since the issue was first reported), and there there hasn't been a compiler optimization that permits calling the `Parse` functions with a `[]byte` without it creating garbage. That is: +```go +var b []byte = ... +v, err := strconv.ParseXXX(string(b), ...) +``` +always (as of Go1.15) allocates and copies the input `[]byte`. + +Forking `strconv` is an unfavorable workaround because it means that the vendor fails to benefit from future optimizations to `strconv` (e.g., [cl/187957](https://golang.org/cl/187957) or [cl/260858](https://golang.org/cl/260858)) and fixes to the implementation (e.g., #29491) and may go against company guidelines that forbid forks. Personally, I haven't seen anyone fork `strconv`. Rather, in most cases I see users cast a `[]byte` to a `string` using `unsafe`. This is what we do in the protobuf module. However, some use-cases are constrained to avoid using `unsafe` (e.g., `encoding/json`) and so continue to suffer from performance losses. + +Given the passage of time and the lack of a natural solution to this, I think we should revisit this issue. It seems that we should either: +1) Modify the compiler to detect cases where a string variable does not escape and that it's use [involves no synchronization points](https://github.com/golang/go/issues/2632#issuecomment-144865645), so that it functionally performs an allocation-free cast of `[]byte` to `string` in the example snippet above. If such a compiler optimization existed, we would probably also need to modify `strconv` to avoid escaping the [string input through the error value](https://github.com/golang/go/blob/d21af00dd22d478d0026797c91961168ba83aff9/src/strconv/atof.go#L693) by copying the input string. Note that this will slow down cases where parsing fails. +2) Accept that a compiler optimization is not happening, in which case we add `ParseBoolBytes`, `ParseComplexBytes`, `ParseFloatBytes`, `ParseIntBytes`, and `ParseUintBytes`, which are identical to their counterparts without the `Bytes` suffix, but operate on a `[]byte` as the input instead of a `string`. (We can add `Bytes` equivalents for the `QuoteXXX` functions as well, but those seem to be rarely with a `[]byte`.) + +Obviously option 1 is preferred, but if its not going to happen, but perhaps it's time to do option 2. It's been almost a decade. + +\cc @mvdan @rogpeppe @mdlayher ",True,"strconv: optimize Parse for []byte arguments - In 2016, #2632 was closed with the [explanation that](https://github.com/golang/go/issues/2632#issuecomment-252725945): +> I still think we might be able to do something to make these conversions free and avoid 2x API bloat everywhere. I'd rather hold out for that. People who are super-sensitive to these allocations today can easily copy+modify the current code and ship that in their programs. + +In summary, it's argued that 1) the compiler should address this, and 2) people can vendor and modify the `strconv` package. + +It's been 4 years since the issue was closed (and 9 years since the issue was first reported), and there there hasn't been a compiler optimization that permits calling the `Parse` functions with a `[]byte` without it creating garbage. That is: +```go +var b []byte = ... +v, err := strconv.ParseXXX(string(b), ...) +``` +always (as of Go1.15) allocates and copies the input `[]byte`. + +Forking `strconv` is an unfavorable workaround because it means that the vendor fails to benefit from future optimizations to `strconv` (e.g., [cl/187957](https://golang.org/cl/187957) or [cl/260858](https://golang.org/cl/260858)) and fixes to the implementation (e.g., #29491) and may go against company guidelines that forbid forks. Personally, I haven't seen anyone fork `strconv`. Rather, in most cases I see users cast a `[]byte` to a `string` using `unsafe`. This is what we do in the protobuf module. However, some use-cases are constrained to avoid using `unsafe` (e.g., `encoding/json`) and so continue to suffer from performance losses. + +Given the passage of time and the lack of a natural solution to this, I think we should revisit this issue. It seems that we should either: +1) Modify the compiler to detect cases where a string variable does not escape and that it's use [involves no synchronization points](https://github.com/golang/go/issues/2632#issuecomment-144865645), so that it functionally performs an allocation-free cast of `[]byte` to `string` in the example snippet above. If such a compiler optimization existed, we would probably also need to modify `strconv` to avoid escaping the [string input through the error value](https://github.com/golang/go/blob/d21af00dd22d478d0026797c91961168ba83aff9/src/strconv/atof.go#L693) by copying the input string. Note that this will slow down cases where parsing fails. +2) Accept that a compiler optimization is not happening, in which case we add `ParseBoolBytes`, `ParseComplexBytes`, `ParseFloatBytes`, `ParseIntBytes`, and `ParseUintBytes`, which are identical to their counterparts without the `Bytes` suffix, but operate on a `[]byte` as the input instead of a `string`. (We can add `Bytes` equivalents for the `QuoteXXX` functions as well, but those seem to be rarely with a `[]byte`.) + +Obviously option 1 is preferred, but if its not going to happen, but perhaps it's time to do option 2. It's been almost a decade. + +\cc @mvdan @rogpeppe @mdlayher ",0,strconv optimize parse for byte arguments in was closed with the i still think we might be able to do something to make these conversions free and avoid api bloat everywhere i d rather hold out for that people who are super sensitive to these allocations today can easily copy modify the current code and ship that in their programs in summary it s argued that the compiler should address this and people can vendor and modify the strconv package it s been years since the issue was closed and years since the issue was first reported and there there hasn t been a compiler optimization that permits calling the parse functions with a byte without it creating garbage that is go var b byte v err strconv parsexxx string b always as of allocates and copies the input byte forking strconv is an unfavorable workaround because it means that the vendor fails to benefit from future optimizations to strconv e g or and fixes to the implementation e g and may go against company guidelines that forbid forks personally i haven t seen anyone fork strconv rather in most cases i see users cast a byte to a string using unsafe this is what we do in the protobuf module however some use cases are constrained to avoid using unsafe e g encoding json and so continue to suffer from performance losses given the passage of time and the lack of a natural solution to this i think we should revisit this issue it seems that we should either modify the compiler to detect cases where a string variable does not escape and that it s use so that it functionally performs an allocation free cast of byte to string in the example snippet above if such a compiler optimization existed we would probably also need to modify strconv to avoid escaping the by copying the input string note that this will slow down cases where parsing fails accept that a compiler optimization is not happening in which case we add parseboolbytes parsecomplexbytes parsefloatbytes parseintbytes and parseuintbytes which are identical to their counterparts without the bytes suffix but operate on a byte as the input instead of a string we can add bytes equivalents for the quotexxx functions as well but those seem to be rarely with a byte obviously option is preferred but if its not going to happen but perhaps it s time to do option it s been almost a decade cc mvdan rogpeppe mdlayher ,0 +32004,6024024196.0,IssuesEvent,2017-06-08 02:54:59,golang/go,https://api.github.com/repos/golang/go,closed,doc: improve `go test --help` -timeout usage message,Documentation,"Please answer these questions before submitting your issue. Thanks! + +### What version of Go are you using (`go version`)? + +`go version go1.8 darwin/amd64` + +### What operating system and processor architecture are you using (`go env`)? + +``` +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/glendc/go"" +GORACE="""" +GOROOT=""/usr/local/go"" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/gy/ldypn6dn08b_8q7cn3mg0l440000gn/T/go-build629694106=/tmp/go-build -gno-record-gcc-switches -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +PKG_CONFIG=""pkg-config"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +``` + +### What did you do? + +``` +$ go test --help 2> >(grep -A2 timeout) +``` +### What did you expect to see? + +``` + -timeout t + If a package runs longer than t, panic. + The default is 10 minutes (10m). +``` + +### What did you see instead? + +``` + -timeout t + If a test runs longer than t, panic. + The default is 10 minutes (10m). +``` + +Right now it seems to indicate that if an individual test, such as `TestFoo`, runs longer than t, it panic. But this is not true, and in fact after some local testing, it seems to be that it applies the timeout value on a package level, rather than it being applied on a single test only. Especially the ""`a test`"" is very confusing imho. + +I'm not the greatest in writing clear documentation though, so there is probably a better way to put it, than what I propose.",1.0,"doc: improve `go test --help` -timeout usage message - Please answer these questions before submitting your issue. Thanks! + +### What version of Go are you using (`go version`)? + +`go version go1.8 darwin/amd64` + +### What operating system and processor architecture are you using (`go env`)? + +``` +GOARCH=""amd64"" +GOBIN="""" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/glendc/go"" +GORACE="""" +GOROOT=""/usr/local/go"" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/gy/ldypn6dn08b_8q7cn3mg0l440000gn/T/go-build629694106=/tmp/go-build -gno-record-gcc-switches -fno-common"" +CXX=""clang++"" +CGO_ENABLED=""1"" +PKG_CONFIG=""pkg-config"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +``` + +### What did you do? + +``` +$ go test --help 2> >(grep -A2 timeout) +``` +### What did you expect to see? + +``` + -timeout t + If a package runs longer than t, panic. + The default is 10 minutes (10m). +``` + +### What did you see instead? + +``` + -timeout t + If a test runs longer than t, panic. + The default is 10 minutes (10m). +``` + +Right now it seems to indicate that if an individual test, such as `TestFoo`, runs longer than t, it panic. But this is not true, and in fact after some local testing, it seems to be that it applies the timeout value on a package level, rather than it being applied on a single test only. Especially the ""`a test`"" is very confusing imho. + +I'm not the greatest in writing clear documentation though, so there is probably a better way to put it, than what I propose.",1,doc improve go test help timeout usage message please answer these questions before submitting your issue thanks what version of go are you using go version go version darwin what operating system and processor architecture are you using go env goarch gobin goexe gohostarch gohostos darwin goos darwin gopath users glendc go gorace goroot usr local go gotooldir usr local go pkg tool darwin gccgo gccgo cc clang gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map var folders gy t go tmp go build gno record gcc switches fno common cxx clang cgo enabled pkg config pkg config cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g what did you do go test help grep timeout what did you expect to see timeout t if a package runs longer than t panic the default is minutes what did you see instead timeout t if a test runs longer than t panic the default is minutes right now it seems to indicate that if an individual test such as testfoo runs longer than t it panic but this is not true and in fact after some local testing it seems to be that it applies the timeout value on a package level rather than it being applied on a single test only especially the a test is very confusing imho i m not the greatest in writing clear documentation though so there is probably a better way to put it than what i propose ,1 +285602,24680271018.0,IssuesEvent,2022-10-18 20:38:41,golang/go,https://api.github.com/repos/golang/go,closed,net/http: test flake in TestTransportIgnores408/h1,Testing NeedsInvestigation,"Seen on a trybot. Did not find an existing issue. CC @neild @bradfitz + +https://storage.googleapis.com/go-build-log/4868bfba/linux-amd64_7494de7d.log + +``` +--- FAIL: TestTransportIgnores408 (0.00s) + --- FAIL: TestTransportIgnores408/h1 (0.01s) + transport_test.go:6017: expected no log output; got: 2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:51852: EOF + 2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:35068: EOF +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:46010: read tcp 127.0.0.1:45467->127.0.0.1:46010: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:45980: read tcp 127.0.0.1:45467->127.0.0.1:45980: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:46022: write tcp 127.0.0.1:45467->127.0.0.1:46022: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:45996: read tcp 127.0.0.1:45467->127.0.0.1:45996: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:46036: write tcp 127.0.0.1:45467->127.0.0.1:46036: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:46046: write tcp 127.0.0.1:45467->127.0.0.1:46046: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:54726: read tcp 127.0.0.1:44951->127.0.0.1:54726: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:54764: write tcp 127.0.0.1:44951->127.0.0.1:54764: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:54716: write tcp 127.0.0.1:44951->127.0.0.1:54716: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:54780: write tcp 127.0.0.1:44951->127.0.0.1:54780: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:54740: write tcp 127.0.0.1:44951->127.0.0.1:54740: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:54790: write tcp 127.0.0.1:44951->127.0.0.1:54790: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:54752: write tcp 127.0.0.1:44951->127.0.0.1:54752: use of closed network connection +2022/10/09 03:30:01 http2: server: error reading preface from client 127.0.0.1:60128: bogus greeting ""CONNECT golang.fake.tld:"" +2022/10/09 03:30:01 http2: server: error reading preface from client 127.0.0.1:37392: bogus greeting ""CONNECT golang.fake.tld:"" +FAIL +FAIL net/http 2.757s +FAIL +```",1.0,"net/http: test flake in TestTransportIgnores408/h1 - Seen on a trybot. Did not find an existing issue. CC @neild @bradfitz + +https://storage.googleapis.com/go-build-log/4868bfba/linux-amd64_7494de7d.log + +``` +--- FAIL: TestTransportIgnores408 (0.00s) + --- FAIL: TestTransportIgnores408/h1 (0.01s) + transport_test.go:6017: expected no log output; got: 2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:51852: EOF + 2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:35068: EOF +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:46010: read tcp 127.0.0.1:45467->127.0.0.1:46010: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:45980: read tcp 127.0.0.1:45467->127.0.0.1:45980: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:46022: write tcp 127.0.0.1:45467->127.0.0.1:46022: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:45996: read tcp 127.0.0.1:45467->127.0.0.1:45996: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:46036: write tcp 127.0.0.1:45467->127.0.0.1:46036: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:46046: write tcp 127.0.0.1:45467->127.0.0.1:46046: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:54726: read tcp 127.0.0.1:44951->127.0.0.1:54726: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:54764: write tcp 127.0.0.1:44951->127.0.0.1:54764: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:54716: write tcp 127.0.0.1:44951->127.0.0.1:54716: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:54780: write tcp 127.0.0.1:44951->127.0.0.1:54780: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:54740: write tcp 127.0.0.1:44951->127.0.0.1:54740: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:54790: write tcp 127.0.0.1:44951->127.0.0.1:54790: use of closed network connection +2022/10/09 03:30:01 http: TLS handshake error from 127.0.0.1:54752: write tcp 127.0.0.1:44951->127.0.0.1:54752: use of closed network connection +2022/10/09 03:30:01 http2: server: error reading preface from client 127.0.0.1:60128: bogus greeting ""CONNECT golang.fake.tld:"" +2022/10/09 03:30:01 http2: server: error reading preface from client 127.0.0.1:37392: bogus greeting ""CONNECT golang.fake.tld:"" +FAIL +FAIL net/http 2.757s +FAIL +```",0,net http test flake in seen on a trybot did not find an existing issue cc neild bradfitz fail fail transport test go expected no log output got http tls handshake error from eof http tls handshake error from eof http tls handshake error from read tcp use of closed network connection http tls handshake error from read tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from read tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from read tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection http tls handshake error from write tcp use of closed network connection server error reading preface from client bogus greeting connect golang fake tld server error reading preface from client bogus greeting connect golang fake tld fail fail net http fail ,0 +173146,14403565531.0,IssuesEvent,2020-12-03 16:12:42,golang/go,https://api.github.com/repos/golang/go,closed,"doc/go1.16: document new packages in Go 1.16 standard library (io/fs, embed, runtime/metrics, testing/fstest)",Documentation NeedsInvestigation help wanted release-blocker,"As of filing this issue, the [Go 1.16 draft release notes](https://tip.golang.org/doc/go1.16) contained the following HTML: + +```HTML +
+ TODO: mention significant additions like new packages (io/fs),
+ new proposal-scoped features (//go:embed), and so on
+
+ TODO: mention significant additions like new packages (io/fs),
+ new proposal-scoped features (//go:embed), and so on
+
+$ go version +go version go1.12.4 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What did you do? + +Call [`req.SetBasicAuth(user, pass)`](https://golang.org/pkg/net/http/#Request.SetBasicAuth) with special characters in either the username or the password, e.g.: +```go + req, err := http.NewRequest(""POST"", ""http://127.0.0.1/foo"", nil) + req.SetBasicAuth(""foo"", ""bar+baz"") + if err != nil { + panic(err) + } + fmt.Println(req.Header.Get(""Authorization"")) +``` + +### What did you expect to see? + +The above program should probably print `Basic Zm9vOmJhciUyQmJheg==` + +### What did you see instead? + +The above program prints `Basic Zm9vOmJhcitiYXo=` + +### Discussion + +So I spent a long long _long_ time debugging some OpenID Connect authentication issue with `kubectl` and [dex](https://github.com/dexidp/dex). Long story short, it turns out that the random client secret I had generated contained a `+` sign and it needed to be URL encoded before being base64-encoded when used with basic auth. + +After looking at the code in Kubernetes and various other projects, I realized that nobody ever escapes the arguments passed to `SetBasicAuth()`. So this issue is extremely widespread. In fact the bug was even present in Go's own OAuth2 implementation until golang/oauth2#237 fixed it. + +The godoc doesn't say anything about escaping so it's not clear to me whether the intent was to have users do it themselves (and, clearly, they don't) or, more likely, this was just an unfortunate omission (i.e. a bug) when the library was implemented. + +Given how widespread this issue is, I think the standard library should do the URL encoding automagically. Now since there are some callers that already do it (e.g. the OAuth2 library after the fix mentioned above), this means that the code should probably make a pass through the strings it's given and if they contain anything that needs escaping, then escape the whole string, otherwise use the string as-is. + +If you guys disagree that the library should take care of escaping the arguments, then at the very least the godoc should be updated to explicitly state that the strings must be URL-safe or URL encoded. But I strongly think that the library should just make it work automatically given that virtually none of the existing code out there does this properly. + +Granted this problem is probably not that likely to occur in practice, again I hit it because I used a random string of ASCII characters as a client secret, and there was a `+` in there. So `kubectl` worked for a while but once it needed to refresh its token, I'd get a mysterious 401 due to this bug.",1.0,"net/http: document that Request.SetBasicAuth doesn't do any additional escaping - ### What version of Go are you using (`go version`)? + +
+$ go version +go version go1.12.4 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What did you do? + +Call [`req.SetBasicAuth(user, pass)`](https://golang.org/pkg/net/http/#Request.SetBasicAuth) with special characters in either the username or the password, e.g.: +```go + req, err := http.NewRequest(""POST"", ""http://127.0.0.1/foo"", nil) + req.SetBasicAuth(""foo"", ""bar+baz"") + if err != nil { + panic(err) + } + fmt.Println(req.Header.Get(""Authorization"")) +``` + +### What did you expect to see? + +The above program should probably print `Basic Zm9vOmJhciUyQmJheg==` + +### What did you see instead? + +The above program prints `Basic Zm9vOmJhcitiYXo=` + +### Discussion + +So I spent a long long _long_ time debugging some OpenID Connect authentication issue with `kubectl` and [dex](https://github.com/dexidp/dex). Long story short, it turns out that the random client secret I had generated contained a `+` sign and it needed to be URL encoded before being base64-encoded when used with basic auth. + +After looking at the code in Kubernetes and various other projects, I realized that nobody ever escapes the arguments passed to `SetBasicAuth()`. So this issue is extremely widespread. In fact the bug was even present in Go's own OAuth2 implementation until golang/oauth2#237 fixed it. + +The godoc doesn't say anything about escaping so it's not clear to me whether the intent was to have users do it themselves (and, clearly, they don't) or, more likely, this was just an unfortunate omission (i.e. a bug) when the library was implemented. + +Given how widespread this issue is, I think the standard library should do the URL encoding automagically. Now since there are some callers that already do it (e.g. the OAuth2 library after the fix mentioned above), this means that the code should probably make a pass through the strings it's given and if they contain anything that needs escaping, then escape the whole string, otherwise use the string as-is. + +If you guys disagree that the library should take care of escaping the arguments, then at the very least the godoc should be updated to explicitly state that the strings must be URL-safe or URL encoded. But I strongly think that the library should just make it work automatically given that virtually none of the existing code out there does this properly. + +Granted this problem is probably not that likely to occur in practice, again I hit it because I used a random string of ASCII characters as a client secret, and there was a `+` in there. So `kubectl` worked for a while but once it needed to refresh its token, I'd get a mysterious 401 due to this bug.",1,net http document that request setbasicauth doesn t do any additional escaping what version of go are you using go version go version go version darwin does this issue reproduce with the latest release yes what did you do call with special characters in either the username or the password e g go req err http newrequest post nil req setbasicauth foo bar baz if err nil panic err fmt println req header get authorization what did you expect to see the above program should probably print basic what did you see instead the above program prints basic discussion so i spent a long long long time debugging some openid connect authentication issue with kubectl and long story short it turns out that the random client secret i had generated contained a sign and it needed to be url encoded before being encoded when used with basic auth after looking at the code in kubernetes and various other projects i realized that nobody ever escapes the arguments passed to setbasicauth so this issue is extremely widespread in fact the bug was even present in go s own implementation until golang fixed it the godoc doesn t say anything about escaping so it s not clear to me whether the intent was to have users do it themselves and clearly they don t or more likely this was just an unfortunate omission i e a bug when the library was implemented given how widespread this issue is i think the standard library should do the url encoding automagically now since there are some callers that already do it e g the library after the fix mentioned above this means that the code should probably make a pass through the strings it s given and if they contain anything that needs escaping then escape the whole string otherwise use the string as is if you guys disagree that the library should take care of escaping the arguments then at the very least the godoc should be updated to explicitly state that the strings must be url safe or url encoded but i strongly think that the library should just make it work automatically given that virtually none of the existing code out there does this properly granted this problem is probably not that likely to occur in practice again i hit it because i used a random string of ascii characters as a client secret and there was a in there so kubectl worked for a while but once it needed to refresh its token i d get a mysterious due to this bug ,1 +52335,7759136373.0,IssuesEvent,2018-05-31 22:02:16,golang/go,https://api.github.com/repos/golang/go,closed,net/http: document that Server.Serve expects a hashable net.Listener (as a map key),Documentation,"### What version of Go are you using (`go version`)? +1.10 + +### Does this issue reproduce with the latest release? +yes + +### What operating system and processor architecture are you using (`go env`)? +``` +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/vagrant/.cache/go-build"" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/vagrant/workspace-dss"" +GORACE="""" +GOROOT=""/usr/local/go-1.10"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go-1.10/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build230598238=/tmp/go-build -gno-record-gcc-switches"" +``` + +### What did you do? + +I implemented `net.Listener` with a struct that defined a `func()` field. I passed this struct to `http.Server.Serve`. The code compiled just fine and panicked at run-time because my listener implementation couldn't be used as a hash key (see `trackListener` in the `http` package). + +### What did you expect to see? + +A working `http.Server`. Or else some documentation that clearly states the constraints for the kinds of listeners usable with `http.Server`. + +### What did you see instead? + +Panic at run-time.",1.0,"net/http: document that Server.Serve expects a hashable net.Listener (as a map key) - ### What version of Go are you using (`go version`)? +1.10 + +### Does this issue reproduce with the latest release? +yes + +### What operating system and processor architecture are you using (`go env`)? +``` +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/vagrant/.cache/go-build"" +GOEXE="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOOS=""linux"" +GOPATH=""/home/vagrant/workspace-dss"" +GORACE="""" +GOROOT=""/usr/local/go-1.10"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go-1.10/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build230598238=/tmp/go-build -gno-record-gcc-switches"" +``` + +### What did you do? + +I implemented `net.Listener` with a struct that defined a `func()` field. I passed this struct to `http.Server.Serve`. The code compiled just fine and panicked at run-time because my listener implementation couldn't be used as a hash key (see `trackListener` in the `http` package). + +### What did you expect to see? + +A working `http.Server`. Or else some documentation that clearly states the constraints for the kinds of listeners usable with `http.Server`. + +### What did you see instead? + +Panic at run-time.",1,net http document that server serve expects a hashable net listener as a map key what version of go are you using go version does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env goarch gobin gocache home vagrant cache go build goexe gohostarch gohostos linux goos linux gopath home vagrant workspace dss gorace goroot usr local go gotmpdir gotooldir usr local go pkg tool linux gccgo gccgo cc gcc cxx g cgo enabled cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fmessage length fdebug prefix map tmp go tmp go build gno record gcc switches what did you do i implemented net listener with a struct that defined a func field i passed this struct to http server serve the code compiled just fine and panicked at run time because my listener implementation couldn t be used as a hash key see tracklistener in the http package what did you expect to see a working http server or else some documentation that clearly states the constraints for the kinds of listeners usable with http server what did you see instead panic at run time ,1 +174819,14500008787.0,IssuesEvent,2020-12-11 17:27:14,golang/go,https://api.github.com/repos/golang/go,closed,doc/go1.16: document go command changes for Go 1.16,Documentation GoCommand NeedsInvestigation okay-after-beta1 release-blocker,"As of filing this issue, the [Go 1.16 draft release notes](https://tip.golang.org/doc/go1.16) contained the following HTML: + +```HTML +
+ TODO + + + + + +
+``` + +And these TODOs: + +``` +TODO: write and link to section in golang.org/ref/mod +TODO: write and link to blog post +[...] +TODO: write and link to section in golang.org/ref/mod +TODO: write and link to tutorial or blog post +``` + +Per [golang.org/s/release](https://golang.org/s/release), it's a release blocker for Go 1.16 Beta 1 to have a complete draft of the eventual release notes, and so the TODO needs to be resolved. + +A sequence of steps to resolve this issue may be: + +1. Come up with a draft release note entry in this issue, then move the issue to NeedsFix state. +2. Send a CL with ""doc/go1.16:"" [prefix](https://go-review.googlesource.com/q/project:go+doc/go1.16) and include ""For #40700. Fixes #{this issue}."" in the body. +",1.0,"doc/go1.16: document go command changes for Go 1.16 - As of filing this issue, the [Go 1.16 draft release notes](https://tip.golang.org/doc/go1.16) contained the following HTML: + +```HTML ++ TODO + + + + + +
+``` + +And these TODOs: + +``` +TODO: write and link to section in golang.org/ref/mod +TODO: write and link to blog post +[...] +TODO: write and link to section in golang.org/ref/mod +TODO: write and link to tutorial or blog post +``` + +Per [golang.org/s/release](https://golang.org/s/release), it's a release blocker for Go 1.16 Beta 1 to have a complete draft of the eventual release notes, and so the TODO needs to be resolved. + +A sequence of steps to resolve this issue may be: + +1. Come up with a draft release note entry in this issue, then move the issue to NeedsFix state. +2. Send a CL with ""doc/go1.16:"" [prefix](https://go-review.googlesource.com/q/project:go+doc/go1.16) and include ""For #40700. Fixes #{this issue}."" in the body. +",1,doc document go command changes for go as of filing this issue the contained the following html html go command todo and these todos todo write and link to section in golang org ref mod todo write and link to blog post todo write and link to section in golang org ref mod todo write and link to tutorial or blog post per it s a release blocker for go beta to have a complete draft of the eventual release notes and so the todo needs to be resolved a sequence of steps to resolve this issue may be come up with a draft release note entry in this issue then move the issue to needsfix state send a cl with doc and include for fixes this issue in the body ,1 +30445,5796681474.0,IssuesEvent,2017-05-02 20:03:51,golang/go,https://api.github.com/repos/golang/go,closed,doc: CLA instructions are out of date,Documentation NeedsFix,"https://golang.org/doc/contribute.html#cla suggests to navigate to Settings -> Agreements in gerrit. There is no menu entry called ""Agreements"" for me on https://go-review.googlesource.com/settings.",1.0,"doc: CLA instructions are out of date - https://golang.org/doc/contribute.html#cla suggests to navigate to Settings -> Agreements in gerrit. There is no menu entry called ""Agreements"" for me on https://go-review.googlesource.com/settings.",1,doc cla instructions are out of date suggests to navigate to settings agreements in gerrit there is no menu entry called agreements for me on ,1 +37953,18853090401.0,IssuesEvent,2021-11-12 00:17:24,golang/go,https://api.github.com/repos/golang/go,closed,net: allow not creating a goroutine for netFD.connect in case of caller passes context which is not going to be cancelled manually,Performance NeedsInvestigation,"### What version of Go are you using (`go version`)? +go1.17.2 + +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? +`GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/mikefaraponov/Library/Caches/go-build"" +GOENV=""/Users/mikefaraponov/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/mikefaraponov/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/mikefaraponov/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/Cellar/go/1.15.6/libexec"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.15.6/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/mikefaraponov/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/97/d1hwd7t96mj0_jxmpngf2m5w0000gn/T/go-build319243062=/tmp/go-build -gno-record-gcc-switches -fno-common""` + +### What did you do? +Creating TCPConn connection via net.Dialer + +### What did you expect to see? +No netFD func2 goroutines to be spawned. + +### What did you see instead? +Each new connection created create netFD interruptor goroutine + +### Solution +net/fd_unix.go + +```go +if deadline, hasDeadline := ctx.Deadline(); hasDeadline { + fd.pfd.SetWriteDeadline(deadline) + defer fd.pfd.SetWriteDeadline(noDeadline) +} + +// Start the ""interrupter"" goroutine, if this context might be canceled. +// (The background context cannot) +// +// The interrupter goroutine waits for the context to be done and +// interrupts the dial (by altering the fd's write deadline, which +// wakes up waitWrite). +if ctxDone := ctx.Done(); ctxDone != nil { + // skip creation of goroutine and allow fd.pfd.SetWriteDeadline(deadline) to gracefully close this connection on timeout, this allows to pass custom context.Context implementation with deadline but not cancelable or just check some ctx.Value(""bypasscreationofgoroutine"") instead of ctx.Done() != nil check may be prefereble + // Wait for the interrupter goroutine to exit before returning + // from connect. + done := make(chan struct{}) + interruptRes := make(chan error) + defer func() { + close(done) + if ctxErr := <-interruptRes; ctxErr != nil && ret == nil { + // The interrupter goroutine called SetWriteDeadline, + // but the connect code below had returned from + // waitWrite already and did a successful connect (ret + // == nil). Because we've now poisoned the connection + // by making it unwritable, don't return a successful + // dial. This was issue 16523. + ret = mapErr(ctxErr) + fd.Close() // prevent a leak + } + }() + go func() { + select { + case <-ctxDone: + // Force the runtime's poller to immediately give up + // waiting for writability, unblocking waitWrite + // below. + fd.pfd.SetWriteDeadline(aLongTimeAgo) + testHookCanceledDial() + interruptRes <- ctx.Err() + case <-done: + interruptRes <- nil + } + }() +} +``` +And then smth like this can be used to bypass context cancel mechanism and do not utilise interruptor goroutine: +```go +type deadlineCtx struct { + deadline time.Time +} + +func (m *deadlineCtx) Deadline() (deadline time.Time, ok bool) { + return m.deadline, true +} + +func (m *deadlineCtx) Done() <-chan struct{} { + return nil +} + +func (m *deadlineCtx) Err() error { + return nil +} + +func (m *deadlineCtx) Value(interface{}) interface{} { + return nil +} +``` + +",True,"net: allow not creating a goroutine for netFD.connect in case of caller passes context which is not going to be cancelled manually - ### What version of Go are you using (`go version`)? +go1.17.2 + +### Does this issue reproduce with the latest release? +Yes + +### What operating system and processor architecture are you using (`go env`)? +`GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/mikefaraponov/Library/Caches/go-build"" +GOENV=""/Users/mikefaraponov/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOINSECURE="""" +GOMODCACHE=""/Users/mikefaraponov/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/mikefaraponov/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/Cellar/go/1.15.6/libexec"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.15.6/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/mikefaraponov/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/97/d1hwd7t96mj0_jxmpngf2m5w0000gn/T/go-build319243062=/tmp/go-build -gno-record-gcc-switches -fno-common""` + +### What did you do? +Creating TCPConn connection via net.Dialer + +### What did you expect to see? +No netFD func2 goroutines to be spawned. + +### What did you see instead? +Each new connection created create netFD interruptor goroutine + +### Solution +net/fd_unix.go + +```go +if deadline, hasDeadline := ctx.Deadline(); hasDeadline { + fd.pfd.SetWriteDeadline(deadline) + defer fd.pfd.SetWriteDeadline(noDeadline) +} + +// Start the ""interrupter"" goroutine, if this context might be canceled. +// (The background context cannot) +// +// The interrupter goroutine waits for the context to be done and +// interrupts the dial (by altering the fd's write deadline, which +// wakes up waitWrite). +if ctxDone := ctx.Done(); ctxDone != nil { + // skip creation of goroutine and allow fd.pfd.SetWriteDeadline(deadline) to gracefully close this connection on timeout, this allows to pass custom context.Context implementation with deadline but not cancelable or just check some ctx.Value(""bypasscreationofgoroutine"") instead of ctx.Done() != nil check may be prefereble + // Wait for the interrupter goroutine to exit before returning + // from connect. + done := make(chan struct{}) + interruptRes := make(chan error) + defer func() { + close(done) + if ctxErr := <-interruptRes; ctxErr != nil && ret == nil { + // The interrupter goroutine called SetWriteDeadline, + // but the connect code below had returned from + // waitWrite already and did a successful connect (ret + // == nil). Because we've now poisoned the connection + // by making it unwritable, don't return a successful + // dial. This was issue 16523. + ret = mapErr(ctxErr) + fd.Close() // prevent a leak + } + }() + go func() { + select { + case <-ctxDone: + // Force the runtime's poller to immediately give up + // waiting for writability, unblocking waitWrite + // below. + fd.pfd.SetWriteDeadline(aLongTimeAgo) + testHookCanceledDial() + interruptRes <- ctx.Err() + case <-done: + interruptRes <- nil + } + }() +} +``` +And then smth like this can be used to bypass context cancel mechanism and do not utilise interruptor goroutine: +```go +type deadlineCtx struct { + deadline time.Time +} + +func (m *deadlineCtx) Deadline() (deadline time.Time, ok bool) { + return m.deadline, true +} + +func (m *deadlineCtx) Done() <-chan struct{} { + return nil +} + +func (m *deadlineCtx) Err() error { + return nil +} + +func (m *deadlineCtx) Value(interface{}) interface{} { + return nil +} +``` + +",0,net allow not creating a goroutine for netfd connect in case of caller passes context which is not going to be cancelled manually what version of go are you using go version does this issue reproduce with the latest release yes what operating system and processor architecture are you using go env goarch gobin gocache users mikefaraponov library caches go build goenv users mikefaraponov library application support go env goexe goflags gohostarch gohostos darwin goinsecure gomodcache users mikefaraponov go pkg mod gonoproxy gonosumdb goos darwin gopath users mikefaraponov go goprivate goproxy goroot usr local cellar go libexec gosumdb sum golang org gotmpdir gotooldir usr local cellar go libexec pkg tool darwin gccgo gccgo ar ar cc clang cxx clang cgo enabled gomod users mikefaraponov go mod cgo cflags g cgo cppflags cgo cxxflags g cgo fflags g cgo ldflags g pkg config pkg config gogccflags fpic pthread fno caret diagnostics qunused arguments fmessage length fdebug prefix map var folders t go tmp go build gno record gcc switches fno common what did you do creating tcpconn connection via net dialer what did you expect to see no netfd goroutines to be spawned what did you see instead each new connection created create netfd interruptor goroutine solution net fd unix go go if deadline hasdeadline ctx deadline hasdeadline fd pfd setwritedeadline deadline defer fd pfd setwritedeadline nodeadline start the interrupter goroutine if this context might be canceled the background context cannot the interrupter goroutine waits for the context to be done and interrupts the dial by altering the fd s write deadline which wakes up waitwrite if ctxdone ctx done ctxdone nil skip creation of goroutine and allow fd pfd setwritedeadline deadline to gracefully close this connection on timeout this allows to pass custom context context implementation with deadline but not cancelable or just check some ctx value bypasscreationofgoroutine instead of ctx done nil check may be prefereble wait for the interrupter goroutine to exit before returning from connect done make chan struct interruptres make chan error defer func close done if ctxerr interruptres ctxerr nil ret nil the interrupter goroutine called setwritedeadline but the connect code below had returned from waitwrite already and did a successful connect ret nil because we ve now poisoned the connection by making it unwritable don t return a successful dial this was issue ret maperr ctxerr fd close prevent a leak go func select case ctxdone force the runtime s poller to immediately give up waiting for writability unblocking waitwrite below fd pfd setwritedeadline alongtimeago testhookcanceleddial interruptres ctx err case done interruptres nil and then smth like this can be used to bypass context cancel mechanism and do not utilise interruptor goroutine go type deadlinectx struct deadline time time func m deadlinectx deadline deadline time time ok bool return m deadline true func m deadlinectx done chan struct return nil func m deadlinectx err error return nil func m deadlinectx value interface interface return nil ,0 +150924,13385591088.0,IssuesEvent,2020-09-02 13:40:14,golang/go,https://api.github.com/repos/golang/go,closed,doc: include fix for #34437 in Go 1.14 release notes [1.14 backport],CherryPickApproved Documentation,"@dmitshur requested issue #38801 to be considered for backport to the next 1.14 minor release. + +> @gopherbot Please open an issue to backport this to Go 1.14 when the fix is available. This is a documentation fix. +",1.0,"doc: include fix for #34437 in Go 1.14 release notes [1.14 backport] - @dmitshur requested issue #38801 to be considered for backport to the next 1.14 minor release. + +> @gopherbot Please open an issue to backport this to Go 1.14 when the fix is available. This is a documentation fix. +",1,doc include fix for in go release notes dmitshur requested issue to be considered for backport to the next minor release gopherbot please open an issue to backport this to go when the fix is available this is a documentation fix ,1 +253689,19161549963.0,IssuesEvent,2021-12-03 01:10:04,golang/go,https://api.github.com/repos/golang/go,closed,builtin: add documentation for `any` and `comparable` to pseudo-package `builtin`,Documentation release-blocker okay-after-beta1,The new predeclared identifiers `any` and `comparable` in Go 1.18 should have documentation entries in the `builtin` pseudo-package: https://pkg.go.dev/builtin@master,1.0,builtin: add documentation for `any` and `comparable` to pseudo-package `builtin` - The new predeclared identifiers `any` and `comparable` in Go 1.18 should have documentation entries in the `builtin` pseudo-package: https://pkg.go.dev/builtin@master,1,builtin add documentation for any and comparable to pseudo package builtin the new predeclared identifiers any and comparable in go should have documentation entries in the builtin pseudo package ,1 +188130,15128894959.0,IssuesEvent,2021-02-10 00:12:23,golang/go,https://api.github.com/repos/golang/go,closed,wiki: CodeReviewComments change: suggest got/want phrasing instead of actual/expected.,Documentation NeedsDecision,"Google's internal Go style has converged on ""got/want"" phrasing for test failures, with got before want. This is [reflected in the Standard Library tests, but there are exceptions.](https://golang.org/src/io/io_test.go) Even in the linked io_test.go there is one test that is written in the ""expected/got"" style. + +I think it would be useful for the external style guide to suggest ""got/want"" as the common convention for test output: ""In test messages, prefer using the terms 'got/want' instead of 'actual/expected.'"" + +Creating a common convention would make it easier for programmers to read + understand unfamiliar Go tests. It would also mean that we could add a 'got/want' lint rule to Golint.",1.0,"wiki: CodeReviewComments change: suggest got/want phrasing instead of actual/expected. - Google's internal Go style has converged on ""got/want"" phrasing for test failures, with got before want. This is [reflected in the Standard Library tests, but there are exceptions.](https://golang.org/src/io/io_test.go) Even in the linked io_test.go there is one test that is written in the ""expected/got"" style. + +I think it would be useful for the external style guide to suggest ""got/want"" as the common convention for test output: ""In test messages, prefer using the terms 'got/want' instead of 'actual/expected.'"" + +Creating a common convention would make it easier for programmers to read + understand unfamiliar Go tests. It would also mean that we could add a 'got/want' lint rule to Golint.",1,wiki codereviewcomments change suggest got want phrasing instead of actual expected google s internal go style has converged on got want phrasing for test failures with got before want this is even in the linked io test go there is one test that is written in the expected got style i think it would be useful for the external style guide to suggest got want as the common convention for test output in test messages prefer using the terms got want instead of actual expected creating a common convention would make it easier for programmers to read understand unfamiliar go tests it would also mean that we could add a got want lint rule to golint ,1 +9821,7002265875.0,IssuesEvent,2017-12-18 13:29:32,golang/go,https://api.github.com/repos/golang/go,closed,cmd/compile: suboptimal compilation of 64-bit OMOD for 386/arm,Performance,"Compiling: + +``` +package p + +func f(t int64) int64 { + return t%1e9 +} +``` + +for 386 or arm compiles as + +``` +func f(t int64) int64 { + return t - runtime.int64div(t, 1e9) * 1e9 +} +``` + +even though we're not able to do anything to optimize the `* 1e9` multiplication. We might as well just call `runtime.int64mod`. +",True,"cmd/compile: suboptimal compilation of 64-bit OMOD for 386/arm - Compiling: + +``` +package p + +func f(t int64) int64 { + return t%1e9 +} +``` + +for 386 or arm compiles as + +``` +func f(t int64) int64 { + return t - runtime.int64div(t, 1e9) * 1e9 +} +``` + +even though we're not able to do anything to optimize the `* 1e9` multiplication. We might as well just call `runtime.int64mod`. +",0,cmd compile suboptimal compilation of bit omod for arm compiling package p func f t return t for or arm compiles as func f t return t runtime t even though we re not able to do anything to optimize the multiplication we might as well just call runtime ,0 +79925,23070524658.0,IssuesEvent,2022-07-25 17:35:40,golang/go,https://api.github.com/repos/golang/go,closed,"x/build/cmd/pubsubhelper: Gerrit event URL values include an unnecessary ""?usp=email"" query",Builders NeedsFix,"A recent Gerrit event from https://pubsubhelper.golang.org/recent looks like this: + +```JSON +{ + ""Time"": ""2022-07-24T18:47:26.542273157Z"", + ""Gerrit"": { + ""URL"": ""https://go-review.googlesource.com/c/go/+/418734?usp=email"", + ""Project"": ""go"", + ""CommitHash"": ""e810f8204157253ccc66d7f3b4828551088bcd1a"", + ""ChangeNumber"": 418734 + } +}, +``` + +Though it's a valid URL, the inclusion of the the ""usp"" query parameter in the change URL isn't something the caller will find helpful, ~~and it's not helping the maintner corpus size either~~. We can trivially omit it. + +Edit: This event is used only to wake up the maintnerd server, its content doesn't contribute to corpus size.",1.0,"x/build/cmd/pubsubhelper: Gerrit event URL values include an unnecessary ""?usp=email"" query - A recent Gerrit event from https://pubsubhelper.golang.org/recent looks like this: + +```JSON +{ + ""Time"": ""2022-07-24T18:47:26.542273157Z"", + ""Gerrit"": { + ""URL"": ""https://go-review.googlesource.com/c/go/+/418734?usp=email"", + ""Project"": ""go"", + ""CommitHash"": ""e810f8204157253ccc66d7f3b4828551088bcd1a"", + ""ChangeNumber"": 418734 + } +}, +``` + +Though it's a valid URL, the inclusion of the the ""usp"" query parameter in the change URL isn't something the caller will find helpful, ~~and it's not helping the maintner corpus size either~~. We can trivially omit it. + +Edit: This event is used only to wake up the maintnerd server, its content doesn't contribute to corpus size.",0,x build cmd pubsubhelper gerrit event url values include an unnecessary usp email query a recent gerrit event from looks like this json time gerrit url project go commithash changenumber though it s a valid url the inclusion of the the usp query parameter in the change url isn t something the caller will find helpful and it s not helping the maintner corpus size either we can trivially omit it edit this event is used only to wake up the maintnerd server its content doesn t contribute to corpus size ,0 +151373,12034593845.0,IssuesEvent,2020-04-13 16:19:51,golang/go,https://api.github.com/repos/golang/go,closed,x/tools/go/loader: TestStdlib is failing on tip because TestTempFile was moved,NeedsFix Testing Tools,"[CL 226877](https://golang.org/cl/226877) has moved the function `TestTempFile` from `io/ioutil` internal test to external test. `TestStdlib` is now failing: + +``` +$ gotip test +[...] +--- FAIL: TestStdlib (10.54s) + stdlib_test.go:103: package ""io/ioutil"" has no func ""TestTempFile"" + stdlib_test.go:117: GOMAXPROCS: 8 + stdlib_test.go:118: #Source lines: 1303424 + stdlib_test.go:119: Load/parse/typecheck: 10.070588601s + stdlib_test.go:120: #MB: 1068 +FAIL +exit status 1 +FAIL golang.org/x/tools/go/loader 19.542s +``` + +Spotted on [build.golang.org](https://build.golang.org/?repo=golang.org%2fx%2ftools). + +/cc @ianthehat @matloob per [owners](https://dev.golang.org/owners).",1.0,"x/tools/go/loader: TestStdlib is failing on tip because TestTempFile was moved - [CL 226877](https://golang.org/cl/226877) has moved the function `TestTempFile` from `io/ioutil` internal test to external test. `TestStdlib` is now failing: + +``` +$ gotip test +[...] +--- FAIL: TestStdlib (10.54s) + stdlib_test.go:103: package ""io/ioutil"" has no func ""TestTempFile"" + stdlib_test.go:117: GOMAXPROCS: 8 + stdlib_test.go:118: #Source lines: 1303424 + stdlib_test.go:119: Load/parse/typecheck: 10.070588601s + stdlib_test.go:120: #MB: 1068 +FAIL +exit status 1 +FAIL golang.org/x/tools/go/loader 19.542s +``` + +Spotted on [build.golang.org](https://build.golang.org/?repo=golang.org%2fx%2ftools). + +/cc @ianthehat @matloob per [owners](https://dev.golang.org/owners).",0,x tools go loader teststdlib is failing on tip because testtempfile was moved has moved the function testtempfile from io ioutil internal test to external test teststdlib is now failing gotip test fail teststdlib stdlib test go package io ioutil has no func testtempfile stdlib test go gomaxprocs stdlib test go source lines stdlib test go load parse typecheck stdlib test go mb fail exit status fail golang org x tools go loader spotted on cc ianthehat matloob per ,0 +211843,16460193729.0,IssuesEvent,2021-05-21 17:44:28,golang/go,https://api.github.com/repos/golang/go,closed,doc/go1.17: document database/sql changes for Go 1.17,Documentation NeedsInvestigation help wanted release-blocker,"As of filing this issue, the [Go 1.17 draft release notes](https://tip.golang.org/doc/go1.17) contained the following HTML: + ++ TODO: https://golang.org/cl/258360: close driver.Connector if it implements io.Closer +
++ TODO: https://golang.org/cl/311572: add NullInt16 and NullByte +
++ TODO: https://golang.org/cl/258360: close driver.Connector if it implements io.Closer +
++ TODO: https://golang.org/cl/311572: add NullInt16 and NullByte +
++go version go1.12.6 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN=""/Users/tristian/go/bin"" +GOCACHE=""/Users/tristian/Library/Caches/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/tristian/go"" +GOPROXY="""" +GORACE="""" +GOROOT=""/usr/local/Cellar/go/1.12.6/libexec"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.12.6/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/tristian/Repositories/github.com/triztian/my.binary.project/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/g1/v3hz1sm92nv7wbzpg3dx_h_h0000gp/T/go-build549198414=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
+go version go1.12.6 darwin/amd64 ++ +### Does this issue reproduce with the latest release? + +yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GOARCH=""amd64"" +GOBIN=""/Users/tristian/go/bin"" +GOCACHE=""/Users/tristian/Library/Caches/go-build"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GOOS=""darwin"" +GOPATH=""/Users/tristian/go"" +GOPROXY="""" +GORACE="""" +GOROOT=""/usr/local/Cellar/go/1.12.6/libexec"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/Cellar/go/1.12.6/libexec/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD=""/Users/tristian/Repositories/github.com/triztian/my.binary.project/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/g1/v3hz1sm92nv7wbzpg3dx_h_h0000gp/T/go-build549198414=/tmp/go-build -gno-record-gcc-switches -fno-common"" + +
+ TODO +
+ +
+ On Linux, the runtime now defaults to releasing memory to the
+ operating system promptly (using MADV_DONTNEED), rather
+ than lazily when the operating system is under memory pressure
+ (using MADV_FREE). This means process-level memory
+ statistics like RSS will more accurately reflect the amount of
+ physical memory being used by Go processes. Systems that are
+ currently using GODEBUG=madvdontneed=1 to improve
+ memory monitoring behavior no longer need to set this environment
+ variable.
+
+ TODO: https://golang.org/cl/37222: make stack traces of endless recursion print only top and bottom 50 +
++ TODO: https://golang.org/cl/242258: add 24 byte allocation size class +
++ TODO: https://golang.org/cl/254659: implement GODEBUG=inittrace=1 support +
++ TODO +
+ +
+ On Linux, the runtime now defaults to releasing memory to the
+ operating system promptly (using MADV_DONTNEED), rather
+ than lazily when the operating system is under memory pressure
+ (using MADV_FREE). This means process-level memory
+ statistics like RSS will more accurately reflect the amount of
+ physical memory being used by Go processes. Systems that are
+ currently using GODEBUG=madvdontneed=1 to improve
+ memory monitoring behavior no longer need to set this environment
+ variable.
+
+ TODO: https://golang.org/cl/37222: make stack traces of endless recursion print only top and bottom 50 +
++ TODO: https://golang.org/cl/242258: add 24 byte allocation size class +
++ TODO: https://golang.org/cl/254659: implement GODEBUG=inittrace=1 support +
++$ go version +go version go1.13.1 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/andrew/.cache/go-build"" +GOENV=""/home/andrew/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/andrew/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go-1.13"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go-1.13/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/andrew/go/src/code.gitea.io/gitea/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build028639981=/tmp/go-build -gno-record-gcc-switches"" + +
+$ go version +go version go1.13.1 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +yes + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/andrew/.cache/go-build"" +GOENV=""/home/andrew/.config/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/andrew/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/lib/go-1.13"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/lib/go-1.13/pkg/tool/linux_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/home/andrew/go/src/code.gitea.io/gitea/go.mod"" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build028639981=/tmp/go-build -gno-record-gcc-switches"" + +
+ TODO: https://golang.org/cl/305230: support reading shared mime-info database on unix systems +
++ TODO: https://golang.org/cl/305230: support reading shared mime-info database on unix systems +
+What does 'go version' print?
+
+go version go1.4rc1 darwin/amd64
+
+What steps reproduce the problem?
+If possible, include a link to a program on play.golang.org.
+
+1. View the docs at http://tip.golang.org/pkg/net/http/
+
+What happened?
+
+Docs show the following method for cleaning up response bodies:
+
+resp, err := http.Get("http://example.com/")
+if err != nil {
+ // handle error
+}
+defer resp.Body.Close()
+
+What should have happened instead?
+
+The method shown above does not handle the case where both resp and err are non-nil,
+which was preserved for compatibility reasons in #3795. If the response was a redirect
+and the CheckRedirect func returned an error, the http.Client will return both the
+Response and an error. That response's Body would never be closed under the example
+shown above, and its connection would leak.
+
+Unfortunately, I suspect this compatibility fix has probably led to lots of potential
+leaks in Go code in the wild. Since breaking Go 1 compatibility is not an option, the
+docs for Go 1 should show people how to correctly clean up after responses without
+leaking conns & file descriptors.
+
+Instead, the following should work and would not leak:
+
+resp, err := http.Get("http://example.com/")
+if resp != nil {
+ defer resp.Body.Close()
+}
+if err != nil {
+ // handle error
+}
+
+Please provide any additional information below.",1.0,"net/http: docs show insufficient way to cleanup Response Body - What does 'go version' print?
+
+go version go1.4rc1 darwin/amd64
+
+What steps reproduce the problem?
+If possible, include a link to a program on play.golang.org.
+
+1. View the docs at http://tip.golang.org/pkg/net/http/
+
+What happened?
+
+Docs show the following method for cleaning up response bodies:
+
+resp, err := http.Get("http://example.com/")
+if err != nil {
+ // handle error
+}
+defer resp.Body.Close()
+
+What should have happened instead?
+
+The method shown above does not handle the case where both resp and err are non-nil,
+which was preserved for compatibility reasons in #3795. If the response was a redirect
+and the CheckRedirect func returned an error, the http.Client will return both the
+Response and an error. That response's Body would never be closed under the example
+shown above, and its connection would leak.
+
+Unfortunately, I suspect this compatibility fix has probably led to lots of potential
+leaks in Go code in the wild. Since breaking Go 1 compatibility is not an option, the
+docs for Go 1 should show people how to correctly clean up after responses without
+leaking conns & file descriptors.
+
+Instead, the following should work and would not leak:
+
+resp, err := http.Get("http://example.com/")
+if resp != nil {
+ defer resp.Body.Close()
+}
+if err != nil {
+ // handle error
+}
+
+Please provide any additional information below.",1,net http docs show insufficient way to cleanup response body what does go version print go version darwin what steps reproduce the problem if possible include a link to a program on play golang org view the docs at a href what happened docs show the following method for cleaning up response bodies resp err http get quot a href if err nil handle error defer resp body close what should have happened instead the method shown above does not handle the case where both resp and err are non nil which was preserved for compatibility reasons in if the response was a redirect and the checkredirect func returned an error the http client will return both the response and an error that response s body would never be closed under the example shown above and its connection would leak unfortunately i suspect this compatibility fix has probably led to lots of potential leaks in go code in the wild since breaking go compatibility is not an option the docs for go should show people how to correctly clean up after responses without leaking conns amp file descriptors instead the following should work and would not leak resp err http get quot a href if resp nil defer resp body close if err nil handle error please provide any additional information below ,1
+3754,4028538609.0,IssuesEvent,2016-05-18 06:55:25,golang/go,https://api.github.com/repos/golang/go,closed,compress/flate: Add optimizations and re+balance.,Performance,"We should merge optimizations added to https://github.com/klauspost/compress
+
+Typical speedup is around 1.7x for web content, when maintaining roughly the same compression.
+
+With [re-balanced compression settings](https://github.com/klauspost/compress/pull/31), the default level will be 3.1x faster at a 7% compression loss. Mixed content (disk images) show a 3.1x speedup with a 3% compression loss.
+
+Extensive benchmarks in this [google spreadsheet](https://docs.google.com/spreadsheets/d/1nuNE2nPfuINCZJRMt6wFWhKpToF95I47XjSsc-1rbPQ/edit?usp=sharing).",True,"compress/flate: Add optimizations and re+balance. - We should merge optimizations added to https://github.com/klauspost/compress
+
+Typical speedup is around 1.7x for web content, when maintaining roughly the same compression.
+
+With [re-balanced compression settings](https://github.com/klauspost/compress/pull/31), the default level will be 3.1x faster at a 7% compression loss. Mixed content (disk images) show a 3.1x speedup with a 3% compression loss.
+
+Extensive benchmarks in this [google spreadsheet](https://docs.google.com/spreadsheets/d/1nuNE2nPfuINCZJRMt6wFWhKpToF95I47XjSsc-1rbPQ/edit?usp=sharing).",0,compress flate add optimizations and re balance we should merge optimizations added to typical speedup is around for web content when maintaining roughly the same compression with the default level will be faster at a compression loss mixed content disk images show a speedup with a compression loss extensive benchmarks in this ,0
+75249,20740350934.0,IssuesEvent,2022-03-14 17:06:23,golang/go,https://api.github.com/repos/golang/go,closed,x/build: the linux-s390x-ibm builders will be unavailable due to maintenance,Builders,"The linux-s390x-ibm builders will be unavailable due to data center maintenance. The planned outage will start on Friday, March 11th, 5PM ET and servers will be brought back up automatically by 11:59 PM ET Sunday, March 13th.
+
+The builders should startup automatically once the servers are restarted.
+
+/cc @golang/release",1.0,"x/build: the linux-s390x-ibm builders will be unavailable due to maintenance - The linux-s390x-ibm builders will be unavailable due to data center maintenance. The planned outage will start on Friday, March 11th, 5PM ET and servers will be brought back up automatically by 11:59 PM ET Sunday, March 13th.
+
+The builders should startup automatically once the servers are restarted.
+
+/cc @golang/release",0,x build the linux ibm builders will be unavailable due to maintenance the linux ibm builders will be unavailable due to data center maintenance the planned outage will start on friday march et and servers will be brought back up automatically by pm et sunday march the builders should startup automatically once the servers are restarted cc golang release,0
+11046,3454732978.0,IssuesEvent,2015-12-17 17:03:23,golang/go,https://api.github.com/repos/golang/go,closed,net/http: ServeMux unexpectedly redirecting to add trailing slash,Documentation,"`http.ServeMux` unexpectedly redirects to add a trailing slash if there is a route that matches with a trailing slash.
+
+Given the following `ServeMux`, I expect that a request for `/a` would match the path rooted as `/`.
+
+```go
+http.HandleFunc(""/"", ...)
+http.HandleFunc(""/a/"", ...)
+```
+Instead, a 301 redirect is returned redirecting to `/a/` (see http://play.golang.org/p/65Skm2I5hq).
+
+The docs describe redirects as happening in path sanitization cases (ie: requests with `.` or `..` elements), but no mention of transparently adding slashes. The docs also describe the match as a `""rooted subtree""` so it's also unexpected that a pattern for `/a/` would affect requests that don't have that prefix (ie: w/o the trailing slash).
+
+In researching if this situation was reported before, I found a mailing list from 2010 implying this [was expected](https://groups.google.com/d/msg/golang-nuts/P-uq-cN4tjA/Mw9Ns2no35gJ) as well as a [code comment](http://golang.org/src/net/http/server.go#L1566). If that is still the case, then i think the docs should reflect that. (though i personally consider this a bug, i could understand that for some this could be a feature).
+",1.0,"net/http: ServeMux unexpectedly redirecting to add trailing slash - `http.ServeMux` unexpectedly redirects to add a trailing slash if there is a route that matches with a trailing slash.
+
+Given the following `ServeMux`, I expect that a request for `/a` would match the path rooted as `/`.
+
+```go
+http.HandleFunc(""/"", ...)
+http.HandleFunc(""/a/"", ...)
+```
+Instead, a 301 redirect is returned redirecting to `/a/` (see http://play.golang.org/p/65Skm2I5hq).
+
+The docs describe redirects as happening in path sanitization cases (ie: requests with `.` or `..` elements), but no mention of transparently adding slashes. The docs also describe the match as a `""rooted subtree""` so it's also unexpected that a pattern for `/a/` would affect requests that don't have that prefix (ie: w/o the trailing slash).
+
+In researching if this situation was reported before, I found a mailing list from 2010 implying this [was expected](https://groups.google.com/d/msg/golang-nuts/P-uq-cN4tjA/Mw9Ns2no35gJ) as well as a [code comment](http://golang.org/src/net/http/server.go#L1566). If that is still the case, then i think the docs should reflect that. (though i personally consider this a bug, i could understand that for some this could be a feature).
+",1,net http servemux unexpectedly redirecting to add trailing slash http servemux unexpectedly redirects to add a trailing slash if there is a route that matches with a trailing slash given the following servemux i expect that a request for a would match the path rooted as go http handlefunc http handlefunc a instead a redirect is returned redirecting to a see the docs describe redirects as happening in path sanitization cases ie requests with or elements but no mention of transparently adding slashes the docs also describe the match as a rooted subtree so it s also unexpected that a pattern for a would affect requests that don t have that prefix ie w o the trailing slash in researching if this situation was reported before i found a mailing list from implying this as well as a if that is still the case then i think the docs should reflect that though i personally consider this a bug i could understand that for some this could be a feature ,1
+143515,11568324951.0,IssuesEvent,2020-02-20 15:42:29,golang/go,https://api.github.com/repos/golang/go,opened,"net: TestDialCancel failure on linux-arm with ""network is unreachable""",NeedsInvestigation Testing,"In the fix for #15191, we skipped the test in case of a `connection refused` error.
+It looks like we may need to widen that to `network is unreachable` as well.
+
+```
+--- FAIL: TestDialCancel (0.00s)
+ dial_test.go:820: dial error after 0 ticks (5 before cancel sent): dial tcp 198.18.0.254:1234: connect: network is unreachable
+FAIL
+FAIL net 27.044s
+```
+
+CC @ianlancetaylor @bradfitz
+
+[2020-02-19T20:40:29-2200b4f/linux-arm](https://build.golang.org/log/5523485f69960aa5dbec0ff4339f12cdd3b7fac4)
+[2020-01-23T21:01:12-ace25f8/linux-arm](https://build.golang.org/log/f4257efbd7a18e595d454c249d7a7894796b1cec)
+[2020-01-09T17:52:05-cec535b/linux-arm](https://build.golang.org/log/1c214d88ce74268ce8536f43b34342dafc3d1a6a)
+[2020-01-06T15:47:02-72f92de/linux-arm](https://build.golang.org/log/4b30aec77df3712ced1ab66ff6dfe8ec785d5d58)
+[2020-01-06T02:46:02-c6e8426/linux-arm](https://build.golang.org/log/aa738d6e0152d7541ffa81bcc862e9690af70174)
+[2019-11-18T18:14:37-f9dd99c/linux-arm](https://build.golang.org/log/0f5f4da21697db5280324ade62f3aa71155b95d3)
+[2019-10-30T08:17:29-f4e32ae/linux-arm](https://build.golang.org/log/019db9d64edc807077516ba20399da59bd7a949e)
+[2019-10-24T08:47:14-722b0e3/linux-arm](https://build.golang.org/log/7f8f96b8caaa1ad5f1f3b75f9cbc97cfde3b3c9b)
+[2019-10-23T18:41:38-7833302/linux-arm](https://build.golang.org/log/0a75fed0ef5bd75781360367b291954e19023408)
+[2019-10-11T17:03:37-df38069/linux-arm](https://build.golang.org/log/648f8fd836a73fc2f6f428772c21b9f5cda5ff31)
+[2019-09-25T04:18:18-7fc2625/linux-arm](https://build.golang.org/log/29ecd5fb9d6853a2370163d0d81c265a86343e70)
+[2019-09-06T20:05:29-5e43856/linux-arm](https://build.golang.org/log/424f85c190683239a5316a7c8915d39fb1dfcb03)
+[2019-09-01T02:31:50-d15dfdc/linux-arm](https://build.golang.org/log/806bf66f3ac7ce31e8a6f521e619d48485c65b97)
+[2019-08-02T17:51:34-2d1a1e0/linux-arm](https://build.golang.org/log/ed29640b1bf14bb32bc5c0f6be599c4da0c35ad9)
+[2019-06-19T07:09:13-18107ed/linux-arm](https://build.golang.org/log/7460cac43be8414f1f3766051dcc583aa7cbfb8f)
+[2019-06-14T19:37:52-f18aeb3/linux-arm](https://build.golang.org/log/962376bdb46f230de6dcae325f88b618745c3e7c)
+[2019-05-16T03:25:01-dccd5da/linux-arm](https://build.golang.org/log/acf3bbe6a1634db0fd3d45b1bfd7bef643b28a94)
+[2019-05-02T20:30:31-0a338f7/linux-arm](https://build.golang.org/log/d3a3d225d1bb468f5dddf76188b472d7036e3a2e)
+[2019-04-30T20:26:36-85387aa/linux-arm](https://build.golang.org/log/68ce4257c9e3a9bf6e2e01e41ec0e8e8897a5f9e)
+[2019-04-30T17:45:16-1fd1408/linux-arm](https://build.golang.org/log/f48f27568ebadd29cddb93e5d0f88e5ed91b0851)
+[2019-04-27T17:15:55-17a7f21/linux-arm](https://build.golang.org/log/1f0d8614f07980f3cca697a6de720f3b05266d9e)
+",1.0,"net: TestDialCancel failure on linux-arm with ""network is unreachable"" - In the fix for #15191, we skipped the test in case of a `connection refused` error.
+It looks like we may need to widen that to `network is unreachable` as well.
+
+```
+--- FAIL: TestDialCancel (0.00s)
+ dial_test.go:820: dial error after 0 ticks (5 before cancel sent): dial tcp 198.18.0.254:1234: connect: network is unreachable
+FAIL
+FAIL net 27.044s
+```
+
+CC @ianlancetaylor @bradfitz
+
+[2020-02-19T20:40:29-2200b4f/linux-arm](https://build.golang.org/log/5523485f69960aa5dbec0ff4339f12cdd3b7fac4)
+[2020-01-23T21:01:12-ace25f8/linux-arm](https://build.golang.org/log/f4257efbd7a18e595d454c249d7a7894796b1cec)
+[2020-01-09T17:52:05-cec535b/linux-arm](https://build.golang.org/log/1c214d88ce74268ce8536f43b34342dafc3d1a6a)
+[2020-01-06T15:47:02-72f92de/linux-arm](https://build.golang.org/log/4b30aec77df3712ced1ab66ff6dfe8ec785d5d58)
+[2020-01-06T02:46:02-c6e8426/linux-arm](https://build.golang.org/log/aa738d6e0152d7541ffa81bcc862e9690af70174)
+[2019-11-18T18:14:37-f9dd99c/linux-arm](https://build.golang.org/log/0f5f4da21697db5280324ade62f3aa71155b95d3)
+[2019-10-30T08:17:29-f4e32ae/linux-arm](https://build.golang.org/log/019db9d64edc807077516ba20399da59bd7a949e)
+[2019-10-24T08:47:14-722b0e3/linux-arm](https://build.golang.org/log/7f8f96b8caaa1ad5f1f3b75f9cbc97cfde3b3c9b)
+[2019-10-23T18:41:38-7833302/linux-arm](https://build.golang.org/log/0a75fed0ef5bd75781360367b291954e19023408)
+[2019-10-11T17:03:37-df38069/linux-arm](https://build.golang.org/log/648f8fd836a73fc2f6f428772c21b9f5cda5ff31)
+[2019-09-25T04:18:18-7fc2625/linux-arm](https://build.golang.org/log/29ecd5fb9d6853a2370163d0d81c265a86343e70)
+[2019-09-06T20:05:29-5e43856/linux-arm](https://build.golang.org/log/424f85c190683239a5316a7c8915d39fb1dfcb03)
+[2019-09-01T02:31:50-d15dfdc/linux-arm](https://build.golang.org/log/806bf66f3ac7ce31e8a6f521e619d48485c65b97)
+[2019-08-02T17:51:34-2d1a1e0/linux-arm](https://build.golang.org/log/ed29640b1bf14bb32bc5c0f6be599c4da0c35ad9)
+[2019-06-19T07:09:13-18107ed/linux-arm](https://build.golang.org/log/7460cac43be8414f1f3766051dcc583aa7cbfb8f)
+[2019-06-14T19:37:52-f18aeb3/linux-arm](https://build.golang.org/log/962376bdb46f230de6dcae325f88b618745c3e7c)
+[2019-05-16T03:25:01-dccd5da/linux-arm](https://build.golang.org/log/acf3bbe6a1634db0fd3d45b1bfd7bef643b28a94)
+[2019-05-02T20:30:31-0a338f7/linux-arm](https://build.golang.org/log/d3a3d225d1bb468f5dddf76188b472d7036e3a2e)
+[2019-04-30T20:26:36-85387aa/linux-arm](https://build.golang.org/log/68ce4257c9e3a9bf6e2e01e41ec0e8e8897a5f9e)
+[2019-04-30T17:45:16-1fd1408/linux-arm](https://build.golang.org/log/f48f27568ebadd29cddb93e5d0f88e5ed91b0851)
+[2019-04-27T17:15:55-17a7f21/linux-arm](https://build.golang.org/log/1f0d8614f07980f3cca697a6de720f3b05266d9e)
+",0,net testdialcancel failure on linux arm with network is unreachable in the fix for we skipped the test in case of a connection refused error it looks like we may need to widen that to network is unreachable as well fail testdialcancel dial test go dial error after ticks before cancel sent dial tcp connect network is unreachable fail fail net cc ianlancetaylor bradfitz ,0
+12057,3573604348.0,IssuesEvent,2016-01-27 07:37:39,golang/go,https://api.github.com/repos/golang/go,closed,database/sql: document allowed Scan conversions,Documentation,"What does 'go version' print?
+
+go version go1.3.3 darwin/amd64
+
+What steps reproduce the problem?
+If possible, include a link to a program on play.golang.org.
+
+http://play.golang.org/p/mk7wJKtz4H
+
+What happened?
+
+NullString.Scan didn't accept a time.Time value:
+
+error: unsupported driver -> Scan pair: time.Time -> *string
+
+What should have happened instead?
+
+It should have converted the time.Time value into a string, just it does with any other
+type that Scan accepts.
+
+Please provide any additional information below.
+
+The contract for Scanner says:
+
+ // Scan assigns a value from a database driver.
+ //
+ // The src value will be of one of the following restricted
+ // set of types:
+ //
+ // int64
+ // float64
+ // bool
+ // []byte
+ // string
+ // time.Time
+ // nil - for NULL values
+ //
+ // An error should be returned if the value can not be stored
+ // without loss of information.
+ Scan(src interface{}) error
+
+All of the other types work by formatting the values as strings. Given that time.Time
+has a String() function, I would assume it would be handled as well.",1.0,"database/sql: document allowed Scan conversions - What does 'go version' print?
+
+go version go1.3.3 darwin/amd64
+
+What steps reproduce the problem?
+If possible, include a link to a program on play.golang.org.
+
+http://play.golang.org/p/mk7wJKtz4H
+
+What happened?
+
+NullString.Scan didn't accept a time.Time value:
+
+error: unsupported driver -> Scan pair: time.Time -> *string
+
+What should have happened instead?
+
+It should have converted the time.Time value into a string, just it does with any other
+type that Scan accepts.
+
+Please provide any additional information below.
+
+The contract for Scanner says:
+
+ // Scan assigns a value from a database driver.
+ //
+ // The src value will be of one of the following restricted
+ // set of types:
+ //
+ // int64
+ // float64
+ // bool
+ // []byte
+ // string
+ // time.Time
+ // nil - for NULL values
+ //
+ // An error should be returned if the value can not be stored
+ // without loss of information.
+ Scan(src interface{}) error
+
+All of the other types work by formatting the values as strings. Given that time.Time
+has a String() function, I would assume it would be handled as well.",1,database sql document allowed scan conversions what does go version print go version darwin what steps reproduce the problem if possible include a link to a program on play golang org a href what happened nullstring scan didn t accept a time time value error unsupported driver gt scan pair time time gt string what should have happened instead it should have converted the time time value into a string just it does with any other type that scan accepts please provide any additional information below the contract for scanner says scan assigns a value from a database driver the src value will be of one of the following restricted set of types bool byte string time time nil for null values an error should be returned if the value can not be stored without loss of information scan src interface error all of the other types work by formatting the values as strings given that time time has a string function i would assume it would be handled as well ,1
+22376,4793115396.0,IssuesEvent,2016-10-31 17:17:26,golang/go,https://api.github.com/repos/golang/go,closed,reflect: NumMethod doesn't return not exported members of method sets,Documentation,"### What version of Go are you using (`go version`)?
+
+go version go1.7.1 darwin/amd64
+
+### What operating system and processor architecture are you using (`go env`)?
+
+```
+> go env
+GOARCH=""amd64""
+GOBIN=""""
+GOEXE=""""
+GOHOSTARCH=""amd64""
+GOHOSTOS=""darwin""
+GOOS=""darwin""
+GOPATH=""/Users/mlowicki/projects/golang/spec""
+GORACE=""""
+GOROOT=""/usr/local/go""
+GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64""
+CC=""clang""
+GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -gno-record-gcc-switches -fno-common""
+CXX=""clang++""
+CGO_ENABLED=""1""
+```
+
+### Repro
+https://play.golang.org/p/eXoyuqajG6
+
+### Expected result
+I expect to see method `n` also printed out and language spec doesn't enforce that method set contains only exported identifiers.
+
+Currently it displays only info about `M`:
+```
+Number of methods: 1
+Method {M func(main.T) I want to construct a cache of properties computed from a reflect.Type.
+(For an example application, see http://play.golang.org/p/csLP1bBXJV)
+
+The natural representation for that is map[reflect.Type]properties, but the correctness
+of that approach depends on the implementation details of reflect.Type.
+
+The documentation for (reflect.Type).String() says, "To test for equality, compare
+the Types directly." So that gives me some indication that what I'm trying to do
+is reasonable. However, nothing in the package tells me whether I can rely on the fact
+that a reflect.Type is hashable. (In practice, it currently is.)
+
+
+The other alternatives I've considered are:
+
+ map[struct{ pkgPath, name string }]properties - fails for unnamed types.
+
+ map[uintptr]properties using reflect.Value.UnsafeAddr(t) - seems much worse than relying on hashability.
+
+ map[uintptr]struct{reflect.Type, properties} using a hand-rolled hash function - very, very messy.
+
+
+Since reflect.Type is hashable in practice anyway, the simplest solution would be to
+document that that must be the case.
+
+Obviously that has some drawbacks - it prevents reflect.Type from ever acquiring a
+non-hashable field - but that still seems preferable to adding some kind of user-side
+hashing or a new method for retrieving a unique ID.
+
+On the other hand, if reflect.Type is not hashable, it would be good to document the
+preferred workaround for constructing maps with Types as keys.
+",1.0,"reflect: Is reflect.Type guaranteed to be hashable? - I want to construct a cache of properties computed from a reflect.Type.
+(For an example application, see http://play.golang.org/p/csLP1bBXJV)
+
+The natural representation for that is map[reflect.Type]properties, but the correctness
+of that approach depends on the implementation details of reflect.Type.
+
+The documentation for (reflect.Type).String() says, "To test for equality, compare
+the Types directly." So that gives me some indication that what I'm trying to do
+is reasonable. However, nothing in the package tells me whether I can rely on the fact
+that a reflect.Type is hashable. (In practice, it currently is.)
+
+
+The other alternatives I've considered are:
+
+ map[struct{ pkgPath, name string }]properties - fails for unnamed types.
+
+ map[uintptr]properties using reflect.Value.UnsafeAddr(t) - seems much worse than relying on hashability.
+
+ map[uintptr]struct{reflect.Type, properties} using a hand-rolled hash function - very, very messy.
+
+
+Since reflect.Type is hashable in practice anyway, the simplest solution would be to
+document that that must be the case.
+
+Obviously that has some drawbacks - it prevents reflect.Type from ever acquiring a
+non-hashable field - but that still seems preferable to adding some kind of user-side
+hashing or a new method for retrieving a unique ID.
+
+On the other hand, if reflect.Type is not hashable, it would be good to document the
+preferred workaround for constructing maps with Types as keys.
+",1,reflect is reflect type guaranteed to be hashable i want to construct a cache of properties computed from a reflect type for an example application see a href the natural representation for that is map properties but the correctness of that approach depends on the implementation details of reflect type the documentation for reflect type string says quot to test for equality compare the types directly quot so that gives me some indication that what i m trying to do is reasonable however nothing in the package tells me whether i can rely on the fact that a reflect type is hashable in practice it currently is the other alternatives i ve considered are map properties fails for unnamed types map properties using reflect value unsafeaddr t seems much worse than relying on hashability map struct reflect type properties using a hand rolled hash function very very messy since reflect type is hashable in practice anyway the simplest solution would be to document that that must be the case obviously that has some drawbacks it prevents reflect type from ever acquiring a non hashable field but that still seems preferable to adding some kind of user side hashing or a new method for retrieving a unique id on the other hand if reflect type is not hashable it would be good to document the preferred workaround for constructing maps with types as keys ,1
+41206,21557401163.0,IssuesEvent,2022-04-30 17:00:31,golang/go,https://api.github.com/repos/golang/go,opened,cmd/compile: optimized range memclr doesn't work with pointers to arrays,Performance,"```go
+package p
+
+type T struct {
+ a *[10]int
+ b [10]int
+}
+
+func (t *T) resetA() {
+ for i := range t.a {
+ t.a[i] = 0
+ }
+}
+
+func (t *T) resetB() {
+ for i := range t.b {
+ t.b[i] = 0
+ }
+}
+```
+
+resetA compiles to a loop. resetB compiles to a call to runtime.memclrNoHeapPointers. I believe that resetA should also call memclrNoHeapPointers.
+
+This showed up as a hot spot in my code today (with much larger arrays).
+
+cc @randall77 @cuonglm @mdempsky
+
+",True,"cmd/compile: optimized range memclr doesn't work with pointers to arrays - ```go
+package p
+
+type T struct {
+ a *[10]int
+ b [10]int
+}
+
+func (t *T) resetA() {
+ for i := range t.a {
+ t.a[i] = 0
+ }
+}
+
+func (t *T) resetB() {
+ for i := range t.b {
+ t.b[i] = 0
+ }
+}
+```
+
+resetA compiles to a loop. resetB compiles to a call to runtime.memclrNoHeapPointers. I believe that resetA should also call memclrNoHeapPointers.
+
+This showed up as a hot spot in my code today (with much larger arrays).
+
+cc @randall77 @cuonglm @mdempsky
+
+",0,cmd compile optimized range memclr doesn t work with pointers to arrays go package p type t struct a int b int func t t reseta for i range t a t a func t t resetb for i range t b t b reseta compiles to a loop resetb compiles to a call to runtime memclrnoheappointers i believe that reseta should also call memclrnoheappointers this showed up as a hot spot in my code today with much larger arrays cc cuonglm mdempsky ,0
+318740,23737822697.0,IssuesEvent,2022-08-31 09:39:21,golang/go,https://api.github.com/repos/golang/go,closed,net/http/pprof: documentation doesn't mention some available endpoints,Documentation NeedsFix,"Looking at https://pkg.go.dev/net/http/pprof as of Go 1.18.4, the following endpoints are documented:
+
+* heap
+* profile
+* block
+* mutex
+* trace
+
+From looking at https://cs.opensource.google/go/go/+/refs/tags/go1.18.4:src/net/http/pprof/pprof.go;l=344-354, the following are seemingly undocumented:
+
+* allocs
+* cmdline
+* goroutine
+* threadcreate
+
+In particular, I think the `goroutine` endpoint is critically underused; goroutine leaks are a fairly common source of problems in long-lived Go servers, and being able to obtain a goroutine stack dump via `/debug/pprof/goroutine?debug=2` is invaluable. I've met a handful of people over the years who needed this and resorted to heavier alternatives like SIGQUIT because they weren't aware that `net/http/pprof` had it.
+
+cc @cherrymui @rsc per https://dev.golang.org/owners",1.0,"net/http/pprof: documentation doesn't mention some available endpoints - Looking at https://pkg.go.dev/net/http/pprof as of Go 1.18.4, the following endpoints are documented:
+
+* heap
+* profile
+* block
+* mutex
+* trace
+
+From looking at https://cs.opensource.google/go/go/+/refs/tags/go1.18.4:src/net/http/pprof/pprof.go;l=344-354, the following are seemingly undocumented:
+
+* allocs
+* cmdline
+* goroutine
+* threadcreate
+
+In particular, I think the `goroutine` endpoint is critically underused; goroutine leaks are a fairly common source of problems in long-lived Go servers, and being able to obtain a goroutine stack dump via `/debug/pprof/goroutine?debug=2` is invaluable. I've met a handful of people over the years who needed this and resorted to heavier alternatives like SIGQUIT because they weren't aware that `net/http/pprof` had it.
+
+cc @cherrymui @rsc per https://dev.golang.org/owners",1,net http pprof documentation doesn t mention some available endpoints looking at as of go the following endpoints are documented heap profile block mutex trace from looking at the following are seemingly undocumented allocs cmdline goroutine threadcreate in particular i think the goroutine endpoint is critically underused goroutine leaks are a fairly common source of problems in long lived go servers and being able to obtain a goroutine stack dump via debug pprof goroutine debug is invaluable i ve met a handful of people over the years who needed this and resorted to heavier alternatives like sigquit because they weren t aware that net http pprof had it cc cherrymui rsc per ,1
+370129,25889801032.0,IssuesEvent,2022-12-14 17:02:20,golang/go,https://api.github.com/repos/golang/go,opened,"spec: ""type parameters are interfaces"" is confusing",Documentation,"Per the spec, the underlying type of a type parameter is its constraint interface. Similarly to how we talk about an X type (say, an array type) if the underlying type of a named type is X, we also talk about interface types for type parameters. This is confusing.
+
+Reminder issue to try clearer prose where needed.
+
+See also @findleyr 's comment [here](https://go-review.git.corp.google.com/c/go/+/457095/3/doc/go_spec.html#5137).",1.0,"spec: ""type parameters are interfaces"" is confusing - Per the spec, the underlying type of a type parameter is its constraint interface. Similarly to how we talk about an X type (say, an array type) if the underlying type of a named type is X, we also talk about interface types for type parameters. This is confusing.
+
+Reminder issue to try clearer prose where needed.
+
+See also @findleyr 's comment [here](https://go-review.git.corp.google.com/c/go/+/457095/3/doc/go_spec.html#5137).",1,spec type parameters are interfaces is confusing per the spec the underlying type of a type parameter is its constraint interface similarly to how we talk about an x type say an array type if the underlying type of a named type is x we also talk about interface types for type parameters this is confusing reminder issue to try clearer prose where needed see also findleyr s comment ,1
+53761,7855096922.0,IssuesEvent,2018-06-20 23:36:15,golang/go,https://api.github.com/repos/golang/go,closed,doc: update gopherbot wiki to account for backporting command,Documentation NeedsFix,"In https://github.com/golang/go/wiki/gopherbot the section for backporting is currently empty. We should fill it out :)
+
+/cc @filippo
+
+@gopherbot needsfix",1.0,"doc: update gopherbot wiki to account for backporting command - In https://github.com/golang/go/wiki/gopherbot the section for backporting is currently empty. We should fill it out :)
+
+/cc @filippo
+
+@gopherbot needsfix",1,doc update gopherbot wiki to account for backporting command in the section for backporting is currently empty we should fill it out cc filippo gopherbot needsfix,1
+28942,13900364601.0,IssuesEvent,2020-10-20 00:08:25,golang/go,https://api.github.com/repos/golang/go,closed,cmd/compile: support inlining OCALLPART,Performance,"`context.WithCancel` allocates three objects. One is a `*cancelCtx`, unavoidable. Another is a `chan struct{}`, hard to eliminate without runtime magic or a language change. The last is [a closure](https://golang.org/src/context/context.go#L232):
+
+```go
+ return &c, func() { c.cancel(true, Canceled) }
+```
+
+`Canceled` is a top-level var initialized with `errors.New`; it is an `*errorString` under the hood. Note that `true` and `Canceled` are both static data. And `c` has already leaked to the heap, courtesy of the `&c` return. The method `cancel` can be staticly resolved. So it seems like in principle it ought to be possible not to allocate for the closure; everything we need is either static or on the heap already.
+
+Here's a straw man for how this might be accomplished. Generate a wrapper method:
+
+```go
+func (c * cancelCtx) cancelTrueCanceled() { c.cancel(true, Canceled) }
+```
+
+and rewrite the original return to:
+
+```go
+ return &c, c.cancelTrueCanceled
+```
+
+(This can also be done manually, if this first transformation is too hard.) Now we have a partial method call with no free variables instead of a closure.
+
+Now represent this partial method call as a tuple: +$ go version +go version go1.16.3 windows/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes, including on tip. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +set GO111MODULE=on +set GOARCH=amd64 +set GOBIN= +set GOCACHE=C:\Users\zephyr\AppData\Local\go-build +set GOENV=C:\Users\zephyr\AppData\Roaming\go\env +set GOEXE=.exe +set GOFLAGS= +set GOHOSTARCH=amd64 +set GOHOSTOS=windows +set GOINSECURE= +set GOMODCACHE=E:\go\pkg\mod +set GONOPROXY= +set GONOSUMDB= +set GOOS=windows +set GOPATH=E:\go +set GOPRIVATE= +set GOPROXY=https://proxy.golang.org,direct +set GOROOT=c:\go +set GOSUMDB=sum.golang.org +set GOTMPDIR= +set GOTOOLDIR=c:\go\pkg\tool\windows_amd64 +set GOVCS= +set GOVERSION=go1.16.3 +set GCCGO=gccgo +set AR=ar +set CC=gcc +set CXX=g++ +set CGO_ENABLED=1 +set GOMOD=NUL +set CGO_CFLAGS=-g -O2 +set CGO_CPPFLAGS= +set CGO_CXXFLAGS=-g -O2 +set CGO_FFLAGS=-g -O2 +set CGO_LDFLAGS=-g -O2 +set PKG_CONFIG=pkg-config +set GOGCCFLAGS=-m64 -mthreads -fmessage-length=0 -fdebug-prefix-map=C:\Users\zephyr\AppData\Local\Temp +\go-build1861236026=/tmp/go-build -gno-record-gcc-switches +
+$ go version +go version go1.16.3 windows/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes, including on tip. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +set GO111MODULE=on +set GOARCH=amd64 +set GOBIN= +set GOCACHE=C:\Users\zephyr\AppData\Local\go-build +set GOENV=C:\Users\zephyr\AppData\Roaming\go\env +set GOEXE=.exe +set GOFLAGS= +set GOHOSTARCH=amd64 +set GOHOSTOS=windows +set GOINSECURE= +set GOMODCACHE=E:\go\pkg\mod +set GONOPROXY= +set GONOSUMDB= +set GOOS=windows +set GOPATH=E:\go +set GOPRIVATE= +set GOPROXY=https://proxy.golang.org,direct +set GOROOT=c:\go +set GOSUMDB=sum.golang.org +set GOTMPDIR= +set GOTOOLDIR=c:\go\pkg\tool\windows_amd64 +set GOVCS= +set GOVERSION=go1.16.3 +set GCCGO=gccgo +set AR=ar +set CC=gcc +set CXX=g++ +set CGO_ENABLED=1 +set GOMOD=NUL +set CGO_CFLAGS=-g -O2 +set CGO_CPPFLAGS= +set CGO_CXXFLAGS=-g -O2 +set CGO_FFLAGS=-g -O2 +set CGO_LDFLAGS=-g -O2 +set PKG_CONFIG=pkg-config +set GOGCCFLAGS=-m64 -mthreads -fmessage-length=0 -fdebug-prefix-map=C:\Users\zephyr\AppData\Local\Temp +\go-build1861236026=/tmp/go-build -gno-record-gcc-switches +
+$ go version +go version go1.20.1 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/stephen/.cache/go-build"" +GOENV=""/home/stephen/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/stephen/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/stephen/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.20.1"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +GOWORK="""" +CGO_CFLAGS=""-O2 -g"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-O2 -g"" +CGO_FFLAGS=""-O2 -g"" +CGO_LDFLAGS=""-O2 -g"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build223210887=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.20.1 linux/amd64 ++ +### Does this issue reproduce with the latest release? + +Yes. + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/home/stephen/.cache/go-build"" +GOENV=""/home/stephen/.config/go/env"" +GOEXE="""" +GOEXPERIMENT="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""linux"" +GOINSECURE="""" +GOMODCACHE=""/home/stephen/go/pkg/mod"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""linux"" +GOPATH=""/home/stephen/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/linux_amd64"" +GOVCS="""" +GOVERSION=""go1.20.1"" +GCCGO=""gccgo"" +GOAMD64=""v1"" +AR=""ar"" +CC=""gcc"" +CXX=""g++"" +CGO_ENABLED=""1"" +GOMOD=""/dev/null"" +GOWORK="""" +CGO_CFLAGS=""-O2 -g"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-O2 -g"" +CGO_FFLAGS=""-O2 -g"" +CGO_LDFLAGS=""-O2 -g"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build223210887=/tmp/go-build -gno-record-gcc-switches"" +
+$ go version +go version go1.13.4 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/james/Library/Caches/go-build"" +GOENV=""/Users/james/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/james/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/sp/n3hrxcgd3wgb8zb_3mt1w9kr0000gn/T/go-build316781643=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+$ go version +go version go1.13.4 darwin/amd64 ++ +### Does this issue reproduce with the latest release? +Yes + + +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+$ go env +GO111MODULE="""" +GOARCH=""amd64"" +GOBIN="""" +GOCACHE=""/Users/james/Library/Caches/go-build"" +GOENV=""/Users/james/Library/Application Support/go/env"" +GOEXE="""" +GOFLAGS="""" +GOHOSTARCH=""amd64"" +GOHOSTOS=""darwin"" +GONOPROXY="""" +GONOSUMDB="""" +GOOS=""darwin"" +GOPATH=""/Users/james/go"" +GOPRIVATE="""" +GOPROXY=""https://proxy.golang.org,direct"" +GOROOT=""/usr/local/go"" +GOSUMDB=""sum.golang.org"" +GOTMPDIR="""" +GOTOOLDIR=""/usr/local/go/pkg/tool/darwin_amd64"" +GCCGO=""gccgo"" +AR=""ar"" +CC=""clang"" +CXX=""clang++"" +CGO_ENABLED=""1"" +GOMOD="""" +CGO_CFLAGS=""-g -O2"" +CGO_CPPFLAGS="""" +CGO_CXXFLAGS=""-g -O2"" +CGO_FFLAGS=""-g -O2"" +CGO_LDFLAGS=""-g -O2"" +PKG_CONFIG=""pkg-config"" +GOGCCFLAGS=""-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/sp/n3hrxcgd3wgb8zb_3mt1w9kr0000gn/T/go-build316781643=/tmp/go-build -gno-record-gcc-switches -fno-common"" +
+go version go1.20 windows/amd64 ++ +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+set GO111MODULE= +set GOARCH=amd64 +set GOBIN= +set GOCACHE=C:\Users\Steven\AppData\Local\go-build +set GOENV=C:\Users\Steven\AppData\Roaming\go\env +set GOEXE=.exe +set GOEXPERIMENT= +set GOFLAGS= +set GOHOSTARCH=amd64 +set GOHOSTOS=windows +set GOINSECURE= +set GOMODCACHE=C:\Users\Steven\go\pkg\mod +set GONOPROXY= +set GONOSUMDB= +set GOOS=windows +set GOPATH=C:\Users\Steven\go +set GOPRIVATE= +set GOPROXY=https://proxy.golang.org,direct +set GOROOT=D:\go +set GOSUMDB=sum.golang.org +set GOTMPDIR= +set GOTOOLDIR=D:\go\pkg\tool\windows_amd64 +set GOVCS= +set GOVERSION=go1.20 +set GCCGO=gccgo +set GOAMD64=v1 +set AR=ar +set CC=gcc +set CXX=g++ +set CGO_ENABLED=1 +set GOMOD=NUL +set GOWORK= +set CGO_CFLAGS=-O2 -g +set CGO_CPPFLAGS= +set CGO_CXXFLAGS=-O2 -g +set CGO_FFLAGS=-O2 -g +set CGO_LDFLAGS=-O2 -g +set PKG_CONFIG=pkg-config +set GOGCCFLAGS=-m64 -mthreads -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=C:\Windows\TEMP\go-build2434007380=/tmp/go-build -gno-record-gcc-switches +
+go version go1.20 windows/amd64 ++ +### What operating system and processor architecture are you using (`go env`)? + +
go env Output+set GO111MODULE= +set GOARCH=amd64 +set GOBIN= +set GOCACHE=C:\Users\Steven\AppData\Local\go-build +set GOENV=C:\Users\Steven\AppData\Roaming\go\env +set GOEXE=.exe +set GOEXPERIMENT= +set GOFLAGS= +set GOHOSTARCH=amd64 +set GOHOSTOS=windows +set GOINSECURE= +set GOMODCACHE=C:\Users\Steven\go\pkg\mod +set GONOPROXY= +set GONOSUMDB= +set GOOS=windows +set GOPATH=C:\Users\Steven\go +set GOPRIVATE= +set GOPROXY=https://proxy.golang.org,direct +set GOROOT=D:\go +set GOSUMDB=sum.golang.org +set GOTMPDIR= +set GOTOOLDIR=D:\go\pkg\tool\windows_amd64 +set GOVCS= +set GOVERSION=go1.20 +set GCCGO=gccgo +set GOAMD64=v1 +set AR=ar +set CC=gcc +set CXX=g++ +set CGO_ENABLED=1 +set GOMOD=NUL +set GOWORK= +set CGO_CFLAGS=-O2 -g +set CGO_CPPFLAGS= +set CGO_CXXFLAGS=-O2 -g +set CGO_FFLAGS=-O2 -g +set CGO_LDFLAGS=-O2 -g +set PKG_CONFIG=pkg-config +set GOGCCFLAGS=-m64 -mthreads -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=C:\Windows\TEMP\go-build2434007380=/tmp/go-build -gno-record-gcc-switches +
Here is the reproducer: +https://golang.org/cl/10613043/diff/3001/src/pkg/net/rpc/server_test.go + +Report is below. + +The gist: it's impossible to use net/rpc client/server with any non-thread-safe +transport as pipe or socketpair. It's inevitably produces races between read/write and +close. Such races corrupt arbitrary files and write data to random network connections. + +=== RUN TestUnixPipe +================== +WARNING: DATA RACE +Read by goroutine 59: + os.(*File).read() + src/pkg/os/file_unix.go:175 +0x5b + os.(*File).Read() + src/pkg/os/file.go:95 +0xb9 + bufio.(*Reader).fill() + src/pkg/bufio/bufio.go:119 +0x272 + bufio.(*Reader).Read() + src/pkg/bufio/bufio.go:187 +0x3b1 + io.ReadAtLeast() + src/pkg/io/io.go:284 +0x11a + io.ReadFull() + src/pkg/io/io.go:302 +0x7c + encoding/gob.decodeUintReader() + src/pkg/encoding/gob/decode.go:65 +0xba + encoding/gob.(*Decoder).recvMessage() + src/pkg/encoding/gob/decoder.go:73 +0x81 + encoding/gob.(*Decoder).decodeTypeSequence() + src/pkg/encoding/gob/decoder.go:159 +0x92 + encoding/gob.(*Decoder).DecodeValue() + src/pkg/encoding/gob/decoder.go:223 +0x124 + encoding/gob.(*Decoder).Decode() + src/pkg/encoding/gob/decoder.go:202 +0x227 + net/rpc.(*gobClientCodec).ReadResponseHeader() + src/pkg/net/rpc/client.go:218 +0x5d + net/rpc.(*Client).input() + src/pkg/net/rpc/client.go:106 +0x118 + +Previous write by goroutine 57: + os.(*file).close() + src/pkg/os/file_unix.go:110 +0x164 + os.(*File).Close() + src/pkg/os/file_unix.go:99 +0x43 + net/rpc.(*gobClientCodec).Close() + src/pkg/net/rpc/client.go:226 +0x48 + net/rpc.(*Client).Close() + src/pkg/net/rpc/client.go:280 +0xc6 + net/rpc.TestUnixPipe() + src/pkg/net/rpc/server_test.go:567 +0x3d5 + testing.tRunner() + src/pkg/testing/testing.go:361 +0x10c + +Goroutine 59 (running) created at: + net/rpc.NewClientWithCodec() + src/pkg/net/rpc/client.go:196 +0xd5 + net/rpc.NewClient() + src/pkg/net/rpc/client.go:186 +0x18d + net/rpc.TestUnixPipe() + src/pkg/net/rpc/server_test.go:566 +0x3c7 + testing.tRunner() + src/pkg/testing/testing.go:361 +0x10c + +Goroutine 57 (running) created at: + testing.RunTests() + src/pkg/testing/testing.go:441 +0xaef + testing.Main() + src/pkg/testing/testing.go:373 +0xab + main.main() + net/rpc/_test/_testmain.go:74 +0xda +==================+",1.0,"net/rpc: data race on non-net transport -
Here is the reproducer: +https://golang.org/cl/10613043/diff/3001/src/pkg/net/rpc/server_test.go + +Report is below. + +The gist: it's impossible to use net/rpc client/server with any non-thread-safe +transport as pipe or socketpair. It's inevitably produces races between read/write and +close. Such races corrupt arbitrary files and write data to random network connections. + +=== RUN TestUnixPipe +================== +WARNING: DATA RACE +Read by goroutine 59: + os.(*File).read() + src/pkg/os/file_unix.go:175 +0x5b + os.(*File).Read() + src/pkg/os/file.go:95 +0xb9 + bufio.(*Reader).fill() + src/pkg/bufio/bufio.go:119 +0x272 + bufio.(*Reader).Read() + src/pkg/bufio/bufio.go:187 +0x3b1 + io.ReadAtLeast() + src/pkg/io/io.go:284 +0x11a + io.ReadFull() + src/pkg/io/io.go:302 +0x7c + encoding/gob.decodeUintReader() + src/pkg/encoding/gob/decode.go:65 +0xba + encoding/gob.(*Decoder).recvMessage() + src/pkg/encoding/gob/decoder.go:73 +0x81 + encoding/gob.(*Decoder).decodeTypeSequence() + src/pkg/encoding/gob/decoder.go:159 +0x92 + encoding/gob.(*Decoder).DecodeValue() + src/pkg/encoding/gob/decoder.go:223 +0x124 + encoding/gob.(*Decoder).Decode() + src/pkg/encoding/gob/decoder.go:202 +0x227 + net/rpc.(*gobClientCodec).ReadResponseHeader() + src/pkg/net/rpc/client.go:218 +0x5d + net/rpc.(*Client).input() + src/pkg/net/rpc/client.go:106 +0x118 + +Previous write by goroutine 57: + os.(*file).close() + src/pkg/os/file_unix.go:110 +0x164 + os.(*File).Close() + src/pkg/os/file_unix.go:99 +0x43 + net/rpc.(*gobClientCodec).Close() + src/pkg/net/rpc/client.go:226 +0x48 + net/rpc.(*Client).Close() + src/pkg/net/rpc/client.go:280 +0xc6 + net/rpc.TestUnixPipe() + src/pkg/net/rpc/server_test.go:567 +0x3d5 + testing.tRunner() + src/pkg/testing/testing.go:361 +0x10c + +Goroutine 59 (running) created at: + net/rpc.NewClientWithCodec() + src/pkg/net/rpc/client.go:196 +0xd5 + net/rpc.NewClient() + src/pkg/net/rpc/client.go:186 +0x18d + net/rpc.TestUnixPipe() + src/pkg/net/rpc/server_test.go:566 +0x3c7 + testing.tRunner() + src/pkg/testing/testing.go:361 +0x10c + +Goroutine 57 (running) created at: + testing.RunTests() + src/pkg/testing/testing.go:441 +0xaef + testing.Main() + src/pkg/testing/testing.go:373 +0xab + main.main() + net/rpc/_test/_testmain.go:74 +0xda +==================+",1,net rpc data race on non net transport here is the reproducer a href report is below the gist it s impossible to use net rpc client server with any non thread safe transport as pipe or socketpair it s inevitably produces races between read write and close such races corrupt arbitrary files and write data to random network connections run testunixpipe warning data race read by goroutine os file read src pkg os file unix go os file read src pkg os file go bufio reader fill src pkg bufio bufio go bufio reader read src pkg bufio bufio go io readatleast src pkg io io go io readfull src pkg io io go encoding gob decodeuintreader src pkg encoding gob decode go encoding gob decoder recvmessage src pkg encoding gob decoder go encoding gob decoder decodetypesequence src pkg encoding gob decoder go encoding gob decoder decodevalue src pkg encoding gob decoder go encoding gob decoder decode src pkg encoding gob decoder go net rpc gobclientcodec readresponseheader src pkg net rpc client go net rpc client input src pkg net rpc client go previous write by goroutine os file close src pkg os file unix go os file close src pkg os file unix go net rpc gobclientcodec close src pkg net rpc client go net rpc client close src pkg net rpc client go net rpc testunixpipe src pkg net rpc server test go testing trunner src pkg testing testing go goroutine running created at net rpc newclientwithcodec src pkg net rpc client go net rpc newclient src pkg net rpc client go net rpc testunixpipe src pkg net rpc server test go testing trunner src pkg testing testing go goroutine running created at testing runtests src pkg testing testing go testing main src pkg testing testing go main main net rpc test testmain go ,1 +16497,6217791642.0,IssuesEvent,2017-07-08 18:18:57,golang/go,https://api.github.com/repos/golang/go,opened,x/build/devapp: HelpWanted handler supports title prefix filtering ,Builders,"https://dev.golang.org/imfeelinghelpful is pretty useful for those who are trying to randomly help to open issues. But individuals often specialize in a few packages and it would be nice to be able to filter the HelpWanted issues by title prefixes. + +For example, the following query can only return `cmd/go` and `go/parser` issues. + +``` +https://dev.golang.org/imfeelinghelpful?pkg=cmd/go,go/parser +``` + +Then, I can all day long browse random issues related to the packages I am interested to maintain. + +/cc @andybons @bradfitz +",1.0,"x/build/devapp: HelpWanted handler supports title prefix filtering - https://dev.golang.org/imfeelinghelpful is pretty useful for those who are trying to randomly help to open issues. But individuals often specialize in a few packages and it would be nice to be able to filter the HelpWanted issues by title prefixes. + +For example, the following query can only return `cmd/go` and `go/parser` issues. + +``` +https://dev.golang.org/imfeelinghelpful?pkg=cmd/go,go/parser +``` + +Then, I can all day long browse random issues related to the packages I am interested to maintain. + +/cc @andybons @bradfitz +",0,x build devapp helpwanted handler supports title prefix filtering is pretty useful for those who are trying to randomly help to open issues but individuals often specialize in a few packages and it would be nice to be able to filter the helpwanted issues by title prefixes for example the following query can only return cmd go and go parser issues then i can all day long browse random issues related to the packages i am interested to maintain cc andybons bradfitz ,0 +43197,7031691134.0,IssuesEvent,2017-12-26 19:51:53,golang/go,https://api.github.com/repos/golang/go,closed,tools/present: Documentation link to sam documentation is dead,Documentation,"The documentation for the [`tools/present` tool](https://godoc.org/golang.org/x/tools/present) includes a link to http://plan9.bell-labs.com/sys/doc/sam/sam.html, which according to me and according to http://downforeveryoneorjustme.com/plan9.bell-labs.com cannot be reached. + +This means it's hard to find out how the `.code` _address syntax_ works.",1.0,"tools/present: Documentation link to sam documentation is dead - The documentation for the [`tools/present` tool](https://godoc.org/golang.org/x/tools/present) includes a link to http://plan9.bell-labs.com/sys/doc/sam/sam.html, which according to me and according to http://downforeveryoneorjustme.com/plan9.bell-labs.com cannot be reached. + +This means it's hard to find out how the `.code` _address syntax_ works.",1,tools present documentation link to sam documentation is dead the documentation for the includes a link to which according to me and according to cannot be reached this means it s hard to find out how the code address syntax works ,1 +75480,9856121863.0,IssuesEvent,2019-06-19 21:11:16,golang/go,https://api.github.com/repos/golang/go,closed,wiki: CodeReviewComments#NamedResultParameters,Documentation NeedsDecision,"> On the other hand, [...] if the meaning of a result isn't clear from context, adding names may be useful in some contexts. + +In general, this will almost always be true. Humans are extremely bad at assessing how obvious an inference is if they already know the fact to be inferred. This is a special case of the [illusion of transparency](https://en.wikipedia.org/wiki/Illusion_of_transparency). In general, the meaning of a result isn't clear from context even if it feels to the author like it's extremely clear from context. + +Because of this, the advice given in this section is harmful in most cases.",1.0,"wiki: CodeReviewComments#NamedResultParameters - > On the other hand, [...] if the meaning of a result isn't clear from context, adding names may be useful in some contexts. + +In general, this will almost always be true. Humans are extremely bad at assessing how obvious an inference is if they already know the fact to be inferred. This is a special case of the [illusion of transparency](https://en.wikipedia.org/wiki/Illusion_of_transparency). In general, the meaning of a result isn't clear from context even if it feels to the author like it's extremely clear from context. + +Because of this, the advice given in this section is harmful in most cases.",1,wiki codereviewcomments namedresultparameters on the other hand if the meaning of a result isn t clear from context adding names may be useful in some contexts in general this will almost always be true humans are extremely bad at assessing how obvious an inference is if they already know the fact to be inferred this is a special case of the in general the meaning of a result isn t clear from context even if it feels to the author like it s extremely clear from context because of this the advice given in this section is harmful in most cases ,1 +35128,6415848860.0,IssuesEvent,2017-08-08 13:41:39,golang/go,https://api.github.com/repos/golang/go,closed,wiki: apt-get install golang-1.8-go: did not work,Documentation,"### What operating system and processor architecture are you using (`go env`)? +ubuntu 16.x + +### What did you do? + +provision vagrant box to run some go app, + +``` +$provision = <