sivakumar-mahalingam opened a new issue, #981:
URL: https://github.com/apache/burr/issues/981
The `%burr_ui` notebook integration starts the Burr server subprocess using
the literal `python` command instead of the interpreter running the notebook
kernel.
## Current behavior
Both `launch_ui_jupyter()` and `launch_ui_colab()` use:
```python
subprocess.Popen(["python", "-c", ...])
```
A Jupyter kernel can run from a virtual environment even when that
environment is not activated in the notebook server’s `PATH`. In that case,
`python` may resolve to another Python installation without Apache Burr
installed, or it may not exist at all.
As a result, `%burr_ui` can fail to start the tracking server even though
Burr is installed in the active notebook environment.
## Steps to reproduce
1. Start a Jupyter kernel from a virtual environment that is not activated
in the parent process.
2. Confirm that `sys.executable` points to the virtual environment while
`shutil.which("python")` is missing or points to another interpreter.
3. Run:
```python
%load_ext burr.integrations.notebook
%burr_ui
```
4. Observe that the Burr UI server fails to start or runs using the wrong
Python environment.
## Expected behavior
The UI server should use the same Python interpreter as the active notebook
kernel.
Both notebook launch functions should use `sys.executable` instead of the
literal `"python"` command.
## Affected code
- `burr/integrations/notebook.py`
- `launch_ui_jupyter()`
- `launch_ui_colab()`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]