Closed royfrancis closed 8 months ago
If you use the Python: Select Interpreter command (which sets the default Python for the current workspace) then Quarto will follow the version of Python specified there.
Additionally, one can use _environment
(https://quarto.org/docs/projects/environment.html):
QUARTO_PYTHON=/path/to/bin
QUARTO_R=/path/to/bin
I assume you are talking about rendering a quarto document in the terminal. I was asking about interactively working in a quarto document in VS Code using the quarto extension.
At the moment, for local use I enter the conda environment through the terminal and then launch VS Code from there and everything seems to work. But that doesn't work with remote hosts when using VS Code extension Remotes. For that to work I need to manually go into the VS Code R extension settings and set Rpath and Rterm to the R path inside the conda env. This is so impractical. That's why I brought up the Jupyter notebook example where they have the 'Select Kernal' button which makes this all so much easier.
In VS Code, When an ipynb notebook is opened, there is an option in the top right to choose the Python kernal. This gives me the flexibility to choose from the various virtual environments and conda environments that I have.
How do I choose which Python or R to use in a quarto document?