Skip to content

Commit

Permalink
Fix #2631 - handle RuntimeError: dictionary changed size during itera…
Browse files Browse the repository at this point in the history
…tion (#2632)

* Fix #2631 - handle RuntimeError: dictionary changed size during iteration

* Update panel/reactive.py

Co-authored-by: Marc Skov Madsen <masma@orsted.dk>
Co-authored-by: Philipp Rudiger <prudiger@anaconda.com>
  • Loading branch information
3 people committed Sep 1, 2021
1 parent 42e1470 commit 427285e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions panel/reactive.py
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,7 @@ def _param_change(self, *events):
if not msg:
return

for ref, (model, parent) in self._models.items():
for ref, (model, _) in self._models.copy().items():
self._apply_update(events, msg, model, ref)

def _process_events(self, events):
Expand Down Expand Up @@ -939,7 +939,7 @@ def _process_events(self, events):
finally:
self._updating = False
# Ensure that if the data was changed in a user
# callback, we still send the updated data
# callback, we still send the updated data
if old_data is not self.value:
self._update_cds()
if 'indices' in events:
Expand Down

0 comments on commit 427285e

Please sign in to comment.