dance icon indicating copy to clipboard operation
dance copied to clipboard

Dance stopped working on vscode 1.67.2 on Mac.

Open leira opened this issue 3 years ago • 3 comments

I've been using with vscode on Mac without problem until today. Today, after I quit vscode and start it again, Dance stopped working. It seems vscode was in insert mode after start, but Esc didn't take it to normal mode. Type "dance" in command palette shows only "Dance: Focus on Registers View", but no any other Dance commands. I do see the Dance command list in the "Keyboard Shortcuts" window. I'm not sure if Dance is fully enabled or not. Disable/enable or reinstall Dance didn't fix the issue.

Maybe it is because of the recent vscode update to 1.67.2, but I'm not sure. It is possible that I didn't restart vscode when the update was done, and the update only applied when I restart vscode today. But the same issue happened on another instance of vscode-insider 1.68.0 running the same machine, which was also reproduced after the restart of vscode.

How can I get some more insight of the issue, maybe collect some logs?

Here are the detailed vscode versions:

Version: 1.67.2 (Universal)
Commit: c3511e6c69bb39013c4a4b7b9566ec1ca73fc4d5
Date: 2022-05-17T18:20:57.384Z
Electron: 17.4.1
Chromium: 98.0.4758.141
Node.js: 16.13.0
V8: 9.8.177.13-electron.0
OS: Darwin x64 21.5.0
Version: 1.68.0-insider (Universal)
Commit: 6428d0fc7dae5801cdaf2d160ac39a3dfc8f0c06
Date: 2022-05-27T05:15:57.327Z
Electron: 17.4.4
Chromium: 98.0.4758.141
Node.js: 16.13.0
V8: 9.8.177.13-electron.0
OS: Darwin x64 21.5.0

leira avatar May 27 '22 20:05 leira

Some update.

Dance has this keybinding by default.

  {
    "key": "ctrl+f",
    "command": "dance.select.vertically",
    "args": {
      "direction": 1,
      "by": "page",
      "shift": "jump"
    },
    "when": "editorTextFocus && dance.mode == 'insert'"
  },

When I press "ctrl+f", it runs command "cursorRight" instead of "dance.select.vertically". I think it was probably because of the "when" clause is not met. So I removed the "dance.mode" clause, and change add this new keybinding:

  {
    "key": "ctrl+f",
    "command": "dance.select.vertically",
    "args": {
      "direction": 1,
      "by": "page",
      "shift": "jump"
    },
    "when": "editorTextFocus"
  },

This time, the keybinding is called, it shows error "command 'dance.select.vertically' not found". It matches what I observed from the command palette. It seems Dance was not fully enabled. How do I move forward from here?

leira avatar May 27 '22 21:05 leira

It mysteriously recovered for vscode 1.67.2, not sure why 😤. But the problem persists on 1.68.0-insider.

leira avatar May 28 '22 00:05 leira

Not really sure what happening, but thank you for investigating! I can't try to troubleshoot right now, but something you could try is opening the dev tools in VS Code and seeing if an error is logged when Dance is starting up. I also released a new version of Dance two weeks ago -- could it be the cause of the problem?

71 avatar May 29 '22 08:05 71

Is this still an issue with latest VSCode @leira ?

merlinaudio avatar Nov 29 '22 12:11 merlinaudio

Not any more. Closing~

leira avatar Dec 01 '22 23:12 leira