matrix-compute-node 0.1.1__tar.gz → 0.1.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/PKG-INFO +1 -1
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/matrix_compute_node.egg-info/PKG-INFO +1 -1
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/pyproject.toml +1 -1
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/__init__.py +1 -1
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/config/settings.py +40 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/LICENSE +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/README.md +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/matrix_compute_node.egg-info/SOURCES.txt +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/matrix_compute_node.egg-info/dependency_links.txt +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/matrix_compute_node.egg-info/entry_points.txt +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/matrix_compute_node.egg-info/requires.txt +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/matrix_compute_node.egg-info/top_level.txt +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/setup.cfg +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/setup.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/attestation/__init__.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/attestation/base.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/attestation/nvml_attest.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/attestation/sev_snp_attest.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/attestation/simulated.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/attestation/tdx_attest.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/auth/__init__.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/auth/hashcash.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/auth/l402_gate.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/config/__init__.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/crypto/__init__.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/crypto/signer.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/engine/__init__.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/engine/compute_core.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/engine/enclave_compute.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/engine/scheduler.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/engine/session_manager.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/main.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/p2p/__init__.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/p2p/servicer.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/p2p/tunnel_client.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/relay/__init__.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/relay/nostr_client.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/settings.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/test_doubles/__init__.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/test_doubles/mock_nostr_relay.py +0 -0
- {matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/test_doubles/mock_settlement.py +0 -0
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "matrix-compute-node"
|
|
7
|
-
version = "0.1.
|
|
7
|
+
version = "0.1.3"
|
|
8
8
|
description = "Decentralized worker daemon for Distributed Matrix Multiplication network"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.8"
|
|
@@ -723,6 +723,46 @@ class NodeConfig(BaseModel):
|
|
|
723
723
|
merged = {**base_config, **cli_dict}
|
|
724
724
|
if merged.get("enable_outbound_nat") and merged.get("nat_mode") in (None, "direct", ""):
|
|
725
725
|
merged["nat_mode"] = "reverse_tunnel"
|
|
726
|
+
|
|
727
|
+
# When launched via CLI without explicit NAT/port overrides against a public relay,
|
|
728
|
+
# default to outbound reverse_tunnel so residential/NATed nodes remain reachable.
|
|
729
|
+
environ = os.environ if env is None else env
|
|
730
|
+
explicit_nat_or_port = any(
|
|
731
|
+
k in cli_dict for k in ("nat_mode", "p2p_port", "p2p_multiaddr", "enable_outbound_nat")
|
|
732
|
+
) or any(
|
|
733
|
+
environ.get(ev) not in (None, "")
|
|
734
|
+
for ev in (
|
|
735
|
+
"MATRIX_NAT_MODE", "MATRIX_WORKER_NAT_MODE", "NAT_MODE",
|
|
736
|
+
"MATRIX_P2P_PORT", "MATRIX_WORKER_P2P_PORT", "P2P_PORT",
|
|
737
|
+
"MATRIX_P2P_MULTIADDR", "MATRIX_WORKER_P2P_MULTIADDR", "P2P_MULTIADDR",
|
|
738
|
+
"MATRIX_ENABLE_OUTBOUND_NAT", "ENABLE_OUTBOUND_NAT",
|
|
739
|
+
)
|
|
740
|
+
)
|
|
741
|
+
if not explicit_nat_or_port:
|
|
742
|
+
relays = merged.get("nostr_relays") or []
|
|
743
|
+
is_public_relay = any(
|
|
744
|
+
urlparse(str(r)).hostname not in (None, "", "127.0.0.1", "localhost", "0.0.0.0", "relay")
|
|
745
|
+
for r in relays
|
|
746
|
+
)
|
|
747
|
+
if is_public_relay:
|
|
748
|
+
merged["nat_mode"] = "reverse_tunnel"
|
|
749
|
+
merged["p2p_port"] = 0
|
|
750
|
+
|
|
751
|
+
# When launched via CLI without explicit pricing overrides, default to competitive mainnet pricing
|
|
752
|
+
explicit_rate = "sats_per_gflop" in cli_dict or any(
|
|
753
|
+
environ.get(ev) not in (None, "")
|
|
754
|
+
for ev in ("MATRIX_SATS_PER_GFLOP", "MATRIX_WORKER_SATS_PER_GFLOP", "SATS_PER_GFLOP")
|
|
755
|
+
)
|
|
756
|
+
if not explicit_rate:
|
|
757
|
+
merged["sats_per_gflop"] = 0.00001
|
|
758
|
+
|
|
759
|
+
explicit_min_sats = "min_task_sats" in cli_dict or any(
|
|
760
|
+
environ.get(ev) not in (None, "")
|
|
761
|
+
for ev in ("MATRIX_MIN_TASK_SATS", "MATRIX_WORKER_MIN_TASK_SATS", "MIN_TASK_SATS")
|
|
762
|
+
)
|
|
763
|
+
if not explicit_min_sats:
|
|
764
|
+
merged["min_task_sats"] = 1
|
|
765
|
+
|
|
726
766
|
return cls(**merged)
|
|
727
767
|
|
|
728
768
|
# Alias for backwards-compatibility and CLI invocations
|
|
File without changes
|
|
File without changes
|
{matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/matrix_compute_node.egg-info/SOURCES.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/matrix_compute_node.egg-info/requires.txt
RENAMED
|
File without changes
|
{matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/matrix_compute_node.egg-info/top_level.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{matrix_compute_node-0.1.1 → matrix_compute_node-0.1.3}/src/test_doubles/mock_nostr_relay.py
RENAMED
|
File without changes
|
|
File without changes
|