-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathpyproject.toml
More file actions
123 lines (106 loc) · 3.04 KB
/
pyproject.toml
File metadata and controls
123 lines (106 loc) · 3.04 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
[project]
name = "cognite-extractor-utils"
version = "7.6.0"
description = "Utilities for easier development of extractors for CDF"
authors = [
{name = "Mathias Lohne", email = "mathias.lohne@cognite.com"}
]
license = { text = "Apache-2.0" }
readme = "README.md"
requires-python = ">=3.10"
classifiers = [
"Development Status :: 5 - Production/Stable",
"Programming Language :: Python"
]
dependencies = [
"cognite-sdk>=7.59.0",
"prometheus-client>=0.7.0,<=1.0.0",
"arrow>=1.0.0",
"pyyaml>=5.3.0,<7",
"dacite>=1.6.0,<1.9.0",
"psutil>=6.0.0",
"decorator>=5.1.1",
"more-itertools>=10.0.0",
"typing-extensions>=3.7.4,<5",
"python-dotenv>=1.0.0",
"azure-identity>=1.14.0",
"azure-keyvault-secrets>=4.7.0",
"orjson>=3.10.3",
"httpx>=0.27.0,<1",
"pydantic>=2.8.2",
"pyhumps>=3.8.0",
"croniter>=6.0.0",
"jsonlines>=4.0.0",
]
[project.urls]
repository = "https://github.com/cognitedata/python-extractor-utils"
[project.optional-dependencies]
experimental = ["cognite-sdk-experimental"]
[tool.uv]
dev-dependencies = [
"mypy>=1.14.1",
"ruff>=0.9.0",
"pytest>=8.0.0",
"pytest-cov>=6.0.0",
"sphinx>=7.0.0",
"sphinx-rtd-theme>=3.0.0",
"pre-commit>=4.0.0",
"SecretStorage>=3.1.2",
"twine>=6.0.0",
"pytest-order>=1.0.1",
"parameterized",
"requests>=2.31.0",
"types-requests>=2.31.0.20240125",
"faker>=33.0.0",
"types-croniter>=5.0.1.20241205",
"types-pyyaml>=6.0.12.20241230",
"types-psutil>=6.1.0.20241221",
"types-decorator>=5.1.8.20240310",
]
[tool.ruff]
exclude = [
".git",
".mypy_cache",
".ruff_cache",
]
line-length = 120
target-version = "py310"
[tool.ruff.lint]
# TODO: Add these rules, which are likely to require larger changes to the codebase:
# D, DOC - Docstrings
# ANN - Type annotations everywhere, disallow Any, bare dict, bare list, etc.
select = ["A", "E", "F", "I", "T20", "S", "B", "UP", "DTZ", "W", "LOG", "RUF", "SIM", "C4", "PERF", "FURB", "D", "D213"]
ignore = ["S104", "S303", "S311", "PERF203", "D212", "D200", "D107"]
# Allow unused variables when underscore-prefixed.
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
[tool.ruff.lint.per-file-ignores]
"tests/*" = ["S101", "T201", "S105", "S106", "S608", "E501", "S113", "F841", "B017", "D"]
"**/__init__.py" = ["F401"]
"docs/*" = ["E402"]
[tool.ruff.lint.isort]
known-third-party = ["alembic"]
[tool.ruff.lint.pydocstyle]
convention = "google"
[tool.pytest.ini_options]
markers = [
"unstable: tests for the unstable package (deselect with '-m \"not unstable\"')",
]
[tool.mypy]
pretty = true
check_untyped_defs = true
ignore_missing_imports = false
disallow_untyped_defs = true
follow_imports = "normal"
namespace_packages = true
explicit_package_bases = true
show_error_codes = true
warn_redundant_casts = true
warn_unused_ignores = true
exclude = "tests/*"
[tool.hatch.build.targets.wheel]
packages = ["cognite"]
[tool.hatch.build.targets.sdist]
only-include = ["cognite"]
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"