Skip to content

When the CI fails to port language-reference-stable to main, we are not notified #16238

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

Closed
bishabosha opened this issue Oct 24, 2022 · 5 comments

Comments

@bishabosha
Copy link
Member

e.g. #16230 - see action https://github.com/lampepfl/dotty/actions/runs/3312284921

the CI keeps failing because of git conflicts - either the command should change to never have conflicts - or some issue should be generated automatically if it fails.

@Sporarum
Copy link
Contributor

Sporarum commented Oct 24, 2022

The way I see it, there are two problems:

  • The CI always fails (to port language-reference-stable)
  • When the CI fails (to port language-reference-stable), we are not notified

CI always fails

The CI tries to port the changes from language-reference-stable to main by doing a merge, which always fails.

The reason the merge doesn't work is because the files have to be different.
For example, compare the header of derivation.md in main and in language-reference-stable.
But at the same time those two branches are meant to contain the exact same content modulo header at every release, so it's not a simple case of one branch being ahead of the other.
(I believe there is no other way in which they should differ)

There are therefore two ways to propagate changes from one to the other:

  • use rebase --onto to specifically port changes after the initial split (or even a more recent commit)
  • use merge, this requires that we modify the way the headers are handled so that the .md files can be the same on both branches

My opinion is that the second option is cleaner, and probably technically easier, even if it creates potentially a bit more boilerplate in the CI

CI fails silently

It is very likely this can be solved by changing the github action, I will look into how to do it

@julienrf
Copy link
Contributor

But at the same time those two branches are meant to contain the exact same content modulo header at every release, so it's not a simple case of one branch being ahead of the other.

Does that mean that we should cherry pick the commits instead of trying to merge a branch into another? If this is the case, then I guess this is what the rebase --onto solution does, so I think that should be the solution. What do you think?

@Sporarum
Copy link
Contributor

The problem with cherry pick / rebase is that if we accidentally drop a commit once, we'll potentially never see the discrepancy

The benefit of merge is that we can be 100% sure two files are identical

@Sporarum
Copy link
Contributor

After discussion we realized the split between those two branches was not necessary
So we will merge language-reference-stable onto master, and solve the conflicts, at which point, there should not be any more conflicts

There still needs to be a system to automatically create issues in case of failure, this will come a bit later

bishabosha added a commit that referenced this issue Oct 25, 2022
This solves all merge conflicts between `language-reference-stable` and
`main`
Solves the first part of #16238
@julienrf julienrf changed the title CI can't port language-reference-stable back to main When the CI fails to port language-reference-stable to main, we are not notified Oct 27, 2022
@Kordyjan
Copy link
Contributor

Kordyjan commented Dec 5, 2022

I think it is resolved by #16364

@Kordyjan Kordyjan closed this as completed Dec 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants