Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
Correct GridSpec override behavior #748
Closes #514 .
Removed the 'warn' mode to keep only 'error' and 'override'.
WIP since the object deletion feels like a kludge and an additional latent bug was noticed during 'error' behavior resulting from line 937-945.
The if-statement on
Behavior can be observed in a notebook with the following cells
pn.extension() gs = pn.GridSpec(mode='error') gs[0:2, 0] = pn.widgets.MultiSelect(options=[0, 1, 2, 3], name='Initial') display(gs.objects) gs
The following cell will raise an Exception.
gs[0:1, 0] = pn.widgets.MultiSelect(options=[5, 6, 7], name='Second') gs[1:2, 0] = pn.widgets.MultiSelect(options=[9, 10, 11], name='Third') display(gs.objects)
This cell will show that the state of the gs object now still contains the MultiSelect object despite erroring.