Skip to content

Conversation

@fjetter
Copy link
Member

@fjetter fjetter commented Jun 22, 2021

There is a chance for the ConnectionPool to leave connections open even after it was closed.

This came up during #4734

@fjetter
Copy link
Member Author

fjetter commented Jun 23, 2021

Flaky tests are
ubu3.8 #4915
win3.8 #4859

ubu3.9 + ox3.7 + osx3.9 test_register_backend_entrypoint seems to connect to a recent dask release with the message

(dask 2021.6.2 (/Users/runner/miniconda3/envs/dask-distributed/lib/python3.9/site-packages), Requirement.parse('dask==2021.06.1'))

@fjetter
Copy link
Member Author

fjetter commented Jun 23, 2021

I retriggered the run to see if the register_backend_entrypoint issue persists

@fjetter
Copy link
Member Author

fjetter commented Jun 23, 2021

The register_backend_entrypoint issue seems to be unrelated (I believe) but is still persistent, see #4961

Copy link
Member

@mrocklin mrocklin left a comment

Choose a reason for hiding this comment

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

This seems ok to me

# We might still have tasks haning in the semaphore. This will let them
# run into an exception and raise a commclosed
while self._n_connecting:
await asyncio.sleep(0.005)
Copy link
Member

Choose a reason for hiding this comment

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

Just checking, the finally block is triggered when we cancel?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes. That's covered in the test, ensured by assert pool._connecting in line 651

@mrocklin
Copy link
Member

+1 from me

fjetter and others added 2 commits June 23, 2021 18:15
Co-authored-by: Matthew Rocklin <mrocklin@gmail.com>
@fjetter fjetter force-pushed the connectionpool_close branch from 66b9a16 to 14c10af Compare June 23, 2021 16:18
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! This is in

@jrbourbeau jrbourbeau merged commit f1b0172 into dask:main Jun 24, 2021
@fjetter fjetter deleted the connectionpool_close branch June 24, 2021 07:29
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.

3 participants