Commit f6c00fb3 authored by Daniel Scheffler's avatar Daniel Scheffler
Browse files

Caught ValueError: I/O operation on closed file within GMS_logger.__del__....


Caught ValueError: I/O operation on closed file within GMS_logger.__del__. Fixed a static TLS ImportError during runtime of SICOR when scikit-learn>0.22 is imported. Added missing requirements numba and llvmlite to environment_gms_preprocessing.yml.
Signed-off-by: Daniel Scheffler's avatarDaniel Scheffler <danschef@gfz-potsdam.de>
parent 3170a358
......@@ -2,6 +2,14 @@
History
=======
0.18.5 (2020-09-25)
-------------------
* Caught ValueError: I/O operation on closed file within GMS_logger.__del__.
* Fixed a static TLS ImportError during runtime of SICOR when scikit-learn>0.22 is imported.
* Added missing requirements numba and llvmlite to environment_gms_preprocessing.yml.
0.18.4 (2020-09-18)
-------------------
......
......@@ -25,6 +25,7 @@
# with this program. If not, see <http://www.gnu.org/licenses/>.
import os
import sklearn # noqa # avoids a static TLS ImportError during runtime of SICOR (when importing sklearn there)
if 'MPLBACKEND' not in os.environ:
os.environ['MPLBACKEND'] = 'Agg'
......
......@@ -191,7 +191,11 @@ class GMS_logger(logging.Logger):
print(inF.read())
def __del__(self):
self.close()
try:
self.close()
except ValueError as e:
if str(e) == 'I/O operation on closed file':
pass
def __enter__(self):
return self
......
......@@ -24,5 +24,5 @@
# You should have received a copy of the GNU Lesser General Public License along
# with this program. If not, see <http://www.gnu.org/licenses/>.
__version__ = '0.18.4'
__versionalias__ = '20200918.01'
__version__ = '0.18.5'
__versionalias__ = '20200925.01'
......@@ -16,7 +16,7 @@ dependencies:
- ipython
- matplotlib
- basemap
- scikit-learn=0.19.1 # pinned due to spechomo classifiers created with this version
- scikit-learn=0.23.2 # pinned due to spechomo classifiers created with this version
- shapely
- pyhdf
- python-fmask
......@@ -34,6 +34,8 @@ dependencies:
- pyhdf
- h5py
- pytables
- numba
- llvmlite
- pip:
- dicttoxml
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment