fix: Modified incarnation report deletion conflict - #626
Merged
Conversation
foxops silently drops template deletions of locally-modified files If a file was edited in an incarnation and later deleted in the template, FoxOps keeps the local copy and never flags it as a conflict (not even inside a ":construction: CONFLICT" MR) It only surfaces modify/modify conflicts; modify/delete losses are silent. Result: clusters stay on versions that already removed a file, yet still carry it. This is a problem, as it leads to a drift. This fixes it by: - increasing the test coverage to guarantee that incaranation modified files are triggering a conflict upon their template's deletion - engine is raising the right signal in git diff patch. Here is an example of the git apply --reject for an updated file that got deleted in a template: ``` $ git apply --reject ../patch Checking patch README.md... error: while searching for: CONTENT error: patch failed: README.md:1 error: removal patch leaves file contents error: README.md: patch does not apply Checking patch todo... Applied patch todo cleanly. ``` Which you can see the new "patch does not apply" line. This works as git version 2.55. However, this does NOT update the function to be more resilient to any future git operation message change. Signed-off-by: Jean-Philippe Evrard <jean-philippe.evrard+rochepub@external.roche.com>
Contributor
Author
|
@defreng you should have a look at this before continuing, to check if it all makes sense. |
evrardj-roche
marked this pull request as ready for review
August 20, 2026 12:20
Contributor
Author
|
WARNING: The second commit (e2e test) was AI generated. |
Contributor
Author
|
Retriggered CI. |
Contributor
Author
|
Retriggering CI |
Contributor
Author
|
yay, no issue on this run! Can you review this @defreng ? |
Contributor
Author
|
@o1da can you review and merge this? |
o1da
approved these changes
Aug 27, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
foxops silently drops template deletions of locally-modified files If a file was edited in an incarnation and later deleted in the template:
FoxOps keeps the local copy and never flags it as a conflict, (not even inside a ":construction: CONFLICT" MR)
It only surfaces modify/modify conflicts; modify/delete losses are silent. Result: clusters stay on versions that already removed a file, yet still carry it.
This is a problem, as it leads to a drift.
This fixes it by:
Here is an example of the git apply --reject for an updated file that got deleted in a template:
Which you can see the new "patch does not apply" line. This works as git version 2.55.
However, this does NOT update the function to be more resilient to any future git operation message change.