From b8374360ddff7bdfe264f81df42ff15cbeadd465 Mon Sep 17 00:00:00 2001 From: Logan Ward Date: Tue, 2 Apr 2024 11:33:30 -0400 Subject: [PATCH] Bug fix: convert functions correctly (#133) --- colmena/task_server/parsl.py | 2 +- colmena/task_server/tests/test_parsl.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/colmena/task_server/parsl.py b/colmena/task_server/parsl.py index 4edfaba..cde039c 100644 --- a/colmena/task_server/parsl.py +++ b/colmena/task_server/parsl.py @@ -353,7 +353,7 @@ def __init__(self, methods: List[Union[Callable, Tuple[Callable, Dict]]], logger.info(f'Using default executors for {function.__name__}: {default_executors}') # Convert the function to a Colmena task - function = convert_to_colmena_method(method) + function = convert_to_colmena_method(function) name = function.name # If the function is not an executable, submit it as a single task diff --git a/colmena/task_server/tests/test_parsl.py b/colmena/task_server/tests/test_parsl.py index 11901ea..58a89c2 100644 --- a/colmena/task_server/tests/test_parsl.py +++ b/colmena/task_server/tests/test_parsl.py @@ -59,7 +59,7 @@ def store(tmpdir): @fixture(autouse=True) def server_and_queue(config, store) -> Tuple[ParslTaskServer, ColmenaQueues]: queues = PipeQueues(proxystore_name='store', proxystore_threshold=5000, serialization_method='pickle') - server = ParslTaskServer([f, capitalize, bad_task, EchoTask(), FakeMPITask(), count_nodes], queues, config) + server = ParslTaskServer([(f, {'executors': 'all'}), capitalize, bad_task, EchoTask(), FakeMPITask(), count_nodes], queues, config) yield server, queues if server.is_alive(): queues.send_kill_signal()