-
Notifications
You must be signed in to change notification settings - Fork 4.4k
Description
Description of the problem / feature request:
Several rules_go tests that run bazel coverage are failing with Bazel 0.27.0. They pass with 0.26.1, and there haven't been any recent changes to rules_go coverage functionality.
https://buildkite.com/bazel/rules-go-golang/builds/1197#7fba7969-7a88-4201-b0a4-8982d9ebf8d0 is set of test results for an unrelated change. It looks like this is also failing on the "Bazel@HEAD + Downstream" pipeline.
The failures include a lot of bash debugging lines (running with -x?). I think this is the relevant part.
+ BULK_COVERAGE_RUN=1
+ for name in '"$LCOV_MERGER"'
+ [[ ! -e '' ]]
+ echo --
--
+ echo Coverage runner: cannot locate file
Coverage runner: cannot locate file
I'm not sure what file is missing, but something to do with LCOV_MERGER maybe?
Bugs: what's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
git clone https://github.com/bazelbuild/rules_go
cd rules_go
bazel coverage //tests/core/coverage:coverage_test
What operating system are you running Bazel on?
macOS 10.14.5
Tests are failing on all platforms though.
What's the output of bazel info release?
release 0.27.0
Have you found anything relevant by searching the web?
#7529 has the same error message, but I'm not sure if it's related.
bazel-contrib/rules_go#2100 is corresponding issue in rules_go.
Any other information, logs, or outputs that you want to share?
rules_go coverage support is not completely integrated with Bazel coverage. We use the information exposed to Starlark rules by bazel coverage in order to add coverage instrumentation to sources that need it. However, the coverage data file is written in Go's format (not lcov) so that Go tools can analyze it.
Tests do write to the file named by COVERAGE_OUTPUT_FILE, and I've verified that such a file is written by manually running a test binary built with coverage. So I don't think that's the missing file.