Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restore retire workers API #8939

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

fjetter
Copy link
Member

@fjetter fjetter commented Nov 15, 2024

#8935 accidentally changed the public API for retire workers. I thought this was used only internally but it is used by client.retire_workers as well (and of course whenever the request handler is being used directly)

This should restore the API without reverting the changes to the logged event that was the primary intention of #8935

Copy link
Contributor

github-actions bot commented Nov 15, 2024

Unit Test Results

See test report for an extended history of previous test failures. This is useful for diagnosing flaky tests.

    25 files  ±0      25 suites  ±0   10h 23m 7s ⏱️ + 15m 6s
 4 130 tests ±0   4 014 ✅  - 1    110 💤 ±0   6 ❌ +1 
47 692 runs  ±0  45 533 ✅  - 2  2 122 💤 +1  37 ❌ +1 

For more details on these failures, see this check.

Results for commit 97544d5. ± Comparison against base commit 0d905d5.

♻️ This comment has been updated with latest results.

Copy link
Member

@jrbourbeau jrbourbeau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @fjetter

Looks like we need to update distributed/tests/test_active_memory_manager.py::test_RetireWorker_with_actor_proxy too

diff --git a/distributed/tests/test_active_memory_manager.py b/distributed/tests/test_active_memory_manager.py
index bcc0d48d..1bc9855b 100644
--- a/distributed/tests/test_active_memory_manager.py
+++ b/distributed/tests/test_active_memory_manager.py
@@ -1250,7 +1250,7 @@ async def test_RetireWorker_with_actor_proxy(c, s, a, b):
     assert "y" in b.data

     out = await c.retire_workers([b.address])
-    assert out == (b.address,)
+    assert out.keys() == {b.address}
     assert "x" in a.state.actors
     assert "y" in a.data

@@ -7675,7 +7675,7 @@ async def _track_retire_worker(
f"Could not retire worker {ws.address!r}: unique data could not be "
f"moved to any other worker ({stimulus_id=!r})"
)
return ws.address, "no-recipients"
return ws.address, "no-recipients", ws.identity()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I could be missing something, but it looks like we're adding back the verbose thing removed in #8935 now. Just wanted to make sure that's intentional

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants