Roadmap
KillTheMule opened this issue · 2 comments
-
Figure out how plugins can quit
-
Rewrite the API to be type save, and hide
rmpv::Value
from the user- Can probably be done for outgoing requests by recursively creating values
- Fixed args are easy, but something like
nvim_call_function
probably needs going through a trait
- Fixed args are easy, but something like
- Incoming Responses can be done like fixed args
- Incoming Notifications/Requests might be impossible.
- Check out
rmp-serde
or so, so maybe the user has to just declare a struct
- Check out
- #8
- Can probably be done for outgoing requests by recursively creating values
-
Consider making a difference between requests and notifications, and send out notifications with the proper message type, and don't wait for a response
- Does neovim actually recognize this? Read the docs! Maybe everything's a requests anyways, then don't bother
- It does, see https://neovim.io/doc/user/api.html#api-global-events. Maybe not so usefull since there seems little to do where you don't want direct error feedback
- #7
- Does neovim actually recognize this? Read the docs! Maybe everything's a requests anyways, then don't bother
-
Figure out what to do if the handler needs some cleanup logic
-
Consider error handling
- Maybe get away from
Box<dyn Error>
in favor of a small enum? - #6
- Maybe get away from
-
Can we merge
Requester
intoNeovim
? Could avoid doubling the API -
Need more tests
- Test all connection types on all OSes
- Test exttypes
- Check https://docs.rs/loom/0.2.14/loom/
-
We need Tokio right now. What can we do to stay "as generic as possible", so we can move to other executors when the possibility arrives?
- Use stuff from
futures
as far as possible. - See what we really need to expose from
crate::runtime
- Use stuff from
-
Consider public API.
- Right now, everything's just the way it would compile
-
Check rust's API guidelines
-
Document stuff
- Document the library
- I consider this done initially, from now on everything new should be directly documented, and we should be fine.
- More examples
- Document the library
-
Consider logging
- Maybe tokio's tracing is an idea?
First, thank you for your effort of creating this project. I've also been discovering neovim rpc in Rust and neovim-lib
was not satisfying enough.
For
Rewrite the API to be type save, and hide rmpv::Value from the user
You can rely on rmpv::Value with serde
feature and deserialize Value (or ValueRef) into user-defined struct. Your lib could also pre-define popular structs as well. Here is an example of me using in my project:
https://github.com/unrealhoang/lspc/blob/master/src/neovim.rs#L301-L312
Ahh very cool, I was hoping for something like this. Seems like it's an achievable goal to hide Value
from the user :) Thanks!