Skip to content

Conversation

@hendrikmakait
Copy link
Member

@hendrikmakait hendrikmakait commented Aug 1, 2022

Partially addresses pre-commit failures in #6809

  • Tests added / passed
  • Passes pre-commit run --all-files

@github-actions
Copy link
Contributor

github-actions bot commented Aug 1, 2022

Unit Test Results

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

       15 files  +       1         15 suites  +1   6h 44m 23s ⏱️ + 46m 48s
  2 989 tests ±       0    2 897 ✔️  -        1       89 💤 +1  3 +1 
22 165 runs  +1 200  21 116 ✔️ +1 204  1 046 💤  - 3  3 ±0 

For more details on these failures, see this check.

Results for commit b06f421. ± Comparison against base commit 192a8bb.

♻️ This comment has been updated with latest results.

@hendrikmakait hendrikmakait self-assigned this Aug 1, 2022
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.

"""That would be the default in user code"""
server = Server({})
server.status == Status.running
server.status == Status.running # noqa: B015
Copy link
Member

Choose a reason for hiding this comment

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

Why ignore here instead of adding an assert?

Copy link
Member Author

Choose a reason for hiding this comment

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

Based on my understanding of this test, i.e. its name and history (#3875), I think that all we want to do is test that server.status == Status.running doesn't cause an exception or error, not so much test that the result is True/False. If it helps, I'll extend the docstring.

Copy link
Collaborator

Choose a reason for hiding this comment

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

A comment would be helpful here I think

Copy link
Member Author

Choose a reason for hiding this comment

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

Done

@hendrikmakait
Copy link
Member Author

Nice catch. I've not looked into this deeply, but this test seems to assume ws = WorkStealing(s) will update the stealing periodic callback on the scheduler. Are we sure that's actually happening?

I haven't had the time yet to dive into this, but that's what I'm thinking as well. I'll do some digging to understand what the desired and expected behavior should be here.

@pytest.mark.parametrize("interval, expected", [(None, 100), ("500ms", 500), (2, 2)])
@gen_cluster(nthreads=[])
@gen_cluster(nthreads=[], config={"distributed.scheduler.work-stealing": False})
async def test_parse_stealing_interval(s, interval, expected):
Copy link
Member Author

@hendrikmakait hendrikmakait Aug 3, 2022

Choose a reason for hiding this comment

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

I suspect the new implementation is what this test is supposed to be doing. This does not take into account some weirdness around how WorkStealing is added as a plugin in the first place, but that's out of scope.
cc @fjetter

Copy link
Collaborator

@gjoseph92 gjoseph92 left a comment

Choose a reason for hiding this comment

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

This LGTM, assuming the work-stealing test is fixed?

"""That would be the default in user code"""
server = Server({})
server.status == Status.running
server.status == Status.running # noqa: B015
Copy link
Collaborator

Choose a reason for hiding this comment

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

A comment would be helpful here I think

@hendrikmakait hendrikmakait force-pushed the fix-pointless-comparisons branch from 366b032 to f6c0529 Compare August 3, 2022 16:53
@hendrikmakait hendrikmakait force-pushed the fix-pointless-comparisons branch from be85e6f to b06f421 Compare August 3, 2022 16:59
@crusaderky crusaderky merged commit ad65a54 into dask:main Aug 4, 2022
@crusaderky
Copy link
Collaborator

Thank you

gjoseph92 pushed a commit to gjoseph92/distributed that referenced this pull request Oct 31, 2022
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.

4 participants