Help us understand the problem. What is going on with this article?

pyenv 環境下で Visual Studio Code に Python プラグインを入れるとエラーが出る

More than 1 year has passed since last update.

事象

mac で pyenv 環境下で Visual Studio Code に Python プラグインを入れると

Error Linter pylint is not installed

と表示され、Lintingがうまく働かない。また補完候補も表示が期待と異なる。

setting.jsonを見る感じ、VSCodeが読みに行くPythonのPathはpythonコマンドで呼ばれる場所に設定されているはずなのですが、これがなぜか/usr/bin/pythonを読みに行ってしまうからのようです。

解決法

Preferences > Setting を開き、USER SETTING タブのJSONに

    "python.pythonPath": "pyenvで設定したPath(e.g. /User/user/.pyenv/shims/python)"

を追記

差し当たっての解決法ですが、動くようになりました。
(原因ですが未特定、bash_profileにpyenv設定を書いているのが原因?かもです)

環境

  • mac OS Sierra
  • VSCode Version 1.14.2
  • Python プラグイン 0.7.0
Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
Comments
No comments
Sign up for free and join this conversation.
If you already have a Qiita account
Why do not you register as a user and use Qiita more conveniently?
You need to log in to use this function. Qiita can be used more conveniently after logging in.
You seem to be reading articles frequently this month. Qiita can be used more conveniently after logging in.
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
ユーザーは見つかりませんでした