Skip to content

Commit 4616073

Browse files
committed
fix: Changed command name to "send-runner-metadata"
1 parent 9008c0a commit 4616073

File tree

2 files changed

+5
-12
lines changed

2 files changed

+5
-12
lines changed

cosmotech/coal/cli/commands/api/api.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# Any use, reproduction, translation, broadcasting, transmission, distribution,
55
# etc., to any person is prohibited unless it has been previously and
66
# specifically authorized by written means by Cosmo Tech.
7-
from cosmotech.coal.cli.commands.api.postgres_send_run_metadata import postgres_send_run_metadata
7+
from cosmotech.coal.cli.commands.api.postgres_send_runner_metadata import postgres_send_runner_metadata
88
from cosmotech.coal.cli.commands.api.rds_load_csv import rds_load_csv
99
from cosmotech.coal.cli.commands.api.rds_send_csv import rds_send_csv
1010
from cosmotech.coal.cli.commands.api.rds_send_store import rds_send_store
@@ -52,4 +52,4 @@ def api(ctx: click.Context):
5252
api.add_command(runtemplate_load_handler, "runtemplate-load-handler")
5353
api.add_command(run_load_data, "run-load-data")
5454
api.add_command(scenariorun_load_data, "scenariorun-load-data")
55-
api.add_command(postgres_send_run_metadata, "postgres-send-run-metadata")
55+
api.add_command(postgres_send_runner_metadata, "postgres-send-runner-metadata")

cosmotech/coal/cli/commands/api/postgres_send_run_metadata.py renamed to cosmotech/coal/cli/commands/api/postgres_send_runner_metadata.py

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
from cosmotech.coal.cli.utils.click import click
1111
from cosmotech.coal.cosmotech_api.connection import get_api_client
1212
from cosmotech.coal.cosmotech_api.run import get_run_metadata
13+
from cosmotech.coal.cosmotech_api.runner import get_runner_metadata
1314
from cosmotech.coal.utils.logger import LOGGER
1415
from cosmotech.coal.utils.postgresql import generate_postgresql_full_uri
1516

@@ -36,13 +37,6 @@
3637
type=str,
3738
show_envvar=True,
3839
required=True)
39-
@click.option("--run-id",
40-
envvar="CSM_RUN_ID",
41-
help="A run id for the Cosmo Tech API",
42-
metavar="run-XXXXXX",
43-
type=str,
44-
show_envvar=True,
45-
required=True)
4640
@click.option("--table-prefix",
4741
help="Prefix to add to the table name",
4842
metavar="PREFIX",
@@ -79,11 +73,10 @@
7973
envvar="POSTGRES_USER_PASSWORD",
8074
show_envvar=True,
8175
required=True)
82-
def postgres_send_run_metadata(
76+
def postgres_send_runner_metadata(
8377
organization_id,
8478
workspace_id,
8579
runner_id,
86-
run_id,
8780
table_prefix: str,
8881
postgres_host,
8982
postgres_port,
@@ -100,7 +93,7 @@ def postgres_send_run_metadata(
10093
"""
10194

10295
with get_api_client()[0] as api_client:
103-
runner = get_run_metadata(api_client, organization_id, workspace_id, runner_id, run_id)
96+
runner = get_runner_metadata(api_client, organization_id, workspace_id, runner_id)
10497

10598
postgresql_full_uri = generate_postgresql_full_uri(postgres_host,
10699
postgres_port,

0 commit comments

Comments
 (0)