Skip to content
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

Sync: Keybindings overwritten after enabling sync between platforms #86011

Closed
chrmarti opened this issue Dec 3, 2019 · 11 comments
Closed

Sync: Keybindings overwritten after enabling sync between platforms #86011

chrmarti opened this issue Dec 3, 2019 · 11 comments
Assignees
Labels
info-needed Issue requires more information from poster

Comments

@chrmarti
Copy link
Collaborator

chrmarti commented Dec 3, 2019

Issue Type: Bug

Testing #85941

I had Windows and Mac with different keybindings. After enabling sync between platforms, the Windows keybindings simply overwrote the Mac keybindings.

I'd expect to be asked to merge the two.

VS Code version: Code - Insiders 1.41.0-insider (9785578, 2019-12-03T05:35:54.992Z)
OS version: Darwin x64 18.7.0

System Info
Item Value
CPUs Intel(R) Core(TM) i7-4770HQ CPU @ 2.20GHz (8 x 2200)
GPU Status 2d_canvas: enabled
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
metal: disabled_off
multiple_raster_threads: enabled_on
oop_rasterization: disabled_off
protected_video_decode: unavailable_off
rasterization: enabled
skia_renderer: disabled_off
surface_control: disabled_off
surface_synchronization: enabled_on
video_decode: enabled
viz_display_compositor: enabled_on
viz_hit_test_surface_layer: disabled_off
webgl: enabled
webgl2: enabled
Load (avg) 2, 3, 3
Memory (System) 16.00GB (0.02GB free)
Process Argv
Screen Reader no
VM 17%
Extensions (30)
Extension Author (truncated) Version
unique-lines bib 1.0.0
ssh chr 0.0.4
ghlink dt 1.2.0
remotehub eam 0.5.0
tsl-problem-matcher eam 0.1.0
EditorConfig Edi 0.14.2
tslint eg2 1.0.44
git-project-manager fel 1.7.1
vscode-pull-request-github Git 0.13.0
rest-client hum 0.23.0
solidity Jua 0.0.64
theme-karyfoundation-themes kar 18.2.1
graphql-for-vscode kum 1.15.3
vscode-azureappservice ms- 0.16.1
vscode-docker ms- 0.9.0
remote-containers ms- 0.87.0
remote-ssh-edit-nightly ms- 2019.12.2400
remote-ssh-nightly ms- 2019.12.2400
remote-wsl ms- 0.41.1
azure-account ms- 0.8.7
azurecli ms- 0.4.6
github-issues-prs ms- 0.9.2
debugger-for-chrome msj 4.12.2
vetur oct 0.22.6
vscode-versionlens pfl 0.24.0
vscode-yaml red 0.6.1
vscode-workspacecontains-canary rob 0.0.2
vscode-open-in-github sys 1.13.0
ayu tea 0.18.0
vscodeintellicode Vis 1.2.0

(1 theme extensions excluded)

@sandy081
Copy link
Member

sandy081 commented Dec 3, 2019

Does it overwrote completely or merged it? Because it should merge if possible otherwise it should show you the conflicts.

@sandy081 sandy081 added info-needed Issue requires more information from poster settings-sync labels Dec 3, 2019
@chrmarti
Copy link
Collaborator Author

chrmarti commented Dec 3, 2019

Looking closer, I think it merged. There was a keybinding on both platforms for the same command with different keys and that was overwritten (Mac won it seems).

This is from looking at the result now. Let me know if that doesn't make sense and I can try to reproduce.

@sandy081
Copy link
Member

sandy081 commented Dec 3, 2019

It merges when the incoming/outgoing changes do not conflict from their base. Please let me know if this is the case or not?

@chrmarti
Copy link
Collaborator Author

chrmarti commented Dec 3, 2019

I enabled sync between platforms for the first time. What's the base in that case?

@sandy081
Copy link
Member

sandy081 commented Dec 3, 2019

When you enabled sync across platforms for the first time ever then its base and remote are null. So local wins and uploaded to remote.
When you enabled sync across platform on another machine for the first time (but not first time ever) then base should be null and remote should be the latest on the server.

@chrmarti
Copy link
Collaborator Author

chrmarti commented Dec 4, 2019

What if remote has a keybinding for the same command as local when base is null? Should the two keybindings stay or just one of them?

Is there a way to reset remote and base to null?

@sandy081
Copy link
Member

sandy081 commented Dec 4, 2019

it shall show conflict in this case.

@vscodebot vscodebot bot closed this as completed Dec 16, 2019
@vscodebot
Copy link

vscodebot bot commented Dec 16, 2019

This issue has been closed automatically because it needs more information and has not had recent activity. See also our issue reporting guidelines.

Happy Coding!

@sandy081 sandy081 reopened this Dec 17, 2019
@sandy081 sandy081 removed the info-needed Issue requires more information from poster label Dec 17, 2019
@sandy081 sandy081 added the bug Issue identified by VS Code Team member as probable bug label May 6, 2020
@sandy081 sandy081 added this to the May 2020 milestone May 6, 2020
@sandy081
Copy link
Member

sandy081 commented May 6, 2020

Assigning to May for investigation.

@sandy081 sandy081 modified the milestones: May 2020, Backlog Jun 3, 2020
@sandy081 sandy081 removed this from the Backlog milestone Jun 11, 2020
@sandy081 sandy081 added info-needed Issue requires more information from poster and removed bug Issue identified by VS Code Team member as probable bug settings-sync labels Jun 11, 2020
@sandy081
Copy link
Member

I am back to it after long time.

I have following keybindings.json in Mac

[
    {
        "key": "shift+cmd+c",
        "command": "editor.action.insertCursorAbove",
        "when": "editorTextFocus"
    },
    {
        "key": "alt+cmd+up",
        "command": "-editor.action.insertCursorAbove",
        "when": "editorTextFocus"
    }
]

I have following keybindings.json on Windows

// Place your key bindings in this file to override the defaultsauto[]
[
    {
        "key": "ctrl+shift+c",
        "command": "editor.action.insertCursorAbove",
        "when": "editorTextFocus"
    },
    {
        "key": "ctrl+alt+up",
        "command": "-editor.action.insertCursorAbove",
        "when": "editorTextFocus"
    }
]
  • Turned on Sync on Mac, all good as it just pushes data
  • Turned on Sync on Windows, got a dialog to merge/replace as expected
  • I tried both merge and replace and none of them overwrote my keybindings in windows

@chrmarti Sorry that it is long time back, but May I know if I am missing anything here?

@chrmarti
Copy link
Collaborator Author

Not sure if there was anything I did in addition, but even then this has likely been fixed since. I suggest to close the issue.

@github-actions github-actions bot locked and limited conversation to collaborators Jul 30, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
info-needed Issue requires more information from poster
Projects
None yet
Development

No branches or pull requests

2 participants