File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 44from enum import StrEnum
55from pathlib import Path
66import os
7+ from typing import Final
78
89
910class OperatorMode (StrEnum ):
@@ -18,6 +19,11 @@ class TransportBackend(StrEnum):
1819 TOR = "tor"
1920
2021
22+ IMPLEMENTED_TRANSPORT_BACKENDS : Final [tuple [TransportBackend , ...]] = (
23+ TransportBackend .LOCAL ,
24+ )
25+
26+
2127@dataclass (frozen = True , slots = True )
2228class RuntimePaths :
2329 root : Path
@@ -65,11 +71,6 @@ def validate(self) -> None:
6571 if not (1 <= self .tor_socks_port <= 65535 ):
6672 raise ValueError ("tor_socks_port must be within 1..65535" )
6773
68- if self .mode == OperatorMode .HARDENED and self .transport_backend == TransportBackend .LOCAL :
69- raise ValueError (
70- "hardened mode cannot use the local transport backend; choose tcp or tor"
71- )
72-
7374 @classmethod
7475 def from_env (cls ) -> "OperatorConfig" :
7576 mode = OperatorMode (_get_env ("IX_OPERATOR_MODE" , OperatorMode .DEVELOPMENT .value ))
You can’t perform that action at this time.
0 commit comments