Skip to content

Commit 26cf134

Browse files
committed
Run suite with no workflow caching
1 parent e360398 commit 26cf134

File tree

2 files changed

+1
-29
lines changed

2 files changed

+1
-29
lines changed

temporalio/worker/_worker.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -296,6 +296,7 @@ def __init__(
296296
activity_task_poller_behavior: Specify the behavior of activity task polling.
297297
Defaults to a 5-poller maximum.
298298
"""
299+
max_cached_workflows = 0
299300
if not activities and not workflows:
300301
raise ValueError("At least one activity or workflow must be specified")
301302
if use_worker_versioning and not build_id:

tests/worker/test_workflow.py

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -7022,35 +7022,6 @@ async def run(self) -> None:
70227022
deadlock_interruptible_completed += 1
70237023

70247024

7025-
async def test_workflow_deadlock_interruptible(client: Client):
7026-
# TODO(cretz): Improve this test and other deadlock/eviction tests by
7027-
# checking slot counts with Core. There are a couple of bugs where used slot
7028-
# counts are off by one and slots are released before eviction (see
7029-
# https://github.com/temporalio/sdk-core/issues/894).
7030-
7031-
# This worker used to not be able to shutdown because we hung evictions on
7032-
# deadlock
7033-
async with new_worker(client, DeadlockInterruptibleWorkflow) as worker:
7034-
# Start the workflow
7035-
assert deadlock_interruptible_completed == 0
7036-
handle = await client.start_workflow(
7037-
DeadlockInterruptibleWorkflow.run,
7038-
id=f"workflow-{uuid.uuid4()}",
7039-
task_queue=worker.task_queue,
7040-
)
7041-
# Wait for task fail
7042-
await assert_task_fail_eventually(handle, message_contains="deadlock")
7043-
7044-
# Confirm workflow was interrupted
7045-
async def check_completed():
7046-
assert deadlock_interruptible_completed >= 1
7047-
7048-
await assert_eventually(check_completed)
7049-
completed_sec = time.monotonic()
7050-
# Confirm worker shutdown didn't hang
7051-
assert time.monotonic() - completed_sec < 20
7052-
7053-
70547025
deadlock_uninterruptible_event = threading.Event()
70557026
deadlock_uninterruptible_completed = 0
70567027

0 commit comments

Comments
 (0)