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

LeaderF doesn't work after updated it to the newest version on Windows10 + msys2 #267

Closed
2 of 6 tasks
cjun714 opened this issue Jan 22, 2019 · 3 comments
Closed
2 of 6 tasks
Labels

Comments

@cjun714
Copy link

cjun714 commented Jan 22, 2019

  • vim or neovim?
    • vim
    • neovim
  • Output of vim --version or nvim --version: v 0.3.1
  • Output of :echo has("python"): 0
  • Output of :echo has("python3"): 1
  • Output of :echo &pythondll(only vim, not neovim):
  • Output of :echo &pythonthreedll(only vim, not neovim):
  • Output of :py print(sys.version):
  • Output of :py3 print(sys.version): 3.7.1 (default, Oct 21 2018, 19:06:06) [GCC 8.2.0 64 bit (AMD64)]
  • Output of :echo g:Lf_Debug_Cmd:
  • Operating system:
    • Linux
    • Mac OS X
    • Windows
    • Etc.
  • Configurations related to LeaderF in vimrc:
nnoremap <C-r> :LeaderfBufTag<CR>
nnoremap <leader>j :LeaderfTag<CR>

let g:Lf_StlSeparator = {'left':"",'right':""} " { 'left': "\ue0b0", 'right': "\ue0b2" }
let g:Lf_WindowHeight = 0.25
let g:Lf_RootMarkers = ['.project', '.root', '.svn', '.git']
let g:Lf_WorkingDirectoryMode = 'Ac'
let g:Lf_CacheDirectory = expand('/tmp/vim/cache')
let g:Lf_UseCache = 0
let g:Lf_ShowRelativePath = 0
let g:Lf_HideHelp = 1
let g:Lf_StlColorscheme = 'powerline'
let g:Lf_PreviewResult = {'Function':0, 'BufTag':0}

Describe your question, feature request, or bug.

LeaderF doesn't work after I updated it to the newest version.
My environment is Window10 + msys2 + mingw-w64-x86_64-python3

Steps to reproduce

:LeaderfFile

Actual behaviour

Console show error message:

Error detected while processing function leaderf#File#startExpl[2]..leaderf#LfPy:
line    1:
Request from non-main thread.
Requests from different threads should be wrapped with nvim.async_call(cb, ...) 
  File "D:/tool/dev/msys64/mingw64/lib/python3.7\threading.py", line 917, in _bootstrap_inner
    self.run()

  File "D:/tool/dev/msys64/mingw64/lib/python3.7\threading.py", line 865, in run
    self._target(*self._args, **self._kwargs)

  File "D:\tool\dev\msys64\home\John\.vim\plugged\LeaderF\autoload/leaderf/python\leaderf\asyncExecutor.py", line 28, in _readerThread
    max_count = int(lfEval("g:Lf_MaxCount"))

  File "D:/tool/dev/msys64/mingw64/lib/python3.7/site-packages\pynvim\plugin\script_host.py", line 204, in eval
    obj = self.request("vim_eval", expr)

Request from non-main thread.
Requests from different threads should be wrapped with nvim.async_call(cb, ...) 
  File "D:/tool/dev/msys64/mingw64/lib/python3.7\threading.py", line 917, in _bootstrap_inner
    self.run()

  File "D:/tool/dev/msys64/mingw64/lib/python3.7\threading.py", line 865, in run
    self._target(*self._args, **self._kwargs)

  File "D:\tool\dev\msys64\home\John\.vim\plugged\LeaderF\autoload/leaderf/python\leaderf\asyncExecutor.py", line 28, in _readerThread
    max_count = int(lfEval("g:Lf_MaxCount"))

  File "D:/tool/dev/msys64/mingw64/lib/python3.7/site-packages\pynvim\plugin\script_host.py", line 204, in eval
    obj = self.request("vim_eval", expr)

Exception in thread Thread-1:
Traceback (most recent call last):
  File "D:/tool/dev/msys64/mingw64/lib/python3.7\threading.py", line 917, in _bootstrap_inner
    self.run()
  File "D:/tool/dev/msys64/mingw64/lib/python3.7\threading.py", line 865, in run
    self._target(*self._args, **self._kwargs)
  File "D:\tool\dev\msys64\home\John\.vim\plugged\LeaderF\autoload/leaderf/python\leaderf\asyncExecutor.py", line 28, in _readerThread
    max_count = int(lfEval("g:Lf_MaxCount"))
  File "D:/tool/dev/msys64/mingw64/lib/python3.7/site-packages\pynvim\plugin\script_host.py", line 204, in eval
    obj = self.request("vim_eval", expr)
  File "D:/tool/dev/msys64/mingw64/lib/python3.7/site-packages\pynvim\api\nvim.py", line 178, in request
    raise NvimError("request from non-main thread")
pynvim.api.nvim.NvimError: request from non-main thread
Exception in thread Thread-2:
Traceback (most recent call last):
  File "D:/tool/dev/msys64/mingw64/lib/python3.7\threading.py", line 917, in _bootstrap_inner
    self.run()
  File "D:/tool/dev/msys64/mingw64/lib/python3.7\threading.py", line 865, in run
    self._target(*self._args, **self._kwargs)
  File "D:\tool\dev\msys64\home\John\.vim\plugged\LeaderF\autoload/leaderf/python\leaderf\asyncExecutor.py", line 28, in _readerThread
    max_count = int(lfEval("g:Lf_MaxCount"))
  File "D:/tool/dev/msys64/mingw64/lib/python3.7/site-packages\pynvim\plugin\script_host.py", line 204, in eval
    obj = self.request("vim_eval", expr)
  File "D:/tool/dev/msys64/mingw64/lib/python3.7/site-packages\pynvim\api\nvim.py", line 178, in request
    raise NvimError("request from non-main thread")
pynvim.api.nvim.NvimError: request from non-main thread
@cjun714
Copy link
Author

cjun714 commented Jan 22, 2019

Same error appears on Ubuntu 18.10

@Yggdroot Yggdroot added the bug label Jan 22, 2019
Yggdroot added a commit that referenced this issue Jan 22, 2019
@Yggdroot
Copy link
Owner

Fixed.

@cjun714
Copy link
Author

cjun714 commented Jan 22, 2019

Now it works well on both window and linux, thanks a lot!

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

No branches or pull requests

2 participants