From a9a470c841eeb5f0fb2c2ae9639f6c2833f03d00 Mon Sep 17 00:00:00 2001 From: Charles Harris Date: Sun, 9 Jun 2013 21:44:06 -0600 Subject: DEP: Deprecate the oldnumeric and numarray modules. The numarray and oldnumeric modules are deprecated. This is a bit tricky as raising a DeprecationWarning on import causes an error when tests are run. To deal with that, a ModuleDeprecationWarning class is added to numpy and NoseTester is modified to ignore that warning during testing. Closes #2905 --- numpy/numarray/__init__.py | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'numpy/numarray') diff --git a/numpy/numarray/__init__.py b/numpy/numarray/__init__.py index 706ec1c33..468324ced 100644 --- a/numpy/numarray/__init__.py +++ b/numpy/numarray/__init__.py @@ -1,5 +1,8 @@ from __future__ import division, absolute_import, print_function +import warnings +from numpy import ModuleDeprecationWarning + from .util import * from .numerictypes import * from .functions import * @@ -14,6 +17,9 @@ from . import ufuncs from . import compat from . import session +_msg = "The numarray module will be dropped in Numpy 1.9" +warnings.warn(_msg, ModuleDeprecationWarning) + __all__ = ['session', 'numerictypes'] __all__ += util.__all__ __all__ += numerictypes.__all__ -- cgit v1.2.1