forked from debashisbiswas/debashisbiswas.github.io
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
115 lines (100 loc) · 2.6 KB
/
pyproject.toml
File metadata and controls
115 lines (100 loc) · 2.6 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
[tool.poetry]
name = "maverickespinosa-personal-portfolio"
version = "0.0.1"
description = "A template for python-based research project"
authors = ["Maverick Espinosa <emaverick2001@gmail.com>"]
license = "Apache 2.0 License"
readme = "README.md"
packages = [
{ include = "src" }
]
[tool.poetry.dependencies]
python = "^3.9"
mypy = "^1.8.0"
beartype = "^0.17.1"
pydantic = "^2.8.2"
[tool.poetry.group.dev.dependencies]
pre-commit = "^3.6.0"
nbmake = "^1.5.0"
types-setuptools = "^69.0.0.0"
ruff = "^0.3.0"
commitizen = "^3.14.1"
# Removed black and isort since we're using ruff
[tool.poetry.group.test.dependencies]
pytest = "^8.0.0"
pytest-asyncio = "^0.23.5"
pytest-cov = "^4.1.0"
pytest-mock = "^3.12.0"
hypothesis = "^6.98.0"
[build-system]
requires = ["poetry-core>=1.9.0"]
build-backend = "poetry.core.masonry.api"
[tool.mypy]
ignore_missing_imports = true
check_untyped_defs = true
follow_imports = "normal"
strict = true
plugins = ["pydantic.mypy"]
warn_redundant_casts = true
warn_unused_ignores = true
warn_return_any = true
strict_optional = true
disallow_untyped_defs = true
disallow_incomplete_defs = true
[tool.pytest.ini_options]
testpaths = ["tests"]
python_files = "test_*.py"
addopts = "-v --cov=python_project_template --cov-report=term-missing"
markers = [
"slow: marks tests as slow",
"integration: marks tests as integration tests",
]
[tool.coverage.run]
source = ["python_project_template"]
omit = ["tests/*", "**/__init__.py"]
[tool.coverage.report]
exclude_lines = [
"pragma: no cover",
"def __repr__",
"if __name__ == .__main__.:",
"raise NotImplementedError",
"raise ImportError",
"except ImportError:",
]
[tool.codespell]
ignore-words-list = "dout, te, indicies, astroid"
skip = ["data", ".git", "*.pyc", "*.csv", "*.json", "frontend/src/content/blog"]
quiet-level = 3
[tool.ruff]
line-length = 88
target-version = "py310"
[tool.ruff.lint]
select = [
"E", # pycodestyle errors
"W", # pycodestyle warnings
"F", # pyflakes
"I", # isort
"C", # flake8-comprehensions
"B", # flake8-bugbear
"UP", # pyupgrade
]
ignore = ["E203", "E266", "E501"]
[tool.ruff.format]
quote-style = "single"
indent-style = "space"
skip-magic-trailing-comma = false
line-ending = "auto"
[tool.ruff.lint.mccabe]
max-complexity = 10
[tool.ruff.lint.per-file-ignores]
"__init__.py" = ["F401"]
"tests/*" = ["S101"]
[tool.commitizen]
name = "cz_conventional_commits"
version = "0.0.1"
tag_format = "v$version"
bump_message = "bump: version $current_version → $new_version"
version_files = [
"pyproject.toml:version",
"python_project_template/__init__.py:__version__"
]