From c8d70e0603a37956d7c43c88f8e0e2ee8c294aec Mon Sep 17 00:00:00 2001 From: Jason Grout Date: Fri, 12 Dec 2014 19:10:37 +0000 Subject: [PATCH] Make the widget experimental error a real python warning This means it can easily be turned off too. --- IPython/html/widgets/__init__.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/IPython/html/widgets/__init__.py b/IPython/html/widgets/__init__.py index 20b692538..062f0c08b 100644 --- a/IPython/html/widgets/__init__.py +++ b/IPython/html/widgets/__init__.py @@ -25,6 +25,5 @@ from .widget_selectioncontainer import TabWidget, AccordionWidget from .widget_string import HTMLWidget, LatexWidget, TextWidget, TextareaWidget # Warn on import -from IPython.utils.warn import warn -warn("""The widget API is still considered experimental and - may change by the next major release of IPython.""") +from warnings import warn +warn("""The widget API is still considered experimental and may change in the future.""", FutureWarning, stacklevel=2)