gitbutler icon indicating copy to clipboard operation
gitbutler copied to clipboard

Better handling of merge-conflicts in workspace commit creation upon commit

Open Byron opened this issue 7 months ago • 2 comments

When a commit fails due to conflicts when re-merging the workspace commit, right now we see this (as originally reported on Discord.

Image
command: create_commit_from_worktree_changes
params: {"projectId":"50fb464e-00e2-4744-9870-c92df0cfb84d","stackId":"5a0502ec-b843-492a-98a9-8aef91134503","message":"HM scorm token overrides","stackBranchName":"uk/hm-scorm-token-overrides","worktreeChanges":[{"pathBytes":[103,114,97,100,108,101,45,112,114,111,106,101,99,116,45,114,111,111,116,47,99,111,109,109,111,110,47,115,114,99,47,109,97,105,110,47,107,111,116,108,105,110,47,99,111,109,47,115,97,110,97,108,97,98,115,47,99,111,109,109,111,110,47,100,111,109,97,105,110,47,79,114,103,97,110,105,122,97,116,105,111,110,73,100,46,107,116],"hunkHeaders":[]},{"pathBytes":[103,114,97,100,108,101,45,112,114,111,106,101,99,116,45,114,111,111,116,47,99,111,114,101,47,115,114,99,47,109,97,105,110,47,107,111,116,108,105,110,47,99,111,109,47,115,97,110,97,108,97,98,115,47,99,111,114,101,47,115,99,111,114,109,47,83,99,111,114,109,80,114,111,118,105,100,101,114,67,111,110,116,114,111,108,108,101,114,46,107,116],"hunkHeaders":[]}]})

Encountered conflict when merging commits 0534e2c184f5a1fa907ea1120aba73fb9a98dc9d, d3ef09f3d61a3b182b711a7c08fe46e4f66c3026, ab4713b112fc9946b86edf8d50e8fa185435d750

Progress

  • [x] #8333
  • [ ] Frontend shows either critical failure (all paths fail) or offers to retry with the paths that didn't fail (CC @estib-vega)

Byron avatar Apr 29 '25 13:04 Byron

CC @krlvi .

Byron avatar Apr 29 '25 13:04 Byron

Next steps as discussed, written down for posterity: show modal with paths grouped by reason to inform the user about what went wrong, and advise how to fix it.

Probably it's a good idea to differentiate the fatal case, everything failed, from the case where one can retry without the failed paths.

Byron avatar Apr 30 '25 07:04 Byron