STINNER Victor added the comment:
New changeset cd8de40b3b10311de2db7b90abdf80af9e35535f by Victor Stinner in
branch 'main':
bpo-29882: _Py_popcount32() doesn't need 64x64 multiply (GH-30774)
https://github.com/python/cpython/commit/cd8de40b3b10311de2db7b90abdf80af9e35535f
Change by STINNER Victor :
--
pull_requests: +28959
pull_request: https://github.com/python/cpython/pull/30774
___
Python tracker
<https://bugs.python.org/issue29
STINNER Victor added the comment:
New changeset ac1f152421fab3ac854fe4565c575b306e2bb4b5 by Victor Stinner in
branch 'main':
bpo-46417: Use _PyType_CAST() in Objects directory (GH-30764)
https://github.com/python/cpython/commit/ac1f152421fab3ac854fe4565c575b306e2bb4b5
STINNER Victor added the comment:
New changeset 7835cbf949c413a746324721a352cc72670a8a36 by Victor Stinner in
branch 'main':
bpo-46417: Use _PyType_CAST() in Python directory (GH-30769)
https://github.com/python/cpython/commit/7835cbf949c413a746324721a352cc72670a8a36
STINNER Victor added the comment:
New changeset 8ee07dda139f3fa1d7c58a29532a98efc790568d by Victor Stinner in
branch 'main':
bpo-46417: Add _PyType_GetSubclasses() function (GH-30761)
https://github.com/python/cpython/commit/8ee07dda139f3fa1d7c58a29532a98efc790568d
Change by STINNER Victor :
--
pull_requests: +28955
pull_request: https://github.com/python/cpython/pull/30767
___
Python tracker
<https://bugs.python.org/issue46
Change by STINNER Victor :
--
pull_requests: +28954
pull_request: https://github.com/python/cpython/pull/30769
___
Python tracker
<https://bugs.python.org/issue46
Change by STINNER Victor :
--
pull_requests: +28950
pull_request: https://github.com/python/cpython/pull/30764
___
Python tracker
<https://bugs.python.org/issue46
Change by STINNER Victor :
--
pull_requests: +28949
pull_request: https://github.com/python/cpython/pull/30763
___
Python tracker
<https://bugs.python.org/issue46
STINNER Victor added the comment:
New changeset bc67f189fdd62ed42013fa05cd0ef2df498f5967 by Victor Stinner in
branch 'main':
bpo-46417: Add _PyType_CAST() macro (GH-30760)
https://github.com/python/cpython/commit/bc67f189fdd62ed42013fa05cd0ef2df498f5967
Change by STINNER Victor :
--
pull_requests: +28948
pull_request: https://github.com/python/cpython/pull/30761
___
Python tracker
<https://bugs.python.org/issue46
Change by STINNER Victor :
--
pull_requests: +28947
pull_request: https://github.com/python/cpython/pull/30760
___
Python tracker
<https://bugs.python.org/issue46
STINNER Victor added the comment:
#ifdef __cplusplus
char array[1];
#else
char array[];
#endif
Does it change the size of the structure between C and C++,
sizeof(PyBytesObject)? Also, does the size of the struture matter? :-) I guess
that the impart part is the ABI: offset
STINNER Victor added the comment:
An alternative would be to merge PyHeapTypeObject members into PyTypeObject. I
don't get why there is a separated struture: PyTypeObject is excluded from the
stable ABI. See my remark about that:
https://bugs.python.org/issue22079#msg391464
Having
STINNER Victor added the comment:
Oh, it seems like I misunderstood type_ready_mro() change. The check is only
done on static types type. The MRO of heap types is not checked.
--
In my change, I wrote:
// _PyType_GetModuleByDef() must only be called on a heap type created
STINNER Victor added the comment:
New changeset a1bf329bca80a0259da454c936075e11e6af710f by Victor Stinner in
branch 'main':
bpo-46417: Add missing types of _PyTypes_InitTypes() (GH-30749)
https://github.com/python/cpython/commit/a1bf329bca80a0259da454c936075e11e6af710f
STINNER Victor added the comment:
As I already wrote previously, I'm a supporter of requiring debuggers and
profilers to explicitly call PyFrame_FastToLocalsWithError() and
PyFrame_LocalsToFast(). It should only impact a minority of users, whereas the
majority will benefit of way better
STINNER Victor added the comment:
That's not a bug, but a deliberate choice. In Python 3, file descriptors are no
longer inherited by default by child processes (fork+exec). Jelle is right, it
was changed by my PEP 446.
You must use pass_fds=[fd] parameter of subprocess.
Or at least, make
STINNER Victor added the comment:
> bpo-46417: Revert remove_subclass() change (GH-30750)
Ok, this change fixed buildbots.
I saw code in typeobject.c which uses a borrowed reference to tp_subclasses
with a loop which can modify tp_subclasses. This code should be modified to
hold a str
STINNER Victor added the comment:
New changeset fda88864980ffce57add0ea03fb9cbda2798975e by Victor Stinner in
branch 'main':
bpo-46417: Revert remove_subclass() change (GH-30750)
https://github.com/python/cpython/commit/fda88864980ffce57add0ea03fb9cbda2798975e
New submission from STINNER Victor :
The following command hangs:
./python -u -m test -v test_unittest -m test_debug_cleanup_same_loop -v
2>/dev/null
if the following patch is applied on Python:
diff --git a/Lib/unittest/test/test_async_case.py
b/Lib/unittest/test/test_async_case.py
in
Change by STINNER Victor :
--
pull_requests: +28937
pull_request: https://github.com/python/cpython/pull/30750
___
Python tracker
<https://bugs.python.org/issue46
Change by STINNER Victor :
--
pull_requests: +28936
pull_request: https://github.com/python/cpython/pull/30749
___
Python tracker
<https://bugs.python.org/issue46
STINNER Victor added the comment:
Maybe the problem is that I changed the order in which types are initialized in
_PyTypes_InitTypes()?
So far, test_unittest crashed on 4 buildbot workers:
* s390x Debian 3.x: ./configure --prefix '$(PWD)/target' --with-pydebug
https://buildbot.python.org
STINNER Victor added the comment:
> bpo-46417: Py_Finalize() clears static types (GH-30743)
Oh, test_unittest crashed on s390x Debian 3.x:
https://buildbot.python.org/all/#/builders/49/builds/1789
I fail to see the relationship between my change and this crash. I don't expect
test_unitt
STINNER Victor added the comment:
I marked bpo-37776 "[subinterpreters] Test Py_Finalize() from a subinterpreter"
as a duplicate of this issue.
--
___
Python tracker
<https://bugs.python.o
STINNER Victor added the comment:
I mark this issue as a duplicate of bpo-38865.
--
resolution: -> duplicate
stage: patch review -> resolved
status: open -> closed
superseder: -> [subinterpreters] Can Py_Finalize() be called if the current
interpreter is not the main
STINNER Victor added the comment:
New changeset 595225e86dcc6ea520a584839925a878dce7a9b2 by Victor Stinner in
branch 'main':
bpo-46417: Py_Finalize() clears static types (GH-30743)
https://github.com/python/cpython/commit/595225e86dcc6ea520a584839925a878dce7a9b2
STINNER Victor added the comment:
Using "./python -IsS" command, sys.modules now only has 3 extensions which are
not created by PyModuleDef_Init():
* builtins
* _io
* sys
The builtins and sys extensions use many static types. Converting these static
types to heap types is bloc
STINNER Victor added the comment:
New changeset ea38e436fe1e585fb8c1f0badf5482f525b7f9ff by Victor Stinner in
branch 'main':
bpo-46417: Call _PyDebug_PrintTotalRefs() later (GH-30744)
https://github.com/python/cpython/commit/ea38e436fe1e585fb8c1f0badf5482f525b7f9ff
Change by STINNER Victor :
--
pull_requests: +28932
pull_request: https://github.com/python/cpython/pull/30744
___
Python tracker
<https://bugs.python.org/issue1635
Change by STINNER Victor :
--
pull_requests: +28931
pull_request: https://github.com/python/cpython/pull/30744
___
Python tracker
<https://bugs.python.org/issue46
Change by STINNER Victor :
--
pull_requests: +28930
pull_request: https://github.com/python/cpython/pull/30743
___
Python tracker
<https://bugs.python.org/issue46
STINNER Victor added the comment:
> This reminds me, since https://github.com/python/cpython/pull/30715 (which I
> merged yesterday) the deep-frozen objects also reference the small ints
> directly, as well as the singleton for b"". Is this even safe across
> Py_Fi
STINNER Victor added the comment:
> Hm, the deep-frozen objects are statically initialized with a very large
> refcount that isn't accounted for (they are intended to be immortal). It
> seems that Py_Finalize() somehow decrefs those objects. I guess this means we
> need some
Change by STINNER Victor :
--
nosy: +eric.snow, gvanrossum
___
Python tracker
<https://bugs.python.org/issue46449>
___
___
Python-bugs-list mailing list
Unsub
STINNER Victor added the comment:
New changeset d013b241352e902389f955f8f99d75f16c124ee2 by Victor Stinner in
branch 'main':
bpo-46417: signal uses PyStructSequence_NewType() (GH-30735)
https://github.com/python/cpython/commit/d013b241352e902389f955f8f99d75f16c124ee2
STINNER Victor added the comment:
See also bpo-46449 "Deep-freezed modules create inconsistency in
sys.gettotalrefcount() (_Py_Reftotal)".
--
___
Python tracker
<https://bugs.python.o
New submission from STINNER Victor :
Using the C program below, I see that _Py_RefTotal is decreasing at each
iteration:
---
#include
int main(int argc, char *argv[])
{
for (int i=1; i <= 100; i++) {
Py_SetProgramName(L"./_testembed");
Py_Initialize();
STINNER Victor added the comment:
New changeset 1781d55eb34f94029e50970232635fc5082378cb by Victor Stinner in
branch 'main':
bpo-46417: _curses uses PyStructSequence_NewType() (GH-30736)
https://github.com/python/cpython/commit/1781d55eb34f94029e50970232635fc5082378cb
Change by STINNER Victor :
--
pull_requests: +28923
pull_request: https://github.com/python/cpython/pull/30736
___
Python tracker
<https://bugs.python.org/issue46
Change by STINNER Victor :
--
pull_requests: +28922
pull_request: https://github.com/python/cpython/pull/30735
___
Python tracker
<https://bugs.python.org/issue46
STINNER Victor added the comment:
New changeset 17f268a4ae6190b2659c89c6f32ad2d006e0e3c8 by Victor Stinner in
branch 'main':
bpo-46417: time module uses PyStructSequence_NewType() (GH-30734)
https://github.com/python/cpython/commit/17f268a4ae6190b2659c89c6f32ad2d006e0e3c8
STINNER Victor added the comment:
New changeset f389b37fb1cebe7ed66331cdd373a014695261f6 by Victor Stinner in
branch 'main':
bpo-46417: _thread uses PyStructSequence_NewType() (GH-30733)
https://github.com/python/cpython/commit/f389b37fb1cebe7ed66331cdd373a014695261f6
Change by STINNER Victor :
--
pull_requests: +28921
pull_request: https://github.com/python/cpython/pull/30734
___
Python tracker
<https://bugs.python.org/issue46
Change by STINNER Victor :
--
pull_requests: +28920
pull_request: https://github.com/python/cpython/pull/30733
___
Python tracker
<https://bugs.python.org/issue46
STINNER Victor added the comment:
New changeset 6415e2ee4955b1a995c1e75544e2506b03780c3d by Victor Stinner in
branch 'main':
bpo-46417: _testembed.c avoids Py_SetProgramName() (GH-30732)
https://github.com/python/cpython/commit/6415e2ee4955b1a995c1e75544e2506b03780c3d
Change by STINNER Victor :
--
pull_requests: +28919
pull_request: https://github.com/python/cpython/pull/30732
___
Python tracker
<https://bugs.python.org/issue46
STINNER Victor added the comment:
New changeset e9e3eab0b868c7d0b48e472705024240d5c39d5c by Victor Stinner in
branch 'main':
bpo-46417: Finalize structseq types at exit (GH-30645)
https://github.com/python/cpython/commit/e9e3eab0b868c7d0b48e472705024240d5c39d5c
Change by STINNER Victor :
--
Removed message: https://bugs.python.org/msg411050
___
Python tracker
<https://bugs.python.org/issue46070>
___
___
Python-bug
STINNER Victor added the comment:
Another measure using the command:
PYTHONHASHSEED=0 ./python -X showrefcount -c pass
I had to run the command 20 times to get a stable value, I don't know why.
main branch: [21981 refs, 5716 blocks]
PR: [21887 refs, 5667 blocks]
=> the PR removes
STINNER Victor added the comment:
Another measure using the command:
PYTHONHASHSEED=0 ./python -X showrefcount -c pass
I had to run the command 20 times to get a stable value, I don't know why.
main branch: [21981 refs, 5716 blocks]
PR: [21887 refs, 5667 blocks]
=> the PR removes
STINNER Victor added the comment:
I checked with Valgrind the affect of PR 30645.
main branch:
==330902== LEAK SUMMARY:
==330902== possibly lost: 29,128 bytes in 494 blocks
==330902==still reachable: 353,615 bytes in 3,577 blocks
With the PR:
==332161== LEAK SUMMARY:
==332161
STINNER Victor added the comment:
If tomorrow static types are shared between sub-interpreters, it doesn't solve
this problem: we still need to release memory allocated by Py_Initialize() in
Py_Finalize() when Python is embedded. This issue is a sub-set of the big
bpo-1635741 which explains
STINNER Victor added the comment:
> @victor, git bisect tells me the change
> f3fa63ec75fdbb4a08a10957a5c631bf0c4a5970 caused
> test_exceptions.ExceptionTests.test_recursion_in_except_handler to stack
> overflow only on windows debug builds.
FYI this regression was handled last
New submission from STINNER Victor :
The AMD64 FreeBSD Shared 3.x buildbot worker fails to build Python with the
following error message:
error reading 'LASTCFLAGS'
The first failure was today (January 19, 2022) at build 1513:
https://buildbot.python.org/all/#/builders/483/builds/1513
Change by STINNER Victor :
--
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.or
STINNER Victor added the comment:
New changeset a847785b40ed8819bde2dac5849dc31d15e99a74 by Victor Stinner in
branch 'main':
bpo-43869: Time Epoch is the same on all platforms (GH-30664)
https://github.com/python/cpython/commit/a847785b40ed8819bde2dac5849dc31d15e99a74
STINNER Victor added the comment:
I was going to close the change, but I had a last look and... oh... I found
that the Python test suite checks that the Epoch is 1970-01-01 at 00:00 since
2008! I wrote GH-30664 to add an explicit test and I updated the doc
Change by STINNER Victor :
--
pull_requests: +28865
pull_request: https://github.com/python/cpython/pull/30664
___
Python tracker
<https://bugs.python.org/issue43
STINNER Victor added the comment:
New changeset ff7703c4b609a697ada8165fd1c52a73404b6d07 by Miguel Brito in
branch 'main':
bpo-43869: Improve epoch docs (GH-25777)
https://github.com/python/cpython/commit/ff7703c4b609a697ada8165fd1c52a73404b6d07
Change by STINNER Victor :
--
title: [subinterpreters] Clear static types in Py_Finalize() -> Clear static
types in Py_Finalize() for embedded Python
___
Python tracker
<https://bugs.python.org/issu
Change by STINNER Victor :
--
components: +Interpreter Core -Subinterpreters
___
Python tracker
<https://bugs.python.org/issue46417>
___
___
Python-bugs-list m
STINNER Victor added the comment:
> If we have static types, that means there is a mechanism to share some
> objects across interpreters.
Sharing objects between interpreters is bad and is causing complex bugs. See a
recent example of an object traveling from one interpreter to a
Change by STINNER Victor :
--
title: Fixing Copy on Writes from reference counting -> Fixing Copy on Writes
from reference counting and immortal objects
___
Python tracker
<https://bugs.python.org/issu
STINNER Victor added the comment:
See also:
https://discuss.python.org/t/virtual-environments-vs-nix-python-upgrades/12588
"Virtual environments vs. *nix Python upgrades".
--
nosy: +vstinner
___
Python tracker
<https://bugs.python.o
Change by STINNER Victor :
--
keywords: +patch
pull_requests: +28847
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/30645
___
Python tracker
<https://bugs.python.org/issu
STINNER Victor added the comment:
> `sys.float_info.n_unnamed_fields` causes a memory violation if the
> per-interpreter allocated 0 held by sys.float_info.n_unnamed_fields is freed.
> If it is not freed, then `sys.float_info.n_unnamed_fields is 0` is False,
> meaning that t
STINNER Victor added the comment:
Mark:
> `sys.float_info.n_unnamed_fields` causes a memory violation if the
> per-interpreter allocated 0 held by sys.float_info.n_unnamed_fields is freed.
I created bpo-46417 follow-up issue: "[subinterpreters] Clear static types in
STINNER Victor added the comment:
See also bpo-46417 "[subinterpreters] Clear static types in Py_Finalize()".
--
___
Python tracker
<https://bugs.python.o
STINNER Victor added the comment:
> I wrote PR 20763 to "finalize" static types in Py_Finalize(). It mostly
> works, but "./Programs/_testembed test_forced_io_encoding" crash. (...)
I created bpo-46417 follow-up issue: "[subinterpreters] Cle
New submission from STINNER Victor :
Converting static types to heap types is a work-in-progress:
* bpo-40077: "Convert static types to heap types: use PyType_FromSpec()"
* At December 29, 2020, 43% (89/206) of types are declared as heap types on a
total of 206 types. For
STINNER Victor added the comment:
I created https://github.com/python/core-workflow/issues/424 "Should we make
the Docs CI mandatory on the Python main branch?".
--
___
Python tracker
<https://bugs.python.o
STINNER Victor added the comment:
>self.assertEqual(repr(type), '')
For this one, I suggest to replace the value with "..." doctest pattern.
--
___
Python tracker
<https://bugs.pytho
STINNER Victor added the comment:
Do you want to propose a PR?
--
nosy: +vstinner
___
Python tracker
<https://bugs.python.org/issue46381>
___
___
Python-bug
Change by STINNER Victor :
--
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.or
STINNER Victor added the comment:
New changeset 16901c0482734dbd389b09ca3edfcf3e22faeed7 by Victor Stinner in
branch 'main':
bpo-44133: Skip PyThread_get_thread_native_id() if not available (GH-30636)
https://github.com/python/cpython/commit/16901c0482734dbd389b09ca3edfcf3e22faeed7
STINNER Victor added the comment:
Ok, the initial issue is now fixed: the test pass.
If someone wants to write test input() with non-ASCII input and readline, I
suggest to open a new issue and add the test in the test_readline module
instead.
--
resolution: -> fixed
stage: pa
STINNER Victor added the comment:
New changeset 7a822c92782ffda8fa32a4b30a95b9de7cc1b8e6 by Miss Islington (bot)
in branch '3.10':
bpo-46383: Fix signature of zoneinfo module_free function (GH-30607) (GH-30610)
https://github.com/python/cpython/commit/7a822c92782ffda8fa32a4b30a95b9de7cc1b8e6
STINNER Victor added the comment:
New changeset 0fbb9afbddb93408e34bdb7625002374cb2ad68c by Miss Islington (bot)
in branch '3.9':
bpo-13886: Skip PTY non-ASCII tests if readline is loaded (GH-30631) (GH-30635)
https://github.com/python/cpython/commit/0fbb9afbddb93408e34bdb7625002374cb2ad68c
STINNER Victor added the comment:
I reopen the issue to not forget to complete the doc.
--
resolution: fixed ->
status: closed -> open
___
Python tracker
<https://bugs.python.org/i
STINNER Victor added the comment:
With my change, the two following commands now pass successfully:
* ./python -m test test_readline test_builtin
* ./python -m test -R 3:3 test_builtin
--
___
Python tracker
<https://bugs.python.org/issue13
Change by STINNER Victor :
--
nosy: -vstinner
___
Python tracker
<https://bugs.python.org/issue45444>
___
___
Python-bugs-list mailing list
Unsubscribe:
STINNER Victor added the comment:
> Ah, sorry, I could have described the issue better. It's not a problem with
> exporting, PyThread_get_thread_native_id() isn't available on Solaris (and
> possibly other platforms) at all.
Oh ok, it's a simple bug in my test. I wrote GH-306
Change by STINNER Victor :
--
pull_requests: +28839
stage: resolved -> patch review
pull_request: https://github.com/python/cpython/pull/30636
___
Python tracker
<https://bugs.python.org/issu
STINNER Victor added the comment:
Sorry, I had to revert the change since it broke the CI and it prevented to
merge new PRs. Tell me if I can help to get this test fixed and to get this
change merged again.
By the way, the PR 30582 was merged even if the Docs CI failed
STINNER Victor added the comment:
New changeset ad6e640f910787e73fd00f59117fbd22cdf88c78 by Victor Stinner in
branch 'main':
bpo-13886: Skip PTY non-ASCII tests if readline is loaded (GH-30631)
https://github.com/python/cpython/commit/ad6e640f910787e73fd00f59117fbd22cdf88c78
STINNER Victor added the comment:
New changeset 42a64c03ec5c443f2a5c2ee4284622f5d1f5326c by Victor Stinner in
branch 'main':
Revert "bpo-40066: [Enum] update str() and format() output (GH-30582)"
(GH-30632)
https://github.com/python/cpython/commit/42a64c03ec5c443f2a5c2ee4284622
Change by STINNER Victor :
--
nosy: -vstinner
___
Python tracker
<https://bugs.python.org/issue20271>
___
___
Python-bugs-list mailing list
Unsubscribe:
Change by STINNER Victor :
--
nosy: +vstinner
nosy_count: 14.0 -> 15.0
pull_requests: +28835
pull_request: https://github.com/python/cpython/pull/30632
___
Python tracker
<https://bugs.python.org/issu
STINNER Victor added the comment:
I marked bpo-41034 "test_builtin: PtyTests fail when run twice" as a duplicate
of this issue. Moreover, I tested manually: my change GH-30631 fix the
"./python -m test -R 3:3 test_builtin" command.
--
__
STINNER Victor added the comment:
The "./python -m test -R 3:3 test_builtin" command loads the readline module
somehow:
---
$ ./python -i -m test -R 3:3 test_builtin
(...)
SystemExit: 0
>>> import sys
>>> 'readline' in sys.modules
True
---
This bug is a duplica
STINNER Victor added the comment:
I cannot reproduce this issue on the Python main branch on Fedora 35 with Tk
8.6.10 and libX11 1.7.3.1. I close the issue, please reopen it if you can still
reproduce it.
One year ago, Serhiy wrote that the issue was still reproducible on Linux but
he
STINNER Victor added the comment:
rl-locale.diff changes the readline implementation of the PyOS_Readline() to
set LC_CTYPE locale to "C": setlocale(LC_CTYPE, "C"), rather to the user
preferred locale: setlocale(LC_CTYPE, ""). IMO it's a bad idea. Python m
Change by STINNER Victor :
--
title: readline-related test_builtin failure -> test_builtin.PtyTests fail on
non-ASCII characters if the readline module is loaded
___
Python tracker
<https://bugs.python.org/issu
STINNER Victor added the comment:
Since nobody managed to fix this issue in 10 years and the test still fails if
the readline module is loaded, I wrote GH-30631 to skip the test if the
readline module is loaded.
--
___
Python tracker
<ht
Change by STINNER Victor :
--
pull_requests: +28834
pull_request: https://github.com/python/cpython/pull/30631
___
Python tracker
<https://bugs.python.org/issue13
STINNER Victor added the comment:
Oh, the test_builtin.test_input_tty_non_ascii() fails just if test_readline is
loaded previously:
$ ./python -E -m test -m test.test_builtin.PtyTests.test_input_tty_non_ascii -v
test_readline test_builtin
== CPython 3.11.0a4+ (heads/main:7f4b69b9076, Jan 17
STINNER Victor added the comment:
On Fedora 35, I still reproduce the initial issue on the main branch of Python:
$ ./python -E -m test -v test_readline test_builtin
(...)
==
FAIL: test_input_tty_non_ascii
Change by STINNER Victor :
--
nosy: -vstinner
___
Python tracker
<https://bugs.python.org/issue24194>
___
___
Python-bugs-list mailing list
Unsubscribe:
801 - 900 of 34965 matches
Mail list logo