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

Client error 'Failed to determine file type' after undoing rename with Cmd+Z #1581

Closed
sergeysavchuk opened this issue Nov 4, 2024 · 1 comment · Fixed by #1583
Closed
Labels
bug Issue identified by VS Code Team member as probable bug
Milestone

Comments

@sergeysavchuk
Copy link

  1. Server registers feature of workspace/didRename, e.g. didRename: { filters: [{ pattern: { glob: '**/*.clientrc', matches: 'file' }}] }
  2. Open a folder with some .clientrc file
  3. Rename the *.clientrc file
  4. Undo the previous renaming with the hotkey: Cmd+Z
  5. The client reports error Failed to determine file type for <path to the renamed *.clientrc file from step 3>

OS version: macOs 15.1 (24B83)

It can be reproduced by using official lsp-sample with an additional server configuration, please see https://github.com/sergeysavchuk/vscode-extension-samples/tree/undo_renamed_file/lsp-sample (branch: undo_renamed_file)

Log:
[Error - 11:56:30] Failed to determine file type for file:///Users//data/src/test/vscode-rename/testNew.clientrc.
Image

@dbaeumer
Copy link
Member

dbaeumer commented Nov 5, 2024

This shouldn't be an error. We should make this an info since we treat the file as a match to not loose anything.

@dbaeumer dbaeumer added the bug Issue identified by VS Code Team member as probable bug label Nov 5, 2024
@dbaeumer dbaeumer added this to the Next milestone Nov 5, 2024
dbaeumer added a commit that referenced this issue Nov 5, 2024
@dbaeumer dbaeumer closed this as completed Nov 5, 2024
dbaeumer added a commit that referenced this issue Nov 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issue identified by VS Code Team member as probable bug
Projects
None yet
2 participants