vscode: Merge editor doesn't open with REBASE_HEAD
Issue Type: Bug
Open add/add conflict file.
git.mergeEditor: true

git.mergeEditor: false

Neither is terribly useful, frankly.
VS Code version: Code - Insiders 1.69.0-insider (0e3304bca9e862eddc7e437e2bab8a4a4a4f33c9, 2022-06-29T05:20:28.364Z) OS version: Windows_NT x64 6.1.7601 Restricted Mode: No
System Info
| Item | Value |
|---|---|
| CPUs | Intel® Core™ i5-3550 CPU @ 3.30GHz (4 x 3292) |
| GPU Status | 2d_canvas: enabled canvas_oop_rasterization: disabled_off direct_rendering_display_compositor: disabled_off_ok gpu_compositing: enabled multiple_raster_threads: enabled_on opengl: enabled_on rasterization: enabled raw_draw: disabled_off_ok skia_renderer: enabled_on video_decode: enabled video_encode: enabled vulkan: disabled_off webgl: enabled webgl2: enabled |
| Load (avg) | undefined |
| Memory (System) | 15.96GB (10.20GB free) |
| Process Argv | D:\Profiles\anrdaemon\Documents\.github\Otus --crash-reporter-id 6d7cf40a-de80-4f22-8c48-92868c2e08dd |
| Screen Reader | no |
| VM | 0% |
A/B Experiments
vsliv695:30137379
vsins829:30139715
vsliv368cf:30146710
vsreu685:30147344
python383cf:30185419
vspor879:30202332
vspor708:30202333
vspor363:30204092
vslsvsres303:30308271
pythonvspyl392:30422396
pythontb:30258533
pythonptprofiler:30281269
vshan820:30294714
pythondataviewer:30285072
vscod805:30301674
bridge0708:30335490
bridge0723:30353136
vsaa593cf:30376535
pythonvs932:30404738
wslgetstarted:30449409
vscscmwlcmt:30465136
cppdebug:30492333
vscaac:30438845
pylanb8912:30496796
vsclangdf:30492506
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Reactions: 6
- Comments: 26 (8 by maintainers)
Commits related to this issue
- read `REBASE_HEAD` when rebasing, swap yours/theirs (label, sides) as well https://github.com/microsoft/vscode/issues/153737 — committed to microsoft/vscode by jrieken 2 years ago
- read `REBASE_HEAD` when rebasing, swap yours/theirs (label, sides) as well (#155208) https://github.com/microsoft/vscode/issues/153737 — committed to microsoft/vscode by jrieken 2 years ago
- read `REBASE_HEAD` when rebasing, swap yours/theirs (label, sides) as well (#155208) https://github.com/microsoft/vscode/issues/153737 — committed to microsoft/vscode by jrieken 2 years ago
- read `REBASE_HEAD` when rebasing, swap yours/theirs (label, sides) as well (#155208) https://github.com/microsoft/vscode/issues/153737 — committed to microsoft/vscode by jrieken 2 years ago
- also default to opening merge editor when conflict is about adding fixes https://github.com/microsoft/vscode/issues/153737#issuecomment-1189357241 — committed to microsoft/vscode by jrieken 2 years ago
- also default to opening merge editor when conflict is about adding (#155711) fixes https://github.com/microsoft/vscode/issues/153737#issuecomment-1189357241 — committed to microsoft/vscode by jrieken 2 years ago
Still no go. An attempt to open conflicting file produces error in
Log (Window):@jnugh This has landed in insiders. You can help us verifying that this works, see the hint above ⬆️
Yeah they both do. I just spun up a local vscode build to get better debugging capabilities and actually found the cause in my case.
resolveChangeCommandcurrently checks forresource.type === Status.BOTH_MODIFIEDin my case the Status isBOTH_ADDED.Finally - Steps to reproduce:
Changing the condition to
worked in my case. Not sure if this is sufficient though. I would not have thought about checking for
BOTH_ADDEDso maybe there are even more cases.I’m not sure if this is the same issue as the previous git status output looked more like being in a usual merge state but maybe this still helps.
For me this happens during rebase. It works for the first file (sometimes?) and logs the following for the following files:
In case of a rebase
REBASE_HEADshould be used instead ofMERGE_HEADI think.