diff --git a/nominal/cli/attachment.py b/nominal/cli/attachment.py index d2a98e1d..a97285e8 100644 --- a/nominal/cli/attachment.py +++ b/nominal/cli/attachment.py @@ -27,17 +27,17 @@ def get(rid: str, client: NominalClient) -> None: @attachment_cmd.command("upload") @click.option("-n", "--name", required=True) @click.option("-f", "--file", required=True, help="path to the file to upload") -@click.option("-d", "--desc") +@click.option("-d", "--description", help="description of the attachment") @client_options @global_options -def upload(name: str, file: str, desc: str | None, client: NominalClient) -> None: +def upload(name: str, file: str, description: str | None, client: NominalClient) -> None: """Upload attachment from a local file with a given name and description and display the details of the newly created attachment to the user. """ path = Path(file) file_type = FileType.from_path(path) with open(path, "rb") as f: - attachment = client.create_attachment_from_io(f, name, file_type, desc) + attachment = client.create_attachment_from_io(f, name, file_type, description) click.echo(attachment) diff --git a/nominal/cli/dataset.py b/nominal/cli/dataset.py index 2cd105ba..41f11cea 100644 --- a/nominal/cli/dataset.py +++ b/nominal/cli/dataset.py @@ -42,7 +42,7 @@ def dataset_cmd() -> None: ), help="interpretation the primary timestamp column", ) -@click.option("-d", "--desc") +@click.option("-d", "--description", help="description of the dataset") @click.option("--wait/--no-wait", default=True, help="wait until the upload is complete") @client_options @global_options @@ -51,7 +51,7 @@ def upload_csv( file: str, timestamp_column: str, timestamp_type: _LiteralAbsolute, - desc: str | None, + description: str | None, wait: bool, client: NominalClient, ) -> None: @@ -63,7 +63,7 @@ def upload_csv( name, timestamp_column=timestamp_column, timestamp_type=timestamp_type, - description=desc, + description=description, ) # block until ingestion completed, if requested diff --git a/nominal/cli/run.py b/nominal/cli/run.py index 540bcc5f..5605ad95 100644 --- a/nominal/cli/run.py +++ b/nominal/cli/run.py @@ -18,7 +18,7 @@ def run_cmd() -> None: @click.option("-n", "--name", required=True) @click.option("-s", "--start", required=True) @click.option("-e", "--end", required=True) -@click.option("-d", "--desc") +@click.option("-d", "--description", help="description of the run") @click.option("properties", "--property", type=(str, str), multiple=True) @click.option("labels", "--label", type=str, multiple=True) @client_options @@ -27,7 +27,7 @@ def create( name: str, start: str, end: str, - desc: str | None, + description: str | None, properties: Sequence[tuple[str, str]], labels: Sequence[str], client: NominalClient, @@ -37,7 +37,7 @@ def create( name, _SecondsNanos.from_flexible(start).to_nanoseconds(), _SecondsNanos.from_flexible(end).to_nanoseconds(), - desc, + description, properties=dict(properties), labels=labels, )