mljar / mercury

Convert Jupyter Notebooks to Web Apps
https://RunMercury.com
GNU Affero General Public License v3.0
3.94k stars 251 forks source link

Problem with Numeric #465

Open ppv-mipt opened 2 weeks ago

ppv-mipt commented 2 weeks ago

The followin code is not working as expected in the app:

import mercury as mr
a = mr.Numeric(value=30, min=0, max=90, step=1)
b = mr.Button(label="Go")
if not b.clicked:
    mr.Stop()
c = mr.Button(label="Show")
if c.clicked:
    print(a.value)

If I first change the value of Numeric, then push the "Go" button, then press "Show" button, the value of numeric is not printed and the "Show" button disappears. If I use Slider instead of Numeric, everything works fine.

pplonski commented 2 weeks ago

Thank you @ppv-mipt for reporting the issue and thank you for code to reproduce the bug. I will take a look at it. Are you able to continue with Slider in your app?