From 5fa12f1d57de91d6cf7becca85df244d32c310fb Mon Sep 17 00:00:00 2001 From: Remi Gau Date: Fri, 15 Dec 2023 10:52:30 +0100 Subject: [PATCH] use backward compatible type --- docs/source/conf.py | 2 +- giga_connectome/denoise.py | 4 ++-- pyproject.toml | 1 - tools/download_templates.py | 2 +- 4 files changed, 4 insertions(+), 5 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 4d28c2d..32f11ac 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -5,7 +5,7 @@ import os import sys -from giga_connectome import __version__, __packagename__, __copyright__ +from giga_connectome import __copyright__, __packagename__, __version__ sys.path.insert(0, os.path.abspath("..")) # -- Project information ----------------------------------------------------- diff --git a/giga_connectome/denoise.py b/giga_connectome/denoise.py index 807a9c7..ddbb932 100644 --- a/giga_connectome/denoise.py +++ b/giga_connectome/denoise.py @@ -2,7 +2,7 @@ import json from pathlib import Path -from typing import Any, Callable, TypedDict +from typing import Any, Callable, TypedDict, Union import numpy as np import pandas as pd @@ -38,7 +38,7 @@ { "name": str, "function": Callable[..., Any], - "parameters": dict[str, str | list[str]], + "parameters": dict[str, Union[str, list[str]]], }, ) diff --git a/pyproject.toml b/pyproject.toml index af010ab..c4515bc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -109,7 +109,6 @@ module = [ "nilearn.masking.*", "nilearn.image.*", "nilearn.interfaces.*", - "pytest", "rich.*", "scipy.ndimage.*", "templateflow.*", diff --git a/tools/download_templates.py b/tools/download_templates.py index bcefa97..858cd5f 100644 --- a/tools/download_templates.py +++ b/tools/download_templates.py @@ -33,8 +33,8 @@ def download_mist() -> None: # download and convert import importlib.util - import sys import shutil + import sys if spec := importlib.util.spec_from_file_location( "mist2templateflow",