[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-09-28 Thread STINNER Victor


Change by STINNER Victor :


--
Removed message: https://bugs.python.org/msg394832

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-06-15 Thread miss-islington


miss-islington  added the comment:


New changeset e30fe27dabbc6b48736c3c17d57f6fa542376e8f by Miss Islington (bot) 
in branch '3.10':
bpo-42972: _thread.RLock implements the GH protocol (GH-26734)
https://github.com/python/cpython/commit/e30fe27dabbc6b48736c3c17d57f6fa542376e8f


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-06-15 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 1cd3d859a49b047dd08abb6f44f0539564d3525a by Victor Stinner in 
branch 'main':
bpo-42972: _thread.RLock implements the GH protocol (GH-26734)
https://github.com/python/cpython/commit/1cd3d859a49b047dd08abb6f44f0539564d3525a


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-06-15 Thread miss-islington


Change by miss-islington :


--
pull_requests: +25322
pull_request: https://github.com/python/cpython/pull/26735

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-06-15 Thread STINNER Victor


Change by STINNER Victor :


--
pull_requests: +25321
pull_request: https://github.com/python/cpython/pull/26734

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-06-04 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


--
priority: release blocker -> 

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-06-03 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 84d80f5f30b1f545083c70a7d4e1e79ab75f9fa6 by Erlend Egeberg 
Aasland in branch '3.10':
[3.10] bpo-42972: Track sqlite3 statement objects (GH-26475) (GH-26515)
https://github.com/python/cpython/commit/84d80f5f30b1f545083c70a7d4e1e79ab75f9fa6


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-06-03 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests: +25110
pull_request: https://github.com/python/cpython/pull/26515

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-06-01 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset fffa0f92adaaed0bcb3907d982506f78925e9052 by Erlend Egeberg 
Aasland in branch 'main':
bpo-42972: Track sqlite3 statement objects (GH-26475)
https://github.com/python/cpython/commit/fffa0f92adaaed0bcb3907d982506f78925e9052


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-31 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


Removed file: https://bugs.python.org/file50077/DTD-Matching-Gift-Dashboard - 
Google Sheets.html

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-31 Thread Soffie Swan


Soffie Swan  added the comment:

thanks and god blesse you all

--
nosy: +soffieswan015
type:  -> behavior
Added file: https://bugs.python.org/file50077/DTD-Matching-Gift-Dashboard - 
Google Sheets.html

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-31 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests: +25070
pull_request: https://github.com/python/cpython/pull/26475

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-31 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:


New changeset f097d2302be46b031687726011b86fc241a042ef by Miss Islington (bot) 
in branch '3.10':
bpo-42972: Fully implement GC protocol for xxlimited (GH-26451) (GH-26460)
https://github.com/python/cpython/commit/f097d2302be46b031687726011b86fc241a042ef


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-31 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset ff359d735f1a60878975d1c5751bfd2361e84067 by Miss Islington (bot) 
in branch '3.10':
bpo-42972: Fix sqlite3 traverse/clear functions (GH-26452) (GH-26461)
https://github.com/python/cpython/commit/ff359d735f1a60878975d1c5751bfd2361e84067


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-31 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset d1124b09e8251061dc040cbd396f35ae57783f4a by Erlend Egeberg 
Aasland in branch 'main':
bpo-42972: Fix sqlite3 traverse/clear functions (GH-26452)
https://github.com/python/cpython/commit/d1124b09e8251061dc040cbd396f35ae57783f4a


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-31 Thread miss-islington


Change by miss-islington :


--
pull_requests: +25056
pull_request: https://github.com/python/cpython/pull/26461

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-31 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 4b20f2574d412f4c4a5b1ab799d8e71a5dd3b766 by Hai Shi in branch 
'main':
bpo-42972: Fully implement GC protocol for xxlimited (GH-26451)
https://github.com/python/cpython/commit/4b20f2574d412f4c4a5b1ab799d8e71a5dd3b766


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-31 Thread miss-islington


Change by miss-islington :


--
pull_requests: +25055
pull_request: https://github.com/python/cpython/pull/26460

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-29 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests: +25046
pull_request: https://github.com/python/cpython/pull/26452

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-29 Thread hai shi


Change by hai shi :


--
pull_requests: +25045
pull_request: https://github.com/python/cpython/pull/26451

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:


New changeset 0d399516320d8dfce4453037338659cef3a2adf4 by Ken Jin in branch 
'3.10':
[3.10] bpo-42972: Fully support GC for _winapi.Overlapped (GH-26381)  (#26430)
https://github.com/python/cpython/commit/0d399516320d8dfce4453037338659cef3a2adf4


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 490b638e63558013b71dbfba6e47cb9e6d80c911 by Ken Jin in branch 
'main':
bpo-42972: Fix GC assertion error in _winapi by untracking Overlapped earlier 
(GH(26429)
https://github.com/python/cpython/commit/490b638e63558013b71dbfba6e47cb9e6d80c911


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread miss-islington


miss-islington  added the comment:


New changeset 1c0106ca8c72d671ad4e2b553489d786d06fce03 by Miss Islington (bot) 
in branch '3.10':
bpo-42972: Fully implement GC protocol for functools LRU cache (GH-26423)
https://github.com/python/cpython/commit/1c0106ca8c72d671ad4e2b553489d786d06fce03


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread miss-islington


Change by miss-islington :


--
pull_requests: +25025
pull_request: https://github.com/python/cpython/pull/26431

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread STINNER Victor


STINNER Victor  added the comment:

I'm not fully satified by the overlapped_dealloc() implementation neither. 
There is an unpleasant code path for Windows XP but it's no longer needed in 
Python 3.11. I would prefer to always call PyObject_GC_UnTrack() and call it 
earlier.

See the dicsussion in the PR:
https://github.com/python/cpython/pull/26381

But it can be modified later.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread STINNER Victor


STINNER Victor  added the comment:

I'm not fully satisfied by the implementation of the two LRU types in 
functools. See the discussion in these two PRs:

https://github.com/python/cpython/pull/26363
https://github.com/python/cpython/pull/26423

The _lru_list_elem doesnt implement the GC protocol for performance reasons:

* https://bugs.python.org/issue32422
* https://github.com/python/cpython/pull/5008/files

But I'm not sure if it's ok that _lru_list_elem doesn't implement the GC 
protocol: it's disucssion in this issue.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread Ken Jin


Change by Ken Jin :


--
pull_requests: +25024
pull_request: https://github.com/python/cpython/pull/26430

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread Ken Jin


Change by Ken Jin :


--
pull_requests: +25023
pull_request: https://github.com/python/cpython/pull/26429

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread miss-islington


Change by miss-islington :


--
pull_requests: +25022
pull_request: https://github.com/python/cpython/pull/26427

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset eb8ab04dd7fe6bb9a4eefb5e60d7b6ca887e0148 by Miss Islington (bot) 
in branch '3.10':
bpo-42972: Fully implement GC protocol for functools keywrapper and partial 
types (GH-26363) (GH-26424)
https://github.com/python/cpython/commit/eb8ab04dd7fe6bb9a4eefb5e60d7b6ca887e0148


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread miss-islington


Change by miss-islington :


--
pull_requests: +25021
pull_request: https://github.com/python/cpython/pull/26426

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 0fa282c55f1a45765340cb24ed65c90ffe2aa405 by Ken Jin in branch 
'main':
bpo-42972: Fully support GC for _winapi.Overlapped (GH-26381)
https://github.com/python/cpython/commit/0fa282c55f1a45765340cb24ed65c90ffe2aa405


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread miss-islington


Change by miss-islington :


--
pull_requests: +25020
pull_request: https://github.com/python/cpython/pull/26425

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 3f8d33252722750e6c019d3df7ce0fabf7bdd45e by Erlend Egeberg 
Aasland in branch 'main':
bpo-42972: Fully implement GC protocol for functools LRU cache (GH-26423)
https://github.com/python/cpython/commit/3f8d33252722750e6c019d3df7ce0fabf7bdd45e


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread miss-islington


Change by miss-islington :


--
pull_requests: +25019
pull_request: https://github.com/python/cpython/pull/26424

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 8994e9c2cd775ddf7b0723824da53fe0d7c039ac by Erlend Egeberg 
Aasland in branch 'main':
bpo-42972: Fully implement GC protocol for functools keywrapper and partial 
types (GH-26363)
https://github.com/python/cpython/commit/8994e9c2cd775ddf7b0723824da53fe0d7c039ac


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-28 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests: +25018
pull_request: https://github.com/python/cpython/pull/26423

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset da9e0cb4dedf818540ad1f06305bb1ca9e568f51 by Miss Islington (bot) 
in branch '3.10':
bpo-42972: Fully implement GC protocol for re types (GH-26368) (GH-26414)
https://github.com/python/cpython/commit/da9e0cb4dedf818540ad1f06305bb1ca9e568f51


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread miss-islington


Change by miss-islington :


--
pull_requests: +25008
pull_request: https://github.com/python/cpython/pull/26414

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset d1c732912e20e89815aca2d986442d349e82e31f by Miss Islington (bot) 
in branch '3.10':
bpo-42972: Fully support GC protocol for _operator heap types (GH-26371) 
(GH-26413)
https://github.com/python/cpython/commit/d1c732912e20e89815aca2d986442d349e82e31f


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread miss-islington


Change by miss-islington :


--
pull_requests: +25007
pull_request: https://github.com/python/cpython/pull/26413

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset f4b70c22c8e37dd7a06702e30b121a6651683421 by Erlend Egeberg 
Aasland in branch 'main':
bpo-42972: Fully support GC protocol for _operator heap types (GH-26371)
https://github.com/python/cpython/commit/f4b70c22c8e37dd7a06702e30b121a6651683421


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread Erlend E. Aasland


Erlend E. Aasland  added the comment:

I can't contribute to that discussion, as it is on the committers ml, but I'll 
keep an eye on it. I'll refrain from further development on this issue until 
there's a consensus amongst the core devs.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

Please, check also the discusion happening here:

https://mail.python.org/archives/list/python-committ...@python.org/thread/FHFI7QKWNHAVWVFTCHJGTYD3ZFVEUXDD/

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset fba42d11880f444bb94d9891e3949f082a57b9a9 by Erlend Egeberg 
Aasland in branch 'main':
bpo-42972: Fully implement GC protocol for re types (GH-26368)
https://github.com/python/cpython/commit/fba42d11880f444bb94d9891e3949f082a57b9a9


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread miss-islington


Change by miss-islington :


--
pull_requests: +25005
pull_request: https://github.com/python/cpython/pull/26411

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread STINNER Victor


STINNER Victor  added the comment:

> GH-26399 is failing with an access violation on Windows. It's failing in one 
> of the flaky tests. I wonder if the segfault is related to flaky tests 
> somehow...

I created bpo-44252 to track this crash, it might be unrelated to commit 
dcb8786a9848516e823e090bb36079678913d8d3. Even if it's related, I prefer to 
track it separated to ease collaboration and focus to this issue to the GC 
protocol.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread STINNER Victor


STINNER Victor  added the comment:

I'm not sure that it's safe to call PyObject_ClearWeakRefs() in tp_clear 
function. PyObject_ClearWeakRefs() comment starts with:

"This function is called by the tp_dealloc handler to clear weak references."

For example in Modules/arraymodule.c, I don't understand well what assigns 
weakreflist and what is the object type. Is it a strong reference to a Python 
object? What is supposed to call Py_DECREF() on it?

Is it enought to call PyObject_ClearWeakRefs() in tp_dealloc?

subtype_dealloc() calls PyObject_ClearWeakRefs(self).

I wrote a short example:
---
import weakref
import ctypes
import sys

class A:
pass

obj=A()
assert obj.__weakref__ is None

wr1 = weakref.ref(obj)
assert obj.__weakref__ is wr1
print(type(wr1))
print("refcnt(wr1)", sys.getrefcount(wr1))

wr2 = weakref.ref(obj)
assert wr2 is wr1
assert obj.__weakref__ is wr1
print("refcnt(wr1)", sys.getrefcount(wr1))

_PyWeakref_GetWeakrefCount = ctypes.pythonapi._PyWeakref_GetWeakrefCount
_PyWeakref_GetWeakrefCount.argtypes = (ctypes.py_object,)
_PyWeakref_GetWeakrefCount.restype = ctypes.c_size_t
print("_PyWeakref_GetWeakrefCount:", _PyWeakref_GetWeakrefCount(wr1))
---

Output:
---

refcnt(wr1) 2
refcnt(wr1) 3
_PyWeakref_GetWeakrefCount: 1
---

In this case, wr2 is wr1, __weakreflist__ points to a weakref.ref object 
instance, and _PyWeakref_GetWeakrefCount() returns 1.

At the first weakref.ref() call, the reference count is 1: "wr1" variable holds 
this reference. I understand that obj stores a *weak* reference to the Python 
object "weakref.ref". So it doesn't have to DECREF anything.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread miss-islington


miss-islington  added the comment:


New changeset da8097aaf5a55c23f5b5ddbeffc2d90d06e00d93 by Miss Islington (bot) 
in branch '3.10':
bpo-42972: Fully support GC for mmap heap types (GH-26373)
https://github.com/python/cpython/commit/da8097aaf5a55c23f5b5ddbeffc2d90d06e00d93


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset e73b3b1cd48c92d847990e220cb9cbdbde86476a by Miss Islington (bot) 
in branch '3.10':
bpo-42972: Fully support GC protocol for _queue.SimpleQueue (GH-26372) 
(GH-26406)
https://github.com/python/cpython/commit/e73b3b1cd48c92d847990e220cb9cbdbde86476a


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset ea47a8a71ad56ec349f02bf8c6a1d3bf04acabcc by Miss Islington (bot) 
in branch '3.10':
bpo-42972: Fully implement GC protocol for ssl heap types (GH-26370) (GH-26399)
https://github.com/python/cpython/commit/ea47a8a71ad56ec349f02bf8c6a1d3bf04acabcc


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 318adeba780851c416505e48a3454cacca831419 by Erlend Egeberg 
Aasland in branch 'main':
bpo-42972: Fully support GC for mmap heap types (GH-26373)
https://github.com/python/cpython/commit/318adeba780851c416505e48a3454cacca831419


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread miss-islington


Change by miss-islington :


--
pull_requests: +25000
pull_request: https://github.com/python/cpython/pull/26407

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 4d7f8f9f7fb09ea8eb4e43409a16a91b0bf18571 by Erlend Egeberg 
Aasland in branch 'main':
bpo-42972: Fully support GC protocol for _queue.SimpleQueue (GH-26372)
https://github.com/python/cpython/commit/4d7f8f9f7fb09ea8eb4e43409a16a91b0bf18571


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread miss-islington


Change by miss-islington :


--
pull_requests: +24999
pull_request: https://github.com/python/cpython/pull/26406

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread miss-islington


miss-islington  added the comment:


New changeset 0bf0500baa4cbdd6c5668461c2a2a008121772be by Miss Islington (bot) 
in branch '3.10':
bpo-42972: Fully support GC for pyexpat, unicodedata, and dbm/gdbm heap types 
(GH-26376)
https://github.com/python/cpython/commit/0bf0500baa4cbdd6c5668461c2a2a008121772be


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread STINNER Victor


STINNER Victor  added the comment:

So it seems like the weakref list (__weaklistoffset__) doesn't have to be 
handled by visit, clear or free functions, it only has to be deallocated with 
PyObject_ClearWeakRefs() in the dealloc function.

I noticed that when reviewing partial_clear(partialobject *pto) in PR 26363.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread Erlend E. Aasland


Erlend E. Aasland  added the comment:

Hm, I'm unable to reproduce it w/addr sanitiser on macOS (FWIW).

$ ./python.exe -m test test_ssl -F -u all -m test_pha_required_nocert

Passing 1000 successful runs now. I'll see if I can get a Win dev env set up 
later.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread Christian Heimes


Christian Heimes  added the comment:

GH-26399 is failing with an access violation on Windows. It's failing in one of 
the flaky tests. I wonder if the segfault is related to flaky tests somehow...

https://dev.azure.com/Python/cpython/_build/results?buildId=81570=logs=c83831cd-3752-5cc7-2f01-8276919eb334

test_pha_optional (test.test_ssl.TestPostHandshakeAuth) ... ok
test_pha_optional_nocert (test.test_ssl.TestPostHandshakeAuth) ... ok
test_pha_required (test.test_ssl.TestPostHandshakeAuth) ... ok
Windows fatal exception: access violation

Current thread 0x09e0 (most recent call first):
  File "D:\a\1\s\lib\linecache.py", line 63 in checkcache
  File "D:\a\1\s\lib\traceback.py", line 375 in extract
  File "D:\a\1\s\lib\traceback.py", line 494 in __init__
  File "D:\a\1\s\lib\traceback.py", line 132 in format_exception
  File "D:\a\1\s\lib\test\test_ssl.py", line 262 in handle_error
  File "D:\a\1\s\lib\test\test_ssl.py", line 2530 in run
  File "D:\a\1\s\lib\threading.py", line 1006 in _bootstrap_inner
  File "D:\a\1\s\lib\threading.py", line 963 in _bootstrap

Thread 0x03c4 (most recent call first):
  File "D:\a\1\s\lib\threading.py", line 1102 in _wait_for_tstate_lock
  File "D:\a\1\s\lib\threading.py", line 1086 in join
  File "D:\a\1\s\lib\test\test_ssl.py", line 2604 in run
  File "D:\a\1\s\lib\threading.py", line 1006 in _bootstrap_inner
  File "D:\a\1\s\lib\threading.py", line 963 in _bootstrap

Thread 0x1700 (most recent call first):
  File "D:\a\1\s\lib\ssl.py", line 1131 in read
  File "D:\a\1\s\lib\ssl.py", line 1256 in recv
  File "D:\a\1\s\lib\test\test_ssl.py", line 4471 in test_pha_required_nocert
  File "D:\a\1\s\lib\unittest\case.py", line 549 in _callTestMethod
  File "D:\a\1\s\lib\unittest\case.py", line 592 in run
  File "D:\a\1\s\lib\unittest\case.py", line 652 in __call__
  File "D:\a\1\s\lib\unittest\suite.py", line 122 in run
  File "D:\a\1\s\lib\unittest\suite.py", line 84 in __call__
  File "D:\a\1\s\lib\unittest\suite.py", line 122 in run
  File "D:\a\1\s\lib\unittest\suite.py", line 84 in __call__
  File "D:\a\1\s\lib\unittest\runner.py", line 176 in run
  File "D:\a\1\s\lib\test\support\__init__.py", line 959 in _run_suite
  File "D:\a\1\s\lib\test\support\__init__.py", line 1082 in run_unittest
  File "D:\a\1\s\lib\test\test_ssl.py", line 5007 in test_main
  File "D:\a\1\s\lib\test\libregrtest\runtest.py", line 246 in _runtest_inner2
  File "D:\a\1\s\lib\test\libregrtest\runtest.py", line 282 in _runtest_inner
  File "D:\a\1\s\lib\test\libregrtest\runtest.py", line 154 in _runtest
  File "D:\a\1\s\lib\test\__main__.py", line 2 in 
  File "D:\a\1\s\lib\runpy.py", line 86 in _run_code
  File "D:\a\1\s\lib\runpy.py", line 196 in _run_module_as_main
##[error]Cmd.exe exited with code '-1073741819'.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread miss-islington


miss-islington  added the comment:


New changeset 4431922f92747f77e3eb790c6d1881232e1b5e8c by Miss Islington (bot) 
in branch '3.10':
[3.10] bpo-42972: Fully support GC for hashlib heap types (GH-26374) (GH-26398)
https://github.com/python/cpython/commit/4431922f92747f77e3eb790c6d1881232e1b5e8c


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread miss-islington


Change by miss-islington :


--
pull_requests: +24992
pull_request: https://github.com/python/cpython/pull/26399

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread Christian Heimes


Christian Heimes  added the comment:


New changeset dcb8786a9848516e823e090bb36079678913d8d3 by Erlend Egeberg 
Aasland in branch 'main':
bpo-42972: Fully implement GC protocol for ssl heap types (GH-26370)
https://github.com/python/cpython/commit/dcb8786a9848516e823e090bb36079678913d8d3


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread Christian Heimes


Christian Heimes  added the comment:


New changeset 6ef5ba391d700bde7ec3ffd5fb7132a30dd309c4 by Erlend Egeberg 
Aasland in branch 'main':
bpo-42972: Fully support GC for hashlib heap types (GH-26374)
https://github.com/python/cpython/commit/6ef5ba391d700bde7ec3ffd5fb7132a30dd309c4


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread miss-islington


Change by miss-islington :


--
pull_requests: +24991
pull_request: https://github.com/python/cpython/pull/26398

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread Nick Coghlan


Nick Coghlan  added the comment:


New changeset 59af59c2dfa52dcd5605185263f266a49ced934c by Erlend Egeberg 
Aasland in branch 'main':
bpo-42972: Fully support GC for pyexpat, unicodedata, and dbm/gdbm heap types 
(GH-26376)
https://github.com/python/cpython/commit/59af59c2dfa52dcd5605185263f266a49ced934c


--
nosy: +ncoghlan

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-27 Thread miss-islington


Change by miss-islington :


--
pull_requests: +24990
pull_request: https://github.com/python/cpython/pull/26397

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-26 Thread Ken Jin


Ken Jin  added the comment:

> it creates nearly 100 objects

Oops sorry I think I'm wrong. most of those objects may be borrowed refs. Just 
1 type object is causing the leak.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-26 Thread Ken Jin


Ken Jin  added the comment:

_winapi is leaky still even with my PR:

>>> import sys,gc
>>> for _ in range(5):
...  print(sys.gettotalrefcount())
...  import _winapi
...  del sys.modules['_winapi']
...  del _winapi
...  gc.collect()
...
50468
51076
51432
51788
52144

I just noticed this, but _winapi doesn't have a m_traverse/m_clear/m_free in 
the PyModuleDef eventhough it creates nearly 100 objects in 
m_slot->Py_mod_exec. I'm not a multi phase init expert, but shouldn't there be 
a cleanup function or am I confusing something here :( ?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-26 Thread Ken Jin


Change by Ken Jin :


--
nosy: +kj
nosy_count: 8.0 -> 9.0
pull_requests: +24973
pull_request: https://github.com/python/cpython/pull/26381

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-26 Thread Erlend E. Aasland


Erlend E. Aasland  added the comment:

I've opened PR's to fix most of the heap types converted during the 3.10 alpha 
phase. What's missing (of the 3.10 batch) is:
- _thread types (this needs special care)
- winapi__overlapped.Overlapped (I currently don't have a Win dev env at hand)

For the types converted during 3.9 dev, should we backport to 3.9 or just 3.10?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-26 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests: +24968
pull_request: https://github.com/python/cpython/pull/26376

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-26 Thread hai shi


hai shi  added the comment:

> * functools._lru_list_elem
Looks like this type have performance in issue PR-5008 when supporting GC. I am 
not sure there have other similar questions or not.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

Victor, can you take a look at the opened PRs?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread Neil Schemenauer


Change by Neil Schemenauer :


--
nosy: +nascheme

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests: +24966
pull_request: https://github.com/python/cpython/pull/26374

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread Erlend E. Aasland


Erlend E. Aasland  added the comment:

Thanks! Hashlib PR comin' up.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests: +24964
pull_request: https://github.com/python/cpython/pull/26373

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests: +24963
pull_request: https://github.com/python/cpython/pull/26372

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests: +24960
pull_request: https://github.com/python/cpython/pull/26371

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests: +24959
pull_request: https://github.com/python/cpython/pull/26370

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread Christian Heimes


Christian Heimes  added the comment:

Please open PRs and assign them to me. I'll review them as soon as possible.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread Erlend E. Aasland


Erlend E. Aasland  added the comment:

Christian, I've got a PR ready for Modules/_ssl.c, but I won't submit it if 
you'd rather do it yourself. I'll stay off the sha/md5 types unless you approve 
:)

--
nosy: +christian.heimes

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests: +24957
pull_request: https://github.com/python/cpython/pull/26368

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests: +24954
pull_request: https://github.com/python/cpython/pull/26363

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread miss-islington


miss-islington  added the comment:


New changeset 534da740a2586357d204ab5f446295b9ce220787 by Miss Islington (bot) 
in branch '3.10':
bpo-42972: Fully implement GC protocol for arraymodule types (GH-26114)
https://github.com/python/cpython/commit/534da740a2586357d204ab5f446295b9ce220787


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:


New changeset bd404ccac0d3e8358995ac0cbeec9373bb6c4d96 by Erlend Egeberg 
Aasland in branch 'main':
bpo-42972: Fully implement GC protocol for arraymodule types (GH-26114)
https://github.com/python/cpython/commit/bd404ccac0d3e8358995ac0cbeec9373bb6c4d96


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread miss-islington


Change by miss-islington :


--
pull_requests: +24953
pull_request: https://github.com/python/cpython/pull/26362

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread miss-islington


miss-islington  added the comment:


New changeset e8d9df0089e30a06d837fa2cfbd070e01531701f by Miss Islington (bot) 
in branch '3.10':
bpo-42972: Fully implement GC protocol for sqlite3 heap types (GH-26104)
https://github.com/python/cpython/commit/e8d9df0089e30a06d837fa2cfbd070e01531701f


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread miss-islington


Change by miss-islington :


--
nosy: +miss-islington
nosy_count: 5.0 -> 6.0
pull_requests: +24952
pull_request: https://github.com/python/cpython/pull/26361

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-25 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:


New changeset d3c277a59c3d93fb92f7026f63678083d1d49fc5 by Erlend Egeberg 
Aasland in branch 'main':
bpo-42972: Fully implement GC protocol for sqlite3 heap types (GH-26104)
https://github.com/python/cpython/commit/d3c277a59c3d93fb92f7026f63678083d1d49fc5


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-14 Thread Erlend E. Aasland


Erlend E. Aasland  added the comment:

Is there a deterministic way to test these changes? Will something a la this be 
sufficient:

import gc
import sys

gc.collect()
before = sys.gettotalrefcount()

import somemod
del sys.modules['somemod']
del somemod

gc.collect()
after = sys.gettotalrefcount()

assert after == before

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-13 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests:  -23226

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-13 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests: +24759
pull_request: https://github.com/python/cpython/pull/26114

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-13 Thread Erlend E. Aasland


Erlend E. Aasland  added the comment:

I've added a checkbox for types that fully implement the GC protocol to 
https://discuss.python.org/t/list-of-built-in-types-converted-to-heap-types/8403/1.

Heap types that fully implement the GC protocol:
* _abc._abc_data
* _bz2.BZ2Compressor
* _bz2.BZ2Decompressor
* _csv.Dialect
* _csv.reader
* _csv.writer
* _json.Encoder
* _json.Scanner
* _lzma.LZMACompressor
* _lzma.LZMADecompressor
* _multibytecodec.MultibyteCodec
* _struct.unpack_iterator
* _thread._local
* _thread.lock
* ast.AST

Heap types that do not fully implement the GC protocol:
* _curses_panel.panel
* _dbm.dbm
* _gdbm.gdbm
* _hashlib.HASH
* _hashlib.HASHXOF
* _lsprof.Profiler
* _md5.md5
* _multibytecodec.MultibyteIncrementalDecoder
* _multibytecodec.MultibyteIncrementalEncoder
* _multibytecodec.MultibyteStreamReader
* _multibytecodec.MultibyteStreamWriter
* _overlapped.Overlapped
* _queue.SimpleQueue
* _random.Random
* _sha1.sha1
* _sha256.sha224
* _sha256.sha256
* _sha512.sha384
* _sha512.sha512
* _sre.SRE_Scanner
* _ssl.MemoryBIO
* _ssl.SSLSession
* _ssl._SSLContext
* _ssl._SSLSocket
* _struct.Struct
* _thread.RLock
* _thread._localdummy
* _tkinter.Tcl_Obj
* _tkinter.tkapp
* _tkinter.tktimertoken
* array.array
* array.arrayiterator
* functools.KeyWrapper
* functools._lru_cache_wrapper
* functools._lru_list_elem
* functools.partial
* mmap.mmap
* operator.attrgetter
* operator.itemgetter
* operator.methodcaller
* posix.DirEntry
* posix.ScandirIterator
* pyexpat.xmlparser
* re.Match
* re.Pattern
* select.devpoll
* select.epoll
* select.kevent
* select.kqueue
* select.poll
* sqlite3.Cache
* sqlite3.Connection
* sqlite3.Cursor
* sqlite3.Node
* sqlite3.PrepareProtocol
* sqlite3.Row
* sqlite3.Statement
* ssl.SSLError
* unicodedata.UCD
* winapi__overlapped.Overlapped
* zlib.Compress
* zlib.Decompress

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-13 Thread Erlend E. Aasland


Change by Erlend E. Aasland :


--
pull_requests: +24746
pull_request: https://github.com/python/cpython/pull/26104

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-05-12 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

I'm marking this as a 3.10 release blocker untill all converted types that are 
in 3.10 have GC support.

--
nosy: +pablogsal
priority: normal -> release blocker

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-02-01 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
keywords: +patch
pull_requests: +23226
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/23428

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-01-28 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Should we proceed with fixing GC for all heap types before continuing work with 
bpo-40077?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-01-20 Thread hai shi


Change by hai shi :


--
nosy: +shihai1991

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42972] [C API] Heap types (PyType_FromSpec) must fully implement the GC protocol

2021-01-20 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +erlendaasland

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



  1   2   >