[issue21919] Changing cls.__bases__ must ensure proper metaclass inheritance

2015-03-02 Thread Eldar Abusalimov
Eldar Abusalimov added the comment: @Mark, that OK, for the issue without a patch. :) I could make a patch, but I'm not sure whether the proposed behavior is right. It could be considered arguable, I guess... -- ___ Python tracker rep

[issue22735] Fix various crashes exposed through mro() customization

2015-02-06 Thread Eldar Abusalimov
Eldar Abusalimov added the comment: You're welcome, and thank you too for reviewing and merging it. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2015-02-05 Thread Eldar Abusalimov
Eldar Abusalimov added the comment: I feel a bit uneasy, but... any news on this? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-12-12 Thread Eldar Abusalimov
Eldar Abusalimov added the comment: ping? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735 ___ ___ Python-bugs-list mailing list Unsubscribe

[issue22735] Fix various crashes exposed through mro() customization

2014-11-07 Thread Eldar Abusalimov
Eldar Abusalimov added the comment: Thank you for your replies. I don't think forbidding reentrancy is a good idea, and I'm against it for the following reasons. First of all, naive prohibition of type_set_bases within mro() on a class doesn't save from mro() reentrancy: def mro(cls

[issue20440] Use Py_REPLACE/Py_XREPLACE macros

2014-10-30 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: -- nosy: +abusalimov ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue20440 ___ ___ Python

[issue3453] PyType_Ready doesn't ensure that all bases are ready

2014-10-28 Thread Eldar Abusalimov
Eldar Abusalimov added the comment: It is possible to get a partially initialized class from inside a custom mro(). And extending such type results in passing NULL to PySequence_List inside mro_implementation, which in turn leads to PyErr_BadInternalCall. #22735 has a test reproducing

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
New submission from Eldar Abusalimov: The attached patch fixes several bugs revealed by providing a custom mro(). Most of these bugs are reentrancy issues (mainly, cls.__bases__ assignment within mro() which causes incorrect refcounting), but there are also some issues when using incomplete

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: Added file: http://bugs.python.org/file37026/0001-minor-test_mro-test-case-stub-and-helpers.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: Added file: http://bugs.python.org/file37029/0004-minor-type_set_bases-move-undoing-logic-to-the-end.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: Added file: http://bugs.python.org/file37027/0002-test-crashers-NULL-old_mro-and-over-decref-on-reent.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: Added file: http://bugs.python.org/file37030/0005-minor-type_set_bases-extract-add_all_subclasses.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: Added file: http://bugs.python.org/file37028/0003-minor-mro_internal-extract-mro_invoke-and-mro_check.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: Added file: http://bugs.python.org/file37031/0006-minor-mro_subclasses-loop-over-a-list-of-subclasses.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Eldar Abusalimov added the comment: This is a patch with most significant changes, please review it carefully. -- Added file: http://bugs.python.org/file37032/0007-fix-handle-tp_mro-overwritten-through-reentrancy.patch ___ Python tracker rep

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: Added file: http://bugs.python.org/file37033/0008-test-crashers-tp_base-tp_subclasses-inherit-cycles.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: Added file: http://bugs.python.org/file37034/0009-minor-PyType_IsSubtype-extract-a-check-using-tp_base.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: Added file: http://bugs.python.org/file37035/0010-fix-type_set_bases-inherit-cycles-and-reent-checks.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: Added file: http://bugs.python.org/file37037/0012-minor-mro_implementation-pmerge-refactory.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: Added file: http://bugs.python.org/file37038/0013-fix-mro_implementation-check-base-tp_mro-is-not-NULL.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: Added file: http://bugs.python.org/file37036/0011-test-behavior-error-on-extending-an-incomplete-type.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: Added file: http://bugs.python.org/file37039/0014-test-crasher-attr-lookup-on-super-with-uninitialized.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Changes by Eldar Abusalimov eldar.abusali...@gmail.com: Added file: http://bugs.python.org/file37040/0015-fix-super_getattro-check-type-tp_mro-and-refactory.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue22735] Fix various crashes exposed through mro() customization

2014-10-26 Thread Eldar Abusalimov
Eldar Abusalimov added the comment: Just in case, the previous message about reviewing is about [PATCH 07/15] (fix) handle tp_mro overwritten through reentrancy -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue22735

[issue21919] Changing cls.__bases__ must ensure proper metaclass inheritance

2014-07-04 Thread Eldar Abusalimov
New submission from Eldar Abusalimov: When a new class is constructed Python checks for possible metaclass conflicts within bases and an explicitly specified one, if any, choosing the best available (the most specialized) one. That is the following implication is expected: issubclass(B