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

Refactoring and tests for plugin Host and decorators #559

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

wookayin
Copy link
Member

  • refactor: add type annotations for pynvim.plugin.host
  • refactor: add typing for Handler, revise typings in decorators
  • test: add tests and docs for plugin.Host

- `Handler` is a structured subtype of `Callable` decorated by pynvim
  decorators for RPC handlers; this type provides static typing for the
  private fields internally set by pynvim decorators. This way, we have
  a better static typing and thus no need to rely on `hasattr` checks.

- Add minimal test cases for other decorator types.
@justinmk
Copy link
Member

justinmk commented Apr 7, 2024

neovim/neovim#27949 will greatly simplify the implementation and interface of remote plugins.

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

Successfully merging this pull request may close these issues.

2 participants