[Bug] `pythonPath` configuration option not recognized after `basedpyright` update
After a basedpyright update, I have this error when LSP is started:
unknown config option: pythonPath
My pyrightconfig.json is:
{
"venvPath": "C:/Users/<USERNAME>/scoop/persist/miniconda3/envs",
"venv": "common",
"pythonPath": "C:/Users/<USERNAME>/scoop/apps/miniconda3/current/python.exe",
"include": [
"./*" // Includes all files in the root directory and subdirectories
],
"exclude": [
"**/node_modules", // Commonly excluded in many projects
"**/__pycache__", // Exclude Python cache directories
"**/.venv", // Exclude virtual environments
"**/venv", // Exclude virtual environments
".git", // Exclude git directory
"*/site-packages/" // Exclude site-packages directories if not desired
],
}
This configuration was working before the update.
i don't think pythonPath was ever a valid option in pyrightconfig.json. it's not present in the configuration docs, only in the language server settings.
the reason you're only now seeing this error is because i made a change recently that reports invalid config as a notification in the language server instead of just silently logging it: #561
i'm pretty sure that means the setting wasn't doing anything and you can probably just remove it from your pyrightconfig.json. it should just automatically detect your python interpreter
closing this, let us know if you are still having issues and we can re-open and investigate if needed