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/net/nettest: TestTestConn failures on darwin/amd64 10.14 and 10.15 #54416

Closed
thanm opened this issue Aug 12, 2022 · 2 comments
Closed

x/net/nettest: TestTestConn failures on darwin/amd64 10.14 and 10.15 #54416

thanm opened this issue Aug 12, 2022 · 2 comments
Labels
FrozenDueToAge NeedsFix The path to resolution is known, but the work has not been done.
Milestone

Comments

@thanm
Copy link
Contributor

thanm commented Aug 12, 2022

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

Tip:

$ go version
go version devel go1.20-a01c0615ac Tue Aug 9 17:17:36 2022 -0400 linux/amd64

Does this issue reproduce with the latest release?

yes

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

This problem is happening on the darwin 10.14 and 10.15 builders.

What did you do?

Observing the x/net builders on master, e.g.

https://build.golang.org/?repo=golang.org%2fx%2fnet

What did you expect to see?

Clean test run.

What did you see instead?

Failures on tip starting roughly around Jul 29th, with this CL:

--- FAIL: TestTestConn (0.39s)
    --- FAIL: TestTestConn/UnixPipe (0.00s)
        --- FAIL: TestTestConn/UnixPipe/BasicIO (0.00s)
            conntest.go:32: unable to make pipe: listen unix /var/folders/9w/4l2_g3kx01x199n37fbmv3s80000gn/T/workdir-host-darwin-amd64-10_14/tmp/go-nettest2500457411: bind: invalid argument
        --- FAIL: TestTestConn/UnixPipe/PingPong (0.00s)
            conntest.go:33: unable to make pipe: listen unix /var/folders/9w/4l2_g3kx01x199n37fbmv3s80000gn/T/workdir-host-darwin-amd64-10_14/tmp/go-nettest3341344823: bind: invalid argument
        --- FAIL: TestTestConn/UnixPipe/RacyRead (0.00s)
            conntest.go:34: unable to make pipe: listen unix /var/folders/9w/4l2_g3kx01x199n37fbmv3s80000gn/T/workdir-host-darwin-amd64-10_14/tmp/go-nettest3959584814: bind: invalid argument
        --- FAIL: TestTestConn/UnixPipe/RacyWrite (0.00s)
            conntest.go:35: unable to make pipe: listen unix /var/folders/9w/4l2_g3kx01x199n37fbmv3s80000gn/T/workdir-host-darwin-amd64-10_14/tmp/go-nettest4015806942: bind: invalid argument
        --- FAIL: TestTestConn/UnixPipe/ReadTimeout (0.00s)
            conntest.go:36: unable to make pipe: listen unix /var/folders/9w/4l2_g3kx01x199n37fbmv3s80000gn/T/workdir-host-darwin-amd64-10_14/tmp/go-nettest1918107250: bind: invalid argument
        --- FAIL: TestTestConn/UnixPipe/WriteTimeout (0.00s)
            conntest.go:37: unable to make pipe: listen unix /var/folders/9w/4l2_g3kx01x199n37fbmv3s80000gn/T/workdir-host-darwin-amd64-10_14/tmp/go-nettest2002287673: bind: invalid argument
        --- FAIL: TestTestConn/UnixPipe/PastTimeout (0.00s)
            conntest.go:38: unable to make pipe: listen unix /var/folders/9w/4l2_g3kx01x199n37fbmv3s80000gn/T/workdir-host-darwin-amd64-10_14/tmp/go-nettest1774460758: bind: invalid argument
        --- FAIL: TestTestConn/UnixPipe/PresentTimeout (0.00s)
            conntest.go:39: unable to make pipe: listen unix /var/folders/9w/4l2_g3kx01x199n37fbmv3s80000gn/T/workdir-host-darwin-amd64-10_14/tmp/go-nettest1680921935: bind: invalid argument
        --- FAIL: TestTestConn/UnixPipe/FutureTimeout (0.00s)
            conntest.go:40: unable to make pipe: listen unix /var/folders/9w/4l2_g3kx01x199n37fbmv3s80000gn/T/workdir-host-darwin-amd64-10_14/tmp/go-nettest1461741292: bind: invalid argument
        --- FAIL: TestTestConn/UnixPipe/CloseTimeout (0.00s)
            conntest.go:41: unable to make pipe: listen unix /var/folders/9w/4l2_g3kx01x199n37fbmv3s80000gn/T/workdir-host-darwin-amd64-10_14/tmp/go-nettest2686621345: bind: invalid argument
        --- FAIL: TestTestConn/UnixPipe/ConcurrentMethods (0.00s)
            conntest.go:42: unable to make pipe: listen unix /var/folders/9w/4l2_g3kx01x199n37fbmv3s80000gn/T/workdir-host-darwin-amd64-10_14/tmp/go-nettest1138137921: bind: invalid argument
FAIL
FAIL	golang.org/x/net/nettest	0.397s

The odd thing is that these tests passed with slowbots on the CL itself, and also continue to fail when a revert is sent (e.g. CL 423274). This is leading to the theory that there may have been some sort of change to the builders around the same time.

Note sure who would be the best person to dig into this.

@golang/release @neild @ianlancetaylor

@gopherbot gopherbot added this to the Unreleased milestone Aug 12, 2022
@thanm thanm added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Aug 12, 2022
@rsc
Copy link
Contributor

rsc commented Aug 12, 2022

/var/folders/9w/4l2_g3kx01x199n37fbmv3s80000gn/T/workdir-host-darwin-amd64-10_14/tmp/go-nettest2500457411 is 105 bytes long, but Unix domain socket paths are limited to 104 bytes.

This was probably caused by putting "amd64-" in the host name, which appears in the file path.
(That and the fact that the default $TMPDIR on Macs, which is where workdir lives, is not something short like /tmp.)

@gopherbot
Copy link
Contributor

Change https://go.dev/cl/423039 mentions this issue: nettest: fix Unix socket test on macOS

@dmitshur dmitshur added NeedsFix The path to resolution is known, but the work has not been done. and removed NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. labels Aug 12, 2022
@dmitshur dmitshur changed the title x/net: TestTestConn failures on darwin/amd64 10.14 and 10.15 x/net/nettest: TestTestConn failures on darwin/amd64 10.14 and 10.15 Oct 4, 2022
WeiminShang added a commit to WeiminShang/net that referenced this issue Nov 16, 2022
The macOS temp directory name is so long that it makes for
socket names that are far too long.

Fixes golang/go#54416.

Change-Id: Id09cb5af6122227132a9be1e8101ce3450af09e5
Reviewed-on: https://go-review.googlesource.com/c/net/+/423039
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Auto-Submit: Russ Cox <rsc@golang.org>
Run-TryBot: Russ Cox <rsc@golang.org>
@golang golang locked and limited conversation to collaborators Oct 4, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge NeedsFix The path to resolution is known, but the work has not been done.
Projects
None yet
Development

No branches or pull requests

4 participants