-
Notifications
You must be signed in to change notification settings - Fork 84
Expand file tree
/
Copy pathpyproject.toml
More file actions
143 lines (123 loc) · 4.7 KB
/
pyproject.toml
File metadata and controls
143 lines (123 loc) · 4.7 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
[project]
name = "frappe-manager"
version = "0.19.0.dev0"
description = "A CLI tool based on Docker Compose to easily manage Frappe based projects. As of now, only suitable for development in local machines running on Mac and Linux based OS."
readme = "README.md"
requires-python = ">=3.13,<3.14"
license = { text = "MIT" }
authors = [ { name = "rtCamp", email = "sys@rtcamp.com" } ]
maintainers = [ { name = "Alok Singh", email = "alok.singh@rtcamp.com" } ]
dependencies = [
"typer>=0.21.0,<0.22.0",
"requests>=2.32.0,<3.0.0",
"psutil>=7.0.0,<8.0.0",
"configargparse!=1.7",
"ruamel-yaml>=0.19.0,<0.20.0",
"tomlkit>=0.14.0,<0.15.0",
"pydantic>=2.9.0,<3.0.0",
"email-validator>=2.3.0,<3.0.0",
"jinja2>=3.1.6,<4.0.0",
"ngrok>=1.7.0,<2.0.0",
"passlib>=1.7.4,<2.0.0",
"inquirerpy>=0.3.4,<0.4.0",
"gitpython>=3.1.40,<4.0.0",
"cryptography>=46.0.0,<47.0.0",
"packaging>=26.0.0,<27.0.0",
]
[project.urls]
Repository = "https://github.com/rtcamp/frappe-manager"
Documentation = "https://github.com/rtcamp/frappe-manager/wiki"
"Bug Tracker" = "https://github.com/rtcamp/frappe-manager/issues"
[project.scripts]
fm = "frappe_manager.main:cli_entrypoint"
[tool.ruff]
line-length = 120
indent-width = 4
target-version = "py313"
[tool.ruff.lint]
dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
select = ["E", "F", "I", "B", "C", "W", "UP", "N", "YTT", "S", "BLE", "FBT", "A", "COM", "C4", "DTZ", "T10", "EM", "EXE", "ISC", "ICN", "G", "INP", "PIE", "T20", "PYI", "PT", "Q", "RSE", "RET", "SLF", "SIM", "TID", "TCH", "ARG", "PTH", "ERA", "PD", "PGH", "PL", "TRY", "RUF"]
ignore = [
# Existing exceptions
"F841", # Unused variables
"E501", # Line too long (handled by formatter)
"C901", # Function is too complex
"PLR0913", # Too many arguments to function call
"FBT001", # Boolean positional argument (matches existing DisplayManager API)
"FBT002", # Boolean default positional argument (matches existing DisplayManager API)
"ARG002", # Unused method argument (required by interface/ABC)
"BLE001", # Catching broad exception (intentional for robustness)
"S110", # Try-except-pass (intentional no-op in silent handler)
"COM812", # Trailing comma (conflicts with formatter - formatter handles this)
# Test-related
"S101", # Assert statement (standard in pytest)
"PT011", # pytest.raises() too broad (acceptable for integration tests)
# CLI tool patterns
"T201", # Print statements (CLI tool requires them for output)
# Code organization
"G004", # F-string in logging (more readable than % formatting)
"PLC0415", # Import outside top-level (lazy/conditional imports for performance)
"E402", # Module import not at top (conditional imports)
"INP001", # Implicit namespace package (intentional project structure)
# Exception handling style (high noise, low value)
"TRY003", # Raise with string message (common, readable pattern)
"EM101", # Raw string in exception (no practical benefit to extract)
"EM102", # F-string in exception (more readable than concatenation)
"TRY002", # Raise vanilla class (custom exceptions not always needed)
"TRY201", # Verbose raise (explicit re-raise can be clearer)
"TRY400", # Use Exception instead of error (minor distinction)
# Complexity rules (context-dependent, often necessary)
"PLR0912", # Too many branches (sometimes unavoidable in business logic)
"PLR0915", # Too many statements (sometimes needed for clarity)
"PLR2004", # Magic value comparison (often clear from context)
]
fixable = ["ALL"]
unfixable = []
[tool.ruff.format]
indent-style = "space"
skip-magic-trailing-comma = false
line-ending = "auto"
quote-style = "preserve"
[tool.ruff.lint.isort]
force-single-line = false
known-first-party = ["frappe_manager"]
[tool.poetry.urls]
Repository = "https://github.com/rtcamp/frappe-manager"
[tool.pyright]
reportOptionalMemberAccess = false
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.hatch.build.targets.wheel]
packages = ["frappe_manager"]
[tool.uv]
package = true
[tool.uv.sources]
[dependency-groups]
dev = [
"pytest>=9.0.0",
"pytest-mock>=3.15.0",
"pytest-cov>=7.0.0",
"pytest-env>=1.2.0",
"debugpy>=1.8.20",
]
[tool.pytest.ini_options]
testpaths = ["tests"]
python_files = ["test_*.py"]
python_classes = ["Test*"]
python_functions = ["test_*"]
addopts = [
"-v",
"--cov=frappe_manager/ssl_manager",
"--cov-report=html",
"--cov-report=term-missing",
"--strict-markers",
]
markers = [
"unit: Unit tests",
"integration: Integration tests",
"slow: Slow running tests",
]
env = [
"FM_LETSENCRYPT_STAGING=0",
]