iamcco / coc-vimlsp

viml language server
212 stars 7 forks source link

Unhandled 'error' event: EPERM: operation not permitted #46

Closed zoumi closed 2 years ago

zoumi commented 2 years ago

Log:

 parser: child_log: Index Workspace Error: d:\programs\vim\**\*.vim
Error => Error: EPERM: operation not permitted, scandir 'C:\Users\zoumi\Application Data'
events.js:353
      throw er; // Unhandled 'error' event
      ^

Error: EPERM: operation not permitted, scandir 'C:\Users\zoumi\Cookies'
Emitted 'error' event at:
    at c._handleError (D:\programs\vim\coc\extensions\node_modules\coc-vimlsp\out\scan.js:2:377134)
    at D:\programs\vim\coc\extensions\node_modules\coc-vimlsp\out\scan.js:2:376832
    at worked (D:\programs\vim\coc\extensions\node_modules\coc-vimlsp\out\scan.js:2:382257)
    at D:\programs\vim\coc\extensions\node_modules\coc-vimlsp\out\scan.js:2:376951
    at u (D:\programs\vim\coc\extensions\node_modules\coc-vimlsp\out\scan.js:2:378889)
    at D:\programs\vim\coc\extensions\node_modules\coc-vimlsp\out\scan.js:2:378083
    at fs.js:180:23
    at FSReqCallback.req.oncomplete (fs.js:1026:9) {
  errno: -4048,
  code: 'EPERM',
  syscall: 'scandir',
  path: 'C:\\Users\\zoumi\\Cookies'
}
parser: disconnect
parser: exit: 1, signal: null
parser: close: 1, signal: null
iamcco commented 2 years ago

Do you open vim file in C:// directory?

iamcco commented 2 years ago

Or some vim file link to C://xxx

zoumi commented 2 years ago

I have no idea why it scans C://XXX. I'm editing a file under d:\programs\vim. If this error doesn't make the lsp server exit unexpectedly, we can ignore it.

iamcco commented 2 years ago

Please set "vimlsp.indexes.runtimepath": false to test if it's because the vim runtime files in C://

zoumi commented 2 years ago

Thank you. I will re-open this issue when I can stably reproduce it.