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
Function signature explodes screen on some functions #418
Comments
It's a jedi issue, so your plugins don't really matter. |
That should not happen in jedi-vim - errors should show up in @hath995 |
My environment is an ubuntu vagrant, running vim in screen. uname -a
I move my cursor into 'fancyview.html' type 2 characters and the error appears. |
Actually type two characters into any of the parameters of render causes the error. |
Does it happen with the following then for you, too? It does not happen for me, but I get no signatures - although jedi-vim is able to resolve/goto the I am using Django 1.8.
|
yes, it does. |
Weird. I've tried it with So there's some other issue with Can you test it with Do you see anything in Are you using latest jedi-vim and jedi? |
It happens when show_call_signatures=1 but not when =2. I don't see the signature at all when =2. |
Yes, I pulled from jedi-vim master this week. |
I could reproduce it now, but it shows up in It's really a jedi issue, but it's odd that it messes up your buffer through jedi-vim. The code to handle the exception in jedi-vim is:
So it uses just What Vim version are you using?
For reference, here's the full traceback:
@davidhalter |
You probably have to restart Vim, or reload the buffer ( It seems like the command line signatures only show up with Django 1.7.x.. (for this example)! |
Oh, yeah. You might try a newer version (to fix the jedi-vim side of this issue). |
BTW I'm still using VIM 7.3 :)
I don't care. For me personally, linking to Jedi (by using the |
Switching to neovim was mostly painless. It does "fix" the error, though I'm still curious why adding a decorator to the function would cause that error on an unrelated function inside. |
Strange, especially since the error happens somewhere deep within Jedi. |
When I define a Generally I fix this by disabling jedi vim if I find myself doing a task that involves many decorators.
|
This issue has been fixed in Jedi's dev branch. It has been reported to Jedi a number of times. |
👍 |
When editing parameters of django.shortcuts render (django 1.8) the function signature helper throws an errror and renders the screen un readable. A :redraw! is required to clear the screen of the error message. This is the part of the error message I can access. Edit: It seems the decorator I'm trying to apply it the issue not the django function. Removing the decorator on the view prevents the error from happening.
le()
~ File "/home/vagrant/.vim/bundle/jedi-vim/jedi/jedi/parser/user_context.py", line 332, in module
~ return self._parser().module
~ File "/home/vagrant/.vim/bundle/jedi-vim/jedi/jedi/cache.py", line 143, in wrapper
~ result = func(self)
~ File "/home/vagrant/.vim/bundle/jedi-vim/jedi/jedi/parser/user_context.py", line 277, in _parser
~ parser = FastParser(self._grammar, self._source, self._path)
~ File "/home/vagrant/.vim/bundle/jedi-vim/jedi/jedi/parser/fast.py", line 109, in call
~ p.update(source)
~ File "/home/vagrant/.vim/bundle/jedi-vim/jedi/jedi/parser/fast.py", line 257, in update
-- INSERT -- self._parse(source) 8,53 All
File "/home/vagrant/.vim/bundle/jedi-vim/jedi/jedi/parser/fast.py", line 383, in _parse
line_offset, nodes)
File "/home/vagrant/.vim/bundle/jedi-vim/jedi/jedi/parser/fast.py", line 435, in _get_node
p = Parser(self._grammar, parser_code, self.module_path, tokenizer=tokenizer)
File "/home/vagrant/.vim/bundle/jedi-vim/jedi/jedi/parser/init.py", line 155, in init
self.module = p.parse(self._tokenize(tokenizer))
File "/home/vagrant/.vim/bundle/jedi-vim/jedi/jedi/parser/pgen2/parse.py", line 106, in parse
if self.addtoken(type, value, prefix, start_pos):
File "/home/vagrant/.vim/bundle/jedi-vim/jedi/jedi/parser/pgen2/parse.py", line 170, in addtoken
value, start_pos, prefix, self.addtoken)
File "/home/vagrant/.vim/bundle/jedi-vim/jedi/jedi/parser/init.py", line 269, in error_recovery
self._stack_removal(grammar, stack, index + 1, value, start_pos)
File "/home/vagrant/.vim/bundle/jedi-vim/jedi/jedi/parser/init.py", line 304, in _stack_removal
clear_names(children=node[1])
File "/home/vagrant/.vim/bundle/jedi-vim/jedi/jedi/parser/init.py", line 294, in clear_names
clear_names(c.children)
File "/home/vagrant/.vim/bundle/jedi-vim/jedi/jedi/parser/init.py", line 298, in clear_names
self._scope_names_stack[-1][c.value].remove(c)
KeyError: u'staff_user_required'
These are the plugins I'm trying to use.
argtextobj.vim CamelCaseMotion emmet-vim flake8-vim jedi-vim nerdtree tern_for_vim vim-airline vim-over vim-surround
the decorator
The text was updated successfully, but these errors were encountered: