Skip to content

nvim: show errors in handler on stderr when used as client #217

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

Merged
merged 1 commit into from
Aug 17, 2016

Conversation

bfredl
Copy link
Member

@bfredl bfredl commented Jul 21, 2016

fixes #216. A modified test case to cover both cases:

import sys
import os
from neovim import attach

def setup_cb():
    nvim.command('call rpcnotify({}, "foo")'.format(nvim.channel_id))
    nvim.call('rpcrequest', nvim.channel_id, "bar", "xx", async=True)


def notification_cb(msg, _args):
    num -= 1

def request_cb(name, args):
    FAIL


nvim = attach('child', argv=['nvim', '-u', 'NONE', '--embed'])
nvim.run_loop(request_cb, notification_cb, setup_cb)

This should not affect plugins running inside vim, as the plugin host already catches Exception:s and displays the plugin traceback appropriately.

@bfredl bfredl merged commit 4280e49 into neovim:master Aug 17, 2016
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

Successfully merging this pull request may close these issues.

No error shown when triggered in a callback
1 participant