[issue44232] Crash in Objects/typeobject.c

2021-05-26 Thread STINNER Victor
STINNER Victor added the comment: Ok, it's now fixed in 3.10 and main branches. Thanks for the bug report, and thanks Ken Jin for your PR ;-) -- priority: release blocker -> resolution: -> fixed stage: patch review -> resolved status: open -> closed

[issue44232] Crash in Objects/typeobject.c

2021-05-26 Thread STINNER Victor
STINNER Victor added the comment: New changeset 7b3b6982a5683f5146ede58a448d3edb777e501b by Miss Islington (bot) in branch '3.10': bpo-44232: Fix type_new() error reporting (GH-26359) (GH-26365) https://github.com/python/cpython/commit/7b3b6982a5683f5146ede58a448d3edb777e501b --

[issue44232] Crash in Objects/typeobject.c

2021-05-25 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 4.0 -> 5.0 pull_requests: +24956 pull_request: https://github.com/python/cpython/pull/26365 ___ Python tracker

[issue44232] Crash in Objects/typeobject.c

2021-05-25 Thread STINNER Victor
STINNER Victor added the comment: New changeset bd199e72fb60a8ff001a023f23925092a290be91 by Victor Stinner in branch 'main': bpo-44232: Fix type_new() error reporting (GH-26359) https://github.com/python/cpython/commit/bd199e72fb60a8ff001a023f23925092a290be91 --

[issue44232] Crash in Objects/typeobject.c

2021-05-25 Thread STINNER Victor
STINNER Victor added the comment: > We noticed a behavior change in [1]. Hey, well done bisection, you're right, it's a regression of my large type_new() refactoring in bpo-43770. I wrote PR 26359 to fix it. -- ___ Python tracker

[issue44232] Crash in Objects/typeobject.c

2021-05-25 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +24951 pull_request: https://github.com/python/cpython/pull/26359 ___ Python tracker ___

[issue44232] Crash in Objects/typeobject.c

2021-05-25 Thread Ken Jin
Change by Ken Jin : -- keywords: +patch pull_requests: +24950 stage: -> patch review pull_request: https://github.com/python/cpython/pull/26358 ___ Python tracker ___

[issue44232] Crash in Objects/typeobject.c

2021-05-25 Thread Ken Jin
Ken Jin added the comment: Alright, I got a minimum reproducible example: class XBase(type): def __new__(cls, name, bases, attrs, **kwargs): attrs.pop('__module__') return super().__new__(cls, name, bases, attrs, **kwargs) class X(metaclass=XBase): ... type('A', (X, ),

[issue44232] Crash in Objects/typeobject.c

2021-05-25 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- nosy: +pablogsal priority: normal -> release blocker ___ Python tracker ___ ___

[issue44232] Crash in Objects/typeobject.c

2021-05-25 Thread Ken Jin
Ken Jin added the comment: Can you please try removing the `assert(type != NULL);` line at https://github.com/python/cpython/blob/main/Objects/typeobject.c#L3313 and see if it works for you? I suspect that `winner->tp_new()` may sometimes fail and *should* return NULL to indicate that in

[issue44232] Crash in Objects/typeobject.c

2021-05-25 Thread Mariusz Felisiak
New submission from Mariusz Felisiak : We noticed a behavior change in [1]. One of our tests `apps.tests.AppsTests.test_model_clash()`[2] crashes with: python: Objects/typeobject.c:3219: type_new: Assertion `type != NULL' failed. Fatal Python error: Aborted Current thread 0x7ffa6951a280