-
Notifications
You must be signed in to change notification settings - Fork 12
/
pyproject.toml
156 lines (141 loc) · 3.85 KB
/
pyproject.toml
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
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[project]
name = "sqlalchemy-file"
description = "SQLAlchemy-file is a SQLAlchemy extension for attaching files to SQLAlchemy model and uploading them to various storage."
readme = "README.md"
license = "MIT"
requires-python = ">=3.7"
keywords = ["sqlalchemy", "sqlmodel", "file-upload", "apache-libcloud"]
authors = [
{ name = "Jocelin Hounon", email = "[email protected]" },
]
classifiers = [
'Development Status :: 4 - Beta',
"Framework :: AsyncIO",
'Environment :: Web Environment',
'Intended Audience :: Developers',
"License :: OSI Approved :: MIT License",
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Software Development :: Libraries :: Python Modules',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
"Topic :: Database",
"Topic :: Database :: Database Engines/Servers",
]
dependencies = [
"SQLAlchemy >=1.4, <2.1",
"apache-libcloud >=3.6, <3.8",
]
dynamic = ["version"]
[project.urls]
Homepage = "https://jowilf.github.io/sqlalchemy-file"
Documentation = "https://jowilf.github.io/sqlalchemy-file"
Repository = "https://github.com/jowilf/sqlalchemy-file"
Changelog = "https://jowilf.github.io/sqlalchemy-file/changelog/"
[project.optional-dependencies]
test = [
"pytest >=7.2.0, <7.3.0",
"mypy ==1.0.1",
"ruff ==0.0.253",
"black ==23.1.0",
"coverage >=7.0.0, <7.3.0",
"fasteners ==0.18",
"PyMySQL[rsa] >=1.0.2, <1.1.0",
"psycopg2-binary >=2.9.5, <3.0.0",
"Pillow >=9.4.0, <9.5.0",
"python-multipart ==0.0.6",
"fastapi >=0.92, <0.93",
"Flask >=2.2, <2.3",
"Flask-SQLAlchemy >=3.0,<3.1"
]
doc = [
"mkdocs-material >=9.0.0, <10.0.0",
"mkdocstrings[python] >=0.19.0, <0.21.0"
]
dev = [
"pre-commit >=2.20.0, <4.0.0",
"uvicorn >=0.20.0, <0.21.0",
]
[tool.hatch.envs.default]
features = [
"test",
"dev"
]
[tool.hatch.envs.default.scripts]
format = [
"ruff sqlalchemy_file tests docs_src --fix",
"black ."
]
[tool.hatch.envs.test]
features = [
"test",
]
[tool.hatch.envs.test.scripts]
lint = [
"mypy sqlalchemy_file",
"ruff sqlalchemy_file tests",
"black . --check"
]
run = "coverage run -m pytest tests"
cov = [
"coverage combine",
"coverage report --show-missing",
"coverage xml"
]
[[tool.hatch.envs.test.matrix]]
sqla_version = ["1.4.x", "2.0.x"]
[tool.hatch.envs.test.overrides]
matrix.sqla_version.dependencies = [
{ value = "SQLAlchemy >=2.0, <2.1", if = ["2.0.x"] },
{ value = "SQLAlchemy >=1.4, <1.5", if = ["1.4.x"] },
{ value = "sqlmodel ==0.0.8", if = ["1.4.x"] },
]
matrix.sqla_version.scripts = [
{ key = "run", value = 'coverage run -m pytest tests --ignore=tests/test_sqlmodel.py', if = ["2.0.x"] },
{ key = "cov", value = '', if = ["2.0.x"] },
]
[tool.hatch.envs.docs]
features = [
"doc",
]
[tool.hatch.envs.docs.scripts]
serve = "mkdocs serve -a localhost:8080"
build = "mkdocs build"
deploy = "mkdocs gh-deploy --force"
[tool.hatch.version]
path = "sqlalchemy_file/__init__.py"
[tool.coverage.report]
fail_under = 99
show_missing = true
exclude_lines = [
"pragma: no cover",
"if TYPE_CHECKING:",
]
[tool.coverage.run]
parallel = true
command_line = "-m pytest"
source = ["sqlalchemy_file", "tests"]
[tool.ruff]
select = [
"E", # pycodestyle errors
"W", # pycodestyle warnings
"F", # pyflakes
"I", # isort
"C", # flake8-comprehensions
"B", # flake8-bugbear
]
ignore = ["E501", "B904", "B008"]
[tool.ruff.isort]
known-third-party = ["sqlalchemy_file"]
[tool.mypy]
strict = true
warn_unused_ignores = false
[tool.hatch.build.targets.wheel]
[tool.hatch.build.targets.sdist]
include = ["sqlalchemy_file"]