From 18785e875a79a83bf6dba79ffdcd6971984733f3 Mon Sep 17 00:00:00 2001 From: KPrasch Date: Wed, 7 Aug 2024 19:53:29 +0700 Subject: [PATCH] respond to RFCs in PR #297 --- deployment/constants.py | 2 +- deployment/utils.py | 4 ++-- scripts/initiate_ritual.py | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/deployment/constants.py b/deployment/constants.py index 6723c255..cb8808cf 100644 --- a/deployment/constants.py +++ b/deployment/constants.py @@ -59,7 +59,7 @@ # Sampling # -PORTER_ENDPOINTS = { +PORTER_SAMPLING_ENDPOINTS = { MAINNET: "https://porter.nucypher.io/bucket_sampling", LYNX: "https://porter-lynx.nucypher.io/get_ursulas", TAPIR: "https://porter-tapir.nucypher.io/get_ursulas", diff --git a/deployment/utils.py b/deployment/utils.py index f68c5b2b..5575baa0 100644 --- a/deployment/utils.py +++ b/deployment/utils.py @@ -9,7 +9,7 @@ from ape.contracts import ContractContainer, ContractInstance from ape_etherscan.utils import API_KEY_ENV_KEY_MAP -from deployment.constants import ARTIFACTS_DIR, LYNX, MAINNET, PORTER_ENDPOINTS, TAPIR +from deployment.constants import ARTIFACTS_DIR, LYNX, MAINNET, PORTER_SAMPLING_ENDPOINTS, TAPIR from deployment.networks import is_local_network @@ -162,7 +162,7 @@ def registry_filepath_from_domain(domain: str) -> Path: def sample_nodes( domain: str, num_nodes: int, random_seed: Optional[int] = None, duration: Optional[int] = None ): - porter_endpoint = PORTER_ENDPOINTS.get(domain) + porter_endpoint = PORTER_SAMPLING_ENDPOINTS.get(domain) if not porter_endpoint: raise ValueError(f"Porter endpoint not found for domain '{domain}'") diff --git a/scripts/initiate_ritual.py b/scripts/initiate_ritual.py index 4f5c106c..9dd80e65 100644 --- a/scripts/initiate_ritual.py +++ b/scripts/initiate_ritual.py @@ -85,7 +85,7 @@ def cli( if not (bool(handpicked) ^ (num_nodes is not None)): raise click.BadOptionUsage( option_name="--num-nodes", - message=f"Specify either --num-nodes or --handpicked; got {num_nodes} {handpicked}", + message=f"Specify either --num-nodes or --handpicked; got {num_nodes}, {handpicked}.", ) if handpicked and random_seed: raise click.BadOptionUsage(