Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

noaa_coops 0.4.0 #64

Merged
merged 5 commits into from
Aug 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
- name: Install Python
uses: actions/setup-python@v4
with:
python: ${{ matrix.python-version }}
python-version: ${{ matrix.python-version }}

- name: Install Poetry
uses: snok/install-poetry@v1
Expand All @@ -31,7 +31,7 @@ jobs:
uses: actions/cache@v3
with:
path: .venv
key: venv-${{ runner.os }}-${{ steps.setup-python.outputs.python-version }}-${{ hashFiles('**/poetry.lock') }}
key: venv-${{ runner.os }}-${{ matrix.python-version }}-${{ hashFiles('**/poetry.lock') }}

- name: Install dependencies (cache not available)
if: steps.cached-poetry-dependencies.outputs.cache-hit != 'true'
Expand All @@ -58,7 +58,7 @@ jobs:
- name: Install Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python: ${{ matrix.python-version }}
python-version: ${{ matrix.python-version }}

- name: Install Poetry
uses: snok/install-poetry@v1
Expand All @@ -71,7 +71,7 @@ jobs:
uses: actions/cache@v3
with:
path: .venv
key: venv-${{ runner.os }}-${{ steps.setup-python.outputs.python-version }}-${{ hashFiles('**/poetry.lock') }}
key: venv-${{ runner.os }}-${{ matrix.python-version }}-${{ hashFiles('**/poetry.lock') }}

- name: Install dependencies (cache not available)
if: steps.cached-poetry-dependencies.outputs.cache-hit != 'true'
Expand Down
6 changes: 2 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,11 @@ all: format lint

.PHONY: format
format:
@autoflake --remove-all-unused-imports --remove-unused-variables --ignore-init-module-imports --recursive --in-place .
@isort .
@black .
@ruff format .

.PHONY: lint
lint:
@flake8 ./noaa_coops ./tests
@ruff check ./noaa_coops/ ./tests/

# @black --check .

Expand Down
2 changes: 1 addition & 1 deletion noaa_coops/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from noaa_coops.station import Station, get_stations_from_bbox # noqa: F401


__version__ = "0.3.2"
__version__ = "0.4.0"
8 changes: 3 additions & 5 deletions noaa_coops/station.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ def __init__(self, message: str) -> None:


def get_stations_from_bbox(
lat_coords: list[float, float],
lon_coords: list[float, float],
lat_coords: list[float],
lon_coords: list[float],
) -> list[str]:
"""Return a list of stations IDs found within a bounding box.

Expand Down Expand Up @@ -751,9 +751,7 @@ def get_data(
# DEBUGGING
from pprint import pprint

import noaa_coops as nc

station = nc.Station(id="8775241")
station = Station(id="8775241")

df = station.get_data(
begin_date="20230320 00:00",
Expand Down
Loading
Loading