[issue31862] Port the standard library to PEP 489 multiphase initialization

2017-10-24 Thread Petr Viktorin
Petr Viktorin added the comment: FWIW, Marcel is an intern in my team, tasked to learn CPython internals by trying to improve subinterpreter support. If I don't comment on his issues it's because we discussed privately beforehand. --

[issue25083] Python can sometimes create incorrect .pyc files

2017-10-25 Thread Petr Viktorin
Petr Viktorin added the comment: tzickel, could you sign the CLA? It will formally allow PSF to distribute your patch with Python. (You retain the copyright.) See the dev guide for instructions: https://docs.python.org/devguide/pullrequest.html#cla I can't do that for you, but if you wa

[issue31901] atexit callbacks only called for current subinterpreter

2017-10-31 Thread Petr Viktorin
Petr Viktorin added the comment: I don't have a reason to think Py_Finalize is not *destroying* the other subinterpreters. But it's not calling their atexit callbacks. (Is there any reason Py_Finalize couldn't switch to the main interpreter itself? Assuming it&#

[issue31901] atexit callbacks only called for current subinterpreter

2017-10-31 Thread Petr Viktorin
Petr Viktorin added the comment: I'm not sure where the concept of "main subinterpreter" comes in, with respect to this issue. I thnik the issue of atexit callbacks could be solved by something like keeping info about each callback's subinterpreter, and switching su

[issue31338] Use abort() for code we never expect to hit

2017-11-08 Thread Petr Viktorin
Change by Petr Viktorin : -- pull_requests: +4291 ___ Python tracker <https://bugs.python.org/issue31338> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue31901] atexit callbacks only called for current subinterpreter

2017-11-08 Thread Petr Viktorin
Petr Viktorin added the comment: When you destroy a subinterpreter before Py_Finalize is called, Python can't start calling its atexit callbacks – they no longer have a subinterpreter to run in. Therefore I think callbacks for a particular subinterpreter should be called when (and only

[issue26179] Python C-API "unused-parameter" warnings

2017-11-08 Thread Petr Viktorin
Change by Petr Viktorin : -- pull_requests: +4297 ___ Python tracker <https://bugs.python.org/issue26179> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue29179] Py_UNUSED is not documented

2017-11-08 Thread Petr Viktorin
Petr Viktorin added the comment: Since the macro has a public name and is used in the wild outside CPython, I'll go ahead and submit a pull request documenting it. -- ___ Python tracker <https://bugs.python.org/is

[issue19976] Argument Clinic: generate second arg for METH_NOARGS

2017-11-08 Thread Petr Viktorin
Change by Petr Viktorin : -- pull_requests: +4296 ___ Python tracker <https://bugs.python.org/issue19976> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue29179] Py_UNUSED is not documented

2017-11-08 Thread Petr Viktorin
Change by Petr Viktorin : -- keywords: +patch pull_requests: +4295 stage: -> patch review ___ Python tracker <https://bugs.python.org/issue29179> ___ ___ Py

[issue6531] atexit_callfuncs() crashing within Py_Finalize() when using multiple interpreters.

2017-12-07 Thread Petr Viktorin
Change by Petr Viktorin : -- nosy: +Dormouse759, encukou ___ Python tracker <https://bugs.python.org/issue6531> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue32374] Document that m_traverse for multi-phase initialized modules can be called with m_state=NULL

2017-12-19 Thread Petr Viktorin
New submission from Petr Viktorin : After the create phase of multiphase initialization, the per-module state is NULL and the module object is reachable by the garbage collector. Between the create and exec phases, Python code is run and garbage collection can be triggered. So, any custom

[issue32374] Document that m_traverse for multi-phase initialized modules can be called with m_state=NULL

2017-12-19 Thread Petr Viktorin
Petr Viktorin added the comment: Marcel, could you look into this? -- nosy: +Dormouse759 ___ Python tracker <https://bugs.python.org/issue32374> ___ ___ Pytho

[issue17763] test_pydoc fails with the installed testsuite

2018-01-06 Thread Petr Viktorin
Petr Viktorin added the comment: This is caused by Brailcom's Speech Dispatcher, whose config script ran optparse on import. Apparently it was fixed in their version 0.8.6. Some references: https://github.com/brailcom/speechd/commit/1808ea1a6e840951ffde61e5a6476ccfc118ab5a

[issue32459] Capsule API usage docs are incompatible with module reloading (etc)

2018-01-09 Thread Petr Viktorin
Change by Petr Viktorin : -- nosy: +Dormouse759, encukou ___ Python tracker <https://bugs.python.org/issue32459> ___ ___ Python-bugs-list mailing list Unsub

[issue29640] _PyThreadState_Init and fork race leads to inconsistent key list

2018-01-09 Thread Petr Viktorin
Petr Viktorin added the comment: I'm a bit out of my depth here. Victor, could you chime in? The problem with Harris' patch is that, once fork() is protected by the thread lock, acquiring that lock (by e.g. calling `PyGILState_GetThisThreadState`) from an `atfork` handler hangs dea

[issue29640] _PyThreadState_Init and fork race leads to inconsistent key list

2018-01-09 Thread Petr Viktorin
Petr Viktorin added the comment: Gah! The more I look into locks & forks ... the more I learn, to put it mildly. Instead of piling on workarounds, I'll try my hand at using native thread-local storage for pthread, and avoid the locking altogether. Hopefully that can make it in as

[issue29640] _PyThreadState_Init and fork race leads to inconsistent key list

2018-01-09 Thread Petr Viktorin
Change by Petr Viktorin : -- pull_requests: +5000 stage: -> patch review ___ Python tracker <https://bugs.python.org/issue29640> ___ ___ Python-bugs-list mai

[issue29640] _PyThreadState_Init and fork race leads to inconsistent key list

2018-01-09 Thread Petr Viktorin
Petr Viktorin added the comment: WIP pull request: https://github.com/python/cpython/pull/5141 (I'll not get back to this for a few days, sadly.) -- ___ Python tracker <https://bugs.python.org/is

[issue32414] PyCapsule_Import fails when name is in the form 'package.module.capsule'

2018-05-16 Thread Petr Viktorin
Petr Viktorin added the comment: Is "package.module:namespace.attribute" worth supporting? I guess it isn't, at least for now. So Serhyi's patch will work. -- ___ Python tracker <https://bug

[issue33537] Help on importlib.resources outputs the builtin open description

2018-05-16 Thread Petr Viktorin
Change by Petr Viktorin : -- nosy: +barry ___ Python tracker <https://bugs.python.org/issue33537> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue33503] use pypi.org instead of pypi.python.org

2018-05-16 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset 51b2f6d3a3d6433b832f30d03382653f92a31cdf by Petr Viktorin (Miss Islington (bot)) in branch '3.7': bpo-33503: Fix the broken pypi link in the source and the documentation (GH-6814) (GH-6872) https://github.com/python/cpyt

[issue33503] use pypi.org instead of pypi.python.org

2018-05-16 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset e4cd12d3d338e691ab0c12a2f2f90422eee04bda by Petr Viktorin (Stéphane Wirtel) in branch '3.6': [3.6] bpo-33503: Fix the broken pypi link in the source and the documentation (GH-6814) (GH-6885) https://github.com/python/cpyt

[issue28167] remove platform.linux_distribution()

2018-05-16 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset 8b94b41ab7b12f745dea744e8940631318816935 by Petr Viktorin in branch 'master': bpo-28167: Remove platform.linux_distribution (GH-6871) https://github.com/python/cpython/commit/8b94b41ab7b12f745dea744e894063

[issue28167] remove platform.linux_distribution()

2018-05-16 Thread Petr Viktorin
Petr Viktorin added the comment: platform.linux_distribution is removed from Python 3.8. Thanks for everyone involved! If there are any complaints or other fallout you don't want to deal with, feel free to point people to me :) -- resolution: -> fixed stage: patc

[issue5286] urrlib2 digest authentication problems

2018-05-16 Thread Petr Viktorin
Petr Viktorin added the comment: I withdraw the patch (and I should have done that years ago). Nowadays, hopefully Requests does the right thing. -- resolution: -> out of date stage: test needed -> resolved status: open -> closed _

[issue33435] incorrect detection of information of some distributions

2018-05-16 Thread Petr Viktorin
Petr Viktorin added the comment: I understand that's what distro (https://github.com/nir0s/distro) is based on -- but a lot of complexity is required on top of that. -- ___ Python tracker <https://bugs.python.org/is

[issue1322] Deprecate platform.dist() and platform.linux_distribution() functions

2018-05-16 Thread Petr Viktorin
Petr Viktorin added the comment: For the record, I opened an issue on `distro` about the vicious circle of distro detection instead of feature detection: https://github.com/nir0s/distro/issues/221 -- ___ Python tracker <https://bugs.python.

[issue28167] remove platform.linux_distribution()

2018-05-20 Thread Petr Viktorin
Petr Viktorin added the comment: Thanks for closing that one. -- ___ Python tracker <https://bugs.python.org/issue28167> ___ ___ Python-bugs-list mailin

[issue29640] _PyThreadState_Init and fork race leads to inconsistent key list

2018-05-20 Thread Petr Viktorin
Petr Viktorin added the comment: pthread is not generally compatible with int, so it can't be used with Python 2's API. This was changed in py3 with PEP 539, which however makes it so that the old TLS API is only available if PTHREAD_KEY_T_IS_COMPATIBL

[issue33468] Add try-finally contextlib.contextmanager example

2018-05-20 Thread Petr Viktorin
Change by Petr Viktorin : -- nosy: +petr.viktorin ___ Python tracker <https://bugs.python.org/issue33468> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue29640] _PyThreadState_Init and fork race leads to inconsistent key list

2018-05-22 Thread Petr Viktorin
Petr Viktorin added the comment: > PTHREAD_KEY_T_IS_COMPATIBLE_WITH_INT is defined on most (pthread) platforms, > no? > I propose to cast pthread_key_create() result to int, but only define > PyThread_create_key() in Python/thread_pthread.h if > PTHREAD_KEY_T_IS_COMPATI

[issue32374] Document that m_traverse for multi-phase initialized modules can be called with m_state=NULL

2018-05-25 Thread Petr Viktorin
Petr Viktorin added the comment: > That's a weak test: if the script fails before calling > spec.loader.create_module(), the test also pass. If the function raises an > exception but don't crash, the test pass as well. That's a good argument, thanks. Marcel, would you

[issue20454] platform.linux_distribution() returns empty value on Archlinux and python 2.7

2018-05-25 Thread Petr Viktorin
Petr Viktorin added the comment: linux_distribution is removed in Python 3.7. Closing. -- nosy: +petr.viktorin resolution: -> out of date stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue19213] platform.linux_distribution detects Oracle Linux as Red Hat Enterprise Linux

2018-05-25 Thread Petr Viktorin
Petr Viktorin added the comment: linux_distribution is removed in Python 3.7. Closing. -- nosy: +petr.viktorin resolution: -> out of date stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue20454] platform.linux_distribution() returns empty value on Archlinux and python 2.7

2018-05-25 Thread Petr Viktorin
Petr Viktorin added the comment: Er, sorry, I meant in 3.8. -- ___ Python tracker <https://bugs.python.org/issue20454> ___ ___ Python-bugs-list mailing list Unsub

[issue19213] platform.linux_distribution detects Oracle Linux as Red Hat Enterprise Linux

2018-05-25 Thread Petr Viktorin
Petr Viktorin added the comment: Er, sorry, I meant in 3.8. -- ___ Python tracker <https://bugs.python.org/issue19213> ___ ___ Python-bugs-list mailing list Unsub

[issue18872] platform.linux_distribution() doesn't recognize Amazon Linux

2018-05-25 Thread Petr Viktorin
Petr Viktorin added the comment: linux_distribution is removed in Python 3.8. -- nosy: +petr.viktorin resolution: -> out of date stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue32374] Document that m_traverse for multi-phase initialized modules can be called with m_state=NULL

2018-05-28 Thread Petr Viktorin
Petr Viktorin added the comment: > That's a weak test: if the script fails before calling > spec.loader.create_module(), the test also pass. If the function raises an > exception but don't crash, the test pass as well. Marcel added PR 7145 for that -- it wraps things in

[issue32374] Document that m_traverse for multi-phase initialized modules can be called with m_state=NULL

2018-05-28 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset 08c5aca9d13b24b35faf89ebd26fc348ae1731b2 by Petr Viktorin (Marcel Plch) in branch 'master': bpo-32374: Ignore Python-level exceptions in test_bad_traverse (GH-7145) https://github.com/python/cpython/commit/08c5aca9d13b24b35faf89ebd26fc3

[issue32374] Document that m_traverse for multi-phase initialized modules can be called with m_state=NULL

2018-05-28 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset 983c1ba94aef945386001932c5744f8ce9757fec by Petr Viktorin (Miss Islington (bot)) in branch '3.7': bpo-32374: Ignore Python-level exceptions in test_bad_traverse (GH-7145) (GH-7150) https://github.com/python/cpyt

[issue33666] os.errno gone AWOL

2018-05-28 Thread Petr Viktorin
Petr Viktorin added the comment: I think this was closed prematurely. > Projects that depend on it are incorrect and should be fixed. That's definitely correct; no one here is arguing against it. However, there are projects out there depending on it -- it worked since around Python

[issue33666] Document removal of os.errno

2018-05-28 Thread Petr Viktorin
Change by Petr Viktorin : -- title: os.errno gone absent without official leave (AWOL) -> Document removal of os.errno ___ Python tracker <https://bugs.python.org/issu

[issue33666] Document removal of os.errno

2018-05-29 Thread Petr Viktorin
Petr Viktorin added the comment: Nothing there strikes me to be as prevalent or as discoverable as os.errno. -- ___ Python tracker <https://bugs.python.org/issue33

[issue33666] Document removal of os.errno

2018-05-29 Thread Petr Viktorin
Petr Viktorin added the comment: > Even if it is documented, arn't people know it by running their code on > Python 3.7? How the document help them? "What's new" is the right place to check if something breaks for you on Python 3.7. Let's make it useful.

[issue33666] Document removal of os.errno

2018-05-29 Thread Petr Viktorin
Petr Viktorin added the comment: > Actually removing re._pattern_type, uuid._uuid_generate_time and some private > names in the typing module broke several third-party projects. Those have underscores; that explicitly marks them as private/use at your own risk/will break in future ve

[issue33876] doc Mention the MicroPython implementation in Introduction

2018-06-18 Thread Petr Viktorin
Petr Viktorin added the comment: > I didn't add Cython because it's not clear to me if it's useful for creating > extension modules in a pythonesque language, or if it's also useful by it's > own. Cython only makes extensions for CPython, and uses CPytho

[issue34097] ZIP does not support timestamps before 1980

2018-07-11 Thread Petr Viktorin
New submission from Petr Viktorin : The ZIP format cannot handle times before 1980. Issue6090 provided a nice error message for trying to add such files. I'm seeing a system for reproducible builds that sets mtime to 1970 (zero UNIX timestamp), resulting in files that Python can'

[issue34097] ZIP does not support timestamps before 1980

2018-07-13 Thread Petr Viktorin
Petr Viktorin added the comment: I'm not sure the extensions will solve this problem fully. If an implementation that doesn't support these extensions, how does it handle them? For example, if Python 3.8 implements the extensions, I use py3.8 to create a zipfile containing old

[issue34097] ZIP does not support timestamps before 1980

2018-07-13 Thread Petr Viktorin
Petr Viktorin added the comment: Which third-party utilities support these? As I said, AFAIK `zip` on my system does not. I assume the loss of data is the reason we have an error now -- if that wasn't a concern, zipfile could just silently bump the timestamp to 1980. When the exten

[issue33666] Document removal of os.errno

2018-07-28 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset 1d2dafa249c7fb34f3d24e7a77d1bea02907d92b by Petr Viktorin (INADA Naoki) in branch 'master': bpo-33666: Add what's new entry for os.errno removal (GH-#8497) https://github.com/python/cpython/commit/1d2dafa249c7fb34f3d24e7a7

[issue34113] LLTRACE segv

2018-07-28 Thread Petr Viktorin
Change by Petr Viktorin : -- nosy: +petr.viktorin ___ Python tracker <https://bugs.python.org/issue34113> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue34113] LLTRACE segv

2018-07-28 Thread Petr Viktorin
Petr Viktorin added the comment: The problem here is that tracing for STACKADJ prints out the top of the stack *after* adjustment. This is OK for growing the stack, but not for shrinking it (e.g. calling STACKADJ(-3) pops off three things at once, which can leave TOP undefined when it&#

[issue23642] Interaction of ModuleSpec and C Extension Modules

2018-07-28 Thread Petr Viktorin
Change by Petr Viktorin : -- resolution: -> fixed stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue23642> ___ ___

[issue20177] Derby #8: Convert 28 sites to Argument Clinic across 2 files

2018-07-28 Thread Petr Viktorin
Change by Petr Viktorin : -- nosy: +petr.viktorin ___ Python tracker <https://bugs.python.org/issue20177> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue27201] expose the ABI name as a config variable

2018-07-28 Thread Petr Viktorin
Petr Viktorin added the comment: If Debian's talloc is fine without this, maybe we can close the issue? -- ___ Python tracker <https://bugs.python.org/is

[issue33435] incorrect detection of information of some distributions

2018-07-29 Thread Petr Viktorin
Petr Viktorin added the comment: linux_distribution has beed deprecated for a while and has been removed in GH-6871 (bpo-28167) See https://pypi.org/project/distro for distro detection. -- resolution: -> rejected stage: patch review -> resolved status: open -&g

[issue33666] Document removal of os.errno

2018-07-29 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset 78c54de575fd121d91749c2316fef1949d76fb07 by Petr Viktorin (Miss Islington (bot)) in branch '3.7': bpo-33666: Add what's new entry for os.errno removal (GH-8497) (GH-8526) https://github.com/python

[issue34309] Embedding Python; Py_Initialize / Py_Finalize cycles

2018-08-02 Thread Petr Viktorin
Petr Viktorin added the comment: PEP 489 (Multi-phase extension module initialization) makes it possible/easy to unload/reimport extension modules, in the sense of destroying/recreating the module object. The problem is that the modules needs to opt-in to supporting this, which is not

[issue34325] test_zipfile gets OverflowError in multiple buildbots

2018-08-02 Thread Petr Viktorin
Change by Petr Viktorin : -- nosy: +petr.viktorin ___ Python tracker <https://bugs.python.org/issue34325> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue34325] test_zipfile gets OverflowError in multiple buildbots

2018-08-03 Thread Petr Viktorin
Change by Petr Viktorin : -- nosy: +Dormouse759 ___ Python tracker <https://bugs.python.org/issue34325> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue34325] test_zipfile gets OverflowError in multiple buildbots

2018-08-03 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset 7b41dbad78c6b03ca2f98800a92a1977d3946643 by Petr Viktorin (Marcel Plch) in branch 'master': bpo-34325: Skip zipfile test for large timestamps when filesystem don't support them. (GH-8656) https://github.com/python

[issue32973] Importing the same extension module under multiple names breaks non-reinitialisable extension modules

2018-08-25 Thread Petr Viktorin
Petr Viktorin added the comment: That's quite problematic, since then you're sharing a mutable object across interpreters. The user can store any attribute on module objects, including e.g. Python functions that reference their original interpreter's global state, but beco

[issue6531] atexit_callfuncs() crashing within Py_Finalize() when using multiple interpreters.

2018-09-10 Thread Petr Viktorin
Change by Petr Viktorin : -- stage: patch review -> resolved status: pending -> closed ___ Python tracker <https://bugs.python.org/issue6531> ___ ___ Pyth

[issue26502] traceback.extract_tb breaks compatibility by returning FrameSummary

2018-09-10 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset 9797b7ae4496627836c55333765e10201a9840e3 by Petr Viktorin (Berker Peksag) in branch 'master': bpo-26502: Implement FrameSummary.__len__() (GH-8632) https://github.com/python/cpython/commit/9797b7ae4496627836c55333765e10

[issue25083] Python can sometimes create incorrect .pyc files

2018-09-10 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset f64c813de84011a84ca21d75a294861a9cc2dfdc by Petr Viktorin (tzickel) in branch '2.7': bpo-25083: Python can sometimes create incorrect .pyc files (GH-8449) https://github.com/python/cpython/commit/f64c813de84011a84ca21d75a29486

[issue25083] Python can sometimes create incorrect .pyc files

2018-09-10 Thread Petr Viktorin
Change by Petr Viktorin : -- stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue25083> ___ ___ Pyth

[issue34626] PEP 384's PyType_Spec and PyType_Slot are not documented

2018-09-10 Thread Petr Viktorin
New submission from Petr Viktorin : The documentation of PyType_FromSpec and PyType_FromSpecWithBases is currently not very useful. In particular, PyType_Spec and PyType_Slot are only documented in pep-0384, not in the Python docs. -- messages: 324975 nosy: petr.viktorin priority

[issue34626] PEP 384's PyType_Spec and PyType_Slot are not documented

2018-09-10 Thread Petr Viktorin
Change by Petr Viktorin : -- keywords: +patch pull_requests: +8600 stage: -> patch review ___ Python tracker <https://bugs.python.org/issue34626> ___ ___ Py

[issue26502] traceback.extract_tb breaks compatibility by returning FrameSummary

2018-09-11 Thread Petr Viktorin
Petr Viktorin added the comment: I don't think I have a good enough feel for what should, generally, go to 3.7. So take my opinion with a grain of salt. But honestly, I don't think the issue is important enough -- I've only seen one codebase affected by it, which was

[issue34595] PyUnicode_FromFormat(): add %T format for an object type name

2018-09-11 Thread Petr Viktorin
Petr Viktorin added the comment: > The PEP 399 requires that C accelerator behaves exactly as Python, [...] It does not. PEP 399 requires that that the C code must pass the same *test suite*. And error messages in particular tend to not be checked in tests. Anyway, I don't see

[issue15727] PyType_FromSpecWithBases tp_new bugfix

2018-09-11 Thread Petr Viktorin
Petr Viktorin added the comment: Converting static types to heap ones is just one of the reasons to use PyType_FromSpec*. Another ones are writing such classes from scratch, and converting pure-Python classes to C. I don't think PyObject_FailingNew is a good default for either of thos

[issue26979] The danger of PyType_FromSpec()

2018-09-11 Thread Petr Viktorin
Petr Viktorin added the comment: I don't think PEP 384 should be updated. It documents the feature as it was added, and shouldn't be used as documentation now. Instead, Python documentation should be improved to cover all of PEP 389. I submitted a pull request for that (GH-9154).

[issue26979] The danger of PyType_FromSpec()

2018-09-11 Thread Petr Viktorin
Petr Viktorin added the comment: Christian, do you have a specific example of the default tp_dealloc doing the wrong thing? -- ___ Python tracker <https://bugs.python.org/issue26

[issue33714] module can set an exception in tp_clear

2018-09-11 Thread Petr Viktorin
Petr Viktorin added the comment: I'm not sure what tp_clear should do in this situation. Other than propagating the exception to the GC, the most reasonable behavior seems to be to write the exception to stderr and ignore it -- but I think having the GC do that would be more robust. I

[issue34668] test_resource fails if test has CAP_SYS_RESOURCE but isn't root

2018-09-13 Thread Petr Viktorin
Petr Viktorin added the comment: Check also discussion on issue31132. If you agree, I'm OK with marking that one as duplicate, and removing the test. -- nosy: +petr.viktorin ___ Python tracker <https://bugs.python.org/is

[issue34668] test_resource fails if test has CAP_SYS_RESOURCE but isn't root

2018-09-13 Thread Petr Viktorin
Change by Petr Viktorin : -- resolution: -> duplicate stage: patch review -> resolved status: open -> closed superseder: -> test_prlimit from test_resource fails when building python3 inside systemd-nspawn environment ___ Python tra

[issue34635] inspect: add tools for inspecting subclasses

2018-09-13 Thread Petr Viktorin
Petr Viktorin added the comment: What's the use case for these? -- nosy: +petr.viktorin ___ Python tracker <https://bugs.python.org/issue34635> ___ ___

[issue26979] The danger of PyType_FromSpec()

2018-09-13 Thread Petr Viktorin
Petr Viktorin added the comment: Thanks! I think that explains enough of the issue. Converting static types to heap ones is just one way you can use PyType_Spec. Another is writing new types, which should work much like Python classes. So I don't think we should change the default

[issue34635] inspect: add tools for inspecting subclasses

2018-09-13 Thread Petr Viktorin
Petr Viktorin added the comment: __subclasses__ is, as Tim Peters put it [0], "just Python exposing an internal mechanism for the morbidly curious". I'd expect that not all alternative implementations of Python have something like __subclasses__ -- it's a detail of th

[issue26979] The danger of PyType_FromSpec()

2018-09-14 Thread Petr Viktorin
Petr Viktorin added the comment: 1) If I understand correctly, this problem could be solved by per-class C storage? Something like PyModuleDef.m_size / PyModule_GetState, but for classes? 2) Making PyType_GetSlot work for static types would not be trivial. All types do have the same *basic

[issue24937] Multiple problems in getters & setters in capsulethunk.h

2018-09-14 Thread Petr Viktorin
Petr Viktorin added the comment: Well, hasn't this languished for a while. I've talked with Benjamin, and he's OK with just removing the "Porting Extension Modules to Python 3" HOWTO, and replacing it by links to external guides that do a much better job at docume

[issue24937] Multiple problems in getters & setters in capsulethunk.h

2018-09-14 Thread Petr Viktorin
Change by Petr Viktorin : -- pull_requests: +8743 ___ Python tracker <https://bugs.python.org/issue24937> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue34354] Memory leak on _testCongestion

2018-09-14 Thread Petr Viktorin
Petr Viktorin added the comment: That issue has more information/discussion, and it does look like the same bug, so I'll close this one. Thank you for reporting it! -- nosy: +petr.viktorin resolution: -> duplicate stage: -> resolved status: open -> clo

[issue24056] Better expose closure, generator & coroutine status of functions

2018-09-14 Thread Petr Viktorin
Change by Petr Viktorin : -- nosy: -petr.viktorin ___ Python tracker <https://bugs.python.org/issue24056> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue33486] regen autotools related files

2018-09-14 Thread Petr Viktorin
Petr Viktorin added the comment: > If these changes are autogenerated, I would prefer that a trusted core > developer create a PR. I got the same changes in configure.ac. -- nosy: +petr.viktorin ___ Python tracker <https://bugs.p

[issue33486] regen autotools related files

2018-09-14 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset 24f684692070f53b6f6e4dc67b9fe23dbd58655f by Petr Viktorin (Eitan Adler) in branch 'master': bpo-33486: regen autotools files using autoupdate+autoreconf (GH-6853) https://github.com/python/cpython/commit/24f684692070f53b6f6e4dc67b9fe2

[issue33486] regen autotools related files

2018-09-14 Thread Petr Viktorin
Change by Petr Viktorin : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue26979] The danger of PyType_FromSpec()

2018-09-17 Thread Petr Viktorin
Petr Viktorin added the comment: Ah! It seems you don't need access to all tp_* slots of any type here, but just to PyType.tp_new – only one specific type, and only one specific slot. Specifically, you need a way to create class with a metaclass, from C. Is that right? Or was this on

[issue24937] Multiple problems in getters & setters in capsulethunk.h

2018-09-24 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset 2d3ff2b5ea6c903973f99d2155c9c1b60591dceb by Petr Viktorin in branch 'master': bpo-24937: Replace the extension module porting HOWTO by links to external projects (GH-9317) https://github.com/python/cpyt

[issue24937] Multiple problems in getters & setters in capsulethunk.h

2018-09-24 Thread Petr Viktorin
Change by Petr Viktorin : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue28604] Exception raised by python3.5 when using en_GB locale

2018-09-24 Thread Petr Viktorin
Change by Petr Viktorin : -- nosy: +vstinner ___ Python tracker <https://bugs.python.org/issue28604> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue28167] remove platform.linux_distribution()

2018-10-08 Thread Petr Viktorin
Petr Viktorin added the comment: In the recommended library, distro, real-world issues blew the code size up to 1000 lines of code and the open issue count to 15 – so while it's definitely useful, it doesn't seem either fully complete or trivial to maintain: https://github.com/ni

[issue28167] remove platform.linux_distribution()

2018-10-08 Thread Petr Viktorin
Petr Viktorin added the comment: > I wasn't aware that starting out with a PyPI module is the only accepted > process for getting functionality into stdlib. It's the main way things should get in. (Other ways exist, for example, dataclasses were added as simplification/me

[issue28167] remove platform.linux_distribution()

2018-10-08 Thread Petr Viktorin
Petr Viktorin added the comment: Actually, the scope (right balance between usefulness and maintainability) is probably the hardest real problem to solve here. PyPI lets you iterate on that. For a straight-to-stdlib module, you'd need to get it exactly right on the first

[issue32797] Tracebacks from Cython modules no longer work

2018-10-24 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset 057f4078b044325dae4af55c4c64b684edaca315 by Petr Viktorin (jdemeyer) in branch 'master': bpo-32797: improve documentation of linecache.getline (GH-9540) https://github.com/python/cpython/commit/057f4078b044325dae4af55c4c64b6

[issue34784] Heap-allocated StructSequences

2018-11-13 Thread Petr Viktorin
Petr Viktorin added the comment: New changeset 474eedfb3d1b6fecbd749f36bf4a987cf4a00b44 by Petr Viktorin (Eddie Elizondo) in branch 'master': bpo-34784: Fix PyStructSequence_NewType with heap-allocated StructSequence (GH-9665) https://github.com/python/cpyt

[issue28709] PyStructSequence_NewType is broken; makes GC type without setting Py_TPFLAGS_HEAPTYPE

2018-11-14 Thread Petr Viktorin
Petr Viktorin added the comment: Should be fixed in PR9665 (bpo-34784), thanks to Eddie Elizondo. -- nosy: +petr.viktorin ___ Python tracker <https://bugs.python.org/issue28

[issue28709] PyStructSequence_NewType is broken; makes GC type without setting Py_TPFLAGS_HEAPTYPE

2018-11-14 Thread Petr Viktorin
Change by Petr Viktorin : -- resolution: -> fixed stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue28709> ___ ___

[issue22198] Odd floor-division corner case

2014-09-07 Thread Petr Viktorin
Petr Viktorin added the comment: I tried my hand at writing a patch. I hope it is helpful. The message of the 2001 commit that introduces this says that "there's no platform-independent way to write a test case for this". I assume with @support.requires_IEEE_754 that is no

<    3   4   5   6   7   8   9   10   >