We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
go version
$ go version go version go1.16rc1 darwin/arm64
Yes (& it uses io/fs).
go env
$ go env GO111MODULE="" GOARCH="arm64" GOBIN="/Users/kr/bin" GOCACHE="/Users/kr/Library/Caches/go-build" GOENV="/Users/kr/Library/Application Support/go/env" GOEXE="" GOFLAGS="" GOHOSTARCH="arm64" GOHOSTOS="darwin" GOINSECURE="" GOMODCACHE="/Users/kr/lib/go/pkg/mod" GONOPROXY="" GONOSUMDB="" GOOS="darwin" GOPATH="/Users/kr/lib/go" GOPRIVATE="" GOPROXY="https://proxy.golang.org,direct" GOROOT="/usr/local/go" GOSUMDB="sum.golang.org" GOTMPDIR="" GOTOOLDIR="/usr/local/go/pkg/tool/darwin_arm64" GOVCS="" GOVERSION="go1.16rc1" GCCGO="gccgo" AR="ar" CC="clang" CXX="clang++" CGO_ENABLED="1" GOMOD="/dev/null" CGO_CFLAGS="-g -O2" CGO_CPPFLAGS="" CGO_CXXFLAGS="-g -O2" CGO_FFLAGS="-g -O2" CGO_LDFLAGS="-g -O2" PKG_CONFIG="pkg-config" GOGCCFLAGS="-fPIC -arch arm64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/m7/5qgxb_bd5yd4b7h7w7xthmh00000gn/T/go-build4121125842=/tmp/go-build -gno-record-gcc-switches -fno-common"
Ran this program with go run stat_test.go.
go run stat_test.go
https://gist.github.com/kr/a337f4a7bda21d44048d7d83d52e5456
(It doesn't compile on play.golang.org because it needs 1.6rc1).
FileInfo, same as from os.Stat(runtime.GOROOT()) in the commented line in the testcase gist linked above.
os.Stat(runtime.GOROOT())
open /usr/local/go: invalid argument
The text was updated successfully, but these errors were encountered:
runtime.GOROOT() returns an absolute path which isn't valid for fs.Fs https://tip.golang.org/pkg/io/fs/#ValidPath
runtime.GOROOT()
fs.Fs
see also #44286
Sorry, something went wrong.
Oh, my bad, thanks. Sorry for the noise!
No branches or pull requests
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes (& it uses io/fs).
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
Ran this program with
go run stat_test.go
.https://gist.github.com/kr/a337f4a7bda21d44048d7d83d52e5456
(It doesn't compile on play.golang.org because it needs 1.6rc1).
What did you expect to see?
FileInfo, same as from
os.Stat(runtime.GOROOT())
in the commented line in the testcase gist linked above.What did you see instead?
The text was updated successfully, but these errors were encountered: