-
Notifications
You must be signed in to change notification settings - Fork 22
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
error generating coverage report #46
Comments
Thanks, yes there seems to be some issues with Go 1.20 onwards. Even CI fails with 1.20. I need to spend some time to take a look. We also need to bump the version in go.mod file. cc @JohnStarich in case you want to take a look. |
This appears to be caused by design/51430-revamp-code-coverage Here's the location the stat call occurs: Passing an env |
Nice catch! Looks like we need to do a bit of work to support |
Looked into what it would take to support this. As it turns out, it is much larger than just The new coverage code is accessing I was thinking of other options, like the native filesystem api, but came across your comment forwarding all file-system calls to the webserver so I'm now thinking that as well. If you have not already started on the forwarding fs calls route, I can take a look at it. |
Thanks for digging deep. Yes, the fs API forwarding to the webserver would be a much more robust solution. This would also finally unblock any filesystem read/write related tests, which would fix golang/go#26051! |
Dug a bit deeper, ended up digging a tunnel, then found the light at the end of it. 😃 I have not tested this extensively but it appears to be fairly solid. I'll add more to it in the next few days but wanted to share it for whoever is interested. It definitely needs more testing on non-unix platforms. |
This is awesome, thanks @mlctrez! |
First off 😎 thanks for your work on this!
When a recent version of go I'm getting an error when generating code coverage:
error generating coverage report: output directory "/tmp/go-build888418937/b001/gocoverdir" inaccessible (err: stat /tmp/go-build888418937/b001/gocoverdir: not implemented on js); no coverage data written
go test .
works with later versions of go but breaks when adding-cover
This repository contains my test case wbtexample
When running with
go1.18.4
there are no errors.shell script
When running with
go1.20.7
I get theerror generating coverage
.shell script
I've added logging statements in
github.com/agnivade/wasmbrowsertest
and have tracked it down to a non-zero exit code at main.goI'm using google chrome 116.0.5845.96 on Ubuntu 22.04.3 LTS if that matters.
The text was updated successfully, but these errors were encountered: