diff --git a/examples/compareBackends.py b/examples/compareBackends.py index ef179181e4..21fd0e569f 100644 --- a/examples/compareBackends.py +++ b/examples/compareBackends.py @@ -26,8 +26,6 @@ This script compares the rendering of PlotWidget's matplotlib and OpenGL backends. """ -from __future__ import annotations - __license__ = "MIT" import numpy diff --git a/src/silx/app/utils/parseutils.py b/src/silx/app/utils/parseutils.py index 655d9b4d9a..eef20e23ee 100644 --- a/src/silx/app/utils/parseutils.py +++ b/src/silx/app/utils/parseutils.py @@ -22,8 +22,6 @@ # ############################################################################*/ """Utils related to parsing""" -from __future__ import annotations - __authors__ = ["V. Valls"] __license__ = "MIT" __date__ = "28/05/2018" diff --git a/src/silx/app/view/CustomPlotSelectionWindow.py b/src/silx/app/view/CustomPlotSelectionWindow.py index 373f67eddf..271091e259 100644 --- a/src/silx/app/view/CustomPlotSelectionWindow.py +++ b/src/silx/app/view/CustomPlotSelectionWindow.py @@ -23,8 +23,6 @@ """Custom plot selection window for selecting 1D datasets to plot.""" -from __future__ import annotations - from silx.gui import qt, plot, icons import silx.gui import silx.gui.plot diff --git a/src/silx/app/view/Viewer.py b/src/silx/app/view/Viewer.py index 5ff81e8644..ae0958ee46 100644 --- a/src/silx/app/view/Viewer.py +++ b/src/silx/app/view/Viewer.py @@ -22,8 +22,6 @@ # ############################################################################*/ """Browse a data file with a GUI""" -from __future__ import annotations - __authors__ = ["V. Valls"] __license__ = "MIT" __date__ = "15/01/2019" diff --git a/src/silx/gui/colors.py b/src/silx/gui/colors.py index 57f9382ae2..d39e8bfb53 100755 --- a/src/silx/gui/colors.py +++ b/src/silx/gui/colors.py @@ -23,8 +23,6 @@ # ###########################################################################*/ """This module provides API to manage colors.""" -from __future__ import annotations - __authors__ = ["T. Vincent", "H.Payno"] __license__ = "MIT" __date__ = "29/01/2019" @@ -255,7 +253,7 @@ class _Colormappable: def _getColormapAutoscaleRange( self, - colormap: Colormap | None, + colormap: "Colormap | None", ) -> tuple[float | None, float | None]: """Returns the autoscale range for given colormap. @@ -396,7 +394,7 @@ def __init__( self.__warnBadVmin = True self.__warnBadVmax = True - def setFromColormap(self, other: Colormap): + def setFromColormap(self, other: "Colormap"): """Set this colormap using information from the `other` colormap. :param other: Colormap to use as reference. @@ -894,7 +892,7 @@ def _fromDict(dic: dict): colormap._setFromDict(dic) return colormap - def copy(self) -> Colormap: + def copy(self) -> "Colormap": """Return a copy of the Colormap.""" colormap = Colormap( name=self._name, diff --git a/src/silx/gui/dialog/ColormapDialog.py b/src/silx/gui/dialog/ColormapDialog.py index 587e557c42..63c0a2f38a 100644 --- a/src/silx/gui/dialog/ColormapDialog.py +++ b/src/silx/gui/dialog/ColormapDialog.py @@ -58,8 +58,6 @@ :attr:`ColormapDialog.sigColormapChanged`. """ # noqa -from __future__ import annotations - __authors__ = ["V.A. Sole", "T. Vincent", "H. Payno"] __license__ = "MIT" __date__ = "08/12/2020" diff --git a/src/silx/gui/dialog/_ColormapPercentileWidget.py b/src/silx/gui/dialog/_ColormapPercentileWidget.py index 7c6939607e..83b3b88fcf 100644 --- a/src/silx/gui/dialog/_ColormapPercentileWidget.py +++ b/src/silx/gui/dialog/_ColormapPercentileWidget.py @@ -1,5 +1,3 @@ -from __future__ import annotations - from silx.gui import qt from ..colors import Colormap diff --git a/src/silx/gui/dialog/test/test_datafiledialog.py b/src/silx/gui/dialog/test/test_datafiledialog.py index 1ffc1d2468..f7d0f5f169 100644 --- a/src/silx/gui/dialog/test/test_datafiledialog.py +++ b/src/silx/gui/dialog/test/test_datafiledialog.py @@ -23,8 +23,6 @@ # ###########################################################################*/ """Test for silx.gui.hdf5 module""" -from __future__ import annotations - __authors__ = ["V. Valls"] __license__ = "MIT" __date__ = "08/03/2019" diff --git a/src/silx/gui/dialog/test/test_imagefiledialog.py b/src/silx/gui/dialog/test/test_imagefiledialog.py index b98257a61d..4ca8131f39 100644 --- a/src/silx/gui/dialog/test/test_imagefiledialog.py +++ b/src/silx/gui/dialog/test/test_imagefiledialog.py @@ -23,8 +23,6 @@ # ###########################################################################*/ """Test for silx.gui.hdf5 module""" -from __future__ import annotations - __authors__ = ["V. Valls"] __license__ = "MIT" __date__ = "08/03/2019" diff --git a/src/silx/gui/plot/ImageStack.py b/src/silx/gui/plot/ImageStack.py index 8a4ca7edca..25be3fa6c2 100644 --- a/src/silx/gui/plot/ImageStack.py +++ b/src/silx/gui/plot/ImageStack.py @@ -23,8 +23,6 @@ # ###########################################################################*/ """Image stack view with data prefetch capabilty.""" -from __future__ import annotations - __authors__ = ["H. Payno"] __license__ = "MIT" __date__ = "04/03/2019" diff --git a/src/silx/gui/plot/PlotInteraction.py b/src/silx/gui/plot/PlotInteraction.py index ef8d203c29..3d9da69b49 100644 --- a/src/silx/gui/plot/PlotInteraction.py +++ b/src/silx/gui/plot/PlotInteraction.py @@ -23,8 +23,6 @@ # ###########################################################################*/ """Implementation of the interaction for the :class:`Plot`.""" -from __future__ import annotations - __authors__ = ["T. Vincent"] __license__ = "MIT" __date__ = "15/02/2019" diff --git a/src/silx/gui/plot/PlotWidget.py b/src/silx/gui/plot/PlotWidget.py index 1969b22473..8540dd2bc4 100755 --- a/src/silx/gui/plot/PlotWidget.py +++ b/src/silx/gui/plot/PlotWidget.py @@ -25,8 +25,6 @@ The :class:`PlotWidget` implements the plot API initially provided in PyMca. """ -from __future__ import annotations - __authors__ = ["V.A. Sole", "T. Vincent"] __license__ = "MIT" __date__ = "21/12/2018" @@ -68,7 +66,6 @@ from .. import qt from ._utils.panzoom import ViewConstraints -from ...gui.plot._utils.dtime_ticklayout import timestamp from ...utils.deprecation import deprecated_warning from .backends.BackendBase import BackendBase @@ -101,7 +98,7 @@ class _PlotWidgetSelection(qt.QObject): sigSelectedItemsChanged = qt.Signal() """Signal emitted whenever the list of selected items changes.""" - def __init__(self, parent: PlotWidget): + def __init__(self, parent: "PlotWidget"): assert isinstance(parent, PlotWidget) super().__init__(parent=parent) @@ -380,7 +377,7 @@ class PlotWidget(qt.QMainWindow): def __init__( self, - parent: qt.Qt.Widget | None = None, + parent: qt.QWidget | None = None, backend: BackendType = None, ): self._autoreplot = False @@ -666,7 +663,7 @@ def _getDirtyPlot(self) -> bool | Literal["overlay"]: # Default Qt context menu - def contextMenuEvent(self, event: qt.Qt.QContextEvent): + def contextMenuEvent(self, event: qt.QContextMenuEvent): """Override QWidget.contextMenuEvent to implement the context menu""" menu = qt.QMenu(self) from .actions.control import ZoomBackAction # Avoid cyclic import @@ -1240,7 +1237,7 @@ def addCurve( # tickMode to TickMode.TIME_SERIES and, if necessary, set the axis # to the correct time zone. if len(x) > 0 and isinstance(x[0], dt.datetime): - x = [timestamp(d) for d in x] + x = [d.timestamp() for d in x] curve.setData(x, y, xerror, yerror, baseline=baseline, copy=copy) diff --git a/src/silx/gui/plot/_utils/dtime_ticklayout.py b/src/silx/gui/plot/_utils/dtime_ticklayout.py index 6271265042..466da293d4 100644 --- a/src/silx/gui/plot/_utils/dtime_ticklayout.py +++ b/src/silx/gui/plot/_utils/dtime_ticklayout.py @@ -21,7 +21,7 @@ # THE SOFTWARE. # # ###########################################################################*/ -from __future__ import annotations + """This module implements date-time labels layout on graph axes.""" @@ -35,9 +35,7 @@ import enum import logging import math -import time -import dateutil.tz from dateutil.relativedelta import relativedelta @@ -54,49 +52,6 @@ SECONDS_PER_MONTH_AVERAGE = SECONDS_PER_YEAR / 12 # Seconds per average month -# No dt.timezone in Python 2.7 so we use dateutil.tz.tzutc -_EPOCH = dt.datetime(1970, 1, 1, tzinfo=dateutil.tz.tzutc()) - - -def timestamp(dtObj): - """Returns POSIX timestamp of a datetime objects. - - If the dtObj object has a timestamp() method (python 3.3), this is - used. Otherwise (e.g. python 2.7) it is calculated here. - - The POSIX timestamp is a floating point value of the number of seconds - since the start of an epoch (typically 1970-01-01). For details see: - https://docs.python.org/3/library/datetime.html#datetime.datetime.timestamp - - :param datetime.datetime dtObj: date-time representation. - :return: POSIX timestamp - :rtype: float - """ - if hasattr(dtObj, "timestamp"): - return dtObj.timestamp() - else: - # Back ported from Python 3.5 - if dtObj.tzinfo is None: - return ( - time.mktime( - ( - dtObj.year, - dtObj.month, - dtObj.day, - dtObj.hour, - dtObj.minute, - dtObj.second, - -1, - -1, - -1, - ) - ) - + dtObj.microsecond / 1e6 - ) - else: - return (dtObj - _EPOCH).total_seconds() - - @enum.unique class DtUnit(enum.Enum): YEARS = 0 diff --git a/src/silx/gui/plot/_utils/panzoom.py b/src/silx/gui/plot/_utils/panzoom.py index cb803443ce..62d09b41e9 100644 --- a/src/silx/gui/plot/_utils/panzoom.py +++ b/src/silx/gui/plot/_utils/panzoom.py @@ -23,8 +23,6 @@ # ###########################################################################*/ """Functions to apply pan and zoom on a Plot""" -from __future__ import annotations - __authors__ = ["T. Vincent", "V. Valls"] __license__ = "MIT" __date__ = "08/08/2017" diff --git a/src/silx/gui/plot/backends/BackendBase.py b/src/silx/gui/plot/backends/BackendBase.py index 2088491a65..be2e22c267 100755 --- a/src/silx/gui/plot/backends/BackendBase.py +++ b/src/silx/gui/plot/backends/BackendBase.py @@ -28,8 +28,6 @@ This API is a simplified version of PyMca PlotBackend API. """ -from __future__ import annotations - __authors__ = ["V.A. Sole", "T. Vincent"] __license__ = "MIT" __date__ = "21/12/2018" diff --git a/src/silx/gui/plot/backends/BackendMatplotlib.py b/src/silx/gui/plot/backends/BackendMatplotlib.py index f5127ad982..823c4722df 100755 --- a/src/silx/gui/plot/backends/BackendMatplotlib.py +++ b/src/silx/gui/plot/backends/BackendMatplotlib.py @@ -23,20 +23,17 @@ # ###########################################################################*/ """Matplotlib Plot backend.""" -from __future__ import annotations -from typing import Literal - -from .utils import Range, ensureAspectRatio, findDimToKeep - __authors__ = ["V.A. Sole", "T. Vincent, H. Payno"] __license__ = "MIT" __date__ = "21/12/2018" +from typing import Literal import logging import datetime as dt import numpy +from .utils import Range, ensureAspectRatio, findDimToKeep from ... import qt # First of all init matplotlib and set its backend @@ -64,7 +61,6 @@ from .._utils.dtime_ticklayout import ( calcTicks, formatDatetimes, - timestamp, ) from ...qt import inspect as qt_inspect from .... import config @@ -205,7 +201,7 @@ def tick_values(self, vmin, vmax): dtTicks, self._spacing, self._unit = calcTicks(dtMin, dtMax, self.numTicks) # Convert datetime back to time stamps. - ticks = [timestamp(dtTick) for dtTick in dtTicks] + ticks = [dtTick.timestamp() for dtTick in dtTicks] return ticks diff --git a/src/silx/gui/plot/backends/BackendOpenGL.py b/src/silx/gui/plot/backends/BackendOpenGL.py index 7f73f21afe..17cff0bdcd 100755 --- a/src/silx/gui/plot/backends/BackendOpenGL.py +++ b/src/silx/gui/plot/backends/BackendOpenGL.py @@ -23,8 +23,6 @@ # ############################################################################*/ """OpenGL Plot backend.""" -from __future__ import annotations - __authors__ = ["T. Vincent"] __license__ = "MIT" __date__ = "21/12/2018" diff --git a/src/silx/gui/plot/backends/glutils/GLPlotFrame.py b/src/silx/gui/plot/backends/glutils/GLPlotFrame.py index 5dedd803c7..a30ef0c264 100644 --- a/src/silx/gui/plot/backends/glutils/GLPlotFrame.py +++ b/src/silx/gui/plot/backends/glutils/GLPlotFrame.py @@ -25,8 +25,6 @@ This modules provides the rendering of plot titles, axes and grid. """ -from __future__ import annotations - __authors__ = ["T. Vincent"] __license__ = "MIT" __date__ = "03/04/2017" @@ -58,7 +56,6 @@ calcTicksAdaptive, formatDatetimes, ) -from ..._utils.dtime_ticklayout import timestamp _logger = logging.getLogger(__name__) @@ -466,7 +463,7 @@ def _ticksGenerator(self): ticks = formatDatetimes(visibleDatetimes, spacing, unit) for tickDateTime, text in ticks.items(): - dataPos = timestamp(tickDateTime) + dataPos = tickDateTime.timestamp() xPixel = x0 + (dataPos - dataMin) * xScale yPixel = y0 + (dataPos - dataMin) * yScale yield ((xPixel, yPixel), dataPos, text) diff --git a/src/silx/gui/plot/backends/glutils/GLText.py b/src/silx/gui/plot/backends/glutils/GLText.py index 136ce144ce..37147e7f78 100644 --- a/src/silx/gui/plot/backends/glutils/GLText.py +++ b/src/silx/gui/plot/backends/glutils/GLText.py @@ -26,8 +26,6 @@ It provides Latin-1 (ISO8859-1) characters for one monospace font at one size. """ -from __future__ import annotations - __authors__ = ["T. Vincent"] __license__ = "MIT" __date__ = "03/04/2017" diff --git a/src/silx/gui/plot/items/_cache.py b/src/silx/gui/plot/items/_cache.py index cae5fabbca..bacc81d3c8 100644 --- a/src/silx/gui/plot/items/_cache.py +++ b/src/silx/gui/plot/items/_cache.py @@ -1,6 +1,3 @@ -from __future__ import annotations - - from collections import OrderedDict diff --git a/src/silx/gui/plot/items/axis.py b/src/silx/gui/plot/items/axis.py index 844ea1f5e5..323da9be25 100644 --- a/src/silx/gui/plot/items/axis.py +++ b/src/silx/gui/plot/items/axis.py @@ -23,8 +23,6 @@ # ###########################################################################*/ """This module provides the class for axes of the :class:`PlotWidget`.""" -from __future__ import annotations - __authors__ = ["V. Valls"] __license__ = "MIT" __date__ = "22/11/2018" diff --git a/src/silx/gui/plot/items/core.py b/src/silx/gui/plot/items/core.py index 5900a32a20..4222ea22b3 100644 --- a/src/silx/gui/plot/items/core.py +++ b/src/silx/gui/plot/items/core.py @@ -23,8 +23,6 @@ # ###########################################################################*/ """This module provides the base class for items of the :class:`Plot`.""" -from __future__ import annotations - __authors__ = ["T. Vincent"] __license__ = "MIT" __date__ = "08/12/2020" diff --git a/src/silx/gui/plot/items/curve.py b/src/silx/gui/plot/items/curve.py index 0a249a2ab1..ff649408bb 100644 --- a/src/silx/gui/plot/items/curve.py +++ b/src/silx/gui/plot/items/curve.py @@ -23,8 +23,6 @@ # ###########################################################################*/ """This module provides the :class:`Curve` item of the :class:`Plot`.""" -from __future__ import annotations - __authors__ = ["T. Vincent"] __license__ = "MIT" __date__ = "24/04/2018" diff --git a/src/silx/gui/plot/items/marker.py b/src/silx/gui/plot/items/marker.py index d258d19f50..5f0a5ecb17 100755 --- a/src/silx/gui/plot/items/marker.py +++ b/src/silx/gui/plot/items/marker.py @@ -23,8 +23,6 @@ # ###########################################################################*/ """This module provides markers item of the :class:`Plot`.""" -from __future__ import annotations - __authors__ = ["T. Vincent"] __license__ = "MIT" __date__ = "06/03/2017" diff --git a/src/silx/gui/plot/tools/PlotToolButton.py b/src/silx/gui/plot/tools/PlotToolButton.py index 1f28e99933..693eaa55cf 100644 --- a/src/silx/gui/plot/tools/PlotToolButton.py +++ b/src/silx/gui/plot/tools/PlotToolButton.py @@ -25,8 +25,6 @@ plot tools for a toolbar. """ -from __future__ import annotations - __authors__ = ["V. Valls"] __license__ = "MIT" __date__ = "20/12/2023" diff --git a/src/silx/gui/plot/tools/_PlotOptionButton.py b/src/silx/gui/plot/tools/_PlotOptionButton.py index b9346b4cdb..804f443bd4 100644 --- a/src/silx/gui/plot/tools/_PlotOptionButton.py +++ b/src/silx/gui/plot/tools/_PlotOptionButton.py @@ -1,5 +1,3 @@ -from __future__ import annotations - from typing import TYPE_CHECKING from silx.gui import qt import qtawesome @@ -40,7 +38,7 @@ def _customControlButtonMenu(self): self._menu.addAction(plot.getCrosshairAction()) self._menu.addAction(plot.getPanWithArrowKeysAction()) - def setPlot(self, plot: PlotWindow): + def setPlot(self, plot: "PlotWindow"): from ..PlotWindow import PlotWindow # noqa: F811 avoid cyclic import if not isinstance(plot, PlotWindow): diff --git a/src/silx/gui/plot/tools/profile/core.py b/src/silx/gui/plot/tools/profile/core.py index 9b698654f6..f764bcea85 100644 --- a/src/silx/gui/plot/tools/profile/core.py +++ b/src/silx/gui/plot/tools/profile/core.py @@ -23,8 +23,6 @@ # ###########################################################################*/ """This module define core objects for profile tools.""" -from __future__ import annotations - __authors__ = ["V.A. Sole", "T. Vincent", "P. Knobel", "H. Payno", "V. Valls"] __license__ = "MIT" __date__ = "17/04/2020" @@ -36,7 +34,7 @@ from silx.image.bilinear import BilinearImage from silx.gui import qt from silx.gui import colors -import silx.gui.plot.items +from ...items.core import Item class CurveProfileData(typing.NamedTuple): @@ -188,7 +186,7 @@ def __profileWindowAboutToClose(self): pass def computeProfile( - self, item: silx.gui.plot.items.Item + self, item: Item ) -> CurveProfileData | ImageProfileData | RgbaProfileData | CurvesProfileData: """ Compute the profile which will be displayed. diff --git a/src/silx/gui/plot3d/ParamTreeView.py b/src/silx/gui/plot3d/ParamTreeView.py index 8392a689eb..f3dc267b55 100644 --- a/src/silx/gui/plot3d/ParamTreeView.py +++ b/src/silx/gui/plot3d/ParamTreeView.py @@ -32,8 +32,6 @@ :class:`Vector4DEditor`, :class:`IntSliderEditor`, :class:`BooleanEditor` """ -from __future__ import annotations - __authors__ = ["T. Vincent"] __license__ = "MIT" __date__ = "05/12/2017" diff --git a/src/silx/gui/utils/glutils/__init__.py b/src/silx/gui/utils/glutils/__init__.py index bef1df87e2..88094e2c88 100644 --- a/src/silx/gui/utils/glutils/__init__.py +++ b/src/silx/gui/utils/glutils/__init__.py @@ -23,9 +23,6 @@ # ###########################################################################*/ """This module provides the :func:`isOpenGLAvailable` utility function.""" -from __future__ import annotations - - import os import sys import subprocess diff --git a/src/silx/gui/utils/matplotlib.py b/src/silx/gui/utils/matplotlib.py index 0bf99adbb1..1648497075 100644 --- a/src/silx/gui/utils/matplotlib.py +++ b/src/silx/gui/utils/matplotlib.py @@ -30,8 +30,6 @@ to the used backend. """ -from __future__ import annotations - __authors__ = ["T. Vincent"] __license__ = "MIT" __date__ = "02/05/2018" diff --git a/src/silx/gui/widgets/FloatEdit.py b/src/silx/gui/widgets/FloatEdit.py index 2f87d79bda..31d56cc473 100644 --- a/src/silx/gui/widgets/FloatEdit.py +++ b/src/silx/gui/widgets/FloatEdit.py @@ -23,8 +23,6 @@ # ###########################################################################*/ """Module contains a float editor""" -from __future__ import annotations - __authors__ = ["V.A. Sole", "T. Vincent"] __license__ = "MIT" __date__ = "02/10/2017" diff --git a/src/silx/gui/widgets/FrameBrowser.py b/src/silx/gui/widgets/FrameBrowser.py index e89652fbf7..fc5872415b 100644 --- a/src/silx/gui/widgets/FrameBrowser.py +++ b/src/silx/gui/widgets/FrameBrowser.py @@ -21,17 +21,18 @@ # THE SOFTWARE. # # ###########################################################################*/ -from __future__ import annotations + """This module defines two main classes: - - :class:`FrameBrowser`: a widget with 4 buttons (first, previous, next, - last) to browse between frames and a text entry to access a specific frame - by typing it's number) - - :class:`HorizontalSliderWithBrowser`: a FrameBrowser with an additional - slider. This class inherits :class:`qt.QAbstractSlider`. +- :class:`FrameBrowser`: a widget with 4 buttons (first, previous, next, + last) to browse between frames and a text entry to access a specific frame + by typing it's number) +- :class:`HorizontalSliderWithBrowser`: a FrameBrowser with an additional + slider. This class inherits :class:`qt.QAbstractSlider`. """ + from silx.gui import qt from silx.gui import icons diff --git a/src/silx/gui/widgets/StackedProgressBar.py b/src/silx/gui/widgets/StackedProgressBar.py index 3eee8085de..281eb9cce0 100644 --- a/src/silx/gui/widgets/StackedProgressBar.py +++ b/src/silx/gui/widgets/StackedProgressBar.py @@ -22,7 +22,6 @@ # # ###########################################################################*/ -from __future__ import annotations from typing import NamedTuple, Any @@ -67,7 +66,7 @@ class StackedProgressBar(qt.QProgressBar): Multiple stacked progress bar in single component """ - def __init__(self, parent: qt.Qwidget | None = None): + def __init__(self, parent: qt.QWidget | None = None): super().__init__(parent=parent) self.__stacks: dict[str, ProgressItem] = {} self._animated: int = 0 diff --git a/src/silx/gui/widgets/UrlList.py b/src/silx/gui/widgets/UrlList.py index 669ca61b0b..39f22b9695 100644 --- a/src/silx/gui/widgets/UrlList.py +++ b/src/silx/gui/widgets/UrlList.py @@ -22,7 +22,6 @@ # # ###########################################################################*/ -from __future__ import annotations import logging from collections.abc import Iterable diff --git a/src/silx/io/_sliceh5.py b/src/silx/io/_sliceh5.py index 4d63ab448e..fb76b4cb03 100644 --- a/src/silx/io/_sliceh5.py +++ b/src/silx/io/_sliceh5.py @@ -22,8 +22,6 @@ # ############################################################################*/ """Provides a wrapper to expose a dataset slice as a `commonh5.Dataset`.""" -from __future__ import annotations - from typing import Union import h5py diff --git a/src/silx/io/h5py_utils.py b/src/silx/io/h5py_utils.py index fa54293eb7..ced16f3eef 100644 --- a/src/silx/io/h5py_utils.py +++ b/src/silx/io/h5py_utils.py @@ -20,7 +20,7 @@ # THE SOFTWARE. # # ############################################################################*/ -from __future__ import annotations + """ This module provides utility methods on top of h5py, mainly to handle diff --git a/src/silx/io/test/test_url.py b/src/silx/io/test/test_url.py index 7b8380dcee..ac6dfeac14 100644 --- a/src/silx/io/test/test_url.py +++ b/src/silx/io/test/test_url.py @@ -22,8 +22,6 @@ # ############################################################################*/ """Tests for url module""" -from __future__ import annotations - __authors__ = ["V. Valls"] __license__ = "MIT" __date__ = "29/01/2018" diff --git a/src/silx/io/url.py b/src/silx/io/url.py index 67b9e2be46..18af14146f 100644 --- a/src/silx/io/url.py +++ b/src/silx/io/url.py @@ -23,8 +23,6 @@ # ###########################################################################*/ """URL module""" -from __future__ import annotations - __authors__ = ["V. Valls"] __license__ = "MIT" __date__ = "29/01/2018" diff --git a/src/silx/resources/__init__.py b/src/silx/resources/__init__.py index b7763b10e1..0a601c1e0c 100644 --- a/src/silx/resources/__init__.py +++ b/src/silx/resources/__init__.py @@ -53,8 +53,6 @@ ) """ -from __future__ import annotations - __authors__ = ["V.A. Sole", "Thomas Vincent", "J. Kieffer"] __license__ = "MIT" __date__ = "08/03/2019" diff --git a/src/silx/test/__init__.py b/src/silx/test/__init__.py index 277cf39e48..f9231c5662 100644 --- a/src/silx/test/__init__.py +++ b/src/silx/test/__init__.py @@ -23,8 +23,6 @@ # ###########################################################################*/ """This package provides test of the root modules""" -from __future__ import annotations - import importlib import os.path import subprocess