FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

bpo-44116: Add GC support to _csv heap types by erlend-aasland · Pull Request #26074 · python/cpython · GitHub

/ cpython Public

bpo-44116: Add GC support to _csv heap types - #26074

Merged
pablogsal merged 4 commits into
python:mainfrom
erlend-aasland:gc-csv
May 12, 2021
Merged

bpo-44116: Add GC support to _csv heap types#26074
pablogsal merged 4 commits into
python:mainfrom
erlend-aasland:gc-csv

Conversation

erlend-aasland commented May 12, 2021
edited
Loading

Copy link
Copy Markdown
Contributor
  • Implement full GC protocol support for _csv heap types
  • Use tp_clear iso. tp_finalize to clear type contexts

Petr's reproducer now outputs the following:

$ ./python.exe bug.py
73166
73168
73168
73168
73168
73168
73166
73168
73168
73168

However, the _csv test suite now leaks (EDIT: updated output after b8772d6)
UPDATE: No leaks after 19e2952

https://bugs.python.org/issue44116

Copy link
Copy Markdown
Contributor Author

(I'm applying skip news to this, @pablogsal (@corona10), as it is similar to GH-26072.)

Fidget-Spinner left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Thanks! Some minor nits below:

Comment thread Modules/_csv.c Outdated
Comment thread Modules/_csv.c Outdated
erlend-aasland marked this pull request as ready for review May 12, 2021 16:55

Copy link
Copy Markdown
Member

Doh I should've refreshed before I submitted the review. Didn't see your latest commits :(. Sorry.

Copy link
Copy Markdown
Contributor Author

Doh I should've refreshed before I submitted the review. Didn't see your latest commits :(. Sorry.

No problem, Ken :) I believe all your comments were addressed in 19e2952.

erlend-aasland changed the title [WIP] bpo-44116: Add GC support to _csv heap types bpo-44116: Add GC support to _csv heap types May 12, 2021
Comment thread Modules/_csv.c Outdated
Comment thread Modules/_csv.c Outdated

Copy link
Copy Markdown
Member

One thing that I don't understand is why the CSV tests when executed under the refleak checker don't show any problems

Copy link
Copy Markdown
Member

Does this need backport to 3.9?

pablogsal merged commit e5ba1fe into python:main May 12, 2021

Copy link
Copy Markdown
Contributor

Thanks @erlend-aasland for the PR, and @pablogsal for merging it 🌮🎉.. I'm working now to backport this PR to: 3.10.
🐍🍒⛏🤖

Copy link
Copy Markdown

GH-26081 is a backport of this pull request to the 3.10 branch.

bedevere-bot removed the needs backport to 3.10 only security fixes label May 12, 2021
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request May 12, 2021
(cherry picked from commit e5ba1fe)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
erlend-aasland deleted the gc-csv branch May 12, 2021 18:21

Copy link
Copy Markdown
Contributor Author

Does this need backport to 3.9?

No. This was added in December in GH-23224

erlend-aasland commented May 12, 2021
edited
Loading

Copy link
Copy Markdown
Contributor Author

Thanks for reviewing, Pablo and Ken!

pablogsal pushed a commit that referenced this pull request May 12, 2021

encukou commented May 12, 2021

Copy link
Copy Markdown
Member

Thank you for pushing this through!

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
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.

7 participants


Back | FazBrowse Home | New Git URL