-
Notifications
You must be signed in to change notification settings - Fork 17.9k
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/tools/go/analysis/unitchecker: test fail with "illegal byte sequence" (EILSEQ) #65550
Comments
Found new dashboard test flakes for:
2024-02-03 21:27 x_tools-go1.22-darwin-amd64_12 tools@a1fbc781 release-branch.go1.22@b0957cfc x/tools/go/analysis/unitchecker.TestExampleSeparateAnalysis (log)
|
This string is perror(EILSEQ), which is an errno that is never generated by the Go program, so it must be coming from macOS. The line number of the failure is a call to packagestest.Export, which means the real failure has been obscured by a not-so-helpful call to testing.T.Helper. Looking at all the calls to t.Fatal or t.Error within Export, most are related to os.Mkdir. Hypothesis: we're attempting to create a directory entry that isn't a valid textual name, and macOS has forgotten that it's a UNIX and file names are just byte strings. Experiment: package main
import (
"log"
"os"
)
func main() {
if err := os.Mkdir("ab\xff", 0755); err != nil {
log.Fatal(err)
}
} Result: $ go run a.go
2024/02/09 17:37:39 mkdir ab?: illegal byte sequence
exit status 1 But where are the non-textual strings coming from in the failing test? All the file system operations (Mkdir, WriteFile, etc) seem to derive the filename from either the testing.T.Name, or the test's tempdir, both of which must be valid text strings. |
Oh, it seems that hundreds of tests are failing for the same reason: |
This might be a part of #65461 (comment). I'm seeing only one watchflake report here (https://ci.chromium.org/b/8757079028780343489), and the bot it ran on is showing up as last seen 3 days 4 hours ago, the same timeline as another bot mentioned in #65461 (comment). I think https://go.dev/cl/562399 (CC @prattmic) is expected to help with this in the future. |
Given |
Issue created automatically to collect these failures.
Example (log):
— watchflakes
The text was updated successfully, but these errors were encountered: