Skip to content

Commit 7978caf

Browse files
astrojuanlujonmmease
authored andcommitted
Fix DeprecationWarnings (#1417)
* Fix DeprecationWarning with ipywidgets >= 7 * Fix MutableSequence DeprecationWarning with Python 3.7
1 parent 3908788 commit 7978caf

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

Diff for: plotly/basewidget.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
from .serializers import custom_serializers
1616
from .version import __frontend_version__
1717

18-
@widgets.register()
18+
@widgets.register
1919
class BaseFigureWidget(BaseFigure, widgets.DOMWidget):
2020
"""
2121
Base class for FigureWidget. The FigureWidget class is code-generated as a

Diff for: plotly/grid_objs/grid_objs.py

+4-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,10 @@
55
"""
66
from __future__ import absolute_import
77

8-
from collections import MutableSequence
8+
try:
9+
from collections.abc import MutableSequence
10+
except ImportError:
11+
from collections import MutableSequence
912

1013
from requests.compat import json as _json
1114

0 commit comments

Comments
 (0)