Package: cmor / 2.9.1-5

silence-warning.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
Index: cmor-2.9.1/Lib/__init__.py
===================================================================
--- cmor-2.9.1.orig/Lib/__init__.py
+++ cmor-2.9.1/Lib/__init__.py
@@ -3,7 +3,11 @@ from cmor_const import *
 from pywrapper import axis,variable,write,setup,load_table,dataset,set_table,zfactor,close,grid,set_grid_mapping,time_varying_grid_coordinate,set_cur_dataset_attribute,get_cur_dataset_attribute,has_cur_dataset_attribute,create_output_path,set_variable_attribute,get_variable_attribute,has_variable_attribute
 
 try:
-  from check_CMOR_compliant import checkCMOR
+   from check_CMOR_compliant import checkCMOR
+except ImportError as e:
+   if e == 'No module named cdms2':
+      print("Warning: cdms2 module not found")
+      pass
 except Exception,err:
   print err
   pass