carlitux / deoplete-ternjs

deoplete.nvim source for javascript
MIT License
277 stars 24 forks source link

Tern server doesn't always start #22

Closed simonsmith closed 8 years ago

simonsmith commented 8 years ago

Seeing some weirdness where the tern server doesn't seem to start as I get no entries in the autocomplete. Sometimes I can fix it by manually running tern in another window and then when I restart nvim it seems to work. Strangely if I then kill the tern I started manually it continues to work fine even after restarting nvim.

Is there someway I can see if the tern server fails to start from deopletes side? Perhaps somewhere I can add a debug? Would be great to be able to set a debug option and then see any messages in the :mess command in nvim.

Cheers

carlitux commented 8 years ago

Hi,

please review this pull request https://github.com/carlitux/deoplete-ternjs/pull/19 take a look that you don't have a .tern-port, if there is one the source will think there is running an instance of tern and won't start a new one will use the one that is running.

This was done because some people is using tern_for_vim to use the other features that deoplete doesn't.

simonsmith commented 8 years ago

I don't have a tern-port, just a tern-project and tern-config in my home directory. This seemed to be enough to work previously. Do I need to add anything else?

carlitux commented 8 years ago

No, that should be enough. Maybe with a minimal config to test and reproduce it.