From 0af0218d1e5479667c8d33959513407dc0f12d59 Mon Sep 17 00:00:00 2001 From: Vanya Belyaev Date: Sun, 8 Sep 2024 11:39:19 +0200 Subject: [PATCH] warnings? --- ostap/core/__init__.py | 6 ++++-- ostap/core/ostap_types.py | 3 ++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/ostap/core/__init__.py b/ostap/core/__init__.py index a4e4c736..fc3465a9 100755 --- a/ostap/core/__init__.py +++ b/ostap/core/__init__.py @@ -4,9 +4,11 @@ import sys, os if sys.warnoptions or os.environ.get ( 'OSTAP_CMAKE_TEST', False ) : import warnings - with warnings.catch_warnings(): - warnings.simplefilter ( "always" ) + with warnings.catch_warnings() : + warnings.simplefilter ( "ignore" , category = DeprecationWarning ) + warnings.simplefilter ( "ignore" , category = UserWarning ) import cppyy + # ============================================================================= ## The END # ============================================================================= diff --git a/ostap/core/ostap_types.py b/ostap/core/ostap_types.py index b7842ced..87c511b8 100644 --- a/ostap/core/ostap_types.py +++ b/ostap/core/ostap_types.py @@ -85,7 +85,8 @@ if sys.warnoptions or os.environ.get ( 'OSTAP_CMAKE_TEST', False ) : import warnings with warnings.catch_warnings(): - warnings.simplefilter ( "always" ) + warnings.simplefilter ( "ignore" , category = DeprecationWarning ) + warnings.simplefilter ( "ignore" , category = UserWarning ) import cppyy else : import cppyy