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

Do not rerun module extensions when only imports or locations change #19253

Closed

Conversation

fmeum
Copy link
Collaborator

@fmeum fmeum commented Aug 15, 2023

When using the lockfile, extension evaluation results are now persisted even if the imports (use_repos) fail validation against the actually generated repos and reused if only imports or Starlark locations change.

This requires storing ModuleExtensionMetadata in the lockfile to ensure that the correct fixup warnings are shown if imports are updated but the extension isn't rerun.

When using the lockfile, extension evaluation results are now persisted
even if the imports (`use_repo`s) fail validation against the actually
generated repos and reused if only imports or Starlark locations change.

This requires storing `ModuleExtensionMetadata` in the lockfile to
ensure that the correct fixup warnings are shown if imports are updated
but the extension isn't rerun.
@github-actions github-actions bot added awaiting-review PR is awaiting review from an assigned reviewer team-ExternalDeps External dependency handling, remote repositiories, WORKSPACE file. labels Aug 15, 2023
Copy link
Member

@Wyverald Wyverald left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

overall looks great. thank you for the prompt PR!

@fmeum fmeum force-pushed the persist-module-extension-metadata branch from 8af9d6e to 1614884 Compare August 16, 2023 20:52
@fmeum fmeum requested a review from Wyverald August 16, 2023 20:57
@Wyverald Wyverald added awaiting-PR-merge PR has been approved by a reviewer and is ready to be merge internally and removed awaiting-review PR is awaiting review from an assigned reviewer labels Aug 16, 2023
@github-actions github-actions bot removed the awaiting-PR-merge PR has been approved by a reviewer and is ready to be merge internally label Aug 17, 2023
@fmeum fmeum deleted the persist-module-extension-metadata branch August 17, 2023 18:58
@fmeum
Copy link
Collaborator Author

fmeum commented Aug 17, 2023

@bazel-io flag

@bazel-io bazel-io added the potential release blocker Flagged by community members using "@bazel-io flag". Should be added to a release blocker milestone label Aug 17, 2023
@meteorcloudy
Copy link
Member

@bazel-io fork 6.4.0

@bazel-io bazel-io removed the potential release blocker Flagged by community members using "@bazel-io flag". Should be added to a release blocker milestone label Aug 18, 2023
iancha1992 pushed a commit to iancha1992/bazel that referenced this pull request Aug 18, 2023
When using the lockfile, extension evaluation results are now persisted even if the imports (`use_repo`s) fail validation against the actually generated repos and reused if only imports or Starlark locations change.

This requires storing `ModuleExtensionMetadata` in the lockfile to ensure that the correct fixup warnings are shown if imports are updated but the extension isn't rerun.

Closes bazelbuild#19253.

PiperOrigin-RevId: 557878432
Change-Id: I25909294b118fb445f9c48f61e18463762f78208
iancha1992 added a commit that referenced this pull request Aug 22, 2023
… change (#19284)

When using the lockfile, extension evaluation results are now persisted
even if the imports (`use_repo`s) fail validation against the actually
generated repos and reused if only imports or Starlark locations change.

This requires storing `ModuleExtensionMetadata` in the lockfile to
ensure that the correct fixup warnings are shown if imports are updated
but the extension isn't rerun.

Closes #19253.

Commit
2c2b07b

PiperOrigin-RevId: 557878432
Change-Id: I25909294b118fb445f9c48f61e18463762f78208

Co-authored-by: Fabian Meumertzheim <fabian@meumertzhe.im>
@iancha1992
Copy link
Member

The changes in this PR have been included in Bazel 6.4.0 RC1. Please test out the release candidate and report any issues as soon as possible. If you're using Bazelisk, you can point to the latest RC by setting USE_BAZEL_VERSION=last_rc.
Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
team-ExternalDeps External dependency handling, remote repositiories, WORKSPACE file.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants