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

Startup error on MacOS 12.01 running nvim + python 3 #389

Open
arooni opened this issue Dec 27, 2021 · 7 comments
Open

Startup error on MacOS 12.01 running nvim + python 3 #389

arooni opened this issue Dec 27, 2021 · 7 comments

Comments

@arooni
Copy link

arooni commented Dec 27, 2021

running this version: 4d7a4da [9 days ago] (HEAD -> dev, origin/dev) Doc fix helptags all (#1181) [Tinmarino]

here is error message:

Error detected while processing function provider#python3#Call:
line   18:
Error invoking 'python_execute_file' on channel 3 (python3-script-host):
Traceback (most recent call last):
  File "/Users/david/.vim/plugged/taskwiki/taskwiki/main.py", line 6, in <module>
    import six
ModuleNotFoundError: No module named 'six'
Error invoking 'python_execute' on channel 3 (python3-script-host):
Traceback (most recent call last):
  File "<string>", line 1, in <module>
NameError: name 'WholeBuffer' is not defined
Error invoking 'python_execute' on channel 3 (python3-script-host):
Traceback (most recent call last):
  File "<string>", line 1, in <module>
NameError: name 'cache' is not defined
Press ENTER or type command to continue

here is nvim checkhealth:


health#nvim#check
========================================================================
## Configuration
  - OK: no issues found

## Performance
  - OK: Build type: Release

## Remote Plugins
  - OK: Up to date

## terminal
  - INFO: key_backspace (kbs) terminfo entry: key_backspace=^H
  - INFO: key_dc (kdch1) terminfo entry: key_dc=\E[3~
  - INFO: $COLORTERM='truecolor'

## tmux
  - OK: escape-time: 1
  - INFO: Checking stuff
  - OK: focus-events: on
  - INFO: $TERM: screen-256color
  - WARNING: Neither Tc nor RGB capability set. True colors are disabled. |'termguicolors'| won't work properly.
    - ADVICE:
      - Put this in your ~/.tmux.conf and replace XXX by your $TERM outside of tmux:
          set-option -sa terminal-overrides ',XXX:RGB'
      - For older tmux versions use this instead:
          set-option -ga terminal-overrides ',XXX:Tc'

health#provider#check
========================================================================
## Clipboard (optional)
  - OK: Clipboard tool found: pbcopy

## Python 2 provider (optional)
  - INFO: Disabled (g:loaded_python_provider=0).

## Python 3 provider (optional)
  - INFO: pyenv: Path: /usr/local/Cellar/pyenv/1.2.20/libexec/pyenv
  - INFO: pyenv: $PYENV_ROOT is not set. Infer from `pyenv root`.
  - WARNING: pyenv: Root does not exist: /Users/david/.pyenv. Ignoring pyenv for all following checks.
  - INFO: `g:python3_host_prog` is not set.  Searching for python3 in the environment.
  - INFO: Multiple python3 executables found.  Set `g:python3_host_prog` to avoid surprises.
  - INFO: Executable: /usr/local/bin/python3
  - INFO: Other python executable: /usr/bin/python3
  - INFO: Python version: 3.9.9
  - INFO: pynvim version: 0.4.3
  - OK: Latest pynvim is installed.

## Python virtualenv
  - OK: no $VIRTUAL_ENV

## Ruby provider (optional)
  - INFO: Disabled (g:loaded_ruby_provider=0).

## Node.js provider (optional)
  - INFO: Disabled (g:loaded_node_provider=0).

## Perl provider (optional)
  - ERROR: perl provider error:
    - ADVICE:
      - "Neovim::Ext" cpan module is not installed

health#treesitter#check
========================================================================
## Checking treesitter configuration
  - INFO: Runtime ABI version : 13
  - OK: Loaded parser for c: ABI version 13

here is me ensuring libraries are installed

[I]  ~  pip3 install -U tasklib
DEPRECATION: Configuring installation scheme with distutils config files is deprecated and will no longer work in the near future. If you are using a Homebrew or Linuxbrew Python, please see discussion at https://github.com/Homebrew/homebrew-core/issues/76621
Requirement already satisfied: tasklib in /usr/local/lib/python3.9/site-packages (2.4.3)
Requirement already satisfied: tzlocal in /usr/local/lib/python3.9/site-packages (from tasklib) (4.1)
Requirement already satisfied: pytz in /usr/local/lib/python3.9/site-packages (from tasklib) (2021.3)
Requirement already satisfied: pytz-deprecation-shim in /usr/local/lib/python3.9/site-packages (from tzlocal->tasklib) (0.1.0.post0)
Requirement already satisfied: tzdata in /usr/local/lib/python3.9/site-packages (from pytz-deprecation-shim->tzlocal->tasklib) (2021.5)
DEPRECATION: Configuring installation scheme with distutils config files is deprecated and will no longer work in the near future. If you are using a Homebrew or Linuxbrew Python, please see discussion at https://github.com/Homebrew/homebrew-core/issues/76621
[I]  ~  pip3 install -U pynvim
DEPRECATION: Configuring installation scheme with distutils config files is deprecated and will no longer work in the near future. If you are using a Homebrew or Linuxbrew Python, please see discussion at https://github.com/Homebrew/homebrew-core/issues/76621
Requirement already satisfied: pynvim in ./Library/Python/3.9/lib/python/site-packages (0.4.3)
Requirement already satisfied: greenlet in ./Library/Python/3.9/lib/python/site-packages (from pynvim) (1.1.2)
Requirement already satisfied: msgpack>=0.5.0 in ./Library/Python/3.9/lib/python/site-packages (from pynvim) (1.0.2)
DEPRECATION: Configuring installation scheme with distutils config files is deprecated and will no longer work in the near future. If you are using a Homebrew or Linuxbrew Python, please see discussion at https://github.com/Homebrew/homebrew-core/issues/76621
[I]  ~ 


@jakec-dev
Copy link

I'm getting the same error on MacOS - Big Sur:

Error detected while processing command line..function vimwiki#base#goto_index[33]..vimwiki#base#edit_file[26]..command line..
function vimwiki#base#goto_index[33]..vimwiki#base#edit_file[18]..BufRead Autocommands for "*.md"..function <SNR>12_setup_new_
wiki_buffer[19]..vimwiki#u#ft_set[6]..FileType Autocommands for "*"..function <SNR>8_LoadFTPlugin[17]..script /Users/#####/
.vim/plugged/taskwiki/ftplugin/vimwiki/taskwiki.vim:
line   29:
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/Users/######/.vim/plugged/taskwiki/taskwiki/main.py", line 6, in <module>
    import six
ModuleNotFoundError: No module named 'six'

Only just started happening in the last 2 days.

@nathanbraun
Copy link

Same here. I installed six and am now getting the error message about name 'cache' is not defined.

@adambair
Copy link

Same

@fullstopslash
Copy link

This same error has started popping up for me as well.

@Overbuffer
Copy link

The same on Mac

@dixonge
Copy link

dixonge commented Oct 13, 2022

Same error on Mac 12.6, BUT - this is with vim, not nvim

@Mastermjr
Copy link

Mastermjr commented Jun 23, 2023

https://vi.stackexchange.com/questions/15574/passing-arguments-to-pyfile-py3file-function
you need to check the version vim is running python on

if you're using homebrew, homebrew does this genius thing where it upgrades your packages without really clearly communicating this to you if you're not paying attention. Homebrew "helpfully" does an upgrade during normal package install, which appears to also affect the version of python vim is compiled against

so if you've installed the tasklib/six/packaging package with a python version, it may not be the python version currently running... so double check the python version you're running with vim above, and if its different than the version you already isntalled the dependencies with reinstall them again:
python3.X -m pip install [DEPENDENCIES], where X is the python version you found above in vim....

I think we can probably close this issue, but may want to leave it open so others can find this thread

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

No branches or pull requests

8 participants