diff --git a/packages/python/plotly/plotly/graph_objects/__init__.py b/packages/python/plotly/plotly/graph_objects/__init__.py index 18fb9e23ee1..9bfb6e543de 100644 --- a/packages/python/plotly/plotly/graph_objects/__init__.py +++ b/packages/python/plotly/plotly/graph_objects/__init__.py @@ -273,7 +273,7 @@ from ..graph_objs._figurewidget import FigureWidget else: raise ImportError() - except Exception: + except ImportError: from ..missing_ipywidgets import FigureWidget else: __all__.append("FigureWidget") @@ -291,7 +291,7 @@ def __getattr__(import_name): return FigureWidget else: raise ImportError() - except Exception: + except ImportError: from ..missing_ipywidgets import FigureWidget return FigureWidget