-
Notifications
You must be signed in to change notification settings - Fork 43
/
Copy pathpyproject.toml
139 lines (128 loc) · 3.22 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
[build-system]
requires = ["hatchling>=1.22.2"]
build-backend = "hatchling.build"
[project]
requires-python = ">=3.8"
name = "mocket"
description = "Socket Mock Framework - for all kinds of socket animals, web-clients included - with gevent/asyncio/SSL support"
readme = { file = "README.rst", content-type = "text/x-rst" }
license = { file = "LICENSE" }
authors = [{ name = "Giorgio Salluzzo", email = "[email protected]" }]
urls = { github = "https://github.com/mindflayer/python-mocket" }
classifiers = [
"Development Status :: 6 - Mature",
"Intended Audience :: Developers",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
"Topic :: Software Development",
"Topic :: Software Development :: Testing",
"License :: OSI Approved :: BSD License",
]
dependencies = [
"puremagic",
"decorator>=4.0.0",
"urllib3>=1.25.3",
"h11",
]
dynamic = ["version"]
[project.optional-dependencies]
test = [
"pre-commit",
"psutil",
"pytest",
"pytest-cov",
"pytest-asyncio",
"asgiref",
"requests",
"redis",
"gevent",
"sure",
"flake8>5",
"xxhash",
"httpx",
"pipfile",
"build",
"fastapi",
"aiohttp",
"wait-for-it",
"mypy",
"types-decorator",
]
speedups = [
"xxhash;platform_python_implementation=='CPython'",
"xxhash-cffi;platform_python_implementation=='PyPy'",
]
pook = [
"pook>=0.2.1",
]
[tool.hatch.version]
path = "mocket/__init__.py"
[tool.hatch.build]
ignore-vcs = true
[tool.hatch.build.targets.sdist]
include = [
"README.rst",
"LICENSE",
"pyproject.toml",
"mocket/",
"tests/",
]
exclude = [
".*",
]
[tool.pytest.ini_options]
testpaths = [
"tests", "mocket",
]
addopts = "--doctest-modules --cov=mocket --cov-report=term-missing --cov-append -v -x"
[tool.ruff]
src = ["mocket", "tests"]
[tool.ruff.lint]
extend-ignore = ["E731", "E501"]
select = [
# pycodestyle
"E",
# Pyflakes
"F",
# pyupgrade
"UP",
# flake8-bugbear
"B",
# flake8-simplify
"SIM",
# isort
"I",
]
[tool.ruff.lint.mccabe]
# Unlike Flake8, default to a complexity level of 10.
# https://en.wikipedia.org/wiki/Cyclomatic_complexity#Limiting_complexity_during_development
max-complexity = 8
[tool.mypy]
python_version = "3.8"
files = [
"mocket/exceptions.py",
"mocket/compat.py",
"mocket/utils.py",
# "tests/"
]
strict = true
warn_unused_configs = true
ignore_missing_imports = true
warn_redundant_casts = true
warn_unused_ignores = true
show_error_codes = true
implicit_reexport = true
disallow_any_generics = false
follow_imports = "silent" # enable this once majority is typed
enable_error_code = ['ignore-without-code']
disable_error_code = ["no-untyped-def"] # enable this once full type-coverage is reached
[[tool.mypy.overrides]]
module = "tests.*"
disable_error_code = ['type-arg', 'no-untyped-def']