Skip to content

Commit

Permalink
fix: import is not found under some circumstances
Browse files Browse the repository at this point in the history
Signed-off-by: Jack Cherng <jfcherng@gmail.com>
  • Loading branch information
jfcherng committed May 6, 2024
1 parent d2c049b commit 273a22c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ def python_path(cls, settings: DottedDict, workspace_folders: list[WorkspaceFold
return python_path

if workspace_folders:
workspace_folder = Path(workspace_folders[0].path)
workspace_folder = Path(workspace_folders[0].path).resolve()
for folder in (workspace_folder, *workspace_folder.parents):
if python_path := cls.python_path_from_venv(folder):
return str(python_path)
Expand Down

0 comments on commit 273a22c

Please sign in to comment.