-
Notifications
You must be signed in to change notification settings - Fork 271
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
[ci] Should git-subrepo commits be squashed/in side-history? #1190
Comments
Sorry, I'm still trying to wrap my head around how this works. So I understand that, whenever we make a change in aztec-packages to the docs folder in master (example here), then the CI automatically pushes the changes to the aztec/docs repo (here), and then pushes a new commit in aztec-packages that modifies the subrepo file (this one) to reflect the new commit on the docs repo. Is this correct? And the commit we're trying to eliminate is the third one, ie the one that bumps the revision in the git-subrepo file in aztec-packages? I'm personally not too annoyed by this extra commit, but to be honest I don't understand the side-history approach. As for the squash option, that seems pretty clean. While I'm usually against having the CI rewriting commits (it sucks to push a commit and then immediately see it diverge), this would only affect master, which we should never be pushing to directly. Though I'm not sure how to avoid the duplicate CI run, maybe we can detect it was a force-push with that change and skip the run..? |
Yes, the commit updates some bookkeeping so it knows what commits to replay in the future.
Yes. If we had a few of these, it could add up, too (I guess at least those could be squashed together somehow? would need to be one mirror action). |
The side history approach: There's some branch we reference with this file updated, and we merge those locally basically only if they're newer. It works (I have it prototyped) but it feels finnicky, especially it complicates a history rewinding workflow |
It's a bit icky - we want the CI associated with the new commit hash. I'm also not sure what happens if multiple commits happen in succession (although a merge queue would protect against this) |
I guess it'd be ideal if we could intercept a PR immediately before it gets merged, so we run these actions then. But failing that, I'd vote for option 1 (doing nothing) as it seems to be the less magical one. No strong feelings though, you have the best context here and I trust your judgement if you think 2 or 3 is better. |
I've come to like the explicit commits showing me subrepo action. At least from my POV it keeps me confident the mechanisms are working. Closing until complaints. |
Git subrepo requires tracking commits whenever you push to the other repo (in our case, mirror repos). For barretenberg and docs, a new git subrepo commit is made in master currently. This is straight forward, but perhaps not ideal in that 1. it introduces history noise 2. it commits to master, bypassing branch rules
Options:
Pros are it could be cleanest, could roll back aztec bot bypass permissions, and cons it is the most complex/surprising.
The text was updated successfully, but these errors were encountered: