-
Notifications
You must be signed in to change notification settings - Fork 6
/
setup.py
69 lines (51 loc) · 1.77 KB
/
setup.py
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
# see https://github.com/karlicoss/pymplate for up-to-date reference
url = 'https://github.com/karlicoss/cachew'
author = 'Dima Gerasimov'
author_email = 'karlicoss@gmail.com'
description = 'Easy sqlite-backed persistent cache for dataclasses'
install_requires = [
'appdirs' , # default cache dir
'sqlalchemy>=1.0', # cache DB interaction
'orjson', # fast json serialization
'pytz', # used to properly marshall pytz datatimes
]
from setuptools import setup, find_namespace_packages # type: ignore
def main() -> None:
pkgs = find_namespace_packages('src', exclude=['*.tests'])
pkg = min(pkgs)
setup(
name=pkg,
use_scm_version={
'version_scheme': 'python-simplified-semver',
'local_scheme': 'dirty-tag',
},
setup_requires=['setuptools_scm'],
url=url,
author=author,
author_email=author_email,
description=description,
packages=pkgs,
package_dir={'': 'src'},
package_data={pkg: ['py.typed']},
python_requires='>=3.8',
install_requires=install_requires,
extras_require={
'testing': [
'pytest', 'pytz', 'patchy',
'pylint',
'mypy', 'lxml',
'bandit',
'more-itertools',
'enlighten', # used in logging helper, but not really required
'cattrs', # benchmarking alternative marshalling implementation
'pyinstrument', # for profiling from within tests
'codetiming', # Timer context manager
],
'optional': [
'colorlog',
],
},
zip_safe=False,
)
if __name__ == '__main__':
main()