ipywidgets-static icon indicating copy to clipboard operation
ipywidgets-static copied to clipboard

StaticInteract vanishing output with depending on variable name capitalization

Open akhmerov opened this issue 10 years ago • 1 comments

The following code produces a StaticInteract where the output disappears when the sliders are being moved or clicked:

from ipywidgets import StaticInteract, RangeWidget
StaticInteract(lambda alph, BB: (alph, BB), 
               alph=RangeWidget(0, 10, 1),
               BB=RangeWidget(0, 10, 1))

Changing alph and BB into x and y fixes the problem.

For more examples see http://nbviewer.ipython.org/urls/dl.dropboxusercontent.com/u/763585/multiletter.ipynb

Edit: Further investigation showed that the problem appears when the ordering of variable names is changed by str.tolower().

akhmerov avatar Feb 03 '15 14:02 akhmerov

Thanks! If you know how to fix this, I'll accept a PR!

jakevdp avatar Feb 03 '15 16:02 jakevdp