Roundup Robot added the comment:
New changeset 949acdd43b45 by Larry Hastings in branch 'default':
Issue #20292: Small bug fix for Argument Clinic supporting format units
http://hg.python.org/cpython/rev/949acdd43b45
--
nosy: +python-dev
___
Python
Larry Hastings added the comment:
Thanks for the report! It's fixed now. Sorry about that!
--
assignee: - larry
components: +Demos and Tools -Build
resolution: - fixed
stage: - committed/rejected
status: open - closed
___
Python tracker
Larry Hastings added the comment:
That macro, STRFTIME_FORMAT_CODES, is only used in two functions. If it were
me I'd just copy and paste the text into both functions.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20177
Larry Hastings added the comment:
I think these shouldn't be int, they should be bool. bool will allow you
to use a default of False. It maps to the p format unit, which was new in
3.3.
Back before 3.3, when someone wanted a boolean they just used i, and relied
on the fact that True turned
Larry Hastings added the comment:
I have a couple big patches incoming, over the next couple of days. Here's a
sneak-peek of my todo list:
* buffer support just went in (#20287)
* all builtins support landing maybe tomorrow (#20260)
* suppress the self parameter on impl for METH_STATIC
*
New submission from Serhiy Storchaka:
With patch for the zlib module (issue20193) which uses the unspecified
default value:
$ ./python -m pydoc zlib
Traceback (most recent call last):
File /home/serhiy/py/cpython/Lib/inspect.py, line 1997, in wrap_value
value = eval(s, module_dict)
New submission from Serhiy Storchaka:
Currently Argument Clinic doesn't support the __init__ methods, mainly because
the C implementation of this method should return int, not PyObject *. In some
cases it is possible to wrap a function generated by Argument Clinic (as in
Modules/_pickle.c).
Changes by Serhiy Storchaka storch...@gmail.com:
--
dependencies: +Argument Clinic: add support for __init__, pydoc fails with the
unspecified default value
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20193
Changes by Serhiy Storchaka storch...@gmail.com:
Removed file: http://bugs.python.org/file33369/lzma_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20193
___
Changes by Serhiy Storchaka storch...@gmail.com:
Removed file: http://bugs.python.org/file33368/bz2_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20193
___
Changes by Serhiy Storchaka storch...@gmail.com:
Removed file: http://bugs.python.org/file33370/zlib_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20193
___
Changes by Serhiy Storchaka storch...@gmail.com:
Removed file: http://bugs.python.org/file8/etree_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20159
___
Changes by Serhiy Storchaka storch...@gmail.com:
Removed file: http://bugs.python.org/file33355/etree_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20159
___
Changes by Serhiy Storchaka storch...@gmail.com:
Added file: http://bugs.python.org/file33526/etree_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20159
___
Changes by Serhiy Storchaka storch...@gmail.com:
Removed file: http://bugs.python.org/file33329/sre_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20148
___
Changes by Serhiy Storchaka storch...@gmail.com:
Removed file: http://bugs.python.org/file33353/sre_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20148
___
Serhiy Storchaka added the comment:
Now all methods except Match.group() (which needs *args) use Argument Clinic.
Most important change is that first parameters of some Pattern methods are
renamed from pattern or source to string. This was obvious bug
(issue20283). string conforms to the
Changes by Serhiy Storchaka storch...@gmail.com:
--
stage: - patch review
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20148
___
___
Serhiy Storchaka added the comment:
Here is a patch.
--
keywords: +patch
nosy: +gpolo
stage: - patch review
Added file: http://bugs.python.org/file33528/tkinter_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20168
Changes by Serhiy Storchaka storch...@gmail.com:
Removed file: http://bugs.python.org/file2/binascii_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20151
___
Changes by Serhiy Storchaka storch...@gmail.com:
Removed file: http://bugs.python.org/file33354/binascii_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20151
___
Changes by Serhiy Storchaka storch...@gmail.com:
Added file: http://bugs.python.org/file33529/binascii_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20151
___
Changes by Serhiy Storchaka storch...@gmail.com:
Removed file: http://bugs.python.org/file33320/audioop_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20133
___
Changes by Serhiy Storchaka storch...@gmail.com:
Removed file: http://bugs.python.org/file33352/audioop_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20133
___
Changes by Serhiy Storchaka storch...@gmail.com:
Removed file: http://bugs.python.org/file33461/audioop_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20133
___
Changes by Serhiy Storchaka storch...@gmail.com:
Added file: http://bugs.python.org/file33530/audioop_clinic.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20133
___
Roundup Robot added the comment:
New changeset 8edb892f4d69 by Serhiy Storchaka in branch '2.7':
Issue #20245: The open functions in the tarfile module now correctly handle
empty mode.
http://hg.python.org/cpython/rev/8edb892f4d69
New changeset 8ef1fd952410 by Serhiy Storchaka in branch '3.3':
Roundup Robot added the comment:
New changeset 5c69332dc3b0 by Serhiy Storchaka in branch '3.3':
Issue #20238: TarFile opened with external fileobj and w:gz mode didn't
http://hg.python.org/cpython/rev/5c69332dc3b0
New changeset e154b93f3857 by Serhiy Storchaka in branch 'default':
Issue
Roundup Robot added the comment:
New changeset 61b6accbca9f by Serhiy Storchaka in branch '2.7':
Issue #20243: TarFile no longer raise ReadError when opened in write mode.
http://hg.python.org/cpython/rev/61b6accbca9f
New changeset 2f3b47b63f91 by Serhiy Storchaka in branch '3.3':
Issue #20243:
Roundup Robot added the comment:
New changeset 05d186a1a367 by Serhiy Storchaka in branch '3.3':
Issue #20244: Fixed possible file leaks when unexpected error raised in
http://hg.python.org/cpython/rev/05d186a1a367
New changeset 0386cde12657 by Serhiy Storchaka in branch 'default':
Issue
Changes by Yury Selivanov yseliva...@gmail.com:
--
nosy: +terry.reedy
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17481
___
___
Python-bugs-list
Changes by Serhiy Storchaka storch...@gmail.com:
--
resolution: - fixed
stage: patch review - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20245
Changes by Serhiy Storchaka storch...@gmail.com:
--
resolution: - fixed
stage: patch review - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20238
Changes by Serhiy Storchaka storch...@gmail.com:
--
resolution: - fixed
stage: patch review - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20243
Serhiy Storchaka added the comment:
As for 2.7, I suppose it have file leaks even when expected exception is
raised. 2.7 needs more tests and perhaps changes for GzipFile. This was not
fixed in issue11513 and is not fixed here.
--
resolution: - fixed
stage: patch review -
Roundup Robot added the comment:
New changeset a4a51a0d4575 by Serhiy Storchaka in branch '2.7':
Issue #20270: urllib and urlparse now support empty ports.
http://hg.python.org/cpython/rev/a4a51a0d4575
New changeset 52edc7087c81 by Serhiy Storchaka in branch '3.3':
Issue #20270: urllib.urlparse
Changes by Serhiy Storchaka storch...@gmail.com:
--
resolution: - fixed
stage: patch review - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20270
Larry Hastings added the comment:
Just checking--that happens with current trunk? Revision 32f9e0ae23f7 or newer?
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20293
___
Larry Hastings added the comment:
Oh! I thought it worked fine, because I've seen people convert both an
__init__ and a __new__. But I guess they wrapped them.
It's an easy change, I can try to do that today.
--
assignee: - larry
___
Python
Serhiy Storchaka added the comment:
That happens with current trunk (revision 1469c4fde8cd) and a patch for zlib
from issue20193 [1].
[1] http://bugs.python.org/file33523/zlib_clinic.patch
--
___
Python tracker rep...@bugs.python.org
Serhiy Storchaka added the comment:
I take it.
--
assignee: - serhiy.storchaka
nosy: +serhiy.storchaka
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20171
___
New submission from Martin Vignali:
Add support for detect openexr file (http://www.openexr.com/)
Based on information provided by :
http://www.openexr.com/ReadingAndWritingImageFiles.pdf
I make some tests, on different kind of exr file, to check, the new function.
--
components:
New submission from Rob Browning:
Here (http://docs.python.org/2/c-api/arg.html), the documentation for t# says:
t# (read-only character buffer) [char *, int]...
while the documentation for w# says:
w# (read-write character buffer) [char *, Py_ssize_t]...
However, from getargs.c, it
Larry Hastings added the comment:
I just built from a new clone of trunk, and it works fine for me. I didn't see
the exception you report--I get the documentation for zlib.
Do you still get the error if you build from a new clone of the current trunk?
--
Larry Hastings added the comment:
* As is probably expected, __init__ and __call__ procs
can't be converted.
I should have a fix in for __init__ and __call__ later today. (Issue #20294.)
For the record, you could convert them, you just had to wrap the parsing
function
to deal with the
Larry Hastings added the comment:
Oops, sorry, that last comment was intended for a different issue. Please
ignore, and sorry for the spam!
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20294
Larry Hastings added the comment:
Larry Hastings added the comment:
* As is probably expected, __init__ and __call__ procs
can't be converted.
I should have a fix in for __init__ and __call__ later today. (Issue #20294.)
For the record, you could convert them, you just had to wrap the
Roundup Robot added the comment:
New changeset 9fe32328a573 by R David Murray in branch '2.7':
#19855: restore use of LC_ALL, not LC_MESSAGES
http://hg.python.org/cpython/rev/9fe32328a573
New changeset 706354c4d8f5 by R David Murray in branch '3.3':
#19855: restore use of LC_ALL, not
Terry J. Reedy added the comment:
While I plan to change Idle code to use signature directly, instead of
getfullargspec, I agree that changing inspect also, and in 3.4, is a good idea.
It may, however, affect tests other than Idle's, if there are any other stdlib
consumers. I will try to look
Ryan Smith-Roberts added the comment:
I believe the feature you starred resolves this enhancement issue, in which
case my patches are obsolete. And yes, the 'as' syntax makes a lot more sense.
Here's how I hope it works (the arg parsing wrapper remains unchanged):
foo: int
...
_impl(...,
New submission from Glenn Langford:
as_completed() calls _create_and_install_waiters() over all given Futures, even
if some (or all) of the Futures have already completed.
The following fragment of the as_completed code (from 3.3.3):
with _AcquireFutures(fs):
finished = set(
Larry Hastings added the comment:
On 01/18/2014 01:12 PM, Ryan Smith-Roberts wrote:
Ryan Smith-Roberts added the comment:
I believe the feature you starred resolves this enhancement issue, in which
case my patches are obsolete. And yes, the 'as' syntax makes a lot more
sense. Here's how I
Nikolaus Rath added the comment:
Thanks for looking at this! Attached is an updated patch with testcase (sorry,
I thought I had included testcases everywhere).
--
Added file: http://bugs.python.org/file33532/issue18574_rev2.patch
___
Python tracker
Ryan Smith-Roberts added the comment:
Yes, that makes more sense. The specific syntax is nearly irrelevant compared
to the feature existing at all. You still haven't indicated whether your
starred feature matches the *result* that I outlined. Does it?
--
Stefan Krah added the comment:
One test fails on FreeBSD 9.0 and 6.4:
==
ERROR: testRecvFromIntoSmallBuffer (test.test_socket.BufferIOTest)
--
Traceback (most
Nikolaus Rath added the comment:
Indeed, this makes most sense. I didn't know that glossary entry existed. I
have attached an updated patch. Thanks for reviewing!
--
Added file: http://bugs.python.org/file33533/issue17811_rev2.patch
___
Python
Changes by Nikolaus Rath nikol...@rath.org:
--
versions: -Python 3.5
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17811
___
___
Python-bugs-list
Nikolaus Rath added the comment:
Will do. Another question: what should I do with return annotations, e.g. the
- dict part in
get_clock_info(name: str) - dict\n
Should I drop that part? In the clinic howto, I couldn't find anything about
return annotations (only that parameter annotations
Changes by Serhiy Storchaka storch...@gmail.com:
--
nosy: -serhiy.storchaka
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20227
___
___
Nikolaus Rath added the comment:
One more question: what's a good way to find sites that need changes? Searching
for PyArg_ finds both converted and unconverted functions...
--
___
Python tracker rep...@bugs.python.org
Larry Hastings added the comment:
Yes, you should drop things that look like return annotations in the original
docstring.
I don't have a magic formula for finding unchanged functions, sorry.
--
___
Python tracker rep...@bugs.python.org
Ryan Smith-Roberts added the comment:
I saw the fix for this in the commit stream. Closing.
--
resolution: - fixed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20252
___
Changes by Ryan Smith-Roberts r...@lab.net:
--
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20252
___
___
Python-bugs-list
Ryan Smith-Roberts added the comment:
Perhaps the test is sending an infeasibly large message. If you remove the
'*2048' does it pass? (I set up a FreeBSD 9.2 amd64 VM but all tests are
passing here).
--
___
Python tracker rep...@bugs.python.org
Nikolaus Rath added the comment:
Here is a patch for timemodule.c. I have converted everything except:
* ctime() uses the gettmarg() function. Converting gettmarg() itself doesn't
seem possible to me (because it's not Python callable), and duplicating the
functionality in a single
Changes by Nikolaus Rath nikol...@rath.org:
Removed file: http://bugs.python.org/file33521/issue20177.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20177
___
New submission from David Barnett:
Many sloppy JSON APIs return data with poorly-encoded strings, either with
single-quotes as delimiters:
{'foo': 'bar'}
or with no delimiters at all on keys:
{foo: 'bar'}
The json library is useless for making sense of this data, because all it will
tell
Tal Einat added the comment:
I'm attaching my conversion of deque.rotate and _count_elements in
Modules/_collectionsmodule.c.
There remain 3 other functions in that module to be converted.
One is deque_init which returns int; Larry said (on IRC) to hold off with that
for now.
The other two
Roundup Robot added the comment:
New changeset 093ab6c02ff4 by Benjamin Peterson in branch '3.3':
fix handling of 100-continue status code (closes #18574)
http://hg.python.org/cpython/rev/093ab6c02ff4
New changeset 20a2597d6653 by Benjamin Peterson in branch 'default':
merge 3.3 (#18574)
Terry J. Reedy added the comment:
Attached patch moves all tests, changed (and simplified) to call get_argspec
directly. I will apply after I get tk 8.6 to test with 3.4.
--
Added file: http://bugs.python.org/file33536/test_calltips-33.diff
___
Nikolaus Rath added the comment:
I just realized that the Misc/NEWS entry is just utterly wrong (it is talking
abou the client, even though the bug is in the server), my apologies. Here's a
fixed one:
- Issue #18574: Added missing newline in 100-Continue reply from
Nick Coghlan added the comment:
Aye, I agree with Terry that this is a behavioural bug introduced with the new
partialmethod feature - we missed adding a new test case to check that
inspect.signature handled it properly.
Reviewing the patch now.
--
Roundup Robot added the comment:
New changeset d00ed6e7a823 by Benjamin Peterson in branch '3.3':
correct news entry for #18574
http://hg.python.org/cpython/rev/d00ed6e7a823
New changeset cf0678c3b735 by Benjamin Peterson in branch 'default':
merge 3.3 (#18574)
Nick Coghlan added the comment:
I upgraded the description to a should. Argument Clinic and other changes in
Python 3.4 greatly improve introspection support for various aspects of the
runtime and standard library (for example, issue 20223 will handle the new
functools.partialmethod support).
Roundup Robot added the comment:
New changeset 8b413f813a13 by Benjamin Peterson in branch '3.3':
improve description of buffers argument for readv/writev (closes #17811)
http://hg.python.org/cpython/rev/8b413f813a13
New changeset 4d56006133f1 by Benjamin Peterson in branch 'default':
merge 3.3
Nikolaus Rath added the comment:
Hmm. After reading some of the threads on python-dev, I'm now confused if I did
the conversion of optional arguments correctly.
Should something like strftime(format[, tuple]) be converted using optional
groups, or should tuple become a parameter with a
Larry Hastings added the comment:
If we modify inspect.getfullargspec, shouldn't we modify inspect.getargspec
too? deprecated doesn't mean unsupported, it means not recommended for
new code, please stop using it.
--
___
Python tracker
Larry Hastings added the comment:
Optional groups really are only for cases when that's the behavior
of the original code. If the original function used a switch statement
examining the size of the tuple, then had different parsing functions based on
that size, use optional groups.
But if the
Yury Selivanov added the comment:
Larry,
getargspec uses getfullargspec, so it's covered.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17481
___
Nick Coghlan added the comment:
getargspec() is just a thin wrapper around getfullargspec(), so we get that for
free.
Similarly, getcallargs() is also implicitly updated to full PEP 362 support by
changing the implementation of getfullargspec().
The other two standard library consumers
Larry Hastings added the comment:
Here's a patch. Wasn't as easy as I thought, it kind of took all day.
Changes include:
* __init__ and __new__ always take kwargs.
* if the function signature doesn't accept keyword arguments,
it calls _PyArg_NoKeywords().
* __init__ returns int, not
Nikolaus Rath added the comment:
I can confirm this. The actual problem is that neither XML nor SGML PIs in the
input make it into the etree, and no events are generated for them during
incremental parsing.
XML PIs that are added into the tree using Python functions are correctly
written
Changes by Nikolaus Rath nikol...@rath.org:
--
title: xml.etree.ElementTree strips XML declaration and procesing instructions
- xml.etree.ElementTree skips processing instructions when parsing
___
Python tracker rep...@bugs.python.org
Zachary Ware added the comment:
Problems 1 (ValueError from help(os)) and 2 ('module' as first param) were
simple fixes:
The attached patch fixes problem 1 (and is probably worth doing anyway, since
inspect.signature has the ability to raise ValueError, and (IMO) help(module)
should never
New submission from Ryan Smith-Roberts:
The docs indicate that you can do:
class foo_converter(CConverter):
...
c_default = 'bar()'
py_default = 'Bar'
except that CConverter.__init__() unconditionally overwrites these values.
Patch attached.
--
components: Build
files:
New submission from Ryan Smith-Roberts:
If a custom converter declares both default and converter class attributes, you
get this exception (test file attached):
Exception raised during parsing:
Traceback (most recent call last):
File Tools/clinic/clinic.py, line 1445, in parse
Changes by Ryan Smith-Roberts r...@lab.net:
--
components: +Build
type: - crash
versions: +Python 3.4
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20300
___
Changes by Ryan Smith-Roberts r...@lab.net:
--
nosy: +Nikratio
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20299
___
___
Python-bugs-list
Roundup Robot added the comment:
New changeset 8f11493cf727 by Larry Hastings in branch 'default':
Issue #20299: Argument Clinic custom converters may now change the default
http://hg.python.org/cpython/rev/8f11493cf727
--
nosy: +python-dev
___
Changes by Larry Hastings la...@hastings.org:
--
assignee: - larry
resolution: - fixed
stage: - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20299
Larry Hastings added the comment:
Checked in. Thanks for the report, and the patch!
I worked so quickly, I just realized, I didn't credit you in the NEWS
file for the fix. Do you want me to fix that?
--
___
Python tracker rep...@bugs.python.org
Zachary Ware added the comment:
Rietveld doesn't like the patch and I'm having a hard time finding a changeset
on which I can get it to apply cleanly. May I suggest avoiding `--git` on `hg
diff` unless copying/moving/renaming a file?
--
nosy: +zach.ware
Ryan Smith-Roberts added the comment:
No, I'm happy. It isn't really news anyway, since the patch just brings reality
inline with the docs :).
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20299
Larry Hastings added the comment:
Whoops, that doesn't apply cleanly. Here's an updated patch.
--
Added file:
http://bugs.python.org/file33542/larry.argument.clinic.init.and.new.patch.2.txt
___
Python tracker rep...@bugs.python.org
Changes by Berker Peksag berker.pek...@gmail.com:
--
nosy: +berker.peksag
stage: - patch review
versions: +Python 3.5 -Python 3.4
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20295
___
Terry J. Reedy added the comment:
Attached is patch for 2.7 with all tests passing. 3.x get_argspec cannot
replace 2.x get_arg_text because it uses inspect.getfullargspec, which does not
exist in 2.7. (Its use made the code simpler.) Besides minor changes in
test_calltips.py, I made 3 changes
Larry Hastings added the comment:
Your fixes for #1 and #2 were fine, I've incorporated them into the patch.
I'll update the diff after I've added the tests Nick suggested.
The assertion failure in #3 will also be gone, replaced with a failure:
You can't have two parameters named module!
Zachary Ware added the comment:
Larry Hastings added the comment:
Once I've done that, it'd be easy to make it also rename the secret self
converter name to _module or something. Anyway, long story short, let's
not try to fix #3 in this patch.
That sounds fine. _winapi is the only place
Berker Peksag added the comment:
I just built from a new clone of trunk, and it works fine for me.
It works fine for me, too (revision 8f11493cf727).
--
nosy: +berker.peksag
___
Python tracker rep...@bugs.python.org
Zachary Ware added the comment:
Output looks good and I didn't see anything that scared me in the patch, though
I can't pretend to fully understand 100% of it. Builds on Windows, pickle
tests pass, and nothing else is affected (that's checked in so far). Looks
good to me, as far as I can
1 - 100 of 103 matches
Mail list logo