I am currently able to use quick fix to auto import python functions from external typings such as from typing import List.
Python module quick fix import
However, I am unable to detect local functions/classes for import. For example: If I have the data class SampleDataClass in dataclasses.py, and I reference it in a function in test_file.py, VSCode is unable to detect it and I have to manually type out the import path for the dataclass.
I have the following extensions enabled:
- Python
- Pylance
- Intellicode
My settings.json includes:
{
"python.envFile": "${workspaceFolder}/.env",
"python.languageServer": "Pylance",
"python.analysis.indexing": true,
"python.formatting.provider": "black",
"python.analysis.autoImportCompletions": true,
"python.analysis.autoSearchPaths": true,
"python.autoComplete.extraPaths": ["~/Development/<django repo name>/server"],
"python.analysis.extraPaths": ["~/Development/<django repo name>/server"],
"vsintellicode.features.python.deepLearning": "enabled",
}
I am using poetry for my virtual environment which is located at ~/Development/<django repo name>/.venv
Is there something that I'm missing?
