Skip to content

Commit

Permalink
fix: get_metadata deprecated since traitlets 4.1 (#3894)
Browse files Browse the repository at this point in the history
  • Loading branch information
ManonMarchand authored Aug 21, 2024
1 parent c0c8eb8 commit 72b9397
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion python/ipywidgets/ipywidgets/widgets/widget.py
Original file line number Diff line number Diff line change
Expand Up @@ -684,7 +684,7 @@ def add_traits(self, **traits):
"""Dynamically add trait attributes to the Widget."""
super().add_traits(**traits)
for name, trait in traits.items():
if trait.get_metadata('sync'):
if 'sync' in trait.metadata:
self.keys.append(name)
self.send_state(name)

Expand Down

0 comments on commit 72b9397

Please sign in to comment.