release: prepare 0.2.0 for sing-box 1.14

This commit is contained in:
2026-09-08 19:26:00 +05:00
parent 81ea89f7fa
commit 76dce5b47a
42 changed files with 1634 additions and 549 deletions
+5 -2
View File
@@ -9,6 +9,7 @@ from typing import Any
from urllib.parse import urlsplit
from .errors import ValidationError
from .version import SUPPORTED_SING_BOX_VERSION
@dataclass(frozen=True, slots=True)
@@ -160,8 +161,10 @@ def load_policy(path: str | Path) -> Policy:
health = _mapping(root["healthcheck"], "healthcheck")
required_version = _string(sb, "required_version")
if required_version != "1.13.19":
raise ValidationError("This release requires sing-box version exactly 1.13.19")
if required_version != SUPPORTED_SING_BOX_VERSION:
raise ValidationError(
f"This release requires sing-box version exactly {SUPPORTED_SING_BOX_VERSION}"
)
service = _string(sb, "service")
if not re.fullmatch(r"[A-Za-z0-9@_.:-]+\.service", service):
raise ValidationError("Invalid sing-box systemd service name")