Skip to content

Commit

Permalink
Fixed kwargs being modified when making a copy for saving to redis wo…
Browse files Browse the repository at this point in the history
…rker args.
  • Loading branch information
ryannova committed Sep 12, 2024
1 parent 2b0e8a6 commit e49f378
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion merlin/study/celeryadapter.py
Original file line number Diff line number Diff line change
Expand Up @@ -779,7 +779,7 @@ def launch_celery_worker(worker_cmd, worker_list, kwargs):

# Adding the worker args to redis db
with CeleryManager.get_worker_args_redis_connection() as redis_connection:
args = kwargs
args = kwargs.copy()
# Save worker command with the arguements
args["worker_cmd"] = worker_cmd
# Store the nested dictionaries into a separate key with a link.
Expand Down
8 changes: 3 additions & 5 deletions tests/unit/study/test_celeryadapter.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,9 @@
import json
import os
from datetime import datetime

# from time import sleep
from typing import Dict

# import pytest
from celery import Celery

# from celery.canvas import Signature
from deepdiff import DeepDiff

from merlin.config import Config
Expand All @@ -51,6 +46,9 @@
from tests.unit.study.status_test_files.status_test_variables import SPEC_PATH


# from time import sleep
# import pytest
# from celery.canvas import Signature
# @pytest.mark.order(before="TestInactive")
# class TestActive:
# """
Expand Down

0 comments on commit e49f378

Please sign in to comment.