You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now, quitting a plugin using this lib is a mess, one basically has to call process::exit(_) and tear it all down from a task. What are our options?
Some thoughts:
Quitting happens upon a message from neovim, so we need to handle that. I tend to call this "quit", and just use a notification. Maybe just hardcode this? Maybe the name could/should be some kind of configuration option?
We probably also want to quit from out own code? If a task decides something went wrong, maybe he wants to signal the application to quit. How to do that? If nothing else, nvim.eval("rpcnotify(_, 'quit')") is possible, which we could wrap in a method on the requester.
What should happen on quitting? The io task should finish, so the main function that spawned it can notice and do whatever needs to be done. Need to return something useful from the io task then.
What to do about the other tasks that might still be running? I asked here, but got no answer.
Maybe collect the join handlers of all tasks globally?
Ideas welcome. MVP would be to handle a quit notification by returning from the handler.
The text was updated successfully, but these errors were encountered:
Right now, quitting a plugin using this lib is a mess, one basically has to call
process::exit(_)
and tear it all down from a task. What are our options?Some thoughts:
nvim.eval("rpcnotify(_, 'quit')")
is possible, which we could wrap in a method on the requester.Ideas welcome. MVP would be to handle a
quit
notification by returning from the handler.The text was updated successfully, but these errors were encountered: