From 2e80ab33a5f32fa0998dcb4654c3d1ef8b313878 Mon Sep 17 00:00:00 2001 From: Gary Oberbrunner Date: Thu, 8 Feb 2024 16:45:18 -0500 Subject: [PATCH] Clean up a little --- .github/workflows/python-app.yml | 5 +++-- sea-surface-temps.py | 13 ++++++++----- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/.github/workflows/python-app.yml b/.github/workflows/python-app.yml index f3d4fca..dc98471 100644 --- a/.github/workflows/python-app.yml +++ b/.github/workflows/python-app.yml @@ -34,6 +34,7 @@ jobs: flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics - - name: Test with pytest + - name: Test run: | - pytest + python sea-surface-temps.py --mode map --dataset sst --days-ago 1 + python sea-surface-temps.py --mode map --dataset anom --days-ago 1 diff --git a/sea-surface-temps.py b/sea-surface-temps.py index c5efa93..fcdcf87 100644 --- a/sea-surface-temps.py +++ b/sea-surface-temps.py @@ -1,15 +1,18 @@ # SPDX-License-Identifier: MIT -import sys, requests, io, h5py, urllib3 +import sys +import requests +import io +import urllib3 import datetime import calendar -import pandas as pd -import numpy as np -import matplotlib.pyplot as plt -from matplotlib.colors import LinearSegmentedColormap, ListedColormap import json import argparse import pathlib +import h5py +import numpy as np +import matplotlib.pyplot as plt +from matplotlib.colors import LinearSegmentedColormap urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning)