-
Notifications
You must be signed in to change notification settings - Fork 25
Expand file tree
/
Copy pathpyproject.toml
More file actions
277 lines (250 loc) · 5.8 KB
/
pyproject.toml
File metadata and controls
277 lines (250 loc) · 5.8 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
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
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
[project]
name = "eKoNLPy"
version = "2.2.0"
description = "A Korean natural language processing toolkit for economic analysis"
authors = [{ name = "Young Joon Lee", email = "entelecheia@hotmail.com" }]
license = "MIT"
readme = "README.md"
keywords = ["KoNLPy", "Tokenization", "Sentiment analysis", "Monetary policy"]
requires-python = ">=3.9,<4.0"
classifiers = [
"Intended Audience :: Developers",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"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",
"Topic :: Software Development :: Libraries :: Python Modules",
]
dependencies = [
"click>=8.1.6",
"fugashi>=1.3.3",
"mecab-ko-dic>=1.0.0",
"nltk>=3.8.1",
"scipy>1.10.0,<=1.13.1",
"pandas>=1.5.3,<=2.3.3",
]
[project.urls]
Homepage = "https://ekonlpy.entelecheia.ai"
Repository = "https://github.com/entelecheia/eKoNLPy"
Documentation = "https://ekonlpy.entelecheia.ai"
[dependency-groups]
dev = [
"pytest>=7.2.1",
"pytest-cov>=4.0.0",
"pre-commit>=2.20.0",
"tox-uv>=1.11.3",
"deptry>=0.20.0",
"mypy>=1.0.0",
"ruff>=0.6.9",
"mkdocs>=1.4.2",
"mkdocs-material>=8.5.10",
"mkdocstrings[python]>=0.26.1",
"python-semantic-release>=9.0.0",
"isort>=5.12.0",
"black>=24.0.0",
"flake8>=6.0.0",
"flake8-pyproject>=1.2.2",
]
[tool.hatch.build.targets.wheel]
packages = ["src/ekonlpy"]
[tool.hatch.build.targets.wheel.sources]
"src" = ""
[tool.hatch.build.targets.wheel.include]
"src/ekonlpy/data/*/*.txt" = "ekonlpy/data"
"src/ekonlpy/data/*/*.csv" = "ekonlpy/data"
"src/ekonlpy/data/*/*/*.txt" = "ekonlpy/data"
"src/ekonlpy/data/*/*/*.csv" = "ekonlpy/data"
"src/ekonlpy/data/model/*" = "ekonlpy/data/model"
[project.scripts]
ekonlpy = 'ekonlpy.__cli__:main'
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.black]
# 'extend-exclude' excludes files or directories in addition to the defaults
extend-exclude = '''
# A regex preceded with ^/ will apply only to files and directories
# in the root of the project.
(
_version.py
| .refs
| tests
| docs
| book
| _build
| node_modules
| __pycache__
| .txt
| .csv
)
'''
[tool.isort]
profile = "black"
skip = [
'_version.py',
'node_modules',
'_build',
'docs',
'tests',
'venv',
'.copier-template',
'.refs',
]
[tool.flake8]
ignore = ['F401', 'E501', 'W503']
exclude = ["node_modules", "_build", "docs", "tests", "venv", ".copier-template", ".refs"]
per-file-ignores = ['__init__.py:F401', '_version.py:W292']
[tool.mypy]
namespace_packages = true
exclude = [
"node_modules",
"build",
"_build",
"dist",
"docs",
"tests",
"venv",
".copier-template",
".refs",
]
# 3rd party import
ignore_missing_imports = true
# dynamic typing
disallow_any_unimported = true
disallow_any_expr = false
disallow_any_decorated = false
disallow_any_explicit = true
disallow_any_generics = false
disallow_subclassing_any = true
# platform
python_version = "3.12"
# untyped
disallow_untyped_calls = true
disallow_untyped_defs = true
disallow_incomplete_defs = true
disallow_untyped_decorators = true
# None and Optional
no_implicit_optional = true
# Warnings
warn_return_any = false
warn_unreachable = true
# Misc
pretty = true
[tool.pytest.ini_options]
testpaths = ["tests"]
addopts = "-p no:cacheprovider" # deactivating pytest caching.
[tool.ruff]
target-version = "py39"
line-length = 120
fix = true
[tool.ruff.lint]
select = [
# flake8-2020
"YTT",
# flake8-bandit
"S",
# flake8-bugbear
"B",
# flake8-builtins
"A",
# flake8-comprehensions
"C4",
# flake8-debugger
"T10",
# flake8-simplify
"SIM",
# isort
"I",
# mccabe
"C90",
# pycodestyle
"E",
"W",
# pyflakes
"F",
# pygrep-hooks
"PGH",
# pyupgrade
"UP",
# ruff
"RUF",
# tryceratops
"TRY",
]
ignore = [
# LineTooLong
"E501",
# DoNotAssignLambda
"E731",
]
[tool.ruff.lint.per-file-ignores]
"tests/*" = ["S101", "UP035", "UP006", "S603"]
[tool.ruff.format]
preview = true
[tool.coverage.report]
exclude_lines = ['if __name__ == "__main__":']
skip_empty = true
[tool.coverage.run]
branch = true
source = ["src/ekonlpy"]
[tool.deptry]
ignore = ["DEP001", "DEP003"]
[tool.semantic_release]
# General settings
tag_format = "v{version}"
commit_parser = "angular"
major_on_zero = true
allow_zero_version = true
tag_commit = true
no_git_verify = false
version_source = "tag"
commit_version_number = true
commit_message = ":rocket: {version}\n\nAutomatically generated by python-semantic-release"
build_command = "pip3 install uv && make build"
# Version variables
version_toml = ["pyproject.toml:project.version"]
version_variables = ["src/ekonlpy/_version.py:__version__"]
# Remote settings
[tool.semantic_release.remote]
name = "origin"
type = "github"
ignore_token_for_push = false
insecure = false
token = { env = "GH_TOKEN" }
# Changelog settings
[tool.semantic_release.changelog]
insertion_flag = "<!--next-version-placeholder-->"
mode = "update"
# Commit parser options
[tool.semantic_release.commit_parser_options]
allowed_tags = [
"build",
"chore",
"ci",
"docs",
"feat",
"fix",
"perf",
"style",
"refactor",
"test",
]
minor_tags = ["feat"]
patch_tags = ["fix", "perf"]
default_bump_level = 0
# Branch settings
[tool.semantic_release.branches.main]
match = "(main|master|release)"
prerelease_token = "rc"
prerelease = false
# Commit author settings
[tool.semantic_release.commit_author]
env = "GIT_COMMIT_AUTHOR"
default = "semantic-release <semantic-release>"
# Publish settings
[tool.semantic_release.publish]
dist_glob_patterns = ["dist/*"]
upload_to_vcs_release = true