-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathpyproject.toml
More file actions
188 lines (167 loc) · 6.27 KB
/
pyproject.toml
File metadata and controls
188 lines (167 loc) · 6.27 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
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
[build-system]
requires = ["hatchling>=1.5.0", "hatch-nodejs-version>=0.3.2"]
build-backend = "hatchling.build"
[project]
name = "fileglancer"
readme = "README.md"
authors = [
{ name = "Allison Truhlar", email = "truhlara@janelia.hhmi.org" },
{ name = "Jody Clements", email = "clementsj@janelia.hhmi.org" },
{ name = "Cristian Goina", email = "goinac@janelia.hhmi.org" },
{ name = "Konrad Rokicki", email = "rokickik@janelia.hhmi.org" }
]
license = { file = "LICENSE" }
requires-python = ">=3.12.0"
classifiers = [
"License :: OSI Approved :: BSD License",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
]
dynamic = ["version", "description", "urls", "keywords"]
dependencies = [
"alembic >=1.17.0",
"atlassian-python-api >=4.0.7",
"authlib >=1.6.5",
"cachetools >=6.2.1",
"click >=8.0",
"fastapi >=0.119.1",
"httpx >=0.28.1,<0.29",
"itsdangerous >=2.2.0",
"loguru >=0.7.3",
"pandas >=2.3.3",
"psycopg2-binary >=2.9.10,<3",
"pydantic >=2.10.6",
"pydantic-settings >=2.11.0",
"python-jose >=3.5.0,<4",
"cryptography >=41.0.0",
"sqlalchemy >=2.0.44",
"uvicorn >=0.38.0",
"x2s3 >=1.1.1",
"py-cluster-api >=0.5.0"
]
[project.scripts]
fileglancer = "fileglancer.cli:cli"
[project.optional-dependencies]
test = [
"coverage",
"pytest",
"pytest-asyncio",
"pytest-cov",
"pytest-html",
"requests-mock"
]
release = [
"twine",
"hatch"
]
[tool.hatch.version]
source = "nodejs"
path = "frontend/package.json"
[tool.hatch.metadata.hooks.nodejs]
path = "frontend/package.json"
fields = ["description", "urls", "keywords"]
[tool.hatch.build.targets.sdist]
artifacts = [
"fileglancer/ui",
"fileglancer/alembic.ini",
"fileglancer/alembic/**/*"
]
exclude = [".github"]
[tool.hatch.build.targets.wheel]
artifacts = [
"fileglancer/ui",
"fileglancer/alembic.ini",
"fileglancer/alembic/**/*"
]
[tool.hatch.build.hooks.version]
path = "fileglancer/_version.py"
[tool.check-wheel-contents]
ignore = ["W002"]
[tool.pixi.workspace]
channels = ["conda-forge"]
platforms = ["osx-arm64", "osx-64", "linux-64", "linux-aarch64"]
[tool.pixi.feature.test.tasks]
test-pip-install = { cmd = "pip install -e .", default-environment = "test" }
test-backend = { cmd = "pytest --cov=fileglancer --cov-report=html --cov-report=term", depends-on = ["test-pip-install"], default-environment = "test" }
test-frontend = { cmd = "cd frontend && npm test", default-environment = "test" }
[tool.pixi.feature.test.dependencies]
coverage = ">=7.10.6,<8"
pytest = ">=8.4.2,<9"
pytest-asyncio = ">=1.1.0,<2"
pytest-cov = ">=7.0.0,<8"
pytest-jupyter = ">=0.10.1,<0.11"
requests-mock = ">=1.12.1,<2"
pytest-jupyter-server = ">=0.6.0"
[tool.pixi.feature.release.tasks]
version = "hatch version"
pypi-build = "pip install build && python -m build"
pypi-upload = "twine upload dist/*"
[tool.pixi.feature.release.dependencies]
twine = ">=6.2.0,<7"
hatch = ">=1.14.1,<2"
[tool.pixi.feature.py312.dependencies]
python = "3.12.*"
[tool.pixi.environments]
default = { solve-group = "default" }
test = { features = ["test"], solve-group = "default" }
release = { features = ["release"], solve-group = "default" }
test-py312 = ["test", "py312"]
[tool.pixi.tasks]
pip-install = { cmd = "pixi reinstall fileglancer" }
pip-uninstall = { cmd = "pixi clean" }
node-install = "cd frontend && npm install"
node-build = { cmd = "cd frontend && npm run build", depends-on = ["node-install"] }
node-eslint-check = "cd frontend && npx eslint . --ext .ts,.tsx"
node-eslint-write = "cd frontend && npx eslint . --cache --fix --ext .ts,.tsx"
node-prettier-check = "cd frontend && npx prettier \"**/*{.ts,.tsx,.js,.jsx,.css,.json,.md}\" \"!package-lock.json\" --check"
node-prettier-write = "cd frontend && npx prettier --list-different --write '**/*.{ts,tsx,js,jsx,json,md}' '!package-lock.json'"
node-check = "cd frontend && npx tsc --noEmit -p tsconfig.app.json"
node-install-ui-tests = "npm --prefix frontend/ui-tests install"
test-ui = { cmd = "npm --prefix frontend/ui-tests run test ", depends-on = ["node-install-ui-tests"] }
test-launch = "pixi run uvicorn fileglancer.server:app --no-access-log --port 7879"
dev-install = { depends-on = ["node-build", "pip-install"] }
dev-watch = { cmd = "cd frontend && NODE_ENV=development npm run watch" }
dev-vite = { cmd = "cd frontend && npx vite" }
dev-vite-remote = { cmd = "cd frontend && SSL_KEYFILE=/opt/certs/cert.key SSL_CERTFILE=/opt/certs/cert.crt npx vite" }
dev-launch = "pixi run uvicorn fileglancer.server:app --no-access-log --port 7878 --reload"
dev-launch-remote = "pixi run uvicorn fileglancer.server:app --host 0.0.0.0 --port 7878 --reload --ssl-keyfile /opt/certs/cert.key --ssl-certfile /opt/certs/cert.crt"
prod-launch-remote = "pixi run uvicorn fileglancer.server:app --workers 10 --host 0.0.0.0 --port 7878 --ssl-keyfile /opt/certs/cert.key --ssl-certfile /opt/certs/cert.crt"
dev-launch-secure = "python fileglancer/dev_launch.py"
migrate = "alembic -c fileglancer/alembic.ini upgrade head"
migrate-create = "alembic -c fileglancer/alembic.ini revision --autogenerate"
stamp-db = "python -m fileglancer.stamp_db"
container-rebuild = "npx @devcontainers/cli up --workspace-folder . --remove-existing-container"
container-shell = "npx @devcontainers/cli exec --workspace-folder . bash"
container-claude = "npx @devcontainers/cli exec --workspace-folder . bash -lc 'pixi run claude --dangerously-skip-permissions'"
claude = "claude"
[tool.pixi.tasks.test-py312]
depends-on = [
{ task = "test-pip-install", environment = "test-py312" },
{ task = "test-backend", environment = "test-py312" }
]
[tool.pixi.dependencies]
python = ">=3.12.0"
pip = ">=25.0.1,<26"
nodejs = ">=22.12.0,<23"
alembic = ">=1.17.0,<2"
atlassian-python-api = ">=4.0.7,<5"
authlib = ">=1.6.5,<2"
cachetools = ">=6.2.1,<7"
click = ">=8.0"
fastapi = ">=0.119.1,<0.120"
httpx = ">=0.28.1,<0.29"
itsdangerous = ">=2.2.0,<3"
loguru = ">=0.7.3,<0.8"
pandas = ">=2.3.3,<3"
pydantic = ">=2.10.6,<3"
pydantic-settings = ">=2.11.0,<3"
python-jose = ">=3.5.0,<4"
cryptography = ">=41.0.0"
sqlalchemy = ">=2.0.44,<3"
uvicorn = ">=0.38.0,<0.39"
[tool.pixi.pypi-dependencies]
fileglancer = { path = ".", editable = true }
[dependency-groups]
release = ["build>=1.3.0,<2"]