Closed
Description
Very simple Shiny Express code can either magically work, or magically not work, depending on whether shinywidgets
package is installed. Steps to reproduce:
- Create 2 virtual environments,
venv1
,venv2
. Let's assume 2 terminal windows. In 1st:
cd tmp
python3 -m venv venv1
source venv1/bin/activate
Similarly for for venv2
.
2. In venv1, install:
pip install shiny plotly[express] pandas
- In venv2, install:
pip install shiny plotly[express] pandas shinywidgets
- Use following simple app:
import plotly.express as px
from shiny.express import input, ui
ui.input_slider("n", "Number of sth", 1, 100, 20)
fig = px.line(x=[1, 2, 3], y=[4, 1, 2])
fig
- Run in
venv1
, and observe that a plot is properly rendered:
shiny run -r -b plot_ex.py
- Now run in
venv2
, and observe that a plot isn't rendered:
shiny run -r -b plot_ex.py
Metadata
Metadata
Assignees
Labels
No labels