Vim icon indicating copy to clipboard operation
Vim copied to clipboard

editor.action.marker.next doesn't update position

Open BickfordA opened this issue 1 year ago • 3 comments

          I can confirm this issue happens.

Steps to reproduce:

  1. Use vim extension
  2. Use a language server or similar that lets you "go to next error"
  3. Press Shift+Ctrl+P "Go to next Problem (Error, Warning, Info)"
  4. Observe that the view moves to the next problem, and the caret is visually moved to the problem
  5. Press any vim movement command, eg. hjkl
  6. When movement is done, the view and caret pops back to the previous position
Version: 1.63.2
Commit: 899d46d82c4c95423fb7e10e68eba52050e30ba3
Date: 2021-12-15T09:39:46.686Z
Electron: 13.5.2
Chromium: 91.0.4472.164
Node.js: 14.16.0
V8: 9.1.269.39-electron.0
OS: Linux x64 5.11.0-46-generic

Originally posted by @molysgaard in https://github.com/VSCodeVim/Vim/issues/5746#issuecomment-1040662158

BickfordA avatar Dec 05 '23 18:12 BickfordA

Still running into this issue, I saw the previous issue 5746 was closed. Maybe this is a new one that has the same behavior? But it is still happening for me with v1.27.1 .

This is the snippet of my config that is having the issue. The editor will jump to the next marker, but if i try to move or enter insert mode the position goes back to the location before the jump.

"vim.normalModeKeyBindingsNonRecursive": [
        {
          "before": [
              "]",
              "g"
          ],
          "commands": [
              "editor.action.marker.next",
          ],
          "silent": true
      },
      {
          "before": [
              "[",
              "g"
          ],
          "commands": [
              "editor.action.marker.prev",
          ],
          "silent": true
      },
      ]

Let me know if there is anything else I can add to help track down this issue

BickfordA avatar Dec 05 '23 18:12 BickfordA

Maybe there is command that could be used to force the position to update? After calling "editor.action.marker.prev" ?

BickfordA avatar Dec 05 '23 18:12 BickfordA

I'm still experiencing this issue as well with Visual Studio Code 1.86.0 and VSCodeVim 1.27.2. It only happens occasionally, so I'm not sure how to reproduce it reliably either. And closing and re-opening the file does seem to fix the issue for me, at least temporarily.

austin-beer avatar Feb 02 '24 19:02 austin-beer

A possible, even not ideal solution, could be found here: https://github.com/VSCodeVim/Vim/issues/5746#issuecomment-2205307612

lucaSartore avatar Jul 03 '24 07:07 lucaSartore