[issue38037] Assertion failed: object has negative ref count

2019-09-06 Thread Joannah Nanjekye
Joannah Nanjekye added the comment: I will look after my next meeting which is in 10 minutes. In the meantime have you perused this PR : https://github.com/python/cpython/pull/15701 If it can solve this? -- ___ Python tracker

[issue38037] Assertion failed: object has negative ref count

2019-09-06 Thread STINNER Victor
STINNER Victor added the comment: This issue is a Python 3.8 regression. Joannah: Would you mind to have a look? x = DefaultHandler = PyLong_FromVoidPtr((void *)SIG_DFL); if (PyModule_AddObject(m, "SIG_DFL", x)) goto finally; This change is not easy to read. DefaultHandler m

[issue38037] Assertion failed: object has negative ref count

2019-09-05 Thread Ma Lin
Ma Lin added the comment: I did a Git bisect, this is the first bad commit: https://github.com/python/cpython/commit/9541bd321a94f13dc41163a5d7a1a847816fac84 nosy involved mates. -- nosy: +berker.peksag, nanjekyejoannah ___ Python tracker

[issue38037] Assertion failed: object has negative ref count

2019-09-05 Thread Ma Lin
Change by Ma Lin : -- keywords: +patch pull_requests: +15355 stage: -> patch review pull_request: https://github.com/python/cpython/pull/15701 ___ Python tracker ___ _

[issue38037] Assertion failed: object has negative ref count

2019-09-05 Thread Ma Lin
New submission from Ma Lin : Adding these two lines to /Objects/longobject.c will disable the "preallocated small integer pool": #define NSMALLPOSINTS 0 #define NSMALLNEGINTS 0 Then run this reproduce code (attached): from enum import IntEnum import _signal class Handl