-
Notifications
You must be signed in to change notification settings - Fork 77
/
pyproject.toml
213 lines (199 loc) · 5.83 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
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
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"
[tool.mypy]
check_untyped_defs = true
ignore_missing_imports = true
python_version = "3.9"
show_error_codes = true
follow_imports = "silent"
pretty = true
allow_redefinition = true
exclude = "tests/.*|demisto_sdk/commands/init/templates/.*"
[tool.poetry]
name = "demisto-sdk"
version = "1.32.5"
description = "\"A Python library for the Demisto SDK\""
authors = ["Demisto"]
license = "MIT"
readme = "README.md"
classifiers = [
'Intended Audience :: Developers',
'Natural Language :: English',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
'Programming Language :: Python :: 3.12',
'Programming Language :: Python :: Implementation :: CPython'
]
exclude = [
"TestSuite/**",
"tests_end_to_end/**",
"demisto_sdk/tests/**",
"demisto_sdk/**/tests/**",
"demisto_sdk/**/test_data/**",
"demisto_sdk/**/test_files/**"
]
[tool.poetry.dependencies]
python = ">=3.9,<3.13"
autopep8 = "^2.0.4"
bandit = "^1.7.4"
mypy = "^0.982"
pylint = "^3.3.1"
vulture = "^2.3"
beautifulsoup4 = "^4.11.1"
chardet = ">=4,<6"
coloredlogs = "^15.0.1"
configparser = "^5.2.0"
coverage = "^7.2.1,<7.4" # in 7.4 we get empty results
decorator = "^5.1.1"
demisto-py = "^3.2.10"
dictor = "^0.1.9"
docker = "^7.1.0"
flatten-dict = "^0.4.2"
gitdb = "^4.0.9"
google-cloud-storage = "^2.13.0"
inflection = "^0.5.1"
jsonschema = "^4.4.0"
mergedeep = "^1.3.4"
networkx = "^2.7.1"
nltk = "==3.9.1"
prettytable = "^3.2.0"
pykwalify = "^1.8.0"
pyspellchecker = "^0.6.3"
requests = "^2.27.1"
"ruamel.yaml" = "^0.17.21"
slack-sdk = "^3.17.0"
tenacity = "^8.4.1"
tabulate = ">=0.8.9,<0.10.0"
ujson = "^5.1.0"
urllib3 = ">=1.26,<3"
wcmatch = "^8.3"
yamlordereddictloader = "^0.4.0"
GitPython = "^3.1.37"
Pebble = ">=4.6.3,<6.0.0"
PyPDF2 = "^1.28.6"
giturlparse = "^0.10.0"
pytest-freezegun = "^0.4.2"
python-dotenv = "^0.20.0"
importlib-resources = "^5.6.0"
dictdiffer = "^0.9.0"
imagesize = "^1.3.0"
dateparser = "^1.1.1"
gsutil = {version = "5.17", optional = true}
ordered-set = "^4.1.0"
paramiko = ">=3.4.1,<4.0"
neo4j = "^5.14.0"
pydantic = "^1.10"
typer = {extras = ["all"], version = "^0.13.0"}
packaging = "^24.0"
orjson = "^3.8.3"
more-itertools = "^10.0.0"
junitparser = "^3.1.0"
google-cloud-secret-manager = "^2.18.3"
json5 = "^0.9.14"
klara = {version = "^0.6.3", optional = true}
typing-extensions = "^4.1.1" # not a mypy types- dependency
pre-commit = "^3.5.0"
lxml = "^5.0.0"
uv = "^0.1.5"
toml = "^0.10.2"
werkzeug = "^2.2.0" # Added as mitmproxy8 -> flask<2.1
loguru = "^0.7.2"
pygithub = "^2.2.0"
setuptools = "^75.5.0"
[tool.poetry.extras]
build = ["gsutil"]
generate-unit-tests = ["klara"]
[tool.poetry.group.dev.dependencies]
mitmproxy = "^8.0.0" # if installing zstandard fails, make sure you have python3.x-dev installed.
mock = "^4.0.3"
pytest = "^7.1.1"
pytest-cov = "^4.0.0"
pytest-datadir-ng = "^1.1.1"
pytest-mock = "^3.7.0"
pytest-subprocess = "^1.4.1"
requests-mock = "^1.9.3"
ipykernel = "^6.16.1"
ruff = "^0.6.6"
pytest-github-actions-annotate-failures = "^0.2.0"
pytest-sugar = "^1.0.0"
pytest-loguru = "^0.4.0"
[tool.poetry.group.types.dependencies]
types-requests = "^2.31.0.20240311"
types-mock = "^4.0.15"
types-setuptools = "^75"
types-ujson = "^5.6.0.0"
types-decorator = "^5.1.8"
types-toml = "^0.10.8.7"
types-tabulate = "^0.9.0.20240106"
types-pytz = "^2024.1.0.20240203"
types-dateparser = "^1.1.4.20240106"
types-python-dateutil = "^2.9.0.20240316"
[tool.poetry.scripts]
demisto-sdk = "demisto_sdk.__main__:app"
sdk-changelog = "demisto_sdk.scripts.changelog.changelog:main"
merge-coverage-report = "demisto_sdk.scripts.merge_coverage_report:main"
merge-pytest-reports = "demisto_sdk.scripts.merge_pytest_reports:main"
validate-content-path = "demisto_sdk.scripts.validate_content_path:main"
validate-conf-json = "demisto_sdk.scripts.validate_conf_json:main"
init-validation = "demisto_sdk.scripts.init_validation_script:main"
validate-deleted-files = "demisto_sdk.scripts.validate_deleted_files:main"
validate-file-permission-changes = "demisto_sdk.scripts.validate_file_permission_changes:main"
prevent-mypy-global-ignore = "demisto_sdk.scripts.prevent_mypy_global_ignore:main"
[tool.ruff]
exclude = [
"demisto_sdk/tests/test_files/",
"demisto_sdk/commands/init/tests/test_files",
"demisto_sdk/commands/generate_unit_tests/tests/test_files/",
"demisto_sdk/commands/init/templates",
"demisto_sdk/commands/generate_yml_from_python/tests/generate_yml_from_python_test.py"
]
target-version = "py39"
[tool.ruff.lint]
ignore = [
"F403",
"F405",
"E501"
]
select = [
"C9",
"E",
"F",
"I",
"PLE",
"RUF100",
"T10",
"T20",
"TID251",
"W",
"PTH107",
"PTH113",
"PTH110",
"PTH119"
]
logger-objects = ["demisto_sdk.commands.common.logger.logger"]
[tool.ruff.lint.flake8-tidy-imports]
[tool.ruff.lint.flake8-tidy-imports.banned-api]
"distutils.version".msg = "Use packaging.version.Version"
"git.Repo".msg = "Use GitUtil instead"
"json".msg = "use JSON_Handler instead"
"json5".msg = "use JSON_Handler instead"
"logging".msg = "Use demisto_sdk.commands.common.logger"
"loguru".msg = "Use demisto_sdk.commands.common.logger"
"orjson".msg = "use JSON_Handler instead"
"packaging.version.LooseVersion".msg = "Use packaging.version.Version"
"ruamel.yaml".msg = "use YAML_Handler instead"
"str.StrEnum".msg = "Import from demisto_sdk.commands.common.StrEnum for <3.11 compatability"
"ujson".msg = "use JSON_Handler"
[tool.ruff.lint.mccabe]
max-complexity = 30
[tool.ruff.lint.per-file-ignores]
"demisto_sdk/commands/test_content/timestamp_replacer.py" = ["TID251"] # used outside the SDK
"demisto_sdk/__main__.py" = ["E402"] # The logger must be set up before everything else
[tool.vulture]
exclude = ["*/tests/*"]
min_confidence = 80
paths = ["demisto_sdk", "TestSuite"]
sort_by_size = true