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

coc-prisma won't install. #4

Closed
dotangad opened this issue Oct 15, 2020 · 13 comments · Fixed by #7
Closed

coc-prisma won't install. #4

dotangad opened this issue Oct 15, 2020 · 13 comments · Fixed by #7
Labels
bug Something isn't working

Comments

@dotangad
Copy link

dotangad commented Oct 15, 2020

I'm new to coc and vim in general, I was hoping you could help me out. I've tried running :CocInstall coc-prisma, the installation works but when I try listing my services, prisma doesn't show up. Autocomplete and formatting are also not working.

@dotangad dotangad changed the title coc-prisma wonm coc-prisma won't install. Oct 15, 2020
@pantharshit00
Copy link
Owner

Hey @dotangad

Can you please open .prisma file and paste the output of :CocInfo here. That would help in debugging this.

Mine looks like this:

## versions

vim version: NVIM v0.5.0-705-g9f704c88a
node version: v32.13.0
coc.nvim version: 0.0.79-d2a3186309
coc.nvim directory: C:\Users\panth\AppData\Local\nvim\plugged\coc.nvim
term: vtpcon
platform: win32

## Output channel: explorer


## Output channel: prettier


## Output channel: prisma

Binary test successful.
[Info  - 12:55:09 PM] Installed version of Prisma binary 'prisma-fmt': a6a6ecba74cbaeee0756c312b1b0f2502b27e49c
[Info  - 12:55:09 PM] Extension name @prisma/language-server with version 2.7.1
[Info  - 12:55:09 PM] Prisma CLI version: 2.7.0-dev.61

@pantharshit00 pantharshit00 added the bug Something isn't working label Oct 15, 2020
@dotangad
Copy link
Author

Hey Harshit, here's what I got -

## versions

vim version: NVIM v0.4.4
node version: v14.13.1
coc.nvim version: 0.0.79-6cb5c6cd2d
coc.nvim directory: /Users/angad/.config/nvim/plugged/coc.nvim
term: iTerm.app
platform: darwin

## Output channel: explorer


## Output channel: prettier


## Output channel: prisma

[Info  - 1:19:03 pm] Default version of Prisma binary 'prisma-fmt': 369b3694b7edb869fad14827a33ad3f3f49bbc20
[Info  - 1:19:03 pm] Extension name @prisma/language-server with version 2.9.0
[Info  - 1:19:03 pm] Prisma CLI version: 2.9.0

@pantharshit00
Copy link
Owner

@dotangad Can you please try again? I have updated the language server and made a new release 0.4.0. That might help.

@dotangad
Copy link
Author

I uninstalled the extension (:CocUninstall coc-prisma) an installed it again (:CocInstall coc-prisma). This is my output from :CocInfo -

## versions

vim version: NVIM v0.4.4
node version: v14.13.1
coc.nvim version: 0.0.79-6fc00f1a28
coc.nvim directory: /Users/angad/.config/nvim/plugged/coc.nvim
term: iTerm.app
platform: darwin

## Output channel: explorer


## Output channel: prettier


## Output channel: prisma

[Info  - 5:54:31 pm] Default version of Prisma binary 'prisma-fmt': 369b3694b7edb869fad14827a33ad3f3f49bbc20
[Info  - 5:54:31 pm] Extension name @prisma/language-server with version 2.9.0
[Info  - 5:54:31 pm] Prisma CLI version: 2.9.0
[Error  - 5:54:41 pm] Request textDocument/formatting failed.
  Message: Request textDocument/formatting failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:48 pm] Request textDocument/completion failed.
  Message: Request textDocument/completion failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:48 pm] Request textDocument/completion failed.
  Message: Request textDocument/completion failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:48 pm] Request textDocument/completion failed.
  Message: Request textDocument/completion failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:48 pm] Request textDocument/completion failed.
  Message: Request textDocument/completion failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:49 pm] Request textDocument/completion failed.
  Message: Request textDocument/completion failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:49 pm] Request textDocument/completion failed.
  Message: Request textDocument/completion failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:50 pm] Request textDocument/completion failed.
  Message: Request textDocument/completion failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:52 pm] Request textDocument/completion failed.
  Message: Request textDocument/completion failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:53 pm] Request textDocument/completion failed.
  Message: Request textDocument/completion failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:53 pm] Request textDocument/completion failed.
  Message: Request textDocument/completion failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:53 pm] Request textDocument/completion failed.
  Message: Request textDocument/completion failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:55 pm] Request textDocument/completion failed.
  Message: Request textDocument/completion failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:57 pm] Request textDocument/completion failed.
  Message: Request textDocument/completion failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:58 pm] Request textDocument/formatting failed.
  Message: Request textDocument/formatting failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:54:59 pm] Request textDocument/formatting failed.
  Message: Request textDocument/formatting failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:55:06 pm] Request textDocument/formatting failed.
  Message: Request textDocument/formatting failed with message: Cannot read property 'length' of undefined
  Code: -32603 
[Error  - 5:55:09 pm] Request textDocument/formatting failed.
  Message: Request textDocument/formatting failed with message: Cannot read property 'length' of undefined
  Code: -32603 

@pantharshit00
Copy link
Owner

Hm, that is quite weird. We have some bug fixes which are coming in 2.10 with regarding to binary paths so I will post an update here when 2.10 will be available.

@jvanbaarsen
Copy link

jvanbaarsen commented Oct 28, 2020

I'm seeing the same problems, coc-prisma isn't really doing anything. Formatting for example is not working.

This is the output of cocinfo:

## versions

vim version: NVIM v0.4.4
node version: v14.14.0
coc.nvim version: 0.0.79-c330912985
coc.nvim directory: /Users/jeroen/dotfiles/.vim/plugged/coc.nvim
term: Apple_Terminal
platform: darwin

## Log of coc.nvim

2020-10-28T10:18:53.511 INFO (pid:59988) [services] - registered service "eslint"
2020-10-28T10:18:53.537 INFO (pid:59988) [plugin] - coc.nvim 0.0.79-c330912985 initialized with node: v14.14.0 after 98ms
2020-10-28T10:18:55.879 INFO (pid:59988) [language-client-index] - prisma started with 60174
2020-10-28T10:19:31.525 INFO (pid:59988) [completion-complete] - Results from: around
2020-10-28T10:19:35.227 INFO (pid:59988) [completion-complete] - Results from: around
2020-10-28T10:19:37.585 INFO (pid:59988) [willSaveHandler] - Will save cost: 64

@dotangad
Copy link
Author

I updated the extension and I'm still facing the same problems as @jvanbaarsen.

@pantharshit00
Copy link
Owner

Hey @dotangad

I can also reproduce the problem now on a new machine, I will investigate and fix it over the weekend.

@johnpyp
Copy link
Contributor

johnpyp commented Nov 9, 2020

Hi, I fixed this issue in #7. The issue was that the lsp expected a non-undefined value for a string configuration option, though an empty string works fine.

:CocCommand workspace.showOutput helped me track down the issue more easily, as compared to the outputs above.

@jvanbaarsen
Copy link

@johnpyp Would there be an easy way to use your PR to check it out?

@pantharshit00
Copy link
Owner

Thanks @johnpyp

I will release the fix asap after verifying it. Sorry for the delay everyone, I got sick last weekend.

@pantharshit00
Copy link
Owner

Fix is available in version 0.5.1 (thanks again @johnpyp )

https://github.com/pantharshit00/coc-prisma/releases/tag/v0.5.1

@pantharshit00
Copy link
Owner

@jvanbaarsen Run :CocUpdate now, the fix should be live

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants