#1131 fix for #1121 did not fix vscode behavior on ubuntu (#1149)
So while migrating to pyproject.toml fixed editable installation behavior on Ubuntu,
Pylance was still unable to figure out imports as vscode does not understand the
import script .venv/lib/python3.10/site-packages/__editable___yapf_0_40_2_finder.py
created by an editable install triggered by pip install -m venv .venv
Using https://microsoft.github.io/pyright/#/import-resolution?id=setuptools
suggestions of compat and strict mode did not resolve issues either.
So instead I revert to manually adding third_party to the python.analysis.extraPaths
setting in settings.json
diff --git a/.vscode/settings.default.json b/.vscode/settings.default.json
index 002dd29..502f59d 100644
--- a/.vscode/settings.default.json
+++ b/.vscode/settings.default.json
@@ -12,6 +12,9 @@
"editor.wordBasedSuggestions": false,
"files.trimTrailingWhitespace": true,
},
+ "python.analysis.extraPaths": [
+ "./third_party"
+ ],
"python.analysis.typeCheckingMode": "basic",
"python.languageServer": "Pylance",
"files.exclude": {