Skip to content

fix: Memory leak with persistent task group#21

Merged
achimnol merged 2 commits intomasterfrom
fix/memoryleak-with-persistent-taskgroup
Dec 16, 2020
Merged

fix: Memory leak with persistent task group#21
achimnol merged 2 commits intomasterfrom
fix/memoryleak-with-persistent-taskgroup

Conversation

@achimnol
Copy link
Copy Markdown
Owner

@achimnol achimnol commented Dec 16, 2020

reported back to geldata/gel-python#140.

* When a task group is used throughout the application's whole
  lifecycle, the prior implementation accumulates the references to
  completed tasks in its _tasks attribute.
* Changing _tasks to a WeakSet resolves the issue.
@achimnol achimnol added the bug label Dec 16, 2020
@codecov
Copy link
Copy Markdown

codecov bot commented Dec 16, 2020

Codecov Report

Merging #21 (5e044d9) into master (dd855f5) will increase coverage by 0.04%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #21      +/-   ##
==========================================
+ Coverage   65.09%   65.14%   +0.04%     
==========================================
  Files           9        9              
  Lines         702      703       +1     
==========================================
+ Hits          457      458       +1     
  Misses        245      245              
Impacted Files Coverage Δ
src/aiotools/taskgroup.py 90.36% <100.00%> (+0.05%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update dd855f5...5e044d9. Read the comment docs.

achimnol added a commit to achimnol/edgedb-python that referenced this pull request Dec 16, 2020
* Check out the added test cases in my derivation: achimnol/aiotools#21
@achimnol achimnol merged commit 7c9d08b into master Dec 16, 2020
@achimnol achimnol deleted the fix/memoryleak-with-persistent-taskgroup branch December 16, 2020 07:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant