Skip to content

Commit 50dd7da

Browse files
committed
chore: use pyproject.toml for configuration
1 parent 9300fbe commit 50dd7da

13 files changed

Lines changed: 63 additions & 177 deletions

.github/dependabot.yml

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,6 @@ updates:
55
schedule:
66
interval: weekly
77
- package-ecosystem: pip
8-
directory: "/.github/workflows"
8+
directory: "/"
99
schedule:
1010
interval: weekly
11-
- package-ecosystem: pip
12-
directory: "."
13-
schedule:
14-
interval: daily

.github/workflows/continuous-integration.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
runs-on: ubuntu-latest
1313
strategy:
1414
matrix:
15-
python-version: ["3.8", "3.9", "3.10"]
15+
python-version: ["3.8", "3.9", "3.10", "3.11"]
1616
defaults:
1717
run:
1818
shell: bash -l {0}

.github/workflows/release.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,20 +12,20 @@ jobs:
1212
steps:
1313
- uses: actions/checkout@v3
1414

15-
- name: Set up Python 3.x
15+
- name: Set up Python 3.10
1616
uses: actions/setup-python@v4
1717
with:
18-
python-version: "3.x"
18+
python-version: "3.10"
1919

2020
- name: Install release dependencies
2121
run: |
2222
python -m pip install --upgrade pip
23-
pip install setuptools wheel twine
23+
pip install build twine
2424
2525
- name: Build and publish package
2626
env:
2727
TWINE_USERNAME: ${{ secrets.PYPI_STACUTILS_USERNAME }}
2828
TWINE_PASSWORD: ${{ secrets.PYPI_STACUTILS_PASSWORD }}
2929
run: |
30-
python setup.py sdist bdist_wheel
30+
python -m build
3131
twine upload dist/*

.pre-commit-config.yaml

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,8 @@ repos:
1212
- id: codespell
1313
args: [--ignore-words=.codespellignore]
1414
types_or: [jupyter, markdown, python, shell]
15-
- repo: https://github.com/PyCQA/doc8
16-
rev: v1.1.1
17-
hooks:
18-
- id: doc8
1915
- repo: https://github.com/PyCQA/flake8
20-
rev: 6.0.0
16+
rev: 6.1.0
2117
hooks:
2218
- id: flake8
2319
- repo: https://github.com/pycqa/isort
@@ -26,7 +22,7 @@ repos:
2622
- id: isort
2723
args: ["--profile", "black"]
2824
- repo: https://github.com/pre-commit/mirrors-mypy
29-
rev: v1.4.1
25+
rev: v1.5.0
3026
hooks:
3127
- id: mypy
3228
additional_dependencies:

README.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -143,13 +143,12 @@ Process definitions are sometimes called "Payloads":
143143

144144
## Development
145145

146-
Clone, install in editable mode, install development requirements, and install the **pre-commit** hooks:
146+
Clone, install in editable mode with development requirements, and install the **pre-commit** hooks:
147147

148148
```shell
149149
git clone https://github.com/stac-utils/stac-task
150150
cd stac-task
151-
pip install -e .
152-
pip install -r requirements-dev.txt
151+
pip install -e '.[dev]'
153152
pre-commit install
154153
```
155154

docs/stactask-usage.ipynb

Lines changed: 0 additions & 53 deletions
This file was deleted.

pyproject.toml

Lines changed: 49 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,54 @@
1+
[project]
2+
name = "stactask"
3+
version = "0.1.1"
4+
authors = [{ name = "Matthew Hanson", email = "matt.a.hanson@gmail.com" }]
5+
description = "Class interface for running custom algorithms and workflows on STAC Items"
6+
readme = "README.md"
7+
requires-python = ">=3.8"
8+
keywords = ["pystac", "imagery", "raster", "catalog", "STAC"]
9+
license = { text = "Apache-2.0" }
10+
classifiers = [
11+
"Development Status :: 2 - Pre-Alpha",
12+
"Intended Audience :: Developers",
13+
"License :: OSI Approved :: Apache Software License",
14+
"Natural Language :: English",
15+
"Programming Language :: Python :: 3",
16+
"Programming Language :: Python :: 3.8",
17+
"Programming Language :: Python :: 3.9",
18+
"Programming Language :: Python :: 3.10",
19+
"Programming Language :: Python :: 3.11",
20+
]
21+
dependencies = [
22+
"pystac>=1.6",
23+
"python-dateutil>=2.7.0",
24+
"boto3-utils>=0.3.2",
25+
"fsspec>=2022.8.2",
26+
"jsonpath_ng>=1.5.3",
27+
"requests>=2.28.1",
28+
"s3fs>=2022.8.2",
29+
]
30+
31+
[project.optional-dependencies]
32+
dev = [
33+
"black~=23.7.0",
34+
"codespell~=2.2.5",
35+
"flake8~=6.1.0",
36+
"isort~=5.12.0",
37+
"mypy~=1.5.0",
38+
"pre-commit~=3.3.3",
39+
"pytest~=7.4.0",
40+
"pytest-cov~=4.1.0",
41+
"types-setuptools~=68.0.0",
42+
]
43+
44+
[project.urls]
45+
Issues = "https://github.com/stac-utils/stactask/issues"
46+
Github = "https://github.com/stac-utils/stac-task"
47+
Changelog = "https://github.com/stac-utils/stac-task/blob/main/CHANGELOG.md"
48+
149
[tool.mypy]
250
strict = true
351

452
[[tool.mypy.overrides]]
5-
module = [
6-
"boto3utils",
7-
"jsonpath_ng.ext",
8-
"fsspec",
9-
]
53+
module = ["boto3utils", "jsonpath_ng.ext", "fsspec"]
1054
ignore_missing_imports = true

requirements-dev.txt

Lines changed: 0 additions & 9 deletions
This file was deleted.

scripts/lint renamed to scripts/check

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,14 @@ fi
99
function usage() {
1010
echo -n \
1111
"Usage: $(basename "$0")
12-
Execute project linters.
12+
Execute project checks.
1313
"
1414
}
1515

1616
if [ "${BASH_SOURCE[0]}" = "${0}" ]; then
1717
if [ "${1:-}" = "--help" ]; then
1818
usage
1919
else
20-
# Lint
21-
pre-commit run flake8 --all-files
22-
# Type checking
23-
pre-commit run mypy --all-files
20+
pre-commit run --all-files
2421
fi
2522
fi

scripts/format

Lines changed: 0 additions & 25 deletions
This file was deleted.

0 commit comments

Comments
 (0)