Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x/build/cmd/release: TestScript/test_race_install_cgo and TestDWARF fail for -target=windows-amd64, and just TestDWARF fails for -target=windows-386 #39478

Closed
dmitshur opened this issue Jun 9, 2020 · 3 comments

Comments

@dmitshur
Copy link
Member

@dmitshur dmitshur commented Jun 9, 2020

This is an issue for a specific test. See #39386 for the high level tracking issue.

This can be reproduced if your account has permissions needed to run releasebot (documented here) with:

$ release -target=windows-amd64 -version=go1.15beta1 -watch -rev=cacac8bdc5c93e7bc71df71981fdf32dded017bf
[...]
go test proxy running at GOPROXY=http://127.0.0.1:50986/mod
go proxy: no archive rsc.io v1.5.2: 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 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.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.5.1: file does not exist
go proxy: no archive example.com/newcycle v1.0.0: file does not exist
go proxy: no archive test.go v1.0.0: file does not exist
go proxy: no archive rsc.io v1.5.2: file does not exist
--- FAIL: TestScript (0.01s)
    --- FAIL: TestScript/test_race_install_cgo (1.21s)
        script_test.go:210: 
            # Tests Issue #10500 (1.209s)
            > [!race] skip
            > [!darwin] ! stale cmd/cgo  # The darwin builders are spuriously stale; see #33598.
            FAIL: testdata\script\test_race_install_cgo.txt:5: cmd/cgo is unexpectedly stale
            
            
FAIL
FAIL	cmd/go	111.443s
[...]
--- FAIL: TestDWARF (1.62s)
    dwarf_test.go:39: cmd/link is stale - run go install cmd/link
FAIL
FAIL	cmd/link	19.749s
[...]
FAIL
go tool dist: Failed: exit status 1

And:

$ release -target=windows-386 -version=go1.15beta1 -watch -rev=cacac8bdc5c93e7bc71df71981fdf32dded017bf
[...]
--- FAIL: TestDWARF (1.28s)
    dwarf_test.go:39: cmd/link is stale - run go install cmd/link
FAIL
FAIL	cmd/link	25.084s
[...]
FAIL
go tool dist: Failed: exit status 1

@bcmills I've made you an assignee on this issue based on #39386 (comment) but please let us know if you can't keep looking into this. Thank you.

/cc @toothrot @cagedmantis @andybons @golang/osp-team

@bcmills
Copy link
Member

@bcmills bcmills commented Jun 10, 2020

I am able to reproduce the error using run.bat, but not using ..\bin\go test cmd/link. That suggest to me that cmd/dist is performing some other modification to the environment that is breaking the test. I'm still trying to figure out what.

@bcmills
Copy link
Member

@bcmills bcmills commented Jun 10, 2020

Oh, there's the trouble. The bogus “unset GOROOT_FINAL” logic from cmd/dist is for some reason duplicated in run.bat. Fix incoming.

go/src/run.bat

Lines 38 to 41 in b9332ed

:: we must unset GOROOT_FINAL before tests, because runtime/debug requires
:: correct access to source code, so if we have GOROOT_FINAL in effect,
:: at least runtime/debug test will fail.
set GOROOT_FINAL=

@gopherbot
Copy link

@gopherbot gopherbot commented Jun 10, 2020

Change https://golang.org/cl/237359 mentions this issue: run.bat: do not unset GOROOT_FINAL before running tests

@gopherbot gopherbot closed this in 2a4e71c Jun 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.