From 66252642559e8f5b082f47225d7c5281de626f6d Mon Sep 17 00:00:00 2001 From: Kristen Thyng Date: Mon, 27 Nov 2023 16:18:25 -0600 Subject: [PATCH 1/2] updated syntax for viridis to be default seq cmap --- xcmocean/options.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xcmocean/options.py b/xcmocean/options.py index 8e02d96..053cc0e 100644 --- a/xcmocean/options.py +++ b/xcmocean/options.py @@ -22,7 +22,7 @@ } # sequential colormap defaults to viridis if variable type can't be determined -SEQ = defaultdict(lambda: cmo.cm.viridis) +SEQ = defaultdict(lambda: cmo.mpl.colormaps.get_cmap("viridis")) SEQ.update( { "temp": cmo.thermal, From 8af9aca16f92a882791de7c8aefa448da7f0e46f Mon Sep 17 00:00:00 2001 From: Kristen Thyng Date: Mon, 27 Nov 2023 16:34:24 -0600 Subject: [PATCH 2/2] lint update --- .pre-commit-config.yaml | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 85b11c8..6e0c95c 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -21,7 +21,8 @@ repos: - id: file-contents-sorter files: requirements-dev.txt -- repo: https://gitlab.com/pycqa/flake8 +# - repo: https://gitlab.com/pycqa/flake8 +- repo: https://github.com/pycqa/flake8 rev: 3.7.9 hooks: - id: flake8 @@ -29,19 +30,19 @@ repos: args: [--max-line-length=105, --ignore=E203,E501,W503, --select=select=C,E,F,W,B,B950] - repo: https://github.com/pre-commit/mirrors-isort - rev: v4.3.21 + rev: v5.10.1 hooks: - id: isort additional_dependencies: [toml] args: [--project=gcm_filters, --multi-line=3, --lines-after-imports=2, --lines-between-types=1, --trailing-comma, --force-grid-wrap=0, --use-parentheses, --line-width=88] -- repo: https://github.com/asottile/seed-isort-config - rev: v2.1.1 - hooks: - - id: seed-isort-config +# - repo: https://github.com/asottile/seed-isort-config +# rev: v2.1.1 +# hooks: +# - id: seed-isort-config - repo: https://github.com/psf/black - rev: stable + rev: 22.3.0 # https://github.com/psf/black/issues/2964 hooks: - id: black language_version: python3