-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathpyproject.toml
More file actions
170 lines (144 loc) · 5.21 KB
/
Copy pathpyproject.toml
File metadata and controls
170 lines (144 loc) · 5.21 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
[build-system]
requires = ["setuptools>=64.0", "setuptools_scm[toml]>=6.2"]
build-backend = "setuptools.build_meta"
[project]
name = "bowser-insar"
authors = [{ name = "Scott Staniewicz", email = "scott.stanie@gmail.com" }]
description = "Web UI for browsing InSAR time series"
readme = { file = "README.md", content-type = "text/markdown" }
requires-python = ">=3.11"
dependencies = [
"titiler.xarray[minimal,http]",
"starlette-cramjam",
"boto3",
"uvicorn",
"typing_extensions",
"tqdm",
"opera-utils[all]",
"rioxarray",
"matplotlib",
"pydantic-settings",
"rich",
"s3fs>=2024.1.0",
"aiobotocore>=2.13.0",
"python-multipart",
"starlette>=0.40.0,<1.0.0",
]
classifiers = [
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python",
"Topic :: Scientific/Engineering",
"Typing :: Typed",
]
# The version will be written into a version.py upon install, auto-generated
# see section: setuptools_scm
# https://setuptools.pypa.io/en/latest/userguide/pyproject_config.html#dynamic-metadata
# dependencies will be read from text files
dynamic = ["version"]
[project.optional-dependencies]
test = ["pytest", "httpx", "ipython", "types-python-dateutil"]
# GeoZarr writer: only needed for the `bowser tifs-to-geozarr` subcommand.
# Bowser runtime
# reads back the attrs with plain zarr and never imports this package, so it
# stays out of the default env to avoid pulling pydantic>=2.12.
writer = ["geozarr-toolkit>=0.1.1"]
# [project.urls]
# Homepage = "https://github.com/opera-adt/bowser"
# "Bug Tracker" = "https://github.com/opera-adt/bowser/issues"
# Discussions = "https://github.com/opera-adt/bowser/discussions"
# Changelog = "https://github.com/opera-adt/bowser/releases"
# Entry points for the command line interface
[project.scripts]
bowser = "bowser.cli:cli_app"
[tool.setuptools.packages.find]
# Without this, setuptools auto-discovery picks up sibling React source dirs
# under src/ (components/, hooks/, context/) and ships .tsx files in the wheel.
where = ["src"]
include = ["bowser*"]
[tool.setuptools.package-data]
# Frontend bundle is built by `npm run build` (CD workflow) into src/bowser/dist/.
# Listed explicitly so it ships in the wheel even though it's gitignored.
bowser = ["dist/index.html", "dist/index.js", "dist/index.css", "static/*"]
[tool.setuptools_scm]
# https://github.com/pypa/setuptools_scm#configuration-parameters
write_to = "src/bowser/_version.py"
# https://github.com/pypa/setuptools_scm#version-number-construction
version_scheme = "no-guess-dev" # Will not guess the next version
[tool.pixi.workspace]
channels = ["conda-forge"]
platforms = ["osx-arm64", "linux-64"]
[tool.pixi.pypi-dependencies]
bowser-insar = { path = ".", editable = true }
[tool.pixi.dependencies]
boto3 = "*"
uvicorn = "*"
typing_extensions = "*"
tqdm = "*"
opera-utils = "*"
rioxarray = "*"
matplotlib = "*"
pydantic-settings = "*"
python-dateutil = ">=2.9.0.post0,<3"
s3fs = ">=2024.1.0"
aiobotocore = ">=2.13.0"
[tool.pixi.feature.writer.dependencies]
# geozarr-toolkit requires pydantic >= 2.12; bump it in its own solve-group
# so the default runtime env can keep whatever conda-forge settles on.
# geozarr-toolkit itself is pulled via the PEP 621 extra above (pixi
# auto-maps an extra whose name matches the feature); declaring it again
# in `[tool.pixi.feature.writer.pypi-dependencies]` trips the "already a
# dependency" error on pixi install --locked.
pydantic = ">=2.12"
[tool.pixi.environments]
default = { solve-group = "default" }
test = { features = ["test"], solve-group = "test" }
writer = { features = ["writer"], solve-group = "writer" }
all = { features = ["writer", "test"], solve-group = "all" }
[tool.pixi.tasks]
[tool.ruff]
src = ["src"]
unsafe-fixes = true
select = [
"A", # flake8-builtins
"ARG", # flake8-unused-arguments
"C4", # flake8-comprehensions
"D", # pydocstyle
"E", # pycodestyle (errors)
"W", # pycodestyle (warnings)
"EXE", # flake8-executable
"F", # Pyflakes
"I", # isort
"ISC", # flake8-implicit-str-concat
"N", # pep8-naming
"PTH", # flake8-use-pathlib
"PYI", # flake8-pyi
]
ignore = [
"D100", # Missing docstring in public module
"D104", # Missing docstring in public package
"D105", # Missing docstring in magic method
"D203", # 1 blank line required before class docstring
"D213", # Multi-line docstring summary should start at the second line
"N802", # Function name should be lowercase (Titiler uses a lot of upper)
"N803", # Argument name should be lowercase
"N806", # Variable _ in function should be lowercase
"PIE796", # Non-unique values are redundant and likely a mistake.
"PLR", # Pylint Refactor
"PTH123", # `open()` should be replaced by `Path.open()`
"PTH207", # "Replace `glob` with `Path.glob` or `Path.rglob`
]
[tool.mypy]
python_version = "3.11"
ignore_missing_imports = true
plugins = ["pydantic.mypy"]
[tool.ruff.per-file-ignores]
"**/__init__.py" = ["F403"]
"tests/**" = ["D", "N", "PTH"]
[tool.pytest.ini_options]
addopts = "-W ignore::PendingDeprecationWarning "
filterwarnings = ["error"]