Skip to content

Commit

Permalink
bind and test against the corresponded rmq-out branch of unkcpz/plump…
Browse files Browse the repository at this point in the history
…y changes
  • Loading branch information
unkcpz committed Dec 20, 2024
1 parent d5733b2 commit b1f446a
Show file tree
Hide file tree
Showing 7 changed files with 54 additions and 16 deletions.
6 changes: 5 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ dependencies = [
'importlib-metadata~=6.0',
'numpy~=1.21',
'paramiko~=3.0',
'plumpy~=0.22.3',
'plumpy',
'pgsu~=0.3.0',
'psutil~=5.6',
'psycopg[binary]~=3.0',
Expand Down Expand Up @@ -246,6 +246,7 @@ tests = [
'pympler~=1.0',
'coverage~=7.0',
'sphinx~=7.2.0',
'watchdog~=6.0',
'docutils~=0.20'
]
tui = [
Expand Down Expand Up @@ -510,3 +511,6 @@ passenv =
AIIDA_TEST_WORKERS
commands = molecule {posargs:test}
"""

[tool.uv.sources]
plumpy = {git = "https://github.com/unkcpz/plumpy", branch = "rmq-out"}
1 change: 0 additions & 1 deletion src/aiida/engine/processes/launcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ def handle_continue_exception(node, exception, message):
node.set_process_state(ProcessState.EXCEPTED)
node.seal()


async def _continue(self, pid, nowait, tag=None):
"""Continue the task.
Expand Down
3 changes: 1 addition & 2 deletions src/aiida/engine/runners.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,9 @@
from typing import Any, Callable, Dict, NamedTuple, Optional, Tuple, Type, Union

import kiwipy
from plumpy.rmq import wrap_communicator
from plumpy.events import reset_event_loop_policy, set_event_loop_policy
from plumpy.persistence import Persister
from plumpy.rmq import RemoteProcessThreadController
from plumpy.rmq import RemoteProcessThreadController, wrap_communicator

from aiida.common import exceptions
from aiida.orm import ProcessNode, load_node
Expand Down
9 changes: 5 additions & 4 deletions src/aiida/tools/pytest_fixtures/daemon.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,13 +63,15 @@ def test(started_daemon_client):
daemon_client.start_daemon()
assert daemon_client.is_daemon_running

import time
import threading
import time

from watchdog.events import FileSystemEventHandler

# XXX: watchdog and pytest-timeout as extra deps of tests
from watchdog.observers import Observer
from watchdog.events import FileSystemEventHandler

logger = logging.getLogger("tests.daemon:started_daemon_client")
logger = logging.getLogger('tests.daemon:started_daemon_client')

logger.debug(f'Daemon log file is located at: {daemon_client.daemon_log_file}')

Expand Down Expand Up @@ -105,7 +107,6 @@ def print_log_content(check_interval=0.1):
observer.stop()
observer.join()


# Start a background thread to continuously print new log lines
t = threading.Thread(target=print_log_content, daemon=True)
t.start()
Expand Down
1 change: 0 additions & 1 deletion tests/engine/test_launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
from aiida import orm
from aiida.common import exceptions
from aiida.engine import CalcJob, Process, WorkChain, calcfunction, launch
from aiida.engine.daemon.client import get_daemon_client
from aiida.plugins import CalculationFactory

ArithmeticAddCalculation = CalculationFactory('core.arithmetic.add')
Expand Down
1 change: 0 additions & 1 deletion tests/engine/test_runners.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
import asyncio
import threading

import plumpy
import pytest

from aiida.calculations.arithmetic.add import ArithmeticAddCalculation
Expand Down
49 changes: 43 additions & 6 deletions uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit b1f446a

Please sign in to comment.