From 654a6ac93513c3cc1ef97cacd782ff674c6f4559 Mon Sep 17 00:00:00 2001 From: Alexandre Marie Date: Tue, 9 Jul 2019 10:20:20 +0200 Subject: New upstream version 0.11.0+dfsg --- silx/gui/data/ArrayTableModel.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'silx/gui/data/ArrayTableModel.py') diff --git a/silx/gui/data/ArrayTableModel.py b/silx/gui/data/ArrayTableModel.py index ad4d33a..8805241 100644 --- a/silx/gui/data/ArrayTableModel.py +++ b/silx/gui/data/ArrayTableModel.py @@ -1,7 +1,7 @@ # coding: utf-8 # /*########################################################################## # -# Copyright (c) 2016-2017 European Synchrotron Radiation Facility +# Copyright (c) 2016-2019 European Synchrotron Radiation Facility # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal @@ -245,8 +245,7 @@ class ArrayTableModel(qt.QAbstractTableModel): if index.isValid() and role == qt.Qt.EditRole: try: # cast value to same type as array - v = numpy.asscalar( - numpy.array(value, dtype=self._array.dtype)) + v = numpy.array(value, dtype=self._array.dtype).item() except ValueError: return False -- cgit v1.2.3