-
-
Notifications
You must be signed in to change notification settings - Fork 15k
Check submodule commit provenance in CI #75109
Copy link
Copy link
Open
Labels
C-enhancementCategory: An issue proposing an enhancement or a PR with one.Category: An issue proposing an enhancement or a PR with one.T-infraRelevant to the infrastructure team, which will review and decide on the PR/issue.Relevant to the infrastructure team, which will review and decide on the PR/issue.
Description
Metadata
Metadata
Assignees
Labels
C-enhancementCategory: An issue proposing an enhancement or a PR with one.Category: An issue proposing an enhancement or a PR with one.T-infraRelevant to the infrastructure team, which will review and decide on the PR/issue.Relevant to the infrastructure team, which will review and decide on the PR/issue.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Currently, when any changes are made to a submodule in the Rust repository, rustbot adds a warning comment but it's up to the reviewer to check all the changes.
One of the things that should always be true of a submodule commit (at merge time in the Rust repo) is that it should already be merged in an upstream branch. This can be checked in an automated fashion during CI by checking the commit against a set of allowed remote branches.
If this is not checked, something that might happen is that an author simultaneously makes an upstream and Rust PR with one commit. Later, the author (force) pushes another commit to the same upstream PR but forgets to update the Rust submodule. The original commit will at some point be garbage-collected by GitHub and merging the Rust PR would be bad because the complete source code would not be accessible in git in the future. This happened in #75009.
This check should not be done for try builds, so that development can continue unimpeded.
@rustbot modify labels: +C-enhancement +T-infra