From 9edd2d73ff1267f9ab44c70bf0bc5a5ff077fcd0 Mon Sep 17 00:00:00 2001 From: Silke Schomann Date: Tue, 10 Dec 2024 10:53:09 +0000 Subject: [PATCH] Removed obsolete __future__ imports --- scripts/start_mslice.py | 2 -- src/mslice/app/mainwindow.py | 2 -- src/mslice/cli/__init__.py | 2 -- src/mslice/cli/_mslice_commands.py | 2 -- src/mslice/cli/plotfunctions.py | 2 -- src/mslice/cli/views/cli_data_loader.py | 3 --- src/mslice/cli/views/cli_powder.py | 2 -- src/mslice/models/colors.py | 2 -- src/mslice/models/cut/cut_functions.py | 2 -- src/mslice/models/intensity_correction_algs.py | 1 - src/mslice/models/labels.py | 1 - src/mslice/models/projection/powder/make_projection.py | 1 - .../projection/powder/mantid_projection_calculator.py | 2 -- .../models/projection/powder/projection_calculator.py | 1 - src/mslice/models/slice/slice_functions.py | 1 - src/mslice/models/units.py | 2 -- src/mslice/models/workspacemanager/file_io.py | 1 - .../models/workspacemanager/workspace_algorithms.py | 2 -- src/mslice/plotting/backend.py | 1 - src/mslice/plotting/globalfiguremanager.py | 1 - src/mslice/plotting/plot_window/plot_options.py | 2 -- src/mslice/plotting/plot_window/plot_window.py | 2 -- src/mslice/presenters/cut_widget_presenter.py | 2 -- src/mslice/presenters/data_loader_presenter.py | 2 -- src/mslice/presenters/main_presenter.py | 1 - src/mslice/presenters/plot_options_presenter.py | 1 - src/mslice/presenters/powder_projection_presenter.py | 2 -- src/mslice/presenters/slice_widget_presenter.py | 1 - src/mslice/presenters/validation_decorators.py | 1 - src/mslice/presenters/workspace_manager_presenter.py | 1 - src/mslice/util/compat.py | 2 -- src/mslice/util/mantid/algorithm_wrapper.py | 2 -- src/mslice/util/qt/qapp.py | 1 - src/mslice/views/cut_plotter.py | 1 - src/mslice/views/interfaces/powder_projection_view.py | 3 --- src/mslice/views/interfaces/slice_view.py | 3 --- src/mslice/views/interfaces/workspace_view.py | 3 --- src/mslice/views/slice_plotter.py | 2 -- src/mslice/widgets/cut/command.py | 9 --------- src/mslice/widgets/cut/cut.py | 2 -- src/mslice/widgets/dataloader/dataloader.py | 2 -- src/mslice/widgets/dataloader/inputdialog.py | 1 - src/mslice/widgets/ipythonconsole/ipython_widget.py | 3 --- src/mslice/widgets/projection/powder/powder.py | 2 -- src/mslice/widgets/slice/slice.py | 2 -- src/mslice/widgets/status/status.py | 2 -- src/mslice/workspace/histo_mixin.py | 1 - src/mslice/workspace/histogram_workspace.py | 1 - src/mslice/workspace/pixel_mixin.py | 1 - src/mslice/workspace/pixel_workspace.py | 1 - src/mslice/workspace/workspace.py | 1 - src/mslice/workspace/workspace_mixin.py | 1 - tests/cut_widget_presenter_test.py | 1 - tests/data_loader_test.py | 1 - tests/figure_manager_test.py | 1 - tests/file_io_test.py | 2 -- tests/histogram_workspace_test.py | 1 - tests/intensity_correction_algs_test.py | 2 -- tests/intensity_correction_util_test.py | 2 -- tests/main_presenter_test.py | 1 - tests/pixel_workspace_test.py | 1 - tests/plot_figure_test.py | 1 - tests/plot_options_presenter_test.py | 1 - tests/powder_projection_presenter_test.py | 1 - tests/slice_algorithm_test.py | 2 -- tests/slice_functions_test.py | 2 -- tests/slice_plotter_presenter_test.py | 1 - tests/workspace_algorithms_test.py | 2 -- tests/workspace_provider_test.py | 1 - tests/workspace_test.py | 1 - tests/workspacemanager_presenter_test.py | 1 - 71 files changed, 119 deletions(-) diff --git a/scripts/start_mslice.py b/scripts/start_mslice.py index 086b447c5..687f0f107 100644 --- a/scripts/start_mslice.py +++ b/scripts/start_mslice.py @@ -1,5 +1,3 @@ #!/usr/bin/python -from __future__ import absolute_import - from mslice.app import main main() diff --git a/src/mslice/app/mainwindow.py b/src/mslice/app/mainwindow.py index 113eedd66..9a62fc474 100644 --- a/src/mslice/app/mainwindow.py +++ b/src/mslice/app/mainwindow.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from qtpy.QtWidgets import QApplication, QMainWindow, QLabel, QMenu, QStackedLayout from mslice.models.units import EnergyUnits diff --git a/src/mslice/cli/__init__.py b/src/mslice/cli/__init__.py index 21a9217be..1646bdcbc 100644 --- a/src/mslice/cli/__init__.py +++ b/src/mslice/cli/__init__.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from mslice.app import is_gui from mslice.plotting.pyplot import * # noqa: F401, F403 from matplotlib.axes import Axes diff --git a/src/mslice/cli/_mslice_commands.py b/src/mslice/cli/_mslice_commands.py index a8732c434..597823b93 100644 --- a/src/mslice/cli/_mslice_commands.py +++ b/src/mslice/cli/_mslice_commands.py @@ -1,6 +1,4 @@ """Defines the additional mslice commands on top of the standard matplotlib plotting commands""" -from __future__ import (absolute_import, division, print_function) - import os.path as ospath import matplotlib as mpl diff --git a/src/mslice/cli/plotfunctions.py b/src/mslice/cli/plotfunctions.py index bf0eb05ba..84315f911 100644 --- a/src/mslice/cli/plotfunctions.py +++ b/src/mslice/cli/plotfunctions.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - import mslice.plotting.pyplot as plt import mslice.app as app from mslice.models.workspacemanager.workspace_provider import get_workspace_handle diff --git a/src/mslice/cli/views/cli_data_loader.py b/src/mslice/cli/views/cli_data_loader.py index 7804fca35..17c5f8f4b 100644 --- a/src/mslice/cli/views/cli_data_loader.py +++ b/src/mslice/cli/views/cli_data_loader.py @@ -1,6 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - - class CLIDataLoaderWidget: """ A Dataloader Widget dummy class to interface with the presenter classes without doing anything in CLI mode. diff --git a/src/mslice/cli/views/cli_powder.py b/src/mslice/cli/views/cli_powder.py index 7e6c63469..7d7993112 100644 --- a/src/mslice/cli/views/cli_powder.py +++ b/src/mslice/cli/views/cli_powder.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from mslice.views.interfaces.powder_projection_view import PowderView diff --git a/src/mslice/models/colors.py b/src/mslice/models/colors.py index fc88053d8..cf9def156 100644 --- a/src/mslice/models/colors.py +++ b/src/mslice/models/colors.py @@ -16,8 +16,6 @@ to hex values and both #00bfbf and #00ffff will return the string cyan """ -from __future__ import (absolute_import, division) - import re from matplotlib import rcParams diff --git a/src/mslice/models/cut/cut_functions.py b/src/mslice/models/cut/cut_functions.py index dc86d78aa..19caff6a8 100644 --- a/src/mslice/models/cut/cut_functions.py +++ b/src/mslice/models/cut/cut_functions.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from mantid.api import WorkspaceUnitValidator from mslice.models.workspacemanager.workspace_provider import get_workspace_handle diff --git a/src/mslice/models/intensity_correction_algs.py b/src/mslice/models/intensity_correction_algs.py index 46265ec81..b89fe8488 100644 --- a/src/mslice/models/intensity_correction_algs.py +++ b/src/mslice/models/intensity_correction_algs.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) from six import string_types import numpy as np diff --git a/src/mslice/models/labels.py b/src/mslice/models/labels.py index 93982506d..3881cf58a 100644 --- a/src/mslice/models/labels.py +++ b/src/mslice/models/labels.py @@ -1,6 +1,5 @@ """Module to create axis and legend labels""" -from __future__ import (absolute_import, division, print_function) from mslice.models.units import EnergyUnits CUT_INTENSITY_LABEL = 'Signal/#Events' diff --git a/src/mslice/models/projection/powder/make_projection.py b/src/mslice/models/projection/powder/make_projection.py index f78a2b316..f69bbd230 100644 --- a/src/mslice/models/projection/powder/make_projection.py +++ b/src/mslice/models/projection/powder/make_projection.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import uuid from mantid.api import PythonAlgorithm, MatrixWorkspaceProperty, IMDEventWorkspaceProperty from mantid.kernel import FloatArrayProperty, Direction, StringMandatoryValidator diff --git a/src/mslice/models/projection/powder/mantid_projection_calculator.py b/src/mslice/models/projection/powder/mantid_projection_calculator.py index abaf7f314..7d4a9af3d 100644 --- a/src/mslice/models/projection/powder/mantid_projection_calculator.py +++ b/src/mslice/models/projection/powder/mantid_projection_calculator.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from mslice.models.workspacemanager.workspace_algorithms import propagate_properties from mslice.models.workspacemanager.workspace_provider import get_workspace_handle from mslice.models.projection.powder.projection_calculator import ProjectionCalculator diff --git a/src/mslice/models/projection/powder/projection_calculator.py b/src/mslice/models/projection/powder/projection_calculator.py index 53699816c..beb2cd14c 100644 --- a/src/mslice/models/projection/powder/projection_calculator.py +++ b/src/mslice/models/projection/powder/projection_calculator.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import abc diff --git a/src/mslice/models/slice/slice_functions.py b/src/mslice/models/slice/slice_functions.py index 4e375a3f1..72b38f9c0 100644 --- a/src/mslice/models/slice/slice_functions.py +++ b/src/mslice/models/slice/slice_functions.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import numpy as np from mantid.api import WorkspaceUnitValidator diff --git a/src/mslice/models/units.py b/src/mslice/models/units.py index 5ffee3944..f7e7c8701 100644 --- a/src/mslice/models/units.py +++ b/src/mslice/models/units.py @@ -4,8 +4,6 @@ are defined, but they are separated into a module for possible future expansion. """ -from __future__ import (absolute_import, division, print_function) - import numpy as np diff --git a/src/mslice/models/workspacemanager/file_io.py b/src/mslice/models/workspacemanager/file_io.py index b7e69440d..e52679ff6 100644 --- a/src/mslice/models/workspacemanager/file_io.py +++ b/src/mslice/models/workspacemanager/file_io.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import os.path from qtpy.QtWidgets import QFileDialog from mantid.api import MDNormalization diff --git a/src/mslice/models/workspacemanager/workspace_algorithms.py b/src/mslice/models/workspacemanager/workspace_algorithms.py index 898435903..deeb76a53 100644 --- a/src/mslice/models/workspacemanager/workspace_algorithms.py +++ b/src/mslice/models/workspacemanager/workspace_algorithms.py @@ -4,8 +4,6 @@ # ----------------------------------------------------------------------------- # Imports # ----------------------------------------------------------------------------- -from __future__ import (absolute_import, division, print_function) - import os.path from os.path import splitext diff --git a/src/mslice/plotting/backend.py b/src/mslice/plotting/backend.py index a710de11c..6cefb6ec8 100644 --- a/src/mslice/plotting/backend.py +++ b/src/mslice/plotting/backend.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, unicode_literals) # system imports import importlib diff --git a/src/mslice/plotting/globalfiguremanager.py b/src/mslice/plotting/globalfiguremanager.py index fca1d0675..704337b28 100644 --- a/src/mslice/plotting/globalfiguremanager.py +++ b/src/mslice/plotting/globalfiguremanager.py @@ -26,7 +26,6 @@ Currently there are only two categories ('1d' and '2d') hard coded into the manager. """ -from __future__ import (absolute_import, division, print_function) # system imports from functools import wraps diff --git a/src/mslice/plotting/plot_window/plot_options.py b/src/mslice/plotting/plot_window/plot_options.py index 6fab4f992..e660438b2 100644 --- a/src/mslice/plotting/plot_window/plot_options.py +++ b/src/mslice/plotting/plot_window/plot_options.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from numpy import arange as np_arange from six import iteritems diff --git a/src/mslice/plotting/plot_window/plot_window.py b/src/mslice/plotting/plot_window/plot_window.py index 76d6bfd17..7f0727384 100644 --- a/src/mslice/plotting/plot_window/plot_window.py +++ b/src/mslice/plotting/plot_window/plot_window.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from qtpy import QtCore, QtWidgets from matplotlib.figure import Figure diff --git a/src/mslice/presenters/cut_widget_presenter.py b/src/mslice/presenters/cut_widget_presenter.py index d29a63d62..c3842bf08 100644 --- a/src/mslice/presenters/cut_widget_presenter.py +++ b/src/mslice/presenters/cut_widget_presenter.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from mslice.models.cut.cut import Cut from .busy import show_busy from mslice.models.alg_workspace_ops import get_available_axes, get_axis_range diff --git a/src/mslice/presenters/data_loader_presenter.py b/src/mslice/presenters/data_loader_presenter.py index d1e1a15f8..cb3bf6529 100644 --- a/src/mslice/presenters/data_loader_presenter.py +++ b/src/mslice/presenters/data_loader_presenter.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - import os from .busy import show_busy diff --git a/src/mslice/presenters/main_presenter.py b/src/mslice/presenters/main_presenter.py index cc0b01787..801ae9b37 100644 --- a/src/mslice/presenters/main_presenter.py +++ b/src/mslice/presenters/main_presenter.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) from .interfaces.main_presenter import MainPresenterInterface from mantid.api import IMDHistoWorkspace, IMDEventWorkspace from collections.abc import Callable diff --git a/src/mslice/presenters/plot_options_presenter.py b/src/mslice/presenters/plot_options_presenter.py index b06f5eb01..602ee2648 100644 --- a/src/mslice/presenters/plot_options_presenter.py +++ b/src/mslice/presenters/plot_options_presenter.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) from functools import partial diff --git a/src/mslice/presenters/powder_projection_presenter.py b/src/mslice/presenters/powder_projection_presenter.py index 70902db50..01db38b34 100644 --- a/src/mslice/presenters/powder_projection_presenter.py +++ b/src/mslice/presenters/powder_projection_presenter.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from .busy import show_busy from mslice.models.projection.powder.projection_calculator import ProjectionCalculator from mslice.presenters.presenter_utility import PresenterUtility diff --git a/src/mslice/presenters/slice_widget_presenter.py b/src/mslice/presenters/slice_widget_presenter.py index 015020496..fb4263178 100644 --- a/src/mslice/presenters/slice_widget_presenter.py +++ b/src/mslice/presenters/slice_widget_presenter.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) from .busy import show_busy from mslice.models.alg_workspace_ops import get_available_axes, get_axis_range from mslice.models.axis import Axis diff --git a/src/mslice/presenters/validation_decorators.py b/src/mslice/presenters/validation_decorators.py index 4e9550d9f..574091d84 100644 --- a/src/mslice/presenters/validation_decorators.py +++ b/src/mslice/presenters/validation_decorators.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) from functools import wraps diff --git a/src/mslice/presenters/workspace_manager_presenter.py b/src/mslice/presenters/workspace_manager_presenter.py index daa06f003..c15471eac 100644 --- a/src/mslice/presenters/workspace_manager_presenter.py +++ b/src/mslice/presenters/workspace_manager_presenter.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) from six import string_types from .busy import show_busy diff --git a/src/mslice/util/compat.py b/src/mslice/util/compat.py index 1b735758e..056ae0b9c 100644 --- a/src/mslice/util/compat.py +++ b/src/mslice/util/compat.py @@ -1,5 +1,3 @@ -from __future__ import absolute_import - from matplotlib.legend import Legend diff --git a/src/mslice/util/mantid/algorithm_wrapper.py b/src/mslice/util/mantid/algorithm_wrapper.py index b32e234a2..eb0bc0a4e 100644 --- a/src/mslice/util/mantid/algorithm_wrapper.py +++ b/src/mslice/util/mantid/algorithm_wrapper.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from uuid import uuid4 from six import string_types diff --git a/src/mslice/util/qt/qapp.py b/src/mslice/util/qt/qapp.py index 87566693e..035223c33 100644 --- a/src/mslice/util/qt/qapp.py +++ b/src/mslice/util/qt/qapp.py @@ -3,7 +3,6 @@ # & Institut Laue - Langevin # SPDX - License - Identifier: GPL - 3.0 + # -from __future__ import (absolute_import, unicode_literals) from functools import wraps # make these available in this module for the rest of codebase diff --git a/src/mslice/views/cut_plotter.py b/src/mslice/views/cut_plotter.py index 3dfbc88d4..fff329199 100644 --- a/src/mslice/views/cut_plotter.py +++ b/src/mslice/views/cut_plotter.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import mslice.plotting.pyplot as plt from mslice.plotting.globalfiguremanager import GlobalFigureManager diff --git a/src/mslice/views/interfaces/powder_projection_view.py b/src/mslice/views/interfaces/powder_projection_view.py index 96492d729..dba356b0f 100644 --- a/src/mslice/views/interfaces/powder_projection_view.py +++ b/src/mslice/views/interfaces/powder_projection_view.py @@ -1,6 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - - class PowderView(object): error_occurred = None busy = None diff --git a/src/mslice/views/interfaces/slice_view.py b/src/mslice/views/interfaces/slice_view.py index 526fe106b..9215e9230 100644 --- a/src/mslice/views/interfaces/slice_view.py +++ b/src/mslice/views/interfaces/slice_view.py @@ -1,6 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - - class SliceView: error_occurred = None busy = None diff --git a/src/mslice/views/interfaces/workspace_view.py b/src/mslice/views/interfaces/workspace_view.py index 58b53b9d0..882ecdcf8 100644 --- a/src/mslice/views/interfaces/workspace_view.py +++ b/src/mslice/views/interfaces/workspace_view.py @@ -1,6 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - - class WorkspaceView(object): error_occurred = None busy = None diff --git a/src/mslice/views/slice_plotter.py b/src/mslice/views/slice_plotter.py index 329818a9a..de06a328f 100644 --- a/src/mslice/views/slice_plotter.py +++ b/src/mslice/views/slice_plotter.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - import mslice.plotting.pyplot as plt PICKER_TOL_PTS = 5 diff --git a/src/mslice/widgets/cut/command.py b/src/mslice/widgets/cut/command.py index 5a9fbcfd1..cba3c51fe 100644 --- a/src/mslice/widgets/cut/command.py +++ b/src/mslice/widgets/cut/command.py @@ -1,14 +1,5 @@ """Enumeration for operations allowed in this module """ -# ----------------------------------------------------------------------------- -# Imports -# ----------------------------------------------------------------------------- - -from __future__ import (absolute_import, division, print_function) - -# ----------------------------------------------------------------------------- -# Classes and functions -# ----------------------------------------------------------------------------- class Command(object): diff --git a/src/mslice/widgets/cut/cut.py b/src/mslice/widgets/cut/cut.py index c6c991f9c..cbc61b3c8 100644 --- a/src/mslice/widgets/cut/cut.py +++ b/src/mslice/widgets/cut/cut.py @@ -3,8 +3,6 @@ # ----------------------------------------------------------------------------- # Imports # ----------------------------------------------------------------------------- -from __future__ import (absolute_import, division, print_function) - from qtpy.QtCore import Signal from qtpy.QtWidgets import QWidget from mslice.util.qt import load_ui diff --git a/src/mslice/widgets/dataloader/dataloader.py b/src/mslice/widgets/dataloader/dataloader.py index 18427ca1f..70c1938af 100644 --- a/src/mslice/widgets/dataloader/dataloader.py +++ b/src/mslice/widgets/dataloader/dataloader.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - import os from functools import partial diff --git a/src/mslice/widgets/dataloader/inputdialog.py b/src/mslice/widgets/dataloader/inputdialog.py index 003962a36..7297b395b 100644 --- a/src/mslice/widgets/dataloader/inputdialog.py +++ b/src/mslice/widgets/dataloader/inputdialog.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) from qtpy.QtWidgets import QDialog, QFormLayout, QLabel, QDoubleSpinBox, QPushButton, QCheckBox diff --git a/src/mslice/widgets/ipythonconsole/ipython_widget.py b/src/mslice/widgets/ipythonconsole/ipython_widget.py index 7eb8ab6f5..d3714b75b 100644 --- a/src/mslice/widgets/ipythonconsole/ipython_widget.py +++ b/src/mslice/widgets/ipythonconsole/ipython_widget.py @@ -1,6 +1,3 @@ -from __future__ import (absolute_import, division, - print_function) - import warnings from mslice.util.mantid import in_mantid diff --git a/src/mslice/widgets/projection/powder/powder.py b/src/mslice/widgets/projection/powder/powder.py index ebe69d025..1f879c460 100644 --- a/src/mslice/widgets/projection/powder/powder.py +++ b/src/mslice/widgets/projection/powder/powder.py @@ -3,8 +3,6 @@ # ----------------------------------------------------------------------------- # Imports # ----------------------------------------------------------------------------- -from __future__ import (absolute_import, division, print_function) - from qtpy.QtCore import Signal from qtpy.QtWidgets import QWidget, QMessageBox diff --git a/src/mslice/widgets/slice/slice.py b/src/mslice/widgets/slice/slice.py index 27d55afc2..33da2cbb2 100644 --- a/src/mslice/widgets/slice/slice.py +++ b/src/mslice/widgets/slice/slice.py @@ -3,8 +3,6 @@ # ----------------------------------------------------------------------------- # Imports # ----------------------------------------------------------------------------- -from __future__ import (absolute_import, division, print_function) - from qtpy.QtCore import Signal from qtpy.QtWidgets import QWidget from mslice.util.qt import load_ui diff --git a/src/mslice/widgets/status/status.py b/src/mslice/widgets/status/status.py index db3daa028..9321c6016 100644 --- a/src/mslice/widgets/status/status.py +++ b/src/mslice/widgets/status/status.py @@ -5,8 +5,6 @@ # ----------------------------------------------------------------------------- # Imports # ----------------------------------------------------------------------------- -from __future__ import (absolute_import, division, print_function) - from qtpy.QtWidgets import QWidget from mslice.util.qt import load_ui diff --git a/src/mslice/workspace/histo_mixin.py b/src/mslice/workspace/histo_mixin.py index dee1d2d06..4ba1a3525 100644 --- a/src/mslice/workspace/histo_mixin.py +++ b/src/mslice/workspace/histo_mixin.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import numpy as np import operator as op from mslice.util.numpy_helper import apply_with_corrected_shape, transform_array_to_workspace diff --git a/src/mslice/workspace/histogram_workspace.py b/src/mslice/workspace/histogram_workspace.py index 112fd6dbe..4bc8aacdd 100644 --- a/src/mslice/workspace/histogram_workspace.py +++ b/src/mslice/workspace/histogram_workspace.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) from .base import WorkspaceBase from .histo_mixin import HistoMixin from .workspace_mixin import WorkspaceOperatorMixin, WorkspaceMixin diff --git a/src/mslice/workspace/pixel_mixin.py b/src/mslice/workspace/pixel_mixin.py index 77fda7aa2..b8b4cc042 100644 --- a/src/mslice/workspace/pixel_mixin.py +++ b/src/mslice/workspace/pixel_mixin.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) from .histogram_workspace import HistogramWorkspace from mantid.simpleapi import BinMD diff --git a/src/mslice/workspace/pixel_workspace.py b/src/mslice/workspace/pixel_workspace.py index 306ad0e5f..108f30ea2 100644 --- a/src/mslice/workspace/pixel_workspace.py +++ b/src/mslice/workspace/pixel_workspace.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) from .base import WorkspaceBase from .histogram_workspace import HistogramWorkspace from .pixel_mixin import PixelMixin diff --git a/src/mslice/workspace/workspace.py b/src/mslice/workspace/workspace.py index 82597a2e4..68fd6ba18 100644 --- a/src/mslice/workspace/workspace.py +++ b/src/mslice/workspace/workspace.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) from .base import WorkspaceBase from .workspace_mixin import WorkspaceOperatorMixin, WorkspaceMixin from .helperfunctions import attribute_from_log, attribute_to_log, delete_workspace, rename_workspace diff --git a/src/mslice/workspace/workspace_mixin.py b/src/mslice/workspace/workspace_mixin.py index 986f11779..693171aa4 100644 --- a/src/mslice/workspace/workspace_mixin.py +++ b/src/mslice/workspace/workspace_mixin.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import numpy as np import operator as op diff --git a/tests/cut_widget_presenter_test.py b/tests/cut_widget_presenter_test.py index 49c79bd98..0add57702 100644 --- a/tests/cut_widget_presenter_test.py +++ b/tests/cut_widget_presenter_test.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import mock from mock import call, patch import unittest diff --git a/tests/data_loader_test.py b/tests/data_loader_test.py index 32bc54fdd..8919af58a 100644 --- a/tests/data_loader_test.py +++ b/tests/data_loader_test.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) from tempfile import gettempdir from os.path import join import unittest diff --git a/tests/figure_manager_test.py b/tests/figure_manager_test.py index a7abf5fad..c13f20825 100644 --- a/tests/figure_manager_test.py +++ b/tests/figure_manager_test.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import unittest from unittest import mock from unittest.mock import call diff --git a/tests/file_io_test.py b/tests/file_io_test.py index b665ee1dd..33d4448a7 100644 --- a/tests/file_io_test.py +++ b/tests/file_io_test.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from mock import patch, Mock, MagicMock import numpy as np from os.path import join diff --git a/tests/histogram_workspace_test.py b/tests/histogram_workspace_test.py index 87c144de4..fff9a0434 100644 --- a/tests/histogram_workspace_test.py +++ b/tests/histogram_workspace_test.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import numpy as np from mantid.simpleapi import CreateMDHistoWorkspace diff --git a/tests/intensity_correction_algs_test.py b/tests/intensity_correction_algs_test.py index 68630a568..9598cc5b6 100644 --- a/tests/intensity_correction_algs_test.py +++ b/tests/intensity_correction_algs_test.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from mock import patch, MagicMock, call import numpy as np import unittest diff --git a/tests/intensity_correction_util_test.py b/tests/intensity_correction_util_test.py index e59e87e74..1fc31552e 100644 --- a/tests/intensity_correction_util_test.py +++ b/tests/intensity_correction_util_test.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from mock import patch, MagicMock import unittest diff --git a/tests/main_presenter_test.py b/tests/main_presenter_test.py index 4d3e59696..e08b62fce 100644 --- a/tests/main_presenter_test.py +++ b/tests/main_presenter_test.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import mock import unittest diff --git a/tests/pixel_workspace_test.py b/tests/pixel_workspace_test.py index 67dac465b..44012cfea 100644 --- a/tests/pixel_workspace_test.py +++ b/tests/pixel_workspace_test.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import numpy as np import unittest diff --git a/tests/plot_figure_test.py b/tests/plot_figure_test.py index 6c6d3decc..0f1d1b421 100644 --- a/tests/plot_figure_test.py +++ b/tests/plot_figure_test.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import unittest from unittest import mock from unittest.mock import patch diff --git a/tests/plot_options_presenter_test.py b/tests/plot_options_presenter_test.py index abcc6f309..b1d7a8c1f 100644 --- a/tests/plot_options_presenter_test.py +++ b/tests/plot_options_presenter_test.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) from mock import MagicMock, PropertyMock, Mock, ANY import unittest from mslice.presenters.plot_options_presenter import CutPlotOptionsPresenter, SlicePlotOptionsPresenter diff --git a/tests/powder_projection_presenter_test.py b/tests/powder_projection_presenter_test.py index e1f3f750d..dd843b731 100644 --- a/tests/powder_projection_presenter_test.py +++ b/tests/powder_projection_presenter_test.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import mock import unittest diff --git a/tests/slice_algorithm_test.py b/tests/slice_algorithm_test.py index 57c01e309..d5dafff9c 100644 --- a/tests/slice_algorithm_test.py +++ b/tests/slice_algorithm_test.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from mock import patch, MagicMock, call, ANY import numpy as np import unittest diff --git a/tests/slice_functions_test.py b/tests/slice_functions_test.py index ff0483d3b..f1f17de11 100644 --- a/tests/slice_functions_test.py +++ b/tests/slice_functions_test.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - from mock import patch, MagicMock import numpy as np import unittest diff --git a/tests/slice_plotter_presenter_test.py b/tests/slice_plotter_presenter_test.py index 2f2b3639d..c3bec2c3c 100644 --- a/tests/slice_plotter_presenter_test.py +++ b/tests/slice_plotter_presenter_test.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import mock import unittest import numpy as np diff --git a/tests/workspace_algorithms_test.py b/tests/workspace_algorithms_test.py index 33545f3e9..f4af029b4 100644 --- a/tests/workspace_algorithms_test.py +++ b/tests/workspace_algorithms_test.py @@ -1,5 +1,3 @@ -from __future__ import (absolute_import, division, print_function) - import unittest from mslice.models.axis import Axis diff --git a/tests/workspace_provider_test.py b/tests/workspace_provider_test.py index 98e41ceac..0b115d09b 100644 --- a/tests/workspace_provider_test.py +++ b/tests/workspace_provider_test.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import numpy as np import mock from mock import patch diff --git a/tests/workspace_test.py b/tests/workspace_test.py index 4882ae38b..ad40f93c8 100644 --- a/tests/workspace_test.py +++ b/tests/workspace_test.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import unittest import mock diff --git a/tests/workspacemanager_presenter_test.py b/tests/workspacemanager_presenter_test.py index 3030db562..6233642f2 100644 --- a/tests/workspacemanager_presenter_test.py +++ b/tests/workspacemanager_presenter_test.py @@ -1,4 +1,3 @@ -from __future__ import (absolute_import, division, print_function) import unittest import mock