sillybun / vim-repl

Best REPL environment for Vim
GNU General Public License v2.0
446 stars 39 forks source link

REPLToggle produces NameError: name 'newcodes' is not defined on Ubuntu WSL only #98

Closed shy00n closed 3 years ago

shy00n commented 3 years ago

Describe the bug When I hit REPLToggole:

"ZYTREPL1 [running]" [Modified] --No lines in buffer--
Error detected while processing function repl#REPLToggle[42]..repl#ToREPLPythonCode:
line   23:
Traceback (most recent call last):
  File "<string>", line 9, in <module>
  File "/home/syoon/.vim/plugged/vim-repl/autoload/formatpythoncode.py", line 392, in format_to_repl
    pc.getcode(codes)
  File "/home/syoon/.vim/plugged/vim-repl/autoload/formatpythoncode.py", line 39, in getcode
    self.mergeunfinishline()
  File "/home/syoon/.vim/plugged/vim-repl/autoload/formatpythoncode.py", line 114, in mergeunfinishline
    tobeadded = self.rawcontents[j]
IndexError: list index out of range
line   24:
Traceback (most recent call last):
  File "<string>", line 1, in <module>
NameError: name 'newcodes' is not defined
E858: Eval did not return a valid python object

Screenshots

Desktop (please complete the following information): ~/.vim$ uname -a Linux DESKTOP-3DKM78D 4.19.128-microsoft-standard #1 SMP Tue Jun 23 12:58:10 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux

image

shy00n commented 3 years ago

Seem to be a problem only when virtual env is used in pyenv. Not a show stopper but only a minor issue

shy00n commented 3 years ago

Went away with new ppa upgrade of vim to 8.2 & wipe of Plugs directory. So, no issues.