Closed
Description
In the Python samples that load a Q# project, we often set the project_root as "." However this is relative to the process working directory, which is likely the workspace in VS Code, which means the script fails to run if not at the root of the workspace.
We should probably change the Python samples to use something like,
from pathlib import Path
this_dir = Path(__file__).resolve().parent
qsharp.init(project_root=this_dir)