Skip to content
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

Use bazel info workspace to get workspace, check for MODULE.bazel #9445

Merged
merged 1 commit into from
Jul 31, 2024

Conversation

aran
Copy link
Contributor

@aran aran commented Jun 13, 2024

Fixes: #9444
Related: #9320, #9319
Merge before/after:

Description

  1. Outsource bazel root detection to bazel info workspace
  2. Allow multiple files to be declared as the Bazel root file, adding any found to deps. (1 chosen file now can be a set of several)
  3. Update tests, which required separating the negative test from the positives.

Also tested on my actual repro to make sure it eliminated the very mysterious errors I was running into this morning :)

@aran aran force-pushed the MODULE.bazel branch 2 times, most recently from 5dfea4b to 6c56b17 Compare June 13, 2024 21:11
@aran aran marked this pull request as draft June 13, 2024 23:15
@renzodavid9 renzodavid9 added the kokoro:force-run forces a kokoro re-run on a PR label Jun 19, 2024
@kokoro-team kokoro-team removed the kokoro:force-run forces a kokoro re-run on a PR label Jun 19, 2024
Use bazel logic to determine bazel workspace root
and ensure MODULE.bazel is added as a dep to
Bazel targets if it is present.
Copy link

codecov bot commented Jun 19, 2024

Codecov Report

Attention: Patch coverage is 73.07692% with 7 lines in your changes missing coverage. Please review.

Project coverage is 63.13%. Comparing base (290280e) to head (f7dad74).
Report is 1160 commits behind head on main.

Files Patch % Lines
pkg/skaffold/build/bazel/dependencies.go 73.07% 4 Missing and 3 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #9445      +/-   ##
==========================================
- Coverage   70.48%   63.13%   -7.36%     
==========================================
  Files         515      645     +130     
  Lines       23150    33183   +10033     
==========================================
+ Hits        16317    20949    +4632     
- Misses       5776    10612    +4836     
- Partials     1057     1622     +565     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@aran aran marked this pull request as ready for review June 19, 2024 17:06
@renzodavid9 renzodavid9 self-requested a review June 26, 2024 17:09
@renzodavid9 renzodavid9 merged commit d3902b1 into GoogleContainerTools:main Jul 31, 2024
13 checks passed
@aran aran deleted the MODULE.bazel branch August 28, 2024 17:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

bazel: Changes to MODULE.bazel may be missed, causing incorrect results
3 participants