-
-
Notifications
You must be signed in to change notification settings - Fork 717
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
Remove update_graph_hlg #7502
Remove update_graph_hlg #7502
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,11 +7,9 @@ | |
|
||
import pytest | ||
from packaging.version import parse as parse_version | ||
from tlz import valmap | ||
|
||
from distributed.client import wait | ||
from distributed.utils_test import dec, gen_cluster, gen_tls_cluster, inc, throws | ||
from distributed.worker import dumps_task | ||
|
||
ipywidgets = pytest.importorskip("ipywidgets") | ||
|
||
|
@@ -141,38 +139,6 @@ async def test_multi_progressbar_widget(c, s, a, b): | |
assert sorted(capacities, reverse=True) == capacities | ||
|
||
|
||
@mock_widget() | ||
@gen_cluster() | ||
async def test_multi_progressbar_widget_after_close(s, a, b): | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This test is a bit odd and I couldn't make sense of the suffix There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Keeps failing. After some thought I'm not even sure if this is possible. I'll remove the test |
||
s.update_graph( | ||
tasks=valmap( | ||
dumps_task, | ||
{ | ||
"x-1": (inc, 1), | ||
"x-2": (inc, "x-1"), | ||
"x-3": (inc, "x-2"), | ||
"y-1": (dec, "x-3"), | ||
"y-2": (dec, "y-1"), | ||
"e": (throws, "y-2"), | ||
"other": (inc, 123), | ||
}, | ||
), | ||
keys=["e"], | ||
dependencies={ | ||
"x-2": {"x-1"}, | ||
"x-3": {"x-2"}, | ||
"y-1": {"x-3"}, | ||
"y-2": {"y-1"}, | ||
"e": {"y-2"}, | ||
}, | ||
) | ||
|
||
p = MultiProgressWidget(["x-1", "x-2", "x-3"], scheduler=s.address) | ||
await p.listen() | ||
|
||
assert "x" in p.bars | ||
|
||
|
||
@mock_widget() | ||
def test_values(client): | ||
L = [client.submit(inc, i) for i in range(5)] | ||
|
@@ -232,32 +198,17 @@ def test_progressbar_cancel(client): | |
|
||
|
||
@mock_widget() | ||
@gen_cluster() | ||
async def test_multibar_complete(s, a, b): | ||
s.update_graph( | ||
tasks=valmap( | ||
dumps_task, | ||
{ | ||
"x-1": (inc, 1), | ||
"x-2": (inc, "x-1"), | ||
"x-3": (inc, "x-2"), | ||
"y-1": (dec, "x-3"), | ||
"y-2": (dec, "y-1"), | ||
"e": (throws, "y-2"), | ||
"other": (inc, 123), | ||
}, | ||
), | ||
keys=["e"], | ||
dependencies={ | ||
"x-2": {"x-1"}, | ||
"x-3": {"x-2"}, | ||
"y-1": {"x-3"}, | ||
"y-2": {"y-1"}, | ||
"e": {"y-2"}, | ||
}, | ||
) | ||
|
||
p = MultiProgressWidget(["e"], scheduler=s.address, complete=True) | ||
@gen_cluster(client=True) | ||
async def test_multibar_complete(c, s, a, b): | ||
x1 = c.submit(inc, 1, key="x-1") | ||
x2 = c.submit(inc, x1, key="x-2") | ||
x3 = c.submit(inc, x2, key="x-3") | ||
y1 = c.submit(dec, x3, key="y-1") | ||
y2 = c.submit(dec, y1, key="y-2") | ||
e = c.submit(throws, y2, key="e") | ||
other = c.submit(inc, 123, key="other") | ||
|
||
p = MultiProgressWidget([e.key], scheduler=s.address, complete=True) | ||
await p.listen() | ||
|
||
assert p._last_response["all"] == {"x": 3, "y": 2, "e": 1} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From what I can tell this is not serving any purpose. The future itself lets the scheduler know that it is interested with a
client_desires_keys
so this is redundant and the only non-test invocation of the old API