Skip to content

fix: make coverage work with bootstrap=script #2574

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

Merged
merged 4 commits into from
Jan 23, 2025

Conversation

rickeylev
Copy link
Collaborator

The script based bootstrap wasn't expanding the coverage template variable, which prevented
coverage from activating. This was introduced when it was switched to the venv layout.

To fix, expand the %coverage_tool% template variable as done elsewhere.

Tested manually, per repro instructions in #2572. While I did devise a way to mostly
test this without an integration test, it was thwarted by some other bugs.

Along the way, improve some of the bootstrap debug output and fix a comment.

Fixes #2572

@rickeylev rickeylev requested a review from aignas as a code owner January 23, 2025 04:54
@aignas aignas added this pull request to the merge queue Jan 23, 2025
Merged via the queue into bazel-contrib:main with commit ea716fe Jan 23, 2025
4 checks passed
@rickeylev rickeylev deleted the fix.bootstrap.coverage branch January 24, 2025 17:10
ewianda pushed a commit to ewianda/rules_python that referenced this pull request Jan 25, 2025
The script based bootstrap wasn't expanding the coverage template
variable, which prevented
coverage from activating. This was introduced when it was switched to
the venv layout.

To fix, expand the `%coverage_tool%` template variable as done
elsewhere.

Tested manually, per repro instructions in bazel-contrib#2572. While I did devise a
way to mostly
test this without an integration test, it was thwarted by some other
bugs.

Along the way, improve some of the bootstrap debug output and fix a
comment.

Fixes bazel-contrib#2572
ewianda pushed a commit to ewianda/rules_python that referenced this pull request Jan 25, 2025
The script based bootstrap wasn't expanding the coverage template
variable, which prevented
coverage from activating. This was introduced when it was switched to
the venv layout.

To fix, expand the `%coverage_tool%` template variable as done
elsewhere.

Tested manually, per repro instructions in bazel-contrib#2572. While I did devise a
way to mostly
test this without an integration test, it was thwarted by some other
bugs.

Along the way, improve some of the bootstrap debug output and fix a
comment.

Fixes bazel-contrib#2572
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

bug: Coverage Report Shows no valid records found with bootstrap_impl=script
2 participants