profile
viewpoint
Dmitri Shuralyov dmitshur Google, Go team NYC https://dmitri.shuralyov.com I seek a better understanding of the world, so I can help make it simpler and better. I enjoy writing correct, high-quality Go code. Minimalist.

avelino/awesome-go 56447

A curated list of awesome Go frameworks, libraries and software

gopherjs/gopherjs 9531

A compiler from Go to JavaScript for running Go code in a browser

glfw/glfw 6557

A multi-platform library for OpenGL, OpenGL ES, Vulkan, window and input

google/go-github 6023

Go library for accessing the GitHub API

dustin/go-humanize 2288

Go Humans! (formatters for units to human friendly sizes)

golang/tour 1164

[mirror] A Tour of Go

google/crfs 1003

CRFS: Container Registry Filesystem

go-interpreter/wagon 871

wagon, a WebAssembly-based Go interpreter, for Go.

gregjones/httpcache 536

A Transport for http.Client that will cache responses according to the HTTP RFC

mdempsky/unconvert 298

Remove unnecessary type conversions from Go source

issue commentgolang/go

x/build: golang.org/x/xerrors repository isn't on build.golang.org dashboard

This will get resolved as part of #34744, which is something I'm working on now and it should happen over the next few weeks.

If someone wants to solve it independently of #34744 sooner, feel free to leave a comment here.

dmitshur

comment created time in an hour

issue commentshurcooL/vfsgen

Gzip Writer should use BestCompression

This is a great catch. Thanks for spotting this opportunity and sending a PR.

silverwind

comment created time in 3 hours

issue openedgolang/go

x/build/cmd/release: update to freebsd-{amd64,386}-11_2 builder for 1.15 RC 2+

The cmd/release command is currently configured to use the freebsd-{amd64,386}-11_1 builders for the freebsd release targets.

However, we've documented that Go 1.13 onwards requires at least FreeBSD 11.2 (see https://golang.org/doc/go1.13#freebsd):

As announced in the Go 1.12 release notes, Go 1.13 now requires FreeBSD 11.2 or later; support for previous versions has been discontinued. FreeBSD 12.0 or later requires a kernel with the COMPAT_FREEBSD11 option set (this is the default).

The build dashboard is correctly configured not to test Go 1.13+ commits on freebsd-{amd64,386}-11_1 builders. Luckily, the freebsd-amd64-race still uses FreeBSD 11.1 and does run on new Go commits, so we have test coverage from that. We also have test coverage from freebsd-{amd64,386}-11_2 builders, and they're passing. In summary:

  • FreeBSD 11.1 and older builders are disabled, no supported Go commits are tested (source).
    • Build status is unknown.
  • FreeBSD 11.2 and newer builders are enabled and test supported Go commits (source).
    • Builds are passing.
  • freebsd-amd64-race builder uses FreeBSD 11.1 and tests supported Go commits (source).
    • Builds are passing.

It would've been better if we caught and fixed this earlier, but given there will soon be an RC 2, we can fix this now. In the unlikely case the change of builder causes FreeBSD-specific regressions in RC 2 (despite passing builders), we can consider going back to the previous builder. FreeBSD is not a first class port and this change is outside of tree (which is why I'm not asking for a freeze exception), so it seems in scope. I'll apply release-blocker label because the fix is small and we should get it in if we don't learn something new suggesting otherwise. I'll send a CL.

I filed #40561 so we don't forget during future cycles, and do this at a better time.

/cc @golang/osp-team

created time in 17 hours

issue openedgolang/go

x/build: freebsd-amd64-race builder should be updated to use a newer FreeBSD version

The freebsd-amd64-race builder currently uses host-freebsd-11_1-big. Go 1.13 and newer require FreeBSD 11.2 or newer. We should update this builder accordingly.

If our assumption is that newer stable releases of FreeBSD have fewer bugs, we should likely use the latest stable version we have a builder for, since the goal of a -race builder is to catch data races in the Go code.

/cc @toothrot @cagedmantis @andybons

created time in 17 hours

issue openedgolang/go

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

created time in 17 hours

issue openedgolang/go

x/build/maintner/maintnerd/maintapi/version: support parsing all Go version tags, remove allocations

The current Go tag parser supports only final releases, not betas and not RCs. It would become more useful if it supported all release types. There are some places in x/build where we've wanted to use it, but couldn't do so because of this limitation.

Historically, we've worked around not having a parser by using string manipulation to analyze and modify Go versions, but that can be error prone and won't detect all problems a complete parser would. It's hard to compare or manipulate versions (e.g., get a previous minor release).

<details><summary>Examples</summary><br>

if strings.HasPrefix(goVer, "go1.13") || strings.HasPrefix(goVer, "go1.14") {
	// ...
}
func nextVersion(version string) (string, error) {
	parts := strings.Split(version, ".")
	n, err := strconv.Atoi(parts[len(parts)-1])
	if err != nil {
		return "", err
	}
	parts[len(parts)-1] = strconv.Itoa(n + 1)
	return strings.Join(parts, "."), nil
}
if strings.Contains(release, "beta") {
	// ...
} else if strings.Contains(release, "rc") {
	// ...
} else if strings.Count(w.Version, ".") == 1 {
	// ...
} else if strings.Count(w.Version, ".") == 2 {
	// ...
}

</details>

Additionally, the ParseTag function currently makes allocations, which can be avoided. That would be nice to make it less expensive to use in various loops in the build infrastructure.

CL 245277 implements this.

In the future, if more places in x/build start using this, we may consider moving it to a shorter import path. It doesn't have to happen right away.

created time in a day

push eventshurcooL/home

Dmitri Shuralyov

commit sha 91c5682bc2aa970ba2311282230a37f1b27e4c1c

support HEAD method in ?go-get=1 requests The go command makes ?go-get=1 requests using only the GET method, never with the HEAD method. HEAD requests to ?go-get=1 don't seem very useful, since relevant information is placed in the response body rather than headers, and it wouldn't be available. However, the HTTP specification requires¹ that the HEAD method is supported, so do so. ¹ https://tools.ietf.org/html/rfc7231#section-4

view details

push time in 2 days

issue commentgolang/go

x/pkgsite: linking to module source code

  1. Write a CL. Examples: https://golang.org/cl/245379, https://golang.org/cl/245380. If the site requires more than just adding a pattern, describe your changes here first.

I tried to create a CL that would add support for packages hosted on dmitri.shuralyov.com, a custom server that hosts some Go packages, but it didn't seem to be possible to do by just adding a pattern. So, as you asked, describing it here.

The server itself doesn't support displaying source code in the browser, so it defers to another website that can display source code of Go packages. It was possible to implement this with the following go-source meta tag, using the dmitri.shuralyov.com/gpu/mtl package as an example:

$ curl -s 'https://dmitri.shuralyov.com/gpu/mtl?go-get=1' | grep 'go-source'
<meta name="go-source" content="dmitri.shuralyov.com/gpu/mtl https://dmitri.shuralyov.com/gpu/mtl/... https://gotools.org/dmitri.shuralyov.com/gpu/mtl https://gotools.org/dmitri.shuralyov.com/gpu/mtl#{file}-L{line}">

The go-source tag includes 4 parts (as documented): the import path corresponding to the repository root, the repository's home page, a URL pointing to the directory corresponding to the Go package, and a URL template for a specific line in a specific file. This makes it work on godoc.org (e.g., see https://godoc.org/dmitri.shuralyov.com/gpu/mtl).

I learned there are differences in how the templates work in pkgsite, which contributed to me not seeing a way this package could be made to work without additional modifications:

  1. There's no pattern for the repo/module home page. It's always just {repo} and isn't configurable, so I couldn't find a way to add the "/..." suffix as done in the go-source meta tag.
  2. The {repo} substitution unconditionally includes a "https://" prefix immediately followed by the repo root, and I didn't see a way to use a different domain to display the source code.
  3. The {file} substitution is not just the file name (as it is on godoc.org), but the full path to file from the module root. I didn't see a way to split apart just the name of the file, needed for my template. Similarly, I didn't see a way to compute the import path of Go package whose file (or directory) is to be viewed, as that requires combining {repo} with just the directory of {file}.
  4. On godoc.org, the go-source meta tag applies to an individual package, so it's possible for a custom server to provide templates that work for each package. The templates in pkgsite seem to apply to a repository (or module), so I couldn't work around limitations of templates on the side of the server. (This isn't a problem if there's an equivalent way of doing what I needed via the template.)

I'll send a DNS/DNR CL to show my local prototype in case it's easier to look at some code to understand some details and/or give feedback, but I certainly don't expect it to be merged as is.

I'm not sure if it's in scope of pkgsite to support what's needed to make that package work, or how to best do it, but I wanted to share what I learned from my experience. If it is in scope, please let me know what you think is a good next step. Thank you.

jba

comment created time in 2 days

push eventshurcooL/githubv4

Andrew Haines

commit sha f27d2ca7f6d535f7e35dd817493104814423eb48

regenerate for schema changes by 2020-07-31 Done with: GITHUB_TOKEN=<redacted> go generate ./... Reference: https://developer.github.com/v4/changelog/. GitHub-Pull-Request: https://github.com/shurcooL/githubv4/pull/74

view details

push time in 2 days

PR merged shurcooL/githubv4

Regenerate from latest GraphQL schema

Ran go generate ./... to update the enums and inputs according to the latest schema.

+128 -99

0 comment

2 changed files

haines

pr closed time in 2 days

issue commentgolang/go

runtime: Windows service lifecycle events behave incorrectly when called within a golang environment [1.14 backport]

Thanks, we’ll try to take a look at this request next week.

For programs where it’s critical to receive stop / shutdown event, do you know if there is a workaround that can be used until this issue is resolved?

I’ve also asked a question on the upstream issue about 1.13 since that affects the 1.14 backport.

/cc @toothrot @cagedmangis @andybons

gopherbot

comment created time in 3 days

issue commentgolang/go

runtime: Windows service lifecycle events behave incorrectly when called within a golang environment

Does this issue affect Go 1.13 in addition to 1.14, or was it introduced in 1.14? We need to know this because the minor release policy requires an issue is fixed in all affected supported releases (see https://github.com/golang/go/issues/34536).

yohan1234

comment created time in 3 days

issue openedgolang/go

x/build: corellium iOS and Android builders are missing

From https://farmer.golang.org#pools:

  • host-android-arm64-corellium-android: 0/0 (3 missing)
  • host-darwin-arm64-corellium-ios: 0/0 (3 missing)

Their results have stopped showing up on https://build.golang.org since around Jul 17.

/cc @znly per builder owners. Are you able to take a look at this? Thanks.

/cc @cagedmantis @toothrot @andybons

created time in 4 days

issue commentgolang/go

cmd/go/internal/modfetch: TestCodeRepo failures due to external repo changes

Sounds good. Factored it out into a standalone issue #40519.

ALTree

comment created time in 4 days

issue openedgolang/go

cmd/go, cmd/go/internal/modfetch: update tests not to rely on external domains that only an individual maintainer has access to

Factoring out comment https://github.com/golang/go/issues/28856#issuecomment-665252612 into a separate issue, since it's slightly different than #28856 and out of scope for that issue.

Some of cmd/go and cmd/go/internal/modfetch tests currently rely on content hosted on rsc.io, swtch.com, and insecure.go-get-issue-15410.appspot.com domains, and historically a single individual had access to those projects. They have been very reliable for many years, and since they're explicitly created as test modules for cmd/go tests, and we don't expect the content to change for due to active project development, as in issue #28856.

However, we still want these tests not to have a single point of failure, since an individual person may not be available to investigate should an issue with the domains occurs (e.g., due to being on a vacation), and it is important that we're able to fix any issues if they come up in the future, or if the test data needs to be updated for some reason.

Perhaps this can be resolved by granting access to those hosts to the cmd/go team (as suggested by @rsc and @andybons), or by moving them to an existing host that the cmd/go team has access to (such as vcs-test.golang.org).

Details of tests that were affected recently (from https://storage.googleapis.com/go-build-log/3c347861/linux-amd64-longtest_bb29e807.log, https://storage.googleapis.com/go-build-log/2229151e/linux-386-longtest_dca9ed82.log, and https://storage.googleapis.com/go-build-log/0fcc0a58/linux-amd64-longtest_642c58db.log):

<details><br>

--- FAIL: TestGoGetCustomDomainWildcard (0.24s)
    go_test.go:2628: running testgo [get -u rsc.io/pdf/...]
    go_test.go:2628: standard error:
    go_test.go:2628: package rsc.io/pdf/...: unrecognized import path "rsc.io/pdf": reading https://rsc.io/pdf?go-get=1: 503 Service Unavailable
        
    go_test.go:2628: go [get -u rsc.io/pdf/...] failed unexpectedly in /workdir/go/src/cmd/go: exit status 1
--- FAIL: TestGoGetDotSlashDownload (0.22s)
    go_test.go:2714: running testgo [get ./pprof_mac_fix]
    go_test.go:2714: standard error:
    go_test.go:2714: unrecognized import path "rsc.io/pprof_mac_fix": reading https://rsc.io/pprof_mac_fix?go-get=1: 503 Service Unavailable
        
    go_test.go:2714: go [get ./pprof_mac_fix] failed unexpectedly in /workdir/tmp/cmd-go-test-062451185/gotest700832841/src/rsc.io: exit status 1
    panic.go:617: ended in /workdir/tmp/cmd-go-test-062451185/gotest700832841/src/rsc.io
--- FAIL: TestGoGetInsecure (1.38s)
    --- FAIL: TestGoGetInsecure/gopath (0.11s)
        go_test.go:2895: running testgo [get -d insecure.go-get-issue-15410.appspot.com/pkg/p]
        go_test.go:2895: standard error:
        go_test.go:2895: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": https fetch: Get "https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1": x509: certificate is valid for *.appspot-preview.com, *.an.r.appspot.com, *.app.google, *.appspot.com, *.as.r.appspot.com, *.de.r.appspot.com, *.df.r.appspot.com, *.dt.r.appspot.com, *.du.r.appspot.com, *.el.r.appspot.com, *.et.r.appspot.com, *.ew.r.appspot.com, *.ey.r.appspot.com, *.ez.r.appspot.com, *.lz.r.appspot.com, *.nn.r.appspot.com, *.nw.r.appspot.com, *.nz.r.appspot.com, *.oa.r.appspot.com, *.rj.r.appspot.com, *.thinkwithgoogle.com, *.ts.r.appspot.com, *.tz.r.appspot.com, *.uc.r.appspot.com, *.ue.r.appspot.com, *.uk.r.appspot.com, *.uw.r.appspot.com, *.withgoogle.com, *.withyoutube.com, *.wl.r.appspot.com, *.wm.r.appspot.com, *.wn.r.appspot.com, app.google, appspot-preview.com, appspot.com, thinkwithgoogle.com, withgoogle.com, withyoutube.com, not insecure.go-get-issue-15410.appspot.com
            
        go_test.go:2895: testgo failed as expected: exit status 1
        go_test.go:2898: running testgo [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p]
        go_test.go:2898: standard error:
        go_test.go:2898: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": reading https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1: 503 Service Unavailable
            
        go_test.go:2898: go [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p] failed unexpectedly in /workdir/go/src/cmd/go: exit status 1
    --- FAIL: TestGoGetInsecure/modules (1.26s)
        go_test.go:2895: running testgo [get -d insecure.go-get-issue-15410.appspot.com/pkg/p]
        go_test.go:2895: standard error:
        go_test.go:2895: go get insecure.go-get-issue-15410.appspot.com/pkg/p: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": https fetch: Get "https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1": x509: certificate is valid for *.appspot-preview.com, *.an.r.appspot.com, *.app.google, *.appspot.com, *.as.r.appspot.com, *.de.r.appspot.com, *.df.r.appspot.com, *.dt.r.appspot.com, *.du.r.appspot.com, *.el.r.appspot.com, *.et.r.appspot.com, *.ew.r.appspot.com, *.ey.r.appspot.com, *.ez.r.appspot.com, *.lz.r.appspot.com, *.nn.r.appspot.com, *.nw.r.appspot.com, *.nz.r.appspot.com, *.oa.r.appspot.com, *.rj.r.appspot.com, *.thinkwithgoogle.com, *.ts.r.appspot.com, *.tz.r.appspot.com, *.uc.r.appspot.com, *.ue.r.appspot.com, *.uk.r.appspot.com, *.uw.r.appspot.com, *.withgoogle.com, *.withyoutube.com, *.wl.r.appspot.com, *.wm.r.appspot.com, *.wn.r.appspot.com, app.google, appspot-preview.com, appspot.com, thinkwithgoogle.com, withgoogle.com, withyoutube.com, not insecure.go-get-issue-15410.appspot.com
            
        go_test.go:2895: testgo failed as expected: exit status 1
        go_test.go:2898: running testgo [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p]
        go_test.go:2898: standard error:
        go_test.go:2898: go get insecure.go-get-issue-15410.appspot.com/pkg/p: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": reading https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1: 503 Service Unavailable
            
        go_test.go:2898: go [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p] failed unexpectedly in /workdir/tmp/cmd-go-test-062451185/gotest738708835: exit status 1
        panic.go:617: ended in /workdir/tmp/cmd-go-test-062451185/gotest738708835
--- FAIL: TestGoGetInsecureCustomDomain (0.09s)
    go_test.go:2983: running testgo [get -d insecure.go-get-issue-15410.appspot.com/pkg/p]
    go_test.go:2983: standard error:
    go_test.go:2983: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": https fetch: Get "https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1": x509: certificate is valid for *.appspot-preview.com, *.an.r.appspot.com, *.app.google, *.appspot.com, *.as.r.appspot.com, *.de.r.appspot.com, *.df.r.appspot.com, *.dt.r.appspot.com, *.du.r.appspot.com, *.el.r.appspot.com, *.et.r.appspot.com, *.ew.r.appspot.com, *.ey.r.appspot.com, *.ez.r.appspot.com, *.lz.r.appspot.com, *.nn.r.appspot.com, *.nw.r.appspot.com, *.nz.r.appspot.com, *.oa.r.appspot.com, *.rj.r.appspot.com, *.thinkwithgoogle.com, *.ts.r.appspot.com, *.tz.r.appspot.com, *.uc.r.appspot.com, *.ue.r.appspot.com, *.uk.r.appspot.com, *.uw.r.appspot.com, *.withgoogle.com, *.withyoutube.com, *.wl.r.appspot.com, *.wm.r.appspot.com, *.wn.r.appspot.com, app.google, appspot-preview.com, appspot.com, thinkwithgoogle.com, withgoogle.com, withyoutube.com, not insecure.go-get-issue-15410.appspot.com
        
    go_test.go:2983: testgo failed as expected: exit status 1
    go_test.go:2984: running testgo [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p]
    go_test.go:2984: standard error:
    go_test.go:2984: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": reading https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1: 503 Service Unavailable
        
    go_test.go:2984: go [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p] failed unexpectedly in /workdir/go/src/cmd/go: exit status 1
go test proxy running at GOPROXY=http://127.0.0.1:45253/mod
go proxy: no archive rsc.io v1.5.1: file does not exist
go proxy: no archive example.com/newcycle v1.0.0: file does not exist
go proxy: no archive rsc.io v1.0.0: file does not exist
go proxy: no archive rsc.io v1.4.0: file does not exist
go proxy: no archive rsc.io v1.5.2: file does not exist
go proxy: no archive rsc.io v1.1.0: file does not exist
go proxy: no archive rsc.io v1.0.0: file does not exist
go proxy: no archive rsc.io v1.0.0: file does not exist
go proxy: no archive rsc.io v1.0.0: file does not exist
go proxy: no archive rsc.io v1.0.0: file does not exist
go proxy: no archive golang.org v0.1.0: file does not exist
go proxy: no archive golang.org v0.3.0: file does not exist
go proxy: no archive golang.org/x v0.1.0: file does not exist
go proxy: no archive golang.org/x v0.3.0: file does not exist
go proxy: no archive example.com v0.1.0: file does not exist
go proxy: no archive rsc.io v1.5.2: file does not exist
--- FAIL: TestScript (0.00s)
    --- FAIL: TestScript/mod_init_dep (0.24s)
        script_test.go:193: 
            # modconv uses git directly to examine what old 'go get' would (0.001s)
            # go build should populate go.mod from Gopkg.lock (0.229s)
            > cp go.mod1 go.mod
            > go build
            [stderr]
            go: copying requirements from Gopkg.lock
            go: converting Gopkg.lock: stat rsc.io/sampler@v1.0.0: unrecognized import path "rsc.io/sampler": reading https://rsc.io/sampler?go-get=1: 503 Service Unavailable
            > stderr 'copying requirements from Gopkg.lock'
            > go list -m all
            [stdout]
            x
            > ! stderr 'copying requirements from Gopkg.lock'
            > stdout 'rsc.io/sampler v1.0.0'
            FAIL: testdata/script/mod_init_dep.txt:13: no match for `(?m)rsc.io/sampler v1.0.0` found in stdout
            
    --- FAIL: TestScript/mod_gonoproxy (0.78s)
        script_test.go:193: 
            # disagree with sumdb fails (0.028s)
            # but GONOSUMDB bypasses sumdb, for rsc.io/quote, rsc.io/sampler, golang.org/x/text (0.560s)
            # and GONOPROXY bypasses proxy (0.169s)
            > [!net] skip
            > [!exec:git] skip
            > env GOPRIVATE=none
            > env GONOPROXY='*/fortune'
            > ! go get rsc.io/fortune # does not exist in real world, only on test proxy
            [stderr]
            go get rsc.io/fortune: unrecognized import path "rsc.io/fortune": reading https://rsc.io/fortune?go-get=1: 503 Service Unavailable
            [exit status 1]
            > stderr 'git ls-remote'
            FAIL: testdata/script/mod_gonoproxy.txt:27: no match for `(?m)git ls-remote` found in stderr
            
    --- FAIL: TestScript/mod_download_hash (0.31s)
        script_test.go:193: 
            # Testing mod download with non semantic versions; turn off proxy. (0.307s)
            > [!net] skip
            > [!exec:git] skip
            > env GOPROXY=direct
            > env GOSUMDB=off
            > go mod download rsc.io/quote@a91498bed0a73d4bb9c1fb2597925f7883bc40a7
            [stderr]
            rsc.io/quote@a91498bed0a73d4bb9c1fb2597925f7883bc40a7: unrecognized import path "rsc.io/quote": reading https://rsc.io/quote?go-get=1: 503 Service Unavailable
            [exit status 1]
            FAIL: testdata/script/mod_download_hash.txt:9: unexpected command failure
            
    --- FAIL: TestScript/mod_sumdb_golang (0.27s)
        script_test.go:193: 
            # Test default GOPROXY and GOSUMDB (0.083s)
            # download direct from github (0.190s)
            > [!net] skip
            > [!exec:git] skip
            > env GOSUMDB=sum.golang.org
            > env GOPROXY=direct
            > go get -d rsc.io/quote@v1.5.2
            [stderr]
            go get rsc.io/quote@v1.5.2: unrecognized import path "rsc.io/quote": reading https://rsc.io/quote?go-get=1: 503 Service Unavailable
            [exit status 1]
            FAIL: testdata/script/mod_sumdb_golang.txt:17: unexpected command failure
            
    --- FAIL: TestScript/gopath_moved_repo (0.87s)
        script_test.go:193: 
            # Test that 'go get -u' reports packages whose VCS configurations do not
            # match their import paths. (0.000s)
            # We need to execute a custom Go program to break the config files.
            #
            # git will ask for a username and password when we run 'go get -d -f -u',
            # so we also need to set GIT_ASKPASS. Conveniently, a single binary can
            # perform both tasks! (0.674s)
            # Test that 'go get -u' reports moved git packages. (0.191s)
            > [exec:git] go get -d rsc.io/pdf
            [stderr]
            unrecognized import path "rsc.io/pdf": reading https://rsc.io/pdf?go-get=1: 503 Service Unavailable
            [exit status 1]
            FAIL: testdata/script/gopath_moved_repo.txt:21: unexpected command failure
            
--- FAIL: TestIssue11457 (0.20s)
    go_test.go:1087: running testgo [get -d -u rsc.io/go-get-issue-11457]
    go_test.go:1087: standard error:
    go_test.go:1087: unrecognized import path "rsc.io/go-get-issue-11457": reading https://rsc.io/go-get-issue-11457?go-get=1: 503 Service Unavailable
        
    go_test.go:1087: go [get -d -u rsc.io/go-get-issue-11457] failed unexpectedly in /workdir/go/src/cmd/go: exit status 1
--- FAIL: TestIssue16471 (1.31s)
    go_test.go:1071: git standard error:
    go_test.go:1071: Cloning into 'go-get-issue-10952'...
        
    go_test.go:1072: running testgo [get -u rsc.io/go-get-issue-10952]
    go_test.go:1072: testgo succeeded unexpectedly
FAIL
FAIL	cmd/go	132.219s
FAIL
--- FAIL: TestCodeRepo (11.97s)
    --- FAIL: TestCodeRepo/parallel (0.00s)
        --- FAIL: TestCodeRepo/parallel/swtch.com_testmod/v1.0.0 (0.14s)
            coderepo_test.go:451: Lookup("swtch.com/testmod"): unrecognized import path "swtch.com/testmod": reading https://swtch.com/testmod?go-get=1: 503 Service Unavailable
--- FAIL: TestCodeRepoVersions (1.58s)
    --- FAIL: TestCodeRepoVersions/parallel (0.00s)
        --- FAIL: TestCodeRepoVersions/parallel/swtch.com_testmod (0.00s)
            coderepo_test.go:690: Lookup("swtch.com/testmod"): unrecognized import path "swtch.com/testmod": reading https://swtch.com/testmod?go-get=1: 503 Service Unavailable
--- FAIL: TestLatest (0.47s)
    --- FAIL: TestLatest/parallel (0.00s)
        --- FAIL: TestLatest/parallel/swtch.com_testmod (0.00s)
            coderepo_test.go:768: Lookup("swtch.com/testmod"): unrecognized import path "swtch.com/testmod": reading https://swtch.com/testmod?go-get=1: 503 Service Unavailable
FAIL
FAIL	cmd/go/internal/modfetch	14.044s
--- FAIL: TestGoGetInsecure (1.44s)
    --- FAIL: TestGoGetInsecure/gopath (0.13s)
        go_test.go:2895: running testgo [get -d insecure.go-get-issue-15410.appspot.com/pkg/p]
        go_test.go:2895: standard error:
        go_test.go:2895: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": https fetch: Get "https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1": x509: certificate is valid for *.appspot-preview.com, *.an.r.appspot.com, *.app.google, *.appspot.com, *.as.r.appspot.com, *.de.r.appspot.com, *.df.r.appspot.com, *.dt.r.appspot.com, *.du.r.appspot.com, *.el.r.appspot.com, *.et.r.appspot.com, *.ew.r.appspot.com, *.ey.r.appspot.com, *.ez.r.appspot.com, *.lz.r.appspot.com, *.nn.r.appspot.com, *.nw.r.appspot.com, *.nz.r.appspot.com, *.oa.r.appspot.com, *.rj.r.appspot.com, *.thinkwithgoogle.com, *.ts.r.appspot.com, *.tz.r.appspot.com, *.uc.r.appspot.com, *.ue.r.appspot.com, *.uk.r.appspot.com, *.uw.r.appspot.com, *.withgoogle.com, *.withyoutube.com, *.wl.r.appspot.com, *.wm.r.appspot.com, *.wn.r.appspot.com, app.google, appspot-preview.com, appspot.com, thinkwithgoogle.com, withgoogle.com, withyoutube.com, not insecure.go-get-issue-15410.appspot.com
            
        go_test.go:2895: testgo failed as expected: exit status 1
        go_test.go:2898: running testgo [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p]
        go_test.go:2898: standard error:
        go_test.go:2898: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": reading https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1: 503 Service Unavailable
            
        go_test.go:2898: go [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p] failed unexpectedly in /workdir/go/src/cmd/go: exit status 1
    --- FAIL: TestGoGetInsecure/modules (1.30s)
        go_test.go:2895: running testgo [get -d insecure.go-get-issue-15410.appspot.com/pkg/p]
        go_test.go:2895: standard error:
        go_test.go:2895: go get insecure.go-get-issue-15410.appspot.com/pkg/p: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": https fetch: Get "https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1": x509: certificate is valid for *.appspot-preview.com, *.an.r.appspot.com, *.app.google, *.appspot.com, *.as.r.appspot.com, *.de.r.appspot.com, *.df.r.appspot.com, *.dt.r.appspot.com, *.du.r.appspot.com, *.el.r.appspot.com, *.et.r.appspot.com, *.ew.r.appspot.com, *.ey.r.appspot.com, *.ez.r.appspot.com, *.lz.r.appspot.com, *.nn.r.appspot.com, *.nw.r.appspot.com, *.nz.r.appspot.com, *.oa.r.appspot.com, *.rj.r.appspot.com, *.thinkwithgoogle.com, *.ts.r.appspot.com, *.tz.r.appspot.com, *.uc.r.appspot.com, *.ue.r.appspot.com, *.uk.r.appspot.com, *.uw.r.appspot.com, *.withgoogle.com, *.withyoutube.com, *.wl.r.appspot.com, *.wm.r.appspot.com, *.wn.r.appspot.com, app.google, appspot-preview.com, appspot.com, thinkwithgoogle.com, withgoogle.com, withyoutube.com, not insecure.go-get-issue-15410.appspot.com
            
        go_test.go:2895: testgo failed as expected: exit status 1
        go_test.go:2898: running testgo [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p]
        go_test.go:2898: standard error:
        go_test.go:2898: go get insecure.go-get-issue-15410.appspot.com/pkg/p: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": reading https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1: 503 Service Unavailable
            
        go_test.go:2898: go [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p] failed unexpectedly in /workdir/tmp/cmd-go-test-772897562/gotest647673300: exit status 1
        panic.go:617: ended in /workdir/tmp/cmd-go-test-772897562/gotest647673300
--- FAIL: TestGoGetInsecureCustomDomain (0.10s)
    go_test.go:2983: running testgo [get -d insecure.go-get-issue-15410.appspot.com/pkg/p]
    go_test.go:2983: standard error:
    go_test.go:2983: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": https fetch: Get "https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1": x509: certificate is valid for *.appspot-preview.com, *.an.r.appspot.com, *.app.google, *.appspot.com, *.as.r.appspot.com, *.de.r.appspot.com, *.df.r.appspot.com, *.dt.r.appspot.com, *.du.r.appspot.com, *.el.r.appspot.com, *.et.r.appspot.com, *.ew.r.appspot.com, *.ey.r.appspot.com, *.ez.r.appspot.com, *.lz.r.appspot.com, *.nn.r.appspot.com, *.nw.r.appspot.com, *.nz.r.appspot.com, *.oa.r.appspot.com, *.rj.r.appspot.com, *.thinkwithgoogle.com, *.ts.r.appspot.com, *.tz.r.appspot.com, *.uc.r.appspot.com, *.ue.r.appspot.com, *.uk.r.appspot.com, *.uw.r.appspot.com, *.withgoogle.com, *.withyoutube.com, *.wl.r.appspot.com, *.wm.r.appspot.com, *.wn.r.appspot.com, app.google, appspot-preview.com, appspot.com, thinkwithgoogle.com, withgoogle.com, withyoutube.com, not insecure.go-get-issue-15410.appspot.com
        
    go_test.go:2983: testgo failed as expected: exit status 1
    go_test.go:2984: running testgo [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p]
    go_test.go:2984: standard error:
    go_test.go:2984: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": reading https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1: 503 Service Unavailable
        
    go_test.go:2984: go [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p] failed unexpectedly in /workdir/go/src/cmd/go: exit status 1

</details>

/cc @bcmills @jayconrod @matloob @rsc @andybons

created time in 4 days

issue commentgolang/go

x/website: invalid link found in tutorial documentation.

Thanks for reporting. This looks like a bug that needs to be fixed.

Where did you get to the URL https://golang.org/doc/articles/wiki/final.go from?

selahaddinh

comment created time in 4 days

issue commentshurcooL/githubv4

Star gazers not part of a Repository

Either rename the StarGazers field to Stargazers, or add an explicit name override via field tag:

StarGazers struct {
	TotalCount githubv4.Int
} `graphql:"stargazers"`

There's an implicit conversion happening if you don't set an explicit GraphQL field name via the graphql tag, and the Go field "StarGazers" is converted to "starGazers" (capital 'G'), which doesn't match the field "stargazers" (lower case 'g') in the GraphQL schema. It is case sensitive and fields must match exactly.

g14a

comment created time in 5 days

issue commentgolang/go

runtime: fatal error: checkdead: runnable g [1.13 backport]

Thanks Michael!

dmitshur

comment created time in 5 days

issue openedgolang/go

runtime: fatal error: checkdead: runnable g [1.13 backport]

In a Go release meeting, we noticed issue #40368 likely affects Go 1.13 as well. This needs to be confirmed, and if so, this is the tracking issue for #40368 to be considered for backport to the next 1.13 minor release.

Including a copy of the rationale to backport from the 1.14 tracking issue #40398:

This crash could affect any program running with GOMAXPROCS=1.

/cc @prattmic @aclements @cagedmantis @toothrot

created time in 5 days

issue commentgolang/go

x/pkgsite: linking to module source code

I think there is a benefit to using this idea as a next step to support linking to module source code.

Iterating on this approach in an internal package can help inform the design of an HTTP meta tag, if that were to be pursued in the future. If something about the internal API turns out to work poorly, or an opportunity to improve or simplify appears, it's easier if the code is in an internal package where changes can be done atomically. Once the internal package stabilizes, someone can decide it'd be worth creating an equivalent HTTP meta tag design that websites can choose to implement instead, and the existing entries in the internal package can serve as test cases.

jba

comment created time in 6 days

issue openedgolang/go

x/build/cmd/releasebot: remove obsolete check that the major version is listed on the project page

The https://golang.org/project/ page has a "Version history" section that lists major Go releases that have been released. Prior to CL 229483, it needed to be manually updated before each final major release, and so to catch potential mistakes releasebot has a safety check that aborts the release process if the major version isn't listed:

func (w *Work) checkDocs() {
	// Check that the major version is listed on the project page.
	data, err := ioutil.ReadFile(filepath.Join(w.Dir, "gitwork", "doc/contrib.html"))
	if err != nil {
		w.log.Panic(err)
	}
	major := major(w.Version)
	if !strings.Contains(string(data), major) {
		w.logError("doc/contrib.html does not list major version %s", major)
	}
}

(Source: golang.org/x/build/cmd/releasebot/main.go#L595-L605.)

The doc/contrib.html file no longer needs to be manually updated, and it doesn't even exist in the main repo as it was moved to x/website in CL 229485. The check needs to be removed.

/cc @toothrot @cagedmantis @andybons

created time in 6 days

startedrsc/swtch

started time in 7 days

issue closedgolang/go

Packages under rsc.io are no longer available

<!-- Please answer these questions before submitting your issue. Thanks! For questions please use one of our forums: https://github.com/golang/go/wiki/Questions -->

What version of Go are you using (go version)?

Go 1.12, Go 1.14

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

I don't think this matters but here it goes. This failed both on my laptop with Go 1.14 and in GitHub Action that uses Go1.12

<details><summary><code>go env</code> Output</summary><br><pre> $ 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" </pre></details>

What did you do?

Ran go build command

What did you expect to see?

Modules should be fetched successfully and compilation should succeed.

What did you see instead?

Since this morning, 2 packages under rsc.io have been failing:

go build -buildmode c-shared -o ./bin/kinesis.so ./
go: github.com/aws/amazon-kinesis-firehose-for-fluent-bit@v1.4.1 requires
	github.com/golang/mock@v1.4.3 requires
	rsc.io/quote/v3@v3.1.0: unrecognized import path "rsc.io/quote/v3": reading https://rsc.io/quote/v3?go-get=1: 503 Service Unavailable
$ go mod download

go: finding github.com/aws/amazon-kinesis-firehose-for-fluent-bit v1.2.2-0.20200717080229-e3ffb88e79bb
go: finding github.com/aws/aws-sdk-go v1.33.13
go: finding github.com/lestrrat-go/strftime v1.0.2-0.20200618102204-1b0bc59fa4ab
go: finding github.com/stretchr/objx v0.3.0
go: finding github.com/sirupsen/logrus v1.6.0
go: finding github.com/yuin/goldmark v1.1.33
go: rsc.io/sampler@v1.99.99: unrecognized import path "rsc.io/sampler" (parse https://rsc.io/sampler?go-get=1: no go-import meta tags ())
go: finding golang.org/x/crypto v0.0.0-20200709230013-948cd5f35899
go: finding golang.org/x/text v0.3.3
go: finding github.com/google/gofuzz v1.1.0
go: finding gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776
go: finding github.com/cenkalti/backoff v2.2.1+incompatible
go: finding golang.org/x/net v0.0.0-20200707034311-ab3426394381
go: finding github.com/fluent/fluent-bit-go v0.0.0-20200707230002-2a28684e2382
go: finding github.com/stretchr/testify v1.6.1
go: finding github.com/json-iterator/go v1.1.10
go: finding gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f
go: finding golang.org/x/sys v0.0.0-20200625212154-ddb9806d33ae
go: finding golang.org/x/tools v0.0.0-20200717024301-6ddee64345a6
go: finding github.com/golang/mock v1.4.3
go: error loading module requirements

closed time in 7 days

hencrice

issue commentgolang/go

Packages under rsc.io are no longer available

rsc.io is working again now (see https://github.com/rsc/quote/issues/4#issuecomment-665300101). Making cmd/go tests not depend on external services is tracked in issue #28856. I don't think there's anything else left to do here, so I'll close this.

hencrice

comment created time in 7 days

issue commentrsc/quote

go get does not work anymore (Appengine: http 503)

The immediate issue has been resolved:

$ GOPROXY=direct GO111MODULE=on go get rsc.io/quote/v3
go: downloading rsc.io/quote/v3 v3.1.0
go: downloading rsc.io/quote v1.5.2
go: rsc.io/quote/v3 upgrade => v3.1.0
go: downloading rsc.io/sampler v1.3.0
go: downloading golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c
$ echo $?
0

There may be follow up steps to take to ensure it doesn't regress, I'll leave it to @rsc to close this issue.

olivierlemasle

comment created time in 7 days

issue commentgolang/go

Packages under rsc.io are no longer available

@menghanl Fixing rsc.io/quote is being tracked in issue https://github.com/rsc/quote/issues/4.

hencrice

comment created time in 7 days

issue commentgolang/go

Packages under rsc.io are no longer available

@hencrice The GOPRIVATE environment variable in go env output is set to *, which tells the go command to consider all modules as private and not to use the module mirror and checksum database for them.

To be able to fetch rsc.io/quote/v3 and other public modules from the mirror, that environment variable will need to be updated to something narrower. See https://golang.org/cmd/go/#hdr-Module_configuration_for_non_public_modules for more information about it.

hencrice

comment created time in 7 days

issue commentgolang/go

Packages under rsc.io are no longer available

@hencrice Please post the full output of running go version, then go env, then the exact command you ran that's still giving an error, so we have full information.

It should work okay if GOPROXY is set to use the module mirror and the value is used when you run go build or go mod download, so perhaps the problem was your configuration change wasn't picked up by the other command.

hencrice

comment created time in 7 days

issue commentgolang/go

cmd/go/internal/modfetch: TestCodeRepo failures due to external repo changes

There are some additional cmd/go tests currently failing on the longtest builder because rsc.io is not serving Go packages, see #40452.

Specifically (from https://storage.googleapis.com/go-build-log/3c347861/linux-amd64-longtest_bb29e807.log):

<details><br>

--- FAIL: TestGoGetCustomDomainWildcard (0.24s)
    go_test.go:2628: running testgo [get -u rsc.io/pdf/...]
    go_test.go:2628: standard error:
    go_test.go:2628: package rsc.io/pdf/...: unrecognized import path "rsc.io/pdf": reading https://rsc.io/pdf?go-get=1: 503 Service Unavailable
        
    go_test.go:2628: go [get -u rsc.io/pdf/...] failed unexpectedly in /workdir/go/src/cmd/go: exit status 1
--- FAIL: TestGoGetDotSlashDownload (0.22s)
    go_test.go:2714: running testgo [get ./pprof_mac_fix]
    go_test.go:2714: standard error:
    go_test.go:2714: unrecognized import path "rsc.io/pprof_mac_fix": reading https://rsc.io/pprof_mac_fix?go-get=1: 503 Service Unavailable
        
    go_test.go:2714: go [get ./pprof_mac_fix] failed unexpectedly in /workdir/tmp/cmd-go-test-062451185/gotest700832841/src/rsc.io: exit status 1
    panic.go:617: ended in /workdir/tmp/cmd-go-test-062451185/gotest700832841/src/rsc.io
--- FAIL: TestGoGetInsecure (1.38s)
    --- FAIL: TestGoGetInsecure/gopath (0.11s)
        go_test.go:2895: running testgo [get -d insecure.go-get-issue-15410.appspot.com/pkg/p]
        go_test.go:2895: standard error:
        go_test.go:2895: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": https fetch: Get "https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1": x509: certificate is valid for *.appspot-preview.com, *.an.r.appspot.com, *.app.google, *.appspot.com, *.as.r.appspot.com, *.de.r.appspot.com, *.df.r.appspot.com, *.dt.r.appspot.com, *.du.r.appspot.com, *.el.r.appspot.com, *.et.r.appspot.com, *.ew.r.appspot.com, *.ey.r.appspot.com, *.ez.r.appspot.com, *.lz.r.appspot.com, *.nn.r.appspot.com, *.nw.r.appspot.com, *.nz.r.appspot.com, *.oa.r.appspot.com, *.rj.r.appspot.com, *.thinkwithgoogle.com, *.ts.r.appspot.com, *.tz.r.appspot.com, *.uc.r.appspot.com, *.ue.r.appspot.com, *.uk.r.appspot.com, *.uw.r.appspot.com, *.withgoogle.com, *.withyoutube.com, *.wl.r.appspot.com, *.wm.r.appspot.com, *.wn.r.appspot.com, app.google, appspot-preview.com, appspot.com, thinkwithgoogle.com, withgoogle.com, withyoutube.com, not insecure.go-get-issue-15410.appspot.com
            
        go_test.go:2895: testgo failed as expected: exit status 1
        go_test.go:2898: running testgo [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p]
        go_test.go:2898: standard error:
        go_test.go:2898: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": reading https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1: 503 Service Unavailable
            
        go_test.go:2898: go [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p] failed unexpectedly in /workdir/go/src/cmd/go: exit status 1
    --- FAIL: TestGoGetInsecure/modules (1.26s)
        go_test.go:2895: running testgo [get -d insecure.go-get-issue-15410.appspot.com/pkg/p]
        go_test.go:2895: standard error:
        go_test.go:2895: go get insecure.go-get-issue-15410.appspot.com/pkg/p: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": https fetch: Get "https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1": x509: certificate is valid for *.appspot-preview.com, *.an.r.appspot.com, *.app.google, *.appspot.com, *.as.r.appspot.com, *.de.r.appspot.com, *.df.r.appspot.com, *.dt.r.appspot.com, *.du.r.appspot.com, *.el.r.appspot.com, *.et.r.appspot.com, *.ew.r.appspot.com, *.ey.r.appspot.com, *.ez.r.appspot.com, *.lz.r.appspot.com, *.nn.r.appspot.com, *.nw.r.appspot.com, *.nz.r.appspot.com, *.oa.r.appspot.com, *.rj.r.appspot.com, *.thinkwithgoogle.com, *.ts.r.appspot.com, *.tz.r.appspot.com, *.uc.r.appspot.com, *.ue.r.appspot.com, *.uk.r.appspot.com, *.uw.r.appspot.com, *.withgoogle.com, *.withyoutube.com, *.wl.r.appspot.com, *.wm.r.appspot.com, *.wn.r.appspot.com, app.google, appspot-preview.com, appspot.com, thinkwithgoogle.com, withgoogle.com, withyoutube.com, not insecure.go-get-issue-15410.appspot.com
            
        go_test.go:2895: testgo failed as expected: exit status 1
        go_test.go:2898: running testgo [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p]
        go_test.go:2898: standard error:
        go_test.go:2898: go get insecure.go-get-issue-15410.appspot.com/pkg/p: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": reading https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1: 503 Service Unavailable
            
        go_test.go:2898: go [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p] failed unexpectedly in /workdir/tmp/cmd-go-test-062451185/gotest738708835: exit status 1
        panic.go:617: ended in /workdir/tmp/cmd-go-test-062451185/gotest738708835
--- FAIL: TestGoGetInsecureCustomDomain (0.09s)
    go_test.go:2983: running testgo [get -d insecure.go-get-issue-15410.appspot.com/pkg/p]
    go_test.go:2983: standard error:
    go_test.go:2983: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": https fetch: Get "https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1": x509: certificate is valid for *.appspot-preview.com, *.an.r.appspot.com, *.app.google, *.appspot.com, *.as.r.appspot.com, *.de.r.appspot.com, *.df.r.appspot.com, *.dt.r.appspot.com, *.du.r.appspot.com, *.el.r.appspot.com, *.et.r.appspot.com, *.ew.r.appspot.com, *.ey.r.appspot.com, *.ez.r.appspot.com, *.lz.r.appspot.com, *.nn.r.appspot.com, *.nw.r.appspot.com, *.nz.r.appspot.com, *.oa.r.appspot.com, *.rj.r.appspot.com, *.thinkwithgoogle.com, *.ts.r.appspot.com, *.tz.r.appspot.com, *.uc.r.appspot.com, *.ue.r.appspot.com, *.uk.r.appspot.com, *.uw.r.appspot.com, *.withgoogle.com, *.withyoutube.com, *.wl.r.appspot.com, *.wm.r.appspot.com, *.wn.r.appspot.com, app.google, appspot-preview.com, appspot.com, thinkwithgoogle.com, withgoogle.com, withyoutube.com, not insecure.go-get-issue-15410.appspot.com
        
    go_test.go:2983: testgo failed as expected: exit status 1
    go_test.go:2984: running testgo [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p]
    go_test.go:2984: standard error:
    go_test.go:2984: unrecognized import path "insecure.go-get-issue-15410.appspot.com/pkg/p": reading https://insecure.go-get-issue-15410.appspot.com/pkg/p?go-get=1: 503 Service Unavailable
        
    go_test.go:2984: go [get -d -insecure insecure.go-get-issue-15410.appspot.com/pkg/p] failed unexpectedly in /workdir/go/src/cmd/go: exit status 1
go test proxy running at GOPROXY=http://127.0.0.1:45253/mod
go proxy: no archive rsc.io v1.5.1: file does not exist
go proxy: no archive example.com/newcycle v1.0.0: file does not exist
go proxy: no archive rsc.io v1.0.0: file does not exist
go proxy: no archive rsc.io v1.4.0: file does not exist
go proxy: no archive rsc.io v1.5.2: file does not exist
go proxy: no archive rsc.io v1.1.0: file does not exist
go proxy: no archive rsc.io v1.0.0: file does not exist
go proxy: no archive rsc.io v1.0.0: file does not exist
go proxy: no archive rsc.io v1.0.0: file does not exist
go proxy: no archive rsc.io v1.0.0: file does not exist
go proxy: no archive golang.org v0.1.0: file does not exist
go proxy: no archive golang.org v0.3.0: file does not exist
go proxy: no archive golang.org/x v0.1.0: file does not exist
go proxy: no archive golang.org/x v0.3.0: file does not exist
go proxy: no archive example.com v0.1.0: file does not exist
go proxy: no archive rsc.io v1.5.2: file does not exist
--- FAIL: TestScript (0.00s)
    --- FAIL: TestScript/mod_init_dep (0.24s)
        script_test.go:193: 
            # modconv uses git directly to examine what old 'go get' would (0.001s)
            # go build should populate go.mod from Gopkg.lock (0.229s)
            > cp go.mod1 go.mod
            > go build
            [stderr]
            go: copying requirements from Gopkg.lock
            go: converting Gopkg.lock: stat rsc.io/sampler@v1.0.0: unrecognized import path "rsc.io/sampler": reading https://rsc.io/sampler?go-get=1: 503 Service Unavailable
            > stderr 'copying requirements from Gopkg.lock'
            > go list -m all
            [stdout]
            x
            > ! stderr 'copying requirements from Gopkg.lock'
            > stdout 'rsc.io/sampler v1.0.0'
            FAIL: testdata/script/mod_init_dep.txt:13: no match for `(?m)rsc.io/sampler v1.0.0` found in stdout
            
    --- FAIL: TestScript/mod_gonoproxy (0.78s)
        script_test.go:193: 
            # disagree with sumdb fails (0.028s)
            # but GONOSUMDB bypasses sumdb, for rsc.io/quote, rsc.io/sampler, golang.org/x/text (0.560s)
            # and GONOPROXY bypasses proxy (0.169s)
            > [!net] skip
            > [!exec:git] skip
            > env GOPRIVATE=none
            > env GONOPROXY='*/fortune'
            > ! go get rsc.io/fortune # does not exist in real world, only on test proxy
            [stderr]
            go get rsc.io/fortune: unrecognized import path "rsc.io/fortune": reading https://rsc.io/fortune?go-get=1: 503 Service Unavailable
            [exit status 1]
            > stderr 'git ls-remote'
            FAIL: testdata/script/mod_gonoproxy.txt:27: no match for `(?m)git ls-remote` found in stderr
            
    --- FAIL: TestScript/mod_download_hash (0.31s)
        script_test.go:193: 
            # Testing mod download with non semantic versions; turn off proxy. (0.307s)
            > [!net] skip
            > [!exec:git] skip
            > env GOPROXY=direct
            > env GOSUMDB=off
            > go mod download rsc.io/quote@a91498bed0a73d4bb9c1fb2597925f7883bc40a7
            [stderr]
            rsc.io/quote@a91498bed0a73d4bb9c1fb2597925f7883bc40a7: unrecognized import path "rsc.io/quote": reading https://rsc.io/quote?go-get=1: 503 Service Unavailable
            [exit status 1]
            FAIL: testdata/script/mod_download_hash.txt:9: unexpected command failure
            
    --- FAIL: TestScript/mod_sumdb_golang (0.27s)
        script_test.go:193: 
            # Test default GOPROXY and GOSUMDB (0.083s)
            # download direct from github (0.190s)
            > [!net] skip
            > [!exec:git] skip
            > env GOSUMDB=sum.golang.org
            > env GOPROXY=direct
            > go get -d rsc.io/quote@v1.5.2
            [stderr]
            go get rsc.io/quote@v1.5.2: unrecognized import path "rsc.io/quote": reading https://rsc.io/quote?go-get=1: 503 Service Unavailable
            [exit status 1]
            FAIL: testdata/script/mod_sumdb_golang.txt:17: unexpected command failure
            
    --- FAIL: TestScript/gopath_moved_repo (0.87s)
        script_test.go:193: 
            # Test that 'go get -u' reports packages whose VCS configurations do not
            # match their import paths. (0.000s)
            # We need to execute a custom Go program to break the config files.
            #
            # git will ask for a username and password when we run 'go get -d -f -u',
            # so we also need to set GIT_ASKPASS. Conveniently, a single binary can
            # perform both tasks! (0.674s)
            # Test that 'go get -u' reports moved git packages. (0.191s)
            > [exec:git] go get -d rsc.io/pdf
            [stderr]
            unrecognized import path "rsc.io/pdf": reading https://rsc.io/pdf?go-get=1: 503 Service Unavailable
            [exit status 1]
            FAIL: testdata/script/gopath_moved_repo.txt:21: unexpected command failure
            
--- FAIL: TestIssue11457 (0.20s)
    go_test.go:1087: running testgo [get -d -u rsc.io/go-get-issue-11457]
    go_test.go:1087: standard error:
    go_test.go:1087: unrecognized import path "rsc.io/go-get-issue-11457": reading https://rsc.io/go-get-issue-11457?go-get=1: 503 Service Unavailable
        
    go_test.go:1087: go [get -d -u rsc.io/go-get-issue-11457] failed unexpectedly in /workdir/go/src/cmd/go: exit status 1
--- FAIL: TestIssue16471 (1.31s)
    go_test.go:1071: git standard error:
    go_test.go:1071: Cloning into 'go-get-issue-10952'...
        
    go_test.go:1072: running testgo [get -u rsc.io/go-get-issue-10952]
    go_test.go:1072: testgo succeeded unexpectedly
FAIL
FAIL	cmd/go	132.219s
FAIL

</details>

@bcmills @matloob @jayconrod Is it in scope for this issue to make those tests not fail if rsc.io is not available?

ALTree

comment created time in 7 days

issue commentgolang/go

Packages under rsc.io are no longer available

@hencrice I can't reproduce this with Go 1.14 with a default configuration:

$ go version
go version go1.14.6 darwin/amd64
$ cd $(mktemp -d)
$ go mod init example.com/m
go: creating new go.mod: module example.com/m
$ go mod download github.com/aws/amazon-kinesis-firehose-for-fluent-bit@v1.4.1
$ echo $?
0

What is your go env GOPROXY value? Is it modified from the default? I'm guessing it does not use the module mirror (https://proxy.golang.org/). Is it an option for you to start using it?

Making cmd/go tests not depend on external services is tracked in issue #28856. We should see if the current -longtest failures should be in scope of that issue. I'll see how quickly Russ expects to be able to fix rsc.io to determine the best next steps for it.

hencrice

comment created time in 7 days

issue commentgolang/go

doc: write Go 1.15 release notes

The draft notice is correct. We generally remove it as part of making the final release, not earlier.

dmitshur

comment created time in 8 days

issue commentgolang/go

runtime: tracking bug for ARM-based macOS and GOOS/GOARCH values

Following up on https://github.com/golang/go/issues/38485#issuecomment-647584660.

Since then, I found that Gio (/cc @eliasnaur) also sets the ios build tag unconditionally (see here) when building Go packages for the iOS target, like gomobile and gobind from x/mobile do. The ios build tag has been around since Go 1.5 and will be taken into account if any changes need to be made in the future.

I've talked with @hyangah and @cherrymui in case I was missing anything that's worth considering for the Go 1.15 release. In the past releases, we've sometimes added release note entries about likely upcoming changes that users should be aware of, so I wanted to see if there was something useful we could say that would meet the bar for inclusion. There turned out not to be anything at this time. As Russ said, nothing is changing for 1.15. Much of this issue remains as future work. So, I'll abandon CL 239278 and move this to 1.16 milestone as there's nothing left for the Go 1.15 release.

bradfitz

comment created time in 8 days

issue commentgolang/go

x/playground: version stated on "About" page is one version behind

By now (after some number of days have passed), it says "The current version is go1.14.6." on the About page.

dmitshur

comment created time in 8 days

issue commentshurcooL/githubv4

Authorization issue when running graphql including repository collaborators via this lib

strange thing is we do receive those collaborators regardless in our response.

Maybe the results are incomplete? If you think it's a bug on GitHub's side, it would be helpful to report it to them.

How should I deal with that partial response from the lib if that is the case? What would you recommend?

I need to add to the API to make it possible to type assert the error into a valid GraphQL response containing non-empty errors, to be able tell it apart from other more serious errors (e.g., unable to make the GraphQL query because can't reach the server). This is tracked in issue #41. Also see https://github.com/shurcooL/githubv4/issues/41#issuecomment-465855467 for an idea for a workaround that you can use until a better API is added.

marcofranssen

comment created time in 8 days

issue openeddominikh/go-tools

staticcheck: SA4017: ignore pure calls in testing.AllocsPerRun callbacks

This false positive issue is very similar to #316. Consider test code like this:

func TestFooAllocs(t *testing.T) {
	allocs := testing.AllocsPerRun(1000, func() {
		Foo("bar")
	})
	if allocs != 0 {
		t.Errorf("got allocs = %v; want zero", allocs)
	}
}

Staticcheck should not print:

foo_test.go: Foo is a pure function but its return value is ignored (SA4017)

Because the test code is valid.

Happens with latest master commit (925e3c1d1b98).

created time in 9 days

issue commentdominikh/go-tools

Improve semantic versioning

Overall, I like the plan and the future versions.

As discussed over chat, I think you should avoid retroactively giving existing older releases (all but the latest current release, 2020.1.4) a semantic version that sorts higher than their current version, as that can cause a problem for modules using the current version scheme for the existing releases.

As a minor note, v0.3.0-rc1 should be v0.3.0-rc.1 so that sorting works as expected if there are more than 10 such versions, and to set a better example for others to follow. This is a part of best practices of using semver, also see https://semver.org/#spec-item-11 and the examples of pre-release versions provided there.

dominikh

comment created time in 10 days

issue commentshurcooL/githubv4

Authorization issue when running graphql including repository collaborators via this lib

I can also confirm I'm getting the data back as expected. So it seems to be something in the lib that is doing some check or magic somewhere after getting the response causing that error regarding token push permissions.

I'm quite confident the "Must have push access to view repository collaborators." error is coming from the GitHub API server, it's not in githubv4 or any of its dependencies.

Did you check if the response has an "errors" field set? If so, maybe the GitHub response contains partial data and also an error.

The behavior of graphql and githubv4 is to populate any partial data, and return the first error from "errors" field in the GraphQL response. See here.

marcofranssen

comment created time in 10 days

issue commentgolang/go

x/mobile/cmd/gomobile: Go1.15beta1 cannot generate Objective-c bindings if target includes amd64

Thanks for investigating and confirming this is fixed, Hajime.

libnat

comment created time in 11 days

issue commentshurcooL/githubv4

Authorization issue when running graphql including repository collaborators via this lib

However when ran from graphql playground using the same authentication token it works.

That is unexpected.

Is there a way I can inspect the generated graphql?

Yeah, it's a good idea to confirm the generated query matches what you intended to write. There isn't a public API to do it yet, but in the meantime you can either make changes to graphql package or use an http.RoundTripper that prints the request bodies:

// teeRoundTripper copies request bodies to stdout.
type teeRoundTripper struct {
	http.RoundTripper
}

func (t teeRoundTripper) RoundTrip(req *http.Request) (*http.Response, error) {
	if req.Body != nil {
		req.Body = struct {
			io.Reader
			io.Closer
		}{
			Reader: io.TeeReader(req.Body, os.Stdout),
			Closer: req.Body,
		}
	}
	return t.RoundTripper.RoundTrip(req)
}

(See https://play.golang.org/p/jAKBW46BdPh for a complete snippet.)

marcofranssen

comment created time in 11 days

issue commentgo4org/go4

Installing go4 error

No problem.

@melardev Out of curiosity, did you find the previous invalid "github.com/go4org/go4/strutil" import path written down or suggested somewhere? I'm asking because if there was some resource that made you think that's what you should write, we should try to fix or update it, so that other people don't get misled in the same way.

melardev

comment created time in 12 days

issue commentgo4org/go4

Installing go4 error

The fix is to use a matching module path, which is go4.org. You can see it declared at the top of the go.mod file.

If you visit the documentation for one of the packages in this module, for example, go4.org/osutil, you can see the import path at the top, with a button to copy it to clipboard:

image

melardev

comment created time in 12 days

issue commentgolang/go

x/build/app: build dashboard for subrepos displays wrong columns

I believe this particular misalignment has been resolved by now. I'm not able to spot it by now.

Note that #28643 tracks general readability improvements to the golang.org/x repo view.

mikioh

comment created time in 13 days

issue commentshurcooL/vfsgen

"ignore" build tag is special in module mode

Thanks for reporting the problem with ignore build tag, that indeed needs to be fixed.

Can you please open a separate issue about the problem with importPathToDir? It does need to be run inside the main module, but otherwise should work. It’ll be easier to discuss it in more detail in a dedicated issue. Thanks.

segevfiner

comment created time in 13 days

issue commentgolang/go

x/mobile/cmd/gomobile: the test TestWriter is flaky on the trybots

a bug in the dashboard UI

I've looked into it, it's not a trivial mistake, the problem happens due to insufficient data and a more complete fix would need changes to multiple components (the build dashboard and maintner API server). That'll take longer and it'll happen as part of other work to improve the dashboard UI (see #34744, #28643, etc.). /cc @toothrot

For now, I've sent a smaller patch in CL 244137 so that existing builds aren't hidden, and consider the rest as future work.

It can be previewed to see the past TestWriter failures here.

hajimehoshi

comment created time in 14 days

issue commentgolang/go

x/mobile/cmd/gomobile: the test TestWriter is flaky on the trybots

It turns out it's a bug in the dashboard UI rather than intentional configuration. The linux-amd64-androidemu builder is configured to run both on pre- and post-submit builders. There's even a test case enforcing it. I'll look into fixing the UI so we can see how long this has been failing.

hajimehoshi

comment created time in 14 days

issue commentgolang/go

x/mobile/cmd/gomobile: the test TestWriter is flaky on the trybots

Oh, I was misreading the build dashboard. The linux-amd64-androidemu builder is configured run pre-submit trybots, but not post-submit builds.

Skipping it with this issue open seems reasonable to me, but let's make the skip conditional on it being the linux-amd64-androidemu builder, so it's not skipped unnecessarily elsewhere (unless there's a need for it to be skipped elsewhere as well). I'll post this as a comment on the CL.

hajimehoshi

comment created time in 14 days

issue commentgolang/go

x/mobile/cmd/gomobile: the test TestWriter is flaky on the trybots

Do you know since when it became flaky? How often have you seen it?

I'm not seeing many (or any) previous failures on the post-submit runs (https://build.golang.org/?repo=golang.org%2fx%2fmobile). Is the test only flaky on pre-submit runs?

hajimehoshi

comment created time in 14 days

IssuesEvent

issue commentgolang/go

x/pkgsite, x/website, x/tools/godoc: factory functions are displayed in a way that can cause confusion

My intention was to suggest we use #39813 for tracking improvements to the heuristic of when to consider a function as a "factory function". However, this issue seems slightly different, as it's about the way factory functions are displayed. Reopening so we can consider this issue further.

mleonhard

comment created time in 15 days

issue closedgolang/gddo

Internal server error when viewing packages

Hello,

The production instance is currently throwing ISEs when trying to view the documentation for any package. Is an on call engineer aware and investigating?

Cheers!

closed time in 15 days

theckman

issue commentgolang/gddo

Internal server error when viewing packages

Closing in favor of aforementioned issue.

See https://github.com/golang/go/issues/36642#issuecomment-577908050 for more details about what happened, including the root cause.

theckman

comment created time in 15 days

issue openedgolang/go

x/playground: version stated on "About" page is one version behind

The current latest Go release is Go 1.14.6.

Clicking the About button at https://play.golang.org now says:

The playground uses the latest stable release of Go. The current version is go1.14.5.

However, running the https://play.golang.org/p/Ztyu2FJaajl program suggests the actual playground program execution uses Go 1.14.6. So it's only the frontend that's on the previous version.

So it's not a big deal, but need to understand why this happens and fix it.

/cc @toothrot

created time in 15 days

issue commentgolang/go

x/playground: output caching is not working

It seems the memcached instance has become unhealthy again. I'll look into restarting it for now.

dmitshur

comment created time in 15 days

issue closedgolang/go

x/mobile/cmd/gomobile: Go1.15beta1 cannot generate Objective-c bindings because hardcoded GOARCH=arm configuration is used to load packages

<!-- Please answer these questions before submitting your issue. Thanks! For questions please use one of our forums: https://github.com/golang/go/wiki/Questions -->

What version of Go are you using (go version)?

<pre> $ go version go version go1.15beta1 darwin/amd64 </pre>

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

<details><summary><code>go env</code> Output</summary><br><pre> $ go env GOARCH="amd64" GOOS="darwin" </pre></details>

What did you do?

Tried three ways, all failed with the same error gomobile bind -v -target=ios . gomobile bind -v -target=ios/arm64 . GOARCH=arm64 gomobile bind -v -target=ios . <!-- 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?

Generate objective-c framework

What did you see instead?

gomobile: go [-e -json -compiled=true -test=false -export=false -deps=false -find=true -tags=ios -- mypkg]: exit status 2: cmd/go: unsupported GOOS/GOARCH pair darwin/arm

closed time in 15 days

libnat

push eventshurcooL/home

Dmitri Shuralyov

commit sha e9ff8b15dd53491dc9974c689c910f34742bdd97

indieauth: reject redirects to insecure HTTP protocol The authentication process cannot be completed safely and reliably if it involves a redirect to an insecure protocol like HTTP. Detect and reject such cases. They're unlikely to happen anyway, but if they do, we certainly don't want to proceed silently. For https://github.com/shurcooL/home/issues/34.

view details

push time in 16 days

issue commentgolang/go

x/exp/cmd/gorelease: module source tree too large

It is not committed

If a very large file or directory is not committed, it would not be a real problem, so gorelease reporting that is a false positive as far as I understand. Is there already an issue tracking whether improving that is feasible?

carnott-snap

comment created time in 18 days

issue commentgolang/go

x/exp/cmd/gorelease: module source tree too large

it does not reproduce on other modules or with an older version of gorelease, CL 197299/4.

In the diff between patch set 4 of CL 197299 and the final patch set 15 that was merged, the go.mod went from requiring golang.org/x/mod at v0.1.0 to v0.1.1-0.20191107180719-034126e5016b. That change implemented the check that "total size in bytes of a module zip file may be at most MaxZipFile bytes (500 MiB)" that @hyangah pointed out above. This suggests the old gorelease version was not checking that property.

carnott-snap

comment created time in 18 days

issue closedgolang/go

[Question]: url of to download package

Hi, We can download gem package by https://rubygems.org/downloads/{name}-{version}.gem, cargo creates by https://crates.io/api/v1/crates/{name}/{version}/download. We can download download package directly by this url.

Is there any url to download the go package directly from it if we don't have the version number??

closed time in 19 days

rpotter12

issue commentgolang/go

[Question]: url of to download package

Hi there,

Unlike many projects, the Go project does not use GitHub Issues for general discussion or asking questions. GitHub Issues are used for tracking bugs and proposals only.

For discussion or questions, see:

Please ask the question on one of the above forums. Thanks.

(Quoted from https://golang.org/wiki/Questions.)

rpotter12

comment created time in 19 days

issue commentgolang/go

x/exp/cmd/gorelease: module source tree too large

Is this a regression?

What are the contents and the size of the directory where you ran gorelease?

/cc @jayconrod

carnott-snap

comment created time in 19 days

issue commentgolang/go

testing: streaming output loses parallel subtest associations [1.14 backport]

Now that this change was submitted to the release branch, I'll remove release-blocker label to reduce visual noise when viewing the release history details.

gopherbot

comment created time in 19 days

issue commentgolang/go

reflect: DeepEqual can return true for values that are not equal

@davecheney 1.14.5 was a security release. 1.14.6 is being released right now (see #40256) and it does include the fix. See backport issue #39636 for more details.

ailurarctos

comment created time in 19 days

issue openedgolang/go

x/build/env/linux-arm64/packet: 8 Packet linux/arm64 machines missing (mid-July 2020)

From https://farmer.golang.org:

image

May be similar to #37922.

/cc @andybons @cagedmantis @toothrot

created time in 19 days

issue commentgolang/go

x/mobile: Go1.15beta1 cannot generate Objective-c bindings

@libnat If that issue you found is an issue right now, please open a separate issue to track it. If it's introduced by that CL, please leave a review comment on it.

@diegomontoya Only the darwin 32-bit ports are deprecated in Go 1.15. See https://tip.golang.org/doc/go1.15#darwin.

libnat

comment created time in 20 days

issue commentgolang/go

x/net/http2: TestTransportPingWhenReading fails on android-386-emu sometimes

Issue #39233 was related, but for Plan 9. /cc @millerresearch @0intro

dmitshur

comment created time in 20 days

issue openedgolang/go

x/net/http2: TestTransportPingWhenReading fails on android-386-emu sometimes

panic: Fail in goroutine after TestTransportPingWhenReading/two_pings_in_each_serverResponseInterval has completed

goroutine 14595 [running]:
testing.(*common).Fail(0xc0990500)
	/workdir/go/src/testing/testing.go:613 +0x105
testing.(*common).Error(0xc0990500, 0xc09bbfcc, 0x1, 0x1)
	/workdir/go/src/testing/testing.go:706 +0x62
golang.org/x/net/http2.testTransportPingWhenReading.func2.1(0xc0899a20, 0xc0921800, 0xc0c344a0, 0xc0990500, 0x3b9aca00, 0x0)
	/workdir/gopath/src/golang.org/x/net/http2/transport_test.go:3451 +0x30b
created by golang.org/x/net/http2.testTransportPingWhenReading.func2
	/workdir/gopath/src/golang.org/x/net/http2/transport_test.go:3437 +0x355
exitcode=2FAIL	golang.org/x/net/http2	24.773s

Source:

  • https://build.golang.org/log/da3430afc1a232dc13e98576050154531ba0ec09 (Go 1.14 + recent x/net commit)
  • https://build.golang.org/log/4a5484788c091c8d1bfe2b3923c722c5e548f2ba (Go 1.14 + recent x/net commit)

It may be the builder or the the test. Needs investigation.

/cc @bradfitz @tombergan per owners.

created time in 20 days

issue closedgolang/go

x/pkgsite: function does not appear in table of contents

The function Expect appears on the page https://pkg.go.dev/github.com/onsi/gomega?tab=doc#Expect, but it is not listed in the table of contents.

closed time in 20 days

stamblerre

issue commentgolang/go

x/pkgsite: function does not appear in table of contents

Per comments above, Expect is considered to be a "factory function" for Assertion, so it's displayed underneath it.

The code for this is in go/doc (see https://github.com/golang/go/issues/39813#issuecomment-649636776). I don't see anything to do here, so let's close this. We can use #39813 as the tracking issue for considering changes to the "factory function" behavior.

stamblerre

comment created time in 20 days

issue closedgolang/go

x/website: Make os.Stat() function appear at the top level in Index

What did you do?

My golang program needs to find out if a path refers to an existing directory. I need to find out how to do that. Here's what I did:

  1. Did a web search for golang isdir
  2. Clicked on the first result, os - The Go Programming Language
  3. Searched in the page (CTRL-F) for isdir.
  4. Found type FileInfo. It contains an IsDir() function. The description says "A FileInfo describes a file and is returned by Stat and Lstat."
  5. Spent a minute searching around the page for the proper Stat function. Found type File with a Stat() function. Unfortunately, to create a File struct, one must actually create a normal file on the filesystem.
  6. Saw the Stat(string) function indented under type FileInfo in the index. Clicked on it. This is the same struct that I just looked at. Where is the top-level Stat method?
  7. Confused, I went back to web search and searched for "golang check if directory exists".
  8. Clicked the first result, Check if a file or directory exists in Go (Golang .... That page has an example that starts with fileinfo, err := os.Stat("temp.txt").
  9. I went back to the os package docs page and scanned the index. There is no Stat top-level function. This is so strange.
  10. Tried typing the function in my editor. It's there, with documentation.
  11. Began filing this ticket.
  12. Finally noticed that the Stat function is indented under type FileInfo but it's not actually a method on that struct:
type FileInfo
    func Lstat(name string) (FileInfo, error)
    func Stat(name string) (FileInfo, error)

What did you expect to see?

I expected to see func Stat(name string) (FileInfo, error) unindented, in the top section of the index with the module-level functions. Like this:

Constants
Variables
func Chdir(dir string) error
func Chmod(name string, mode FileMode) error
...
func Setenv(key, value string) error
func Stat(name string) (FileInfo, error)  // <--- here
func Symlink(oldname, newname string) error
...
type File
...
type FileInfo
...
type FileMode
...

What did you see instead?

I saw func Stat(name string) (FileInfo, error) appearing out of order with the other top-level functions in os, indented under type FileInfo as if it is a method of FileInfo.

Constants
Variables
func Chdir(dir string) error
func Chmod(name string, mode FileMode) error
...
func UserConfigDir() (string, error)
func UserHomeDir() (string, error)
type File
...
type FileInfo
    func Lstat(name string) (FileInfo, error)
    func Stat(name string) (FileInfo, error)  // <--- here
type FileMode
...

closed time in 20 days

mleonhard

issue commentgolang/go

x/website: Make os.Stat() function appear at the top level in Index

Thanks for reporting. As @go101 pointed out via related issues, this is a heuristic and it's working as intended. Stat is considered to be a "factory function", so it's displayed underneath FileInfo.

mleonhard

comment created time in 20 days

issue commentgolang/go

database/sql: context cancellation allows statements to execute after rollback

Thank you for doing that work, @odeke-em. The 1.13 backport issue is still in CherryPickCandidate state, so the release managers will need to decide whether it should be approved for backport. Having the backport CL ready makes that process easier.

dadkins-at-dropbox

comment created time in 20 days

issue commentgolang/go

x/build/cmd/release: leave oldlink binary out of RC1 (if the beta doesn't uncover serious linker issues)

Thanks!

This is how the test fails when oldlink binary isn't present:

$ go test -v -run=TestOldLink -count=1 cmd/link
=== RUN   TestOldLink
    link_test.go:558: [/tmp/tmp.AG3oE0Ne/go/bin/go run -gcflags=all=-go115newobj=false -asmflags=all=-go115newobj=false -ldflags=-go115newobj=false /tmp/TestOldLink814981397/main.go]: exit status 2:
        # command-line-arguments
        2020/07/14 18:36:02 invoke oldlink failed:fork/exec /tmp//tmp.AG3oE0Ne/go/pkg/tool/darwin_amd64/oldlink: no such file or directory
--- FAIL: TestOldLink (0.14s)
FAIL
FAIL	cmd/link	0.269s

It's going to affect people who try to run go test cmd/link after installing a binary release of Go from https://golang.org/dl.

Given that 1.15 is shipping a new linker, it's better to avoid misleading test failures, so skipping the test if oldlink binary isn't available seems like a good solution.

toothrot

comment created time in 21 days

issue commentgolang/go

x/build/cmd/release: leave oldlink binary out of RC1 (if the beta doesn't uncover serious linker issues)

A test may fail if the old linker is not present. We could change the test to skip if the binary does not exist.

@cherrymui Which test were you referring to?

I can try to find anything by taking go1.15beta1, removing the oldlink binary, then seeing if anything comes up during go test std cmd.

toothrot

comment created time in 21 days

issue openedgolang/go

x/build/cmd/releasebot: improve -dry-run -mode=prepare to support advance testing for more release types

Right now, it's possible to use releasebot -dry-run -mode=prepare to run a release locally that doesn't produce any public artifacts or changes state, but only for the beta release type (e.g., go1.15beta2).

For most other release types, it fails "too early" to produce useful information. For example, it doesn't take into account that a Gerrit CL isn't mailed, so trying to fetch its commit hash from Gerrit will give 404, and release won't be able to proceed.

This is the tracking issue about improving that. It's broken out of https://github.com/golang/go/issues/29252#issuecomment-632352576.

/cc @toothrot @cagedmantis @andybons

created time in 21 days

issue closedgolang/go

net: remove dependency on fmt, unicode via golang.org/x/net/dns/dnsmessage

net should not depend on fmt and unicode.

golang.org/x/net/dns/dnsmessage contains one line using fmt:

return nil, off, fmt.Errorf("invalid resource type: %d", hdr.Type)

But dnsmessage is vendored into the standard library and imported by net, and this use is making net depend on fmt, and in turn on unicode.

This one line should be changed, to remove the use of fmt.

go/build.TestDependencies claims to check that net does not depend on unicode, which should have detected this, but that test does not look inside vendored packages.

I have a fix that I will send out for that problem as well.

closed time in 21 days

rsc

issue commentgolang/go

net: remove dependency on fmt, unicode via golang.org/x/net/dns/dnsmessage

I've confirmed the package net does not import fmt nor unicode, not even indirectly. It was resolved via CL 241257, and CL 241078 added a regression test (see this line).

Closing as this issue is fixed. Please comment if I missed something.

rsc

comment created time in 21 days

issue commentgolang/go

runtime: pageAlloc.searchAddr may point to unmapped memory in discontiguous heaps, violating its invariant [1.14 backport]

@mknyszek Can you please add a short rationale about why the backport might be needed? (Per MinorReleases.) Thanks.

gopherbot

comment created time in 21 days

issue commentgolang/go

doc: document/reassert that last two releases are supported equally

@ianlancetaylor Issue #37097 was about a problem on the Go-Release-Cycle page.

I spotted a problematic statement in the MinorReleases page; filed #40206 about it.

FiloSottile

comment created time in 21 days

issue openedgolang/go

wiki: MinorReleases has an out of date statement on backporting policy

The https://golang.org/wiki/MinorReleases page currently still says:

"Use a more recent stable version" is a valid workaround, so very few fixes will be backported to both previous issues.

That statement isn't true per discussion in #34536. We should either update it or remove it. If it's not already said elsewhere on the page, we should likely replace it with something similar to what's written in https://github.com/golang/go/issues/34536#issuecomment-572188389.

/cc @ianlancetaylor @cagedmantis @toothrot @andybons

created time in 21 days

issue commentgolang/go

database/sql: context cancellation allows statements to execute after rollback

Based on https://github.com/golang/go/issues/34775#issuecomment-628115836:

this issue has existed since Go1.12 and unfortunately because it wasn't a regression but rather a long standing bug

The backport policy requires that a fix must either be backported to both or neither (see https://github.com/golang/go/issues/34536#issuecomment-572188389).

I've opened #40205 for the 1.13 backport.

dadkins-at-dropbox

comment created time in 21 days

issue openedgolang/go

database/sql: context cancellation allows statements to execute after rollback [1.13 backport]

@dmitshur requested issue #34775 to be considered for backport to the next 1.13 minor release.

The original issue exists in 1.13 too, so per backport policy, it must be considered for backporting to both 1.14 and 1.13. See the corresponding 1.14 backport issue #39101 for more details.

created time in 21 days

issue closedgolang/go

missing function body - x/tools/go/ssa/interp/testdata/src/os/os.go:3:6

<!-- Please answer these questions before submitting your issue. Thanks! -->

What version of Go are you using (go version)?

<pre> $ go version go version go1.14.2 linux/amd64 </pre>

Does this issue reproduce with the latest release?

Yes however it occurred in go 1.12 and so I upgraded to the latest (that's through the official openSUSE repos so perhaps not the absolute cutting edge release).

Also, it was happening on openSUSE 15.1 and I upgraded to 15.2 with no change.

What operating system and processor architecture are you using (go env)?

<details><summary><code>go env</code> Output</summary><br><pre> $ go env GO111MODULE="" GOARCH="amd64" GOBIN="" GOCACHE="/home/reg/.cache/go-build" GOENV="/home/reg/.config/go/env" GOEXE="" GOFLAGS="" GOHOSTARCH="amd64" GOHOSTOS="linux" GOINSECURE="" GONOPROXY="" GONOSUMDB="" GOOS="linux" GOPATH="/home/reg/Jobs/Go" GOPRIVATE="" GOPROXY="https://proxy.golang.org,direct" GOROOT="/usr/lib64/go/1.14" GOSUMDB="sum.golang.org" GOTMPDIR="" GOTOOLDIR="/usr/lib64/go/1.14/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-build995400351=/tmp/go-build -gno-record-gcc-switches" GOROOT/bin/go version: go version go1.14.2 linux/amd64 GOROOT/bin/go tool compile -V: compile version go1.14.2 uname -sr: Linux 5.3.18-lp152.20.7-default LSB Version: core-2.0-noarch:core-3.2-noarch:core-4.0-noarch:core-2.0-x86_64:core-3.2-x86_64:core-4.0-x86_64:desktop-4.0-amd64:desktop-4.0-noarch:graphics-2.0-amd64:graphics-2.0-noarch:graphics-3.2-amd64:graphics-3.2-noarch:graphics-4.0-amd64:graphics-4.0-noarch Distributor ID: openSUSE Description: openSUSE Leap 15.2 Release: 15.2 Codename: n/a /lib64/libc.so.6: GNU C Library (GNU libc) stable release version 2.26 (git 1c9a5c270d8b), by Roland McGrath et al. gdb --version: GNU gdb (GDB; openSUSE Leap 15.2) 8.3.1 </pre></details>

What did you do?

Added the code:

	if err := Config.validate(p); err != nil {
		os.Exit(1)
	}

and the import for the os.Exit(1) seems to have caused it since when I comment out that line it compiles just fine.

<!-- If possible, provide a recipe for reproducing the error.

I don't know if I would have to give you all my code and my system because it's some subtle combination of things or if just the above is enough so I guess, I don't know, is all I can say.

A complete runnable program is good. A link on play.golang.org is best. -->

What did you expect to see?

To compile without errors, at least with only errors from my mistakes, not from calling a core function.

What did you see instead?

Compile error as follows:

/usr/lib64/go/1.14/bin/go build -o /tmp/___1go_build_main_go_debugFlags -gcflags "all=-N -l" /home/reg/Jobs/Go/src/savior/server/main.go
# golang.org/x/tools/go/ssa/interp/testdata/src/os
Jobs/Go/src/golang.org/x/tools/go/ssa/interp/testdata/src/os/os.go:3:6: missing function body
Jobs/Go/src/golang.org/x/tools/go/ssa/interp/testdata/src/os/os.go:5:6: missing function body

closed time in 22 days

DIYCardSecurity

issue commentgolang/go

missing function body - x/tools/go/ssa/interp/testdata/src/os/os.go:3:6

Thanks for clarifying, that's very helpful. In the original issue report, I didn't realize you were using an IDE and could not understand where the error was coming from.

I wish I was already a go expert but I really am at the learning stages right now so if you could give me some guidance I will do what i can.

Thanks a lot for wanting to contribute. Based on what you described, there's a good chance this issue is related to something the IDE was doing. We can't really make progress here without being able to reproduce the problem, and you mentioned it no longer happens.

I'll close this now because there's nothing action to do on the Go project side at this time, but if this happens again, I suggest reporting this as a bug to the IDE and letting them investigate first. Additionally, see https://golang.org/wiki/Questions for where to ask questions and get general help.

If you get to a point where it's possible to narrow down the issue to something in the Go project, please don't hesitate to open a new issue or leave a comment here if this occurs again. Thanks.

DIYCardSecurity

comment created time in 22 days

PR closed golang/go

all: modify VERSION file cla: yes

DO NOT REVIEW DO NOT SUBMIT

This is a test.

+1 -1

2 comments

1 changed file

dmitshur

pr closed time in 22 days

pull request commentgolang/go

all: modify VERSION file

This was a test for #30037. It's no longer needed.

dmitshur

comment created time in 22 days

issue closedgolang/go

x/build/cmd/gerritbot: some pull requests are neither imported nor closed

In #24938 a contributor sent a pull request against release-branch.go1.9. Gopherbot didn't import it into gerrit, but it also didn't close it.

If sending changes to the release branches is not something that is supposed to work, the bot should warn the author about that and then close the pull request.

cc @andybons

closed time in 22 days

ALTree

issue commentgolang/go

x/build/cmd/gerritbot: some pull requests are neither imported nor closed

The current behavior is that GopherBot will import PRs into Gerrit (see https://github.com/golang/go/pull/40190 and https://go-review.googlesource.com/c/go/+/242279 for a recent example). However, it's still not possible to make cherry-pick CLs via PRs because of another problem, see #30037.

This is documented in the last paragraph of https://golang.org/wiki/MinorReleases#making-cherry-pick-cls:

At this time, it's not possible to make a cherry-pick CL by sending a Pull Request. Only Gerrit is supported. See golang.org/issue/30037.

Let's use #30037 to track further improvements.

ALTree

comment created time in 22 days

PR opened golang/go

all: modify VERSION file

DO NOT REVIEW DO NOT SUBMIT

This is a test.

+1 -1

0 comment

1 changed file

pr created time in 22 days

create barnchdmitshur/go

branch : modified-rb112

created branch time in 22 days

fork dmitshur/go

The Go programming language

https://golang.org

fork in 22 days

pull request commentgolang/tour

Fix bump standard for error handling #939

@georettica Does the email you signed the CLA with match the one used as the git author email (can be seen in second line here)?

georgettica

comment created time in 22 days

issue commentgolang/go

x/pkgsite, x/tools/cmd/godoc: some code examples are not displayed (but work at godoc.org)

One lead to investigate is that the exported DB type is defined as:

type DB struct {
	*baseDB
	ctx context.Context
}

Notably, baseDB is an embedded field. The DB type gets many of its methods indirectly via that embedded baseDB type:

// Begin starts a transaction. Most callers should use RunInTransaction instead.
func (db *baseDB) Begin() (*Tx, error)

The example classification logic in go/doc.NewFromFiles needs to know the complete API to determine if an example should be attached to a given identifier, so if it's not able to handle methods via embedded types, that could be the cause for this.

I haven't looked further, just wanted to share this.

vmihailenco

comment created time in 22 days

issue commentgolang/go

x/pkgsite: some code examples are not displayed (but work at godoc.org)

Thanks for reporting.

I tested this package at commit https://github.com/go-pg/pg/commit/6fe164e2d690b7e22a4787f5d40d5dd93fc2e5e3 with pkg.go.dev, godoc.org, and x/tools/cmd/godoc, and can confirm the issue is present in pkg.go.dev and x/tools/cmd/godoc, but not godoc.org.

It's also helpful to look at the complete listing of examples at https://godoc.org/github.com/go-pg/pg?tab=doc#pkg-examples, https://pkg.go.dev/github.com/go-pg/pg/v10?tab=doc#pkg-examples, and the output of x/tools/cmd/godoc:

image

This looks like a valid issue. It needs investigation to understand why these examples, which appear to be following the example naming convention correctly, are not showing up in 2 out of 3 documentation viewers. It might be a problem in the example matching logic in go/doc package, or at a higher level. Once we understand why this is happening, it'll be easier to figure out how to fix this.

/cc @julieqiu @shaqque

vmihailenco

comment created time in 22 days

issue commentgolang/go

missing function body - x/tools/go/ssa/interp/testdata/src/os/os.go:3:6

I would help if you provided a higher level overview of the problem, not the exact specifics. Can you please answer these these questions:

  1. Is there a snippet we can run to reproduce the problem?

  2. Does the problem still happen if you remove the -gcflags "all=-N -l" flag, or does it only happen when that's used?

  3. Is your code importing the golang.org/x/tools/go/ssa/interp/testdata/src/os package? If not, do you know where it's coming from?

Thanks.

DIYCardSecurity

comment created time in 24 days

push eventshurcooL/events

Dmitri Shuralyov

commit sha e83751ac5ad857636323b1fde113c50b5d745913

fs: document possible types of eventDisk.Payload field To improve clarity.

view details

push time in 24 days

push eventshurcooL/git-branches

Dmitri Shuralyov

commit sha 8e7ff6fb0c4eb6c9eb6245e64aa71bd28aebda3f

.travis.yml: use go vet instead of go tool vet As of Go 1.12, go tool vet is no longer supported.¹ Start using the go vet command instead. Use RCS format for gofmt diff. It results in cleaner, easier to read gofmt diffs. ¹ https://golang.org/doc/go1.12#vet

view details

push time in 24 days

issue commentgolang/go

net/http: Re-connect with upgraded HTTP2 connection fails to send Request.body [1.13 backport]

@rsc This backport has been approved for 1.14 and 1.13. It applies cleanly to 1.14, but not 1.13. Since you authored the original CL, would you like to resolve the conflict and send a cherry-pick CL to release-branch.go1.13?

gopherbot

comment created time in 25 days

issue commentgolang/go

x/crypto/acme: Retry on LetsEncrypt rate limit

/cc @FiloSottile @x1ddos per owners.

leesjensen

comment created time in 25 days

issue commentgolang/go

x/sys/windows/svc/example: does not start

/cc @alexbrainman @bradfitz per owners.

macklin-10x

comment created time in 25 days

more