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
|
[build-system]
build-backend = "setuptools.build_meta"
requires = ["setuptools>=62.3"]
[project]
authors = [{ name = "Nabu Casa, Inc.", email = "opensource@nabucasa.com" }]
classifiers = [
"Intended Audience :: End Users/Desktop",
"Intended Audience :: Developers",
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
"Operating System :: OS Independent",
"Topic :: Internet :: Proxy Servers",
"Topic :: Software Development :: Libraries :: Python Modules",
"Development Status :: 5 - Production/Stable",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
]
dependencies = ["aiohttp>=3.9.3", "cryptography>=2.5"]
description = "SNI proxy with TCP multiplexer"
keywords = ["sni", "proxy", "multiplexer", "tls"]
license = { text = "GPL v3" }
name = "snitun"
readme = "README.md"
requires-python = ">=3.12"
version = "0.0.0"
[project.optional-dependencies]
lint = ["ruff==0.12.11"]
test = [
"covdefaults==2.3.0",
"pytest-aiohttp==1.1.0",
"pytest-codspeed==4.0.0",
"pytest-cov==6.2.1",
"pytest-timeout==2.4.0",
"pytest==8.4.1",
]
[project.urls]
Homepage = "https://www.nabucasa.com/"
Repository = "https://github.com/NabuCasa/snitun.git"
[tool.pytest.ini_options]
asyncio_mode = "auto"
[tool.ruff]
fix = true
line-length = 88
show-fixes = true
target-version = "py311"
[tool.ruff.lint]
ignore = [
"A005", # https://docs.astral.sh/ruff/rules/stdlib-module-shadowing/
"ASYNC110", # https://docs.astral.sh/ruff/rules/async-busy-wait/
"EM101", # https://docs.astral.sh/ruff/rules/raw-string-in-exception/
"EM102", # https://docs.astral.sh/ruff/rules/f-string-in-exception/
"FBT", # https://docs.astral.sh/ruff/rules/#flake8-boolean-trap-fbt
"N818", # https://docs.astral.sh/ruff/rules/error-suffix-on-exception-name/
"PLR2004", # https://docs.astral.sh/ruff/rules/magic-value-comparison/
"PERF203", # https://docs.astral.sh/ruff/rules/try-except-in-loop/
"S101", # https://docs.astral.sh/ruff/rules/assert/
"S104", # https://docs.astral.sh/ruff/rules/hardcoded-bind-all-interfaces/
"TC001", # https://docs.astral.sh/ruff/rules/typing-only-first-party-import/
"TC003", # https://docs.astral.sh/ruff/rules/typing-only-standard-library-import/
"TC006", # https://docs.astral.sh/ruff/rules/runtime-cast-value/
"TID252", # https://docs.astral.sh/ruff/rules/relative-imports/
"TRY003", # https://docs.astral.sh/ruff/rules/raise-vanilla-args/
"TRY301", # https://docs.astral.sh/ruff/rules/raise-within-try/
"TRY400", # https://docs.astral.sh/ruff/rules/error-instead-of-exception/
]
select = ["ALL"]
[tool.ruff.lint.extend-per-file-ignores]
"py.typed" = ["D100"]
[tool.ruff.lint.flake8-pytest-style]
fixture-parentheses = false
mark-parentheses = false
[tool.ruff.lint.isort]
combine-as-imports = true
force-sort-within-sections = true
known-first-party = ["snitun"]
[tool.ruff.lint.mccabe]
max-complexity = 22
[tool.ruff.lint.pydocstyle]
# Use Google-style docstrings.
convention = "pep257"
[tool.ruff.lint.pylint]
max-args = 15
max-branches = 30
max-returns = 8
max-statements = 80
[tool.setuptools]
include-package-data = true
platforms = ["any"]
zip-safe = false
[tool.setuptools.packages.find]
include = [
"snitun",
"snitun.metrics",
"snitun.server",
"snitun.client",
"snitun.multiplexer",
"snitun.utils",
]
[tool.coverage.run]
plugins = ["covdefaults"]
[tool.coverage.report]
fail_under = 75
exclude_also = [
"if self._debug:",
]
|