Skip to content

Commit

Permalink
remove trace_info
Browse files Browse the repository at this point in the history
  • Loading branch information
floriankrb committed Jul 1, 2024
1 parent 88a8fd3 commit 128e49c
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions src/anemoi/registry/queue_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,12 @@

import datetime
import logging

from anemoi.utils.humanize import when
from anemoi.utils.text import table
from anemoi.utils.provenance import trace_info
import anemoi.registry.rest as rest

# from anemoi.utils.provenance import trace_info
import anemoi.registry.rest as rest

LOG = logging.getLogger(__name__)

Expand All @@ -27,6 +28,7 @@ def add(record):
LOG.info(f"Added {response} to queue.")
return response["uuid"]


def remove(uuid):
return REST.delete(COLLECTION, uuid)

Expand All @@ -42,14 +44,15 @@ def set_status(uuid, status):


def own(uuid):
trace = trace_info(details=True)
trace = {} # trace_info(details=True)
patch = [
{"op": "test", "path": "/status", "value": "queued"},
{"op": "replace", "path": "/status", "value": "running"},
{"op": "add", "path": "/worker", "value": trace},
]
return REST.patch(f"{COLLECTION}/{uuid}", patch)


def disown(uuid):
patch = [
{"op": "test", "path": "/status", "value": "running"},
Expand Down Expand Up @@ -122,7 +125,7 @@ def main():

own(latest)
return

if args.disown:
disown(args.disown)

Expand Down

0 comments on commit 128e49c

Please sign in to comment.