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

Gradle daemon not persisted after running :Dispatch #159

Open
vitvly opened this issue Dec 22, 2015 · 3 comments
Open

Gradle daemon not persisted after running :Dispatch #159

vitvly opened this issue Dec 22, 2015 · 3 comments

Comments

@vitvly
Copy link

vitvly commented Dec 22, 2015

Hi,

thanks for a great plugin.

I've been using it for some time, and there seems to be an issue with background job handling.

I am using Gradle for Java builds, and have enabled the daemon to speed up builds. So this means that on the first time i run

:Dispatch gradle build

it will create a background java process that will be used for subsequent builds. However - the problem is that the daemon dies as soon as the :Dispatch command is done and the Tmux split window is closed.

I've tried reproducing this issue. Opening a separate Tmux pane and running gradle build there creates a daemon properly, that does not die even when the pane is closed/exited.

It did definitely work some time ago, although i do not remember correct revision number.

@tpope
Copy link
Owner

tpope commented Dec 22, 2015

This could be a difference between interactive/non-interactive shells or any number of things. If you can find a commit that changed things I can assess further.

@vitvly
Copy link
Author

vitvly commented Dec 23, 2015

Sorry for not providing enough details. I did some research.

It is not a problem of vim-dispatch itself, but is related to Tmux. Screen adapter works perfectly fine, for instance. I've trie rolling back to mid-2014 vim-dispatch versions, the issue did not go away.

My Vim version is 7.4.979, Neovim - 0.1.1.

Tried different versions of Tmux as well (1.9a, 2.0, 2.1), and on different machines (CentOS 6.6, OS X 10.11) and shells (bash, zsh).

I will post more results, currently I am at loss here. Will try to narrow further.

@aripollak
Copy link

I believe I have a similar problem with rails+spring and neovim+vim-dispatch-neovim. If I start spring before running neovim, it works fine with vim-dispatch. If I first use spring inside neovim, it doesn't reuse an existing process on subsequent calls.

This makes sense to me given how the spring server works. I'm not sure there's anything vim-dispatch can really do to solve it, but the workaround for me is to just start the server from another shell that's not currently running tmux or vim. I can even drop vim into the background and run the spring server from that parent shell, then foreground vim again to have it work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants