From 88ccd946dfbe1e7c3ca2b9aff3ee1433d867ea8a Mon Sep 17 00:00:00 2001 From: Florian Pinault Date: Wed, 3 Jul 2024 18:10:34 +0200 Subject: [PATCH] rename queues to tasks --- src/anemoi/registry/commands/entry.py | 2 +- src/anemoi/registry/commands/list.py | 2 +- src/anemoi/registry/commands/tasks.py | 2 +- src/anemoi/registry/tasks.py | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/anemoi/registry/commands/entry.py b/src/anemoi/registry/commands/entry.py index 1aa8196..4a4715e 100644 --- a/src/anemoi/registry/commands/entry.py +++ b/src/anemoi/registry/commands/entry.py @@ -90,7 +90,7 @@ def run(self, args): raise ValueError("Invalid API path {path}") _, collection, *_ = path.split("/") - if collection not in ("datasets", "experiments", "weights", "queues"): + if collection not in ("datasets", "experiments", "weights", "tasks"): LOG.warning(f"Unknown collection {collection}") if args.edit: diff --git a/src/anemoi/registry/commands/list.py b/src/anemoi/registry/commands/list.py index f6ff51f..b1b0ddf 100644 --- a/src/anemoi/registry/commands/list.py +++ b/src/anemoi/registry/commands/list.py @@ -64,7 +64,7 @@ def _run_default(self, args): print(json_pretty_dump(payload)) def run_tasks(self, args): - collection = "queues" + collection = "tasks" request = list_to_dict(args.filter) data = RestItemList(collection).get(params=request) self.print_tasks(data, long=args.long, sort=args.sort) diff --git a/src/anemoi/registry/commands/tasks.py b/src/anemoi/registry/commands/tasks.py index b6e8cf9..9c6232f 100644 --- a/src/anemoi/registry/commands/tasks.py +++ b/src/anemoi/registry/commands/tasks.py @@ -64,7 +64,7 @@ class Tasks(BaseCommand): timestamp = True entry_class = TaskCatalogueEntry - collection = "queues" + collection = "tasks" def add_arguments(self, command_parser): command_parser.add_argument("TASK", help="The uuid of the task", nargs="?") diff --git a/src/anemoi/registry/tasks.py b/src/anemoi/registry/tasks.py index 17f9369..2d8901b 100644 --- a/src/anemoi/registry/tasks.py +++ b/src/anemoi/registry/tasks.py @@ -113,7 +113,7 @@ def actor_factory(**record): class TaskCatalogueEntry(CatalogueEntry): - collection = "queues" + collection = "tasks" main_key = "uuid" def to_actor(self):