mason.vim using the wrong python / nvim version -> desired asdf versions
Asked Answered
I

0

8

I've setup mason.vim in nvim, and it's working to install packages, and i've installed several python packages.

It didn't seem to be recognizing my global pip config, so I ran a :checkhealth, and under the mason.vim section it show as using my default python3, pip3 system configs.

This wouldn't have been a problem in the past, but I started using asdf, which install it python to a different dir, and aliases it to : /Users//.asdf/shims/python

I can't figure out how to change the setting at the lsp config level to define the paths to the correct bins.

Wondering if anyone has any ideas on how to to update these setting.

Thanks.

I tried defining the python host param, but that didn't work. 

vim.g.python_host_prog = '/Users/<user>/.asdf/shims/python'
vim.g.python3_host_prog = '/Users/<user>/.asdf/shims/python'

:checkhealth output:

mason: require("mason.health").check()

mason.nvim report

  • OK: neovim version >= 0.7.0
  • WARNING: Go: not available
  • WARNING: cargo: not available
  • OK: luarocks: /Users/<user>/.asdf/installs/lua/5.4.4/luarocks/bin/luarocks 3.9.1
  • OK: Ruby: ruby 2.6.8p205 (2021-07-07 revision 67951) [universal.arm64e-darwin21]
  • OK: RubyGem: 3.0.3.1
  • WARNING: Composer: not available
  • WARNING: PHP: not available
  • OK: npm: 8.19.2
  • OK: node: v19.0.0
  • OK: python3: Python 3.9.6
  • OK: pip3: pip 21.2.4 from /Library/Developer/CommandLineTools/Library/Frameworks/Python3.framework/Versions/3.9/lib/python3.9/site-packages/pip (python 3.9)
  • WARNING: javac: not available
  • WARNING: java: not available
  • WARNING: julia: not available
  • OK: wget: GNU Wget 1.21.3 built on darwin21.3.0.
  • OK: curl: curl 7.79.1 (x86_64-apple-darwin21.0) libcurl/7.79.1 (SecureTransport) LibreSSL/3.3.6 zlib/1.2.11 nghttp2/1.45.1
  • OK: gzip: Apple gzip 353.100.22
  • OK: tar: bsdtar 3.5.1 - libarchive 3.5.1 zlib/1.2.11 liblzma/5.0.5 bz2lib/1.0.8
  • OK: bash: GNU bash, version 3.2.57(1)-release (arm64-apple-darwin21)
  • OK: sh: Ok
  • OK: GitHub API rate limit. Used: 11. Remaining: 49. Limit: 60. Reset: Tue Nov 1 10:42:40 2022.
Iconium answered 1/11, 2022 at 15:29 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.