-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
110 lines (96 loc) · 3.13 KB
/
Copy pathpyproject.toml
File metadata and controls
110 lines (96 loc) · 3.13 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
[project]
name = "ohsome-filter-to-sql"
version = "0.12.0"
authors = [{name="HeiGIT ohsome team", email="ohsome@heigit.org"}]
description = "Translate ohsome API filter to SQL WHERE clause ready to be used with ohsomeDB"
readme = "README.md"
requires-python = ">=3.11,<3.15"
classifiers = [
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"Programming Language :: Python :: 3 :: Only",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Topic :: Scientific/Engineering :: GIS",
"Topic :: Software Development :: Libraries :: Python Modules",
]
license = "LGPL-3.0-only"
license-files = ["COPYING*"]
dependencies = [
"antlr4-python3-runtime>=4.13.2",
"pydantic>=2.12.5",
]
[project.urls]
Homepage = "https://ohsome.org/"
# TODO: update once dedicated documentation is available
Documentation = "https://github.com/GIScience/ohsome-filter-to-sql/blob/main/README.md"
Repository = "https://github.com/GIScience/ohsome-filter-to-sql"
Issues = "https://github.com/GIScience/ohsome-filter-to-sql/issues"
# TODO: create changelog
# Changelog = "https://github.com/GIScience/ohsome-filter-to-sql/blob/main/CHANGELOG.md"
[build-system]
requires = ["uv_build>=0.9.5,<0.12.0"]
build-backend = "uv_build"
[project.scripts]
ohsome-filter-to-sql= "ohsome_filter_to_sql.main:cli"
[tool.uv]
package = true
[tool.uv.build-backend]
module-root = "" # use ohsome-filter-to-sql/ as root instead the default src/ohsome-filter-to-sql
[dependency-groups]
dev = [
"ruff>=0.12.4",
"asyncpg>=0.31.0",
"pytest-asyncio>=1.1.0",
"antlr4-tools>=0.2.2",
"pytest-cov>=7.0.0",
"pytest-sugar>=1.1.1",
"prek>=0.3.0",
"ty>=0.0.24",
"pytest-markdown-docs>=0.9.2",
"pytest-randomly>=4.0.1",
"asyncpg-recorder>=0.8.0",
"pytest>=9.0.3",
"pytest-approval>=0.16.2",
"pytest-nodeid-to-filepath>=0.1.0",
]
[tool.ruff]
extend-exclude = [
"ohsome_filter_to_sql/OFLLexer.py",
"ohsome_filter_to_sql/OFLListener.py",
"ohsome_filter_to_sql/OFLParser.py"
]
[tool.ruff.lint]
select = [
"A", # flake8-builtins
"E", # pycodestyle Error
"F", # Pyflakes
"I", # isort
"N", # pep8-nameing
"Q", # flake8-quotes
"W", # pycodestyle Warning
"C90", # mccabe
"TRY", # tryceratops
"RUF", # ruff-specific rules
"FURB", # refurb
"PERF", # perflint
"S", # bandit
"B", # bugbear
"SIM", # simplify
]
[tool.ruff.lint.extend-per-file-ignores]
"tests/*" = ["S101", "S608"] # S101 usage of asserts; S608 possible SQL injection
"ohsome_filter_to_sql/main.py" = ["N802", "N803"] # N802 function name should be lowercase
[tool.ty.src]
exclude = ["ohsome_filter_to_sql/OFLLexer.py", "ohsome_filter_to_sql/OFLListener.py", "ohsome_filter_to_sql/OFLParser.py"]
[tool.pytest]
addopts = ["-s"]
testpaths = ["tests"]
asyncio_default_fixture_loop_scope = "session"
asyncio_default_test_loop_scope = "session"
[tool.asyncpg-recorder]
"cassettes-dir"="tests/cassettes"
[tool.pytest-approval]
"approvals-dir"="tests/approvals"