Skip to content

[Backport] Add lock to Pubsub.execute_command to ensure only one connection is created #22

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

Merged
merged 1 commit into from
Oct 27, 2023

Conversation

dlunch
Copy link

@dlunch dlunch commented Oct 27, 2023

Pull Request check-list

Please make sure to review and check all of these items:

  • Does $ tox pass with this change (including linting)?
  • Do the CI tests pass with this change (enable it first in your forked repo and wait for the github action build to finish)?
  • Is the new or changed code fully tested?
  • Is a documentation update included (if this change modifies existing APIs, or introduces new ones)?
  • Is there an example added to the examples folder (if applicable)?
  • Was the change added to CHANGES file?

NOTE: these things are not required to open a PR and can be done
afterwards / while the PR is open.

Description of change

Please provide a description of the change here.

…reated (#19)

* Add lock to Pubsub.execute_command to ensure only one connection is created

* Add tests
@dlunch dlunch requested a review from zach-iee October 27, 2023 02:57
@codecov-commenter
Copy link

codecov-commenter commented Oct 27, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (2708435) 91.49% compared to head (328f79e) 91.50%.

Additional details and impacted files
@@           Coverage Diff           @@
##              4.4      #22   +/-   ##
=======================================
  Coverage   91.49%   91.50%           
=======================================
  Files         116      116           
  Lines       30320    30336   +16     
=======================================
+ Hits        27742    27759   +17     
+ Misses       2578     2577    -1     
Files Coverage Δ
redis/client.py 87.22% <100.00%> (+0.14%) ⬆️
tests/test_pubsub.py 76.62% <100.00%> (+0.41%) ⬆️

... and 2 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@dlunch dlunch merged commit c9717b5 into 4.4 Oct 27, 2023
@dlunch dlunch deleted the fix/connection-leak branch October 27, 2023 03:33
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