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
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
Change by Petr Viktorin :
--
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.or
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
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
Change by Petr Viktorin :
--
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.or
Change by Petr Viktorin :
--
nosy: +vstinner
___
Python tracker
<https://bugs.python.org/issue28604>
___
___
Python-bugs-list mailing list
Unsubscribe:
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
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
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
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
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
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
Change by Petr Viktorin :
--
resolution: -> fixed
stage: -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.org/issue28709>
___
___
Petr Kubat added the comment:
Is anyone still working on this? If not I would like to make this work.
Although I'm not exactly sure how to tackle this problem since the built-in
help function is defined as a wrapper around pydoc.help and so the docstring
used for printing help('
Petr Kubat added the comment:
Help at the help> prompt does work, I tested that. But if you (or anyone)
thought of a better way to fix this issue I would be glad to change it.
--
___
Python tracker
<http://bugs.python.org/issu
Petr Kubat added the comment:
I see. So calling help('help') should produce the documentation on the help()
function and typing help at the help> prompt should print the help for the
prompt.
Tricky indeed. I think I'll look at it during the day after tomorrow and post
so
Petr Dlouhý added the comment:
For anyone stuck on Python 2.x, here is an workaround (maybe it could find it's
way to documentation also):
def fix_grouping(bytestring):
try:
return unicode(bytestring)
except UnicodeDecodeError:
return bytestring.decode(&
Petr Prikryl added the comment:
Well, it is quite an old event. Anyway, I have fixed the simple example, and
launched it on Python 2.6, 2.7, 3.2, 3.3. It does not fail now. But I did not
tested it heavily.
>From my point of view, it was probably fi
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
Petr Viktorin added the comment:
Note: I signed the contributor agreement form recently, I should have a * soon.
--
___
Python tracker
<http://bugs.python.org/issue22
Changes by Petr Viktorin :
--
nosy: +encukou
___
Python tracker
<http://bugs.python.org/issue22444>
___
___
Python-bugs-list mailing list
Unsubscribe:
New submission from Petr Viktorin :
Consider this program:
import pdb
pdb.set_trace()
print ("At line 5")
print ("At line 6")
print ("At line 7")
print ("At line 8")
print ("At line 9")
When set_trace starts the debugger, I set a breakpoi
Petr Viktorin added the comment:
It doesn't matter whether the breakpoint is set from within a function
or not, but only the module-level frame is affected.
import pdb
def test():
print ("At line 4")
print ("At line 5")
print ("At line 6")
New submission from Petr Dolezal :
urllib.request.urlretrieve() does not close the file object created for
the retrieval when it fails during processing of the incoming data and
raises an exception (e.g. on HTTP 404 response). Therefore the file
remains opened until the process terminates and
New submission from Petr Dolezal :
inspect.formatargspec is not able to handle functions with keyword only
arguments without the default values (probably rare, but still allowed).
This has also impact on help command which is then unable to show proper
help page for such functions.
Offending
Changes by Petr Splichal :
--
nosy: +psss
___
Python tracker
<http://bugs.python.org/issue5753>
___
___
Python-bugs-list mailing list
Unsubscribe:
Petr Splichal added the comment:
Justin, is there any reproducer available for this issue?
Thanks!
--
nosy: +psss
___
Python tracker
<http://bugs.python.org/issue2
Petr Splichal added the comment:
Justin, is there any reproducer available for this issue?
Thanks!
--
nosy: +psss
___
Python tracker
<http://bugs.python.org/issue2
Changes by Petr Splichal :
--
nosy: +psss
___
Python tracker
<http://bugs.python.org/issue2489>
___
___
Python-bugs-list mailing list
Unsubscribe:
Petr Viktorin added the comment:
The backwards compatibility is not as strong as it could be: previously,
HAVE_LONG_LONG was defined to 1; now it's defined but empty.
At least that's the case on Fedora.
Found in the Python plugin for GCC:
https://bugzilla.redhat.com/show_bug.cgi?
New submission from Petr Viktorin:
The Py_UNUSED macro, which was added in Python 3.4, is not documented.
Is this an omission, or is it undocumented on purpose?
I can prepare a patch if it's the former.
The macro was added in: http://bugs.python.org/issue19976
and referenced in:
New submission from Petr MOTEJLEK:
Hi,
The documentation for signal.signal() clearly states that it is only supposed
to be called on MainThread
However, it does not say so for the signal.sigwait() and neither
signal.sigtimedwait()
I think this is an error on the documentation side of things
Changes by Petr Viktorin :
--
nosy: +ncoghlan
___
Python tracker
<http://bugs.python.org/issue1353344>
___
___
Python-bugs-list mailing list
Unsubscribe:
Petr Viktorin added the comment:
For the record, the magic number was changed in issue27286
--
___
Python tracker
<http://bugs.python.org/issue29514>
___
___
Pytho
Petr Viktorin added the comment:
> How would you propose to fix broken bytecodes in a bugfix be fixed if you
> can't bump the magic number?
That would depend on the situation. I can imagine that if the bug is severe
enough, the number could be bumped, after careful discussion, a
Petr Viktorin added the comment:
According to issue27286, Ubuntu 16.04LTS has the fix and uses the new magic
number. (And this is one reason undoing the change in CPython is out of the
question.)
The patch Nick mentioned is brewing at
https://github.com/encukou/cpython/commit/magic-number
Petr Viktorin added the comment:
> perhaps Petr's patch to accept both magic numbers should be submitted
> upstream so it's the default in 3.5.4+?
I don't think it can be submitted in the current state; it's a one-time hack
intended to be removed and forgotten at the
Petr Viktorin added the comment:
In Fedora also want to stay close to upstream: every downstream patch is like
an open issue, something we'd like to merge given enough time and people. But,
for a problem that:
- is fixed in the latest version (3.6)
- is getting a test to not happen
New submission from Petr MOTEJLEK:
Hello,
We discovered that SimpleXMLRPCDispatcher mangles tracebacks printed from
within the invoked RPC methods when an object that has _dispatch(method,
params) defined has been registered with it
Steps to reproduce
- use
https://docs.python.org/3.4
Changes by Petr MOTEJLEK :
--
pull_requests: +231
___
Python tracker
<http://bugs.python.org/issue29615>
___
___
Python-bugs-list mailing list
Unsubscribe:
Petr Viktorin added the comment:
Here is a proof of concept patch from Jaroslav Škarvada. It fixes the problem
by holding the mutex used for PyThread_create_key while forking.
To make it more than PoC it needs adding _PyThread_AcquireKeyLock and
_ReleaseKeyLock (similar to
New submission from Petr Viktorin:
The Py_VISIT macro (in Include/objimpl.h) does nothing if passed NULL (and did
this since its introduction). It would be nice to have this formally documented.
--
assignee: docs@python
components: Documentation
files: 0001-Doc-c-api-Clarify-that
Petr Ovtchenkov added the comment:
Matthias,
This question is really for you:
fc1903166 (doko2012-09-21 13:52:29 +0200 422) if
multiarch_path_component != '':
fc1903166 (doko2012-09-21 13:52:29 +0200 423)
add_d
Petr Ovtchenkov added the comment:
This mean that code for search in /usr/include/... in multiarch environment was
added by you in commit fc1903166 2012-09-21 13:52:29 +0200, so in my suggestion
I just don't change behaviour of you code.
As for my opinion, any additions of -I/usr/in
New submission from Petr Viktorin:
Currently, Argument Clinic generates "PyModuleDef * module" for the first
argument of module-level functions. But, the functions are passed the actual
module object, not the ModuleDef.
The correct type to use is PyObject*, which is used for modu
Changes by Petr Viktorin :
--
nosy: +encukou
___
Python tracker
<http://bugs.python.org/issue27201>
___
___
Python-bugs-list mailing list
Unsubscribe:
Petr Viktorin added the comment:
Hello,
Is there anything I can do to help get this issue resolved?
--
___
Python tracker
<http://bugs.python.org/issue27
Petr Viktorin added the comment:
The conversation seems to have stalled. Rémi, are you still working on the
patch? Should someone take over?
--
nosy: +encukou
___
Python tracker
<http://bugs.python.org/issue27
Petr Viktorin added the comment:
Hi! I'm on a tight schedule this week, so I'm not looking into this in detail.
But please let me know if you need any help and I'll raise the priority.
--
___
Python tracker
<http://bugs.pyt
Petr Viktorin added the comment:
Apologies for the delay; I missed/did not get a notification.
Alexander, I don't disagree, but I'd like my first patch to Python to not be a
refactoring. As I said, I'd like to keep this patch focused. After that I'd
like to provi
Petr Viktorin added the comment:
ping, could someone please review the patch?
--
___
Python tracker
<http://bugs.python.org/issue22198>
___
___
Python-bugs-list m
Petr Viktorin added the comment:
ping, is there anything I can do to help push the patch forward?
--
___
Python tracker
<http://bugs.python.org/issue22
Petr Viktorin added the comment:
Reported by David Gibson here:
https://bugzilla.redhat.com/show_bug.cgi?id=1201990
--
___
Python tracker
<http://bugs.python.org/issue24
New submission from Petr Viktorin:
When obtaining the signature of a bound method, inspect.signature, by default,
omits the "self" argument to the method, since it is already specified in the
bound method. However, if you create a wrapper around a bound method with
functools.upda
Petr Viktorin added the comment:
Ah, indeed. I need to create a new bytes object here after all.
Here is a fix, with a test.
Thank you Stefan!
--
Added file: http://bugs.python.org/file39546/fix-short-names.patch
___
Python tracker
<h
New submission from Petr Viktorin:
A regression in the PEP 489 implementation prevents loading extension modules
with single-character names (because length-1 bytestrings are interned).
Here is a fix. It would be great to have it in 3.5.0b2.
--
files: fix-short-names.patch
keywords
Petr Viktorin added the comment:
I've opened issue24328 for that regression.
--
___
Python tracker
<http://bugs.python.org/issue24268>
___
___
Python-bugs-l
Petr Viktorin added the comment:
And, the remaining refleak is a known issue from 2012: PyType_FromSpec-created
types with custom tp_dealloc leak references when instantiated.
See issue 16690
There's more discussion is in issue 15653
Martin v. Löwis notes:
> So I'd propose that i
New submission from Petr Viktorin:
PEP 442 added the tp_finalize member for objects, but there's no corresponding
Py_tp_finalize slot. This means that types defined using PyType_FromSpec (and
in particular, extensions using the stable ABI) can't take advantage of the new
GC fi
New submission from Petr Viktorin:
I have sent patches to 3.5 that add new stable API, and later I learned [0]
that additions should be conditional on the value of Py_LIMITED_API.
This patch adds #ifdef blocks for what was added in issues #24268 and #24345.
[0] https://mail.python.org
Petr Viktorin added the comment:
I meant "stable ABI", of course
--
title: Conditionalize 3.5 additions to the stable API -> Conditionalize 3.5
additions to the stable ABI
___
Python tracker
<http://bugs.pytho
New submission from Petr Viktorin:
The example object in the xxlimited module can be part of a reference loop (it
can contain itself), so it needs GC and tp_traverse.
The tp_dealloc hook was incorrect, and a correct version would be difficult to
generalize for something more complicated than
Petr Viktorin added the comment:
I've posted a patch that fixes the remaining refleak in issue24373.
--
___
Python tracker
<http://bugs.python.org/is
Petr Viktorin added the comment:
tp_traverse is completely orthogonal to tp_dealloc, it's needed to detect (and
then break) reference cycles like:
obj = xxlimited.Xxo()
obj.foo = obj
As for tp_finalize: yes, mentioning it in tp_dealloc docs would be good, but
I'll need
Petr Viktorin added the comment:
Since PEP 489 (Python 3.5.0b1), loaders now support create_module/exec_module.
For modules which don't use the PEP's new multi-phase init mechanism (which is
most of them, currently), load_module() does all the work and exec_module is a
no-op.
So,
Petr Viktorin added the comment:
ping; this issue can be closed.
--
___
Python tracker
<http://bugs.python.org/issue23642>
___
___
Python-bugs-list mailin
New submission from Petr Viktorin:
Hello,
Here is a patch documenting PEP 489.
I don't feel comfortable rewriting the tutorial [0] yet: before the issue with
callbacks/module state [1] is solved, which is 3.6 material, multi-phase init
is not suitable for all modules.
So everything in PE
New submission from Petr Messner:
Please, is it possible to put more information about the purpose parameter to
the documentation of ssl.create_default_context()? It's not obvious that
SERVER_AUTH should be used for client sockets and not server sockets. It took
me a while to discover
Petr Viktorin added the comment:
Thanks for the review.
I've added the explanation you suggested, and I've made the names monospace (or
linked them, where it seemed appropriate). I've also marked *NULL*s like in the
rest of the doc.
--
Added file: http://bugs.pytho
Petr Viktorin added the comment:
Yes!
Aside from the callback problem, which is left for another PEP, but limits PEP
489 usefulness in the real world :(
It turns out that one is quite a rabbit hole. I'll post my findings on that
soo
Petr Viktorin added the comment:
Verifying modules to work ith subinterpreters is tricky. What level of
assurance do you want?
Subinterpreters themselves require that you embed Python, which doesn't lend
itself to an easy example. I hope 2.6 makes the situation better.
Example code
New submission from Petr Viktorin:
When this program is invoked as a script (`python reproducer.py`), the __del__
is never called:
---
class ClassWithDel:
def __del__(self):
print('__del__ called')
a = ClassWithDel()
a.link = a
raise SystemExit(0)
---
Raising a
Changes by Petr Viktorin :
--
nosy: +encukou
___
Python tracker
<http://bugs.python.org/issue19713>
___
___
Python-bugs-list mailing list
Unsubscribe:
New submission from Petr Viktorin:
In 3.4, `imp.reload` was deprecated in favor of `importlib.reload`.
https://docs.python.org/3/library/imp.html
--
assignee: docs@python
components: Documentation
files: docs.patch
keywords: patch
messages: 247319
nosy: docs@python, encukou
New submission from Petr Viktorin:
A Python int larger than a C int but smaller than a C long is silently
truncated to int when passed to a ctypes function without C type information
attached.
Ints longer than C long fail with an OverflowError; I believe the same should
happen for numbers
Petr Viktorin added the comment:
Originally found here: https://bugzilla.redhat.com/show_bug.cgi?id=1244261
--
___
Python tracker
<http://bugs.python.org/issue24
Petr Viktorin added the comment:
Eric or me.
I'm not sure I understand the description clearly. Etienne, would it be
possible to write a smaller reproducer, that wouldn't be tied to Windows?
Or is this Windows-only behavior?
--
___
Pyth
Petr Viktorin added the comment:
Apologies for the delay; I was on vacation.
This was indeed a mistake in PEP 489 implementation. I agree with Nick on the
solution.
Here is a patch that adds exec_builtin, with implementation shared with
exec_dynamic.
--
keywords: +patch
Added file
Petr Viktorin added the comment:
Right. I think a common helper is cleaner than calling a clinic-generated
wrapper.
--
___
Python tracker
<http://bugs.python.org/issue24
Petr Viktorin added the comment:
I see some typos in aifc.py:
+_aifc_params.sampwidth.__doc__ = 'Ample width in bytes'
+_aifc_params.compname.__doc__ = ("""A human-readable version ofcompression type
Should that be "Sample width" and "of
New submission from Petr Viktorin:
In https://docs.python.org/3/howto/cporting.html#cobject-replaced-with-capsule
(added in issue13053):
1) __PyCapsule_GetField is defined as::
#define __PyCapsule_GetField(capsule, field, default_value) ...
but called as::
__PyCapsule_GetField
Petr Viktorin added the comment:
Note:
I'm including a tested (+fixed, now) copy of capsulethunk.h in my set of
Python3 C extension porting helpers, http://py3c.readthedocs.org
Unfortunately the tests can't be added to CPython, because they need to run on
Python 2.6 to be useful.
Petr Viktorin added the comment:
Thanks! I'll take good care of it :)
Give me a few days to prepare the docs change; this isn't very high priority.
--
___
Python tracker
<http://bugs.python.o
Petr Viktorin added the comment:
I'd be happy to do any further testing (modulo a vacation until this Tuesday),
but unfortunately I don't have time to dive into tkinter myself and look for
the cause.
IDLE starts normally on this box.
Also note: Fedora 23 is currently in alpha (tho
Petr Viktorin added the comment:
Indeed. I don't have access to a Windows machine, but I will try reproducing
the problem on another system.
--
___
Python tracker
<http://bugs.python.org/is
Petr Viktorin added the comment:
So, if I understand correctly, the problem is that the new imp.load_dynamic in
3.5.0b checks sys.modules, so if a module of the same name was loaded
previously, it's only reloaded, skipping the create_module step.
This patch bypasses that check, so
Petr Viktorin added the comment:
Sorry for the delay; I lost the mail notification.
I don't have a config-main.cfg file.
The last output from the test, with the print added:
test_dialog (idlelib.idle_test.test_configdialog.ConfigDialogTest) ...
('.139655680391704', 'confi
Petr Viktorin added the comment:
This patch removes capsulethunk.h from the docs, and directs the kind reader to
the py3c project, which carries a fixed and tested version of it, along with
the docs.
Larry, would you be OK with releasing capsulethunk.h under the MIT license? The
PSF license
Petr Viktorin added the comment:
As capsulethunk.h is only needed for Python 2.6 and below, which are no longer
maintained, in issue24937 we are discussing moving the header to an external
project.
--
nosy: +encukou
___
Python tracker
<h
Petr Viktorin added the comment:
Thank you for the license.
I mentioned my project mainly as a place where this code can be *tested*. I
have no problem with keeping capsulethunk.h in the Python docs, and
synchronizing the two projects if changes are made on either side. In other
words, feel
Petr Prikryl added the comment:
I have just observed behaviour for the Czech locale. I tried to avoid
collisions with stdout encoding, writing the strings into a file using UTF-8
encoding:
tzname_bug.py
--
#!python3
import time
import sys
with
Petr Prikryl added the comment:
I have worked around a bit differently -- the snippet from the code:
result = time.tzname[0]# simplified version of the original code.
# Because of the bug in Windows libraries, Python 3.3 tried to work around
# some issues. However, the shit hit
Petr Viktorin added the comment:
As it says in the docs, a "logical line that contains only spaces, tabs,
formfeeds and possibly a comment, is ignored."
If you write:
if a=b:
statement
# Comment
another statement
both statements belong to the "if" block.
In your
Petr Prikryl added the comment:
@eryksun: I see. In my case, I can set the locale before importing the time
module. However, the code (asciidoc3.py) will be used as a module, and I cannot
know if the user imported the time module or not.
Instead of your suggestion
result = result.encode
Petr Prikryl added the comment:
@eryksun: Thanks for your help. I have finaly ended with your...
"Call setlocale(LC_CTYPE, ''), and then call time.strftime('%Z') to get the
timezone name."
--
___
Python tracker
<
New submission from Petr Viktorin:
Exceptions from the decimal module are quite unfriendly:
>>> Decimal(42) / Decimal(0)
...
decimal.DivisionByZero: []
>>> huge = Decimal('9' * 99)
>>> huge.quantize(Decimal('0.1'))
...
New submission from Petr Viktorin:
Evaluating the expression f"{(lambda: 0):x}" crashes Python.
$ ./python
Python 3.6.0a0 (default, Feb 5 2016, 02:14:48)
[GCC 5.3.1 20151207 (Red Hat 5.3.1-2)] on linux
Type "help", "copyright", "credits" or "licens
Petr Viktorin added the comment:
Regarding the patch: if trailing underscores are not allowed, `0 if 1_else
1` should be illegal.
--
nosy: +encukou
___
Python tracker
<http://bugs.python.org/issue26
New submission from Petr Viktorin:
According to the docs [0], traceback.extract_tb should return 4-tuples
(filename, line number, function name, text).
[0] https://docs.python.org/3/library/traceback.html#traceback.extract_tb
Instead, since Python 3.5, it returns FrameSummary objects, which
801 - 900 of 950 matches
Mail list logo