-
lsp notifications didCreate, didDelete are sent when using the file explorer operations (create file, delete file). They are not sent when indirectly creating/deleting files by means of using the @theia/git ui and using the discard file changes operations (which in turn could create or delete files on the file system). Any suggestions where to start looking at? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 17 replies
-
Hey @MikeKoda, what version of Theia are you using? We recently noticed an issue in our file watching dependency that we fixed for 1.56.0, see #14545. Since that's the system that's in charge of sending us any disk related events (something that we don't need if the user changes files via the explorer UI), that might be the cause of the issue. Updating to the latest version might resolve this issue for you as well. |
Beta Was this translation helpful? Give feedback.
-
originally observed in 1.55. Switched to 1.56 and the new behaviour is as follows OK: creating a new file via file explorer and deleting the file via git ui "discard changes" operation, triggers the didDeleteFiles notification |
Beta Was this translation helpful? Give feedback.
-
Please note that the @theia/git extension is actually deprecated (#12745). However, I just noticed, it is not correctly marked as deprecated anymore, we will fix this. |
Beta Was this translation helpful? Give feedback.
Yes, but that's by design. I didn't quite notice that you explicitly meant those lsp events only. In the LSP, the editor is only supposed to send events that are explicitly triggered by the user in the IDE. For events that happen outside of the IDE, you need to use the
workspace/didChangeWatchedFiles
notification. I believe those are reliably sent by Theia and VS Code as well.Generally, if you notice that something doesn't work as expected in Theia with a VS Code extension, please confirm the behavior in VS Code first. We will …