Ariel Glenn added the comment:
Verified that with AF_INET instead of AF_UNSPEC I get the error from my c
program. I'll take this to the glibc folks and see what's up. Thanks.
--
___
Python tracker rep...@bugs.python.org
New submission from Vladimir Kerimov:
In the file _io\fileio.c in function
static PyObject *
fileio_readall(fileio *self)
this code is incorrect and crashes the process of Python:
if (_PyBytes_Resize(result, newsize) 0) {
if (total == 0) {
New submission from Serhiy Storchaka:
import io, _pyio
io.StringIO('a\nb\r\nc\rd', newline=None)
_io.StringIO object at 0xb707c734
io.StringIO('a\nb\r\nc\rd', newline=None).getvalue()
'a\nb\nc\nd'
_pyio.StringIO('a\nb\r\nc\rd', newline=None).getvalue()
'a\nb\r\nc\rd'
s =
Serhiy Storchaka added the comment:
Thanks Victor.
--
assignee: - serhiy.storchaka
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20424
___
___
Stefan Krah added the comment:
Terry J. Reedy rep...@bugs.python.org wrote:
and fixed fixed the first-line deletion somewhere in changes to about 30
other files.
Ah, so it was a Derby accident. Let's hope things stabilize soon.
--
___
Python
Roundup Robot added the comment:
New changeset 6ca9ba9eb76b by Serhiy Storchaka in branch '3.3':
Issue #20424: Python implementation of io.StringIO now supports lone surrogates.
http://hg.python.org/cpython/rev/6ca9ba9eb76b
New changeset 483096ef1cf6 by Serhiy Storchaka in branch 'default':
Serhiy Storchaka added the comment:
The test is backported to 2.7 in 3971e1b07af4.
--
resolution: - fixed
stage: patch review - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20424
New submission from Serhiy Storchaka:
$ ./python -m test.regrtest
/home/serhiy/py/cpython-2.7/python: No module named test.regrtest
It worked several days ago.
--
components: Tests
messages: 209630
nosy: ezio.melotti, michael.foord, pitrou, serhiy.storchaka
priority: normal
severity:
Andrew Svetlov added the comment:
Bug can be reproduced if _PyBytes_Resize fails with out-of-memory error than
NULL object decrefed.
Buggy modules are _io, binascii and zlib.
3.4 hasn't the problem.
Patch for 3.3 is attached.
Fix goes to mimic 3.4 -- (replace Py_DECREF with Py_CLEAR), while
Changes by Andrew Svetlov andrew.svet...@gmail.com:
--
keywords: +needs review
stage: - patch review
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20434
___
STINNER Victor added the comment:
Ah yes, the bytes object is set to NULL. In fact, you don't need to call
Py_CLEAR(retval) in case of error, because retval is already NULL. Could you
please update your patch to just do nothing on retval in case of error please?
3.4 hasn't the problem.
Yes,
Lars Gustäbel added the comment:
I cannot yet go into the details, because I have not tested the patch.
The comments, docstrings and quoting are not very consistent with the rest of
the module. There are a few spelling mistakes. The open_volume() method is more
or less a copy of the open()
Nick Coghlan added the comment:
Huh, I thought we did this back when Ethan was working on enum stuff, but I
guess we never figured out exactly where to put it.
Considering that question again now, I suggest adding it to the end of the
subsection on implementing descriptors, since that's when
Eduardo Robles Elvira added the comment:
I cannot yet go into the details, because I have not tested the patch.
The comments, docstrings and quoting are not very consistent with the rest of
the module. There are a few spelling mistakes.
I can try to take care of this, though it'd be best
Nick Coghlan added the comment:
Patch looks good to me.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20425
___
___
Python-bugs-list mailing
Serhiy Storchaka added the comment:
Well, good.
But I still have several nitpicks. Here is revised patch.
* Now ASCII encoding is used to test list() output. And tests now run even if
sys.stdout is a StringIO.
* test_list_verbose now test that printed files are actually separated by one
new
Nick Coghlan added the comment:
This proposal and patch look good to me. The current behaviour definitely isn't
desirable:
import inspect
inspect.Signature.from_function(1)
Traceback (most recent call last):
File stdin, line 1, in module
File /home/ncoghlan/devel/py3k/Lib/inspect.py,
R. David Murray added the comment:
Still works fine for me, and I just updated.
--
nosy: +r.david.murray
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20436
___
New submission from Serhiy Storchaka:
Some time ago Victor proposed in issue16445 a large patch (275 changes) which
replaces Py_DECREF(expr); expr = NULL; to safer Py_CLEAR(expr);. That patch
contained was so large because it included cases where expr is just a local
variable, which are safe
Changes by Serhiy Storchaka storch...@gmail.com:
Added file: http://bugs.python.org/file33795/py_clear-3.3.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20437
___
Changes by Serhiy Storchaka storch...@gmail.com:
Added file: http://bugs.python.org/file33796/py_clear-2.7.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20437
___
Changes by Serhiy Storchaka storch...@gmail.com:
--
keywords: +patch
Added file: http://bugs.python.org/file33794/py_clear-3.4.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20437
___
Serhiy Storchaka added the comment:
Patches are generated by following command:
spatch --in-place --sp-file py_clear.spatch --dir .
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20437
Serhiy Storchaka added the comment:
There are other places where Py_DECREF is called after failed
_PyBytes_Resize(). For example in PyBytes_FromObject():
if (_PyBytes_Resize(new, size) 0)
goto error;
...
error:
/* Error handling when new != NULL */
Antoine Pitrou added the comment:
Works here too. Are you sure you don't have a test.py somewhere on your path?
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20436
___
Serhiy Storchaka added the comment:
Are you sure you don't have a test.py somewhere on your path?
Oh, yes, I have.
Sorry for the noise.
--
resolution: - invalid
stage: - committed/rejected
status: open - closed
___
Python tracker
Larry Hastings added the comment:
Here's a complete patch, converts everything that I think should be converted
for 3.4. With this patch applied, all unit tests pass on my 64-bit Linux box.
I plan to also run tests with the buildbots before checking it in.
The patch... well, it's 14,000
Larry Hastings added the comment:
By the way, my plan is to turn on the file preset just before checkin. The
patch is *much* easier to read without turning that on first; with the file
preset, now you have to keep two windows in sync to compare calls to PyArg_*().
--
Larry Hastings added the comment:
LGTM. If it compiles cleanly and passes the unit test suite--which obviously
it should--you may check the 3.4 patch to trunk.
--
nosy: +larry
___
Python tracker rep...@bugs.python.org
Changes by Brian Quinlan br...@sweetapp.com:
--
assignee: - bquinlan
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20319
___
___
Python-bugs-list
Larry Hastings added the comment:
Sorry for the fresh update, but here's revision 3. Only changes:
* Gave os.access a - bool return converter.
* Fixed up a lot of whitespace. Now, major things are separated by
two empty lines, but removed whitespace between
#ifdef HAVE_SOMETHING
Yury Selivanov added the comment:
Nick, thanks for the review. Committed.
--
resolution: - fixed
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20422
___
Yury Selivanov added the comment:
Signature.from_function() and Signature.from_builtin() should both also be
documented, but we may want to wait for PEP 457 and #17373 in Python 3.5
before sorting all that out.
I would like to wait till 3.5 too. Right now both of them are sort of private
Yury Selivanov added the comment:
Thanks for the review!
--
resolution: - fixed
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20425
___
Roundup Robot added the comment:
New changeset a9fedabb69e5 by Yury Selivanov in branch 'default':
inspect.signature: Add support for decorated (wrapped) builtins #20425
http://hg.python.org/cpython/rev/a9fedabb69e5
--
nosy: +python-dev
___
Python
Roundup Robot added the comment:
New changeset ca974997280d by Yury Selivanov in branch 'default':
inspect.Signature: ensure that non-default params don't follow default ones
#20427
http://hg.python.org/cpython/rev/ca974997280d
--
nosy: +python-dev
Changes by Yury Selivanov yselivanov...@gmail.com:
--
resolution: - fixed
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20427
___
Roundup Robot added the comment:
New changeset 9433b380ad33 by Yury Selivanov in branch 'default':
inspect.Signature: Make from_builtin to raise an exception if no signature can
http://hg.python.org/cpython/rev/9433b380ad33
--
nosy: +python-dev
___
Yury Selivanov added the comment:
Committed.
Thanks for the reviews!
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17481
___
___
Changes by Yury Selivanov yselivanov...@gmail.com:
--
resolution: - fixed
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17481
___
Roundup Robot added the comment:
New changeset 0fa2750c7241 by Yury Selivanov in branch 'default':
inspect.test.getfullargspec: Add a unittest to ensure correct annotations
http://hg.python.org/cpython/rev/0fa2750c7241
--
___
Python tracker
Roundup Robot added the comment:
New changeset 6d1e8162e855 by Yury Selivanov in branch 'default':
inspect.getfullargspec: Use inspect.signature API behind the scenes #17481
http://hg.python.org/cpython/rev/6d1e8162e855
--
nosy: +python-dev
___
New submission from Yury Selivanov:
Should we finally deprecate getfullargspec? With the AC and positional-only
parameters support, getfullargspec doesn't provide full information anymore.
By deprecation I mean changing its existing note Consider using the new
Signature Object interface,
Larry Hastings added the comment:
Actually, forget about the file output preset. It wouldn't work for
posixmodule. 80% of the entry points are #ifdef conditional on platform
functionality. Which means the Clinic generated stuff needs to be #ifdef too.
It wouldn't be that hard to add the
New submission from Yury Selivanov:
The ability to fine-tune formatting of Signature (currently Signature.__str__)
might be useful for pydoc and idle.
--
assignee: yselivanov
messages: 209660
nosy: brett.cannon, larry, ncoghlan, terry.reedy, yselivanov
priority: normal
severity: normal
Serhiy Storchaka added the comment:
And here is a patch which replaces Py_XDECREF(identifier); identifier = NULL;
to Py_CLEAR(identifier); (10 replaces in 7 files). It doesn't fix any bug
(unless identifier is global variable), but makes a code a little cleaner.
Compilers should generate
Serhiy Storchaka added the comment:
The curses module also has many conditionally implemented functions.
I think Argument Clinic can detect preprocessor instructions
(#if/#ifdef/#ifndef/#else/#endif) and generate needed #if/#endif in generated
file. This would be more robust than explicitly
Changes by Charles-François Natali cf.nat...@gmail.com:
--
resolution: - invalid
stage: - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20418
___
New submission from Serhiy Storchaka:
Proposed patches replaced idiomatic code
Py_DECREF(ptr);
ptr = new_value;
to Py_REPLACE(ptr, new_value); which is expanded to
{
PyObject *__tmp__ = ptr;
ptr = new_value;
Py_DECREF(__tmp__);
}
(and same for
Changes by Serhiy Storchaka storch...@gmail.com:
Added file: http://bugs.python.org/file33803/py_replace-2.7.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20440
___
Changes by Serhiy Storchaka storch...@gmail.com:
Added file: http://bugs.python.org/file33802/py_replace-3.3.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20440
___
Changes by Serhiy Storchaka storch...@gmail.com:
--
nosy: +benjamin.peterson, georg.brandl
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20437
___
Changes by Serhiy Storchaka storch...@gmail.com:
--
keywords: +patch
Added file: http://bugs.python.org/file33801/py_replace-3.4.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20440
___
Brett Cannon added the comment:
Although I say do it in 3.5.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20438
___
___
Python-bugs-list
Brett Cannon added the comment:
I vote deprecation with no stated plans of removal
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20438
___
___
Antoine Pitrou added the comment:
Something similar was proposed in issue3081.
--
nosy: +pitrou
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20440
___
Georg Brandl added the comment:
Matthias and I agreed this isn't necessary since on the relevant distribution
it's already documented.
--
resolution: - works for me
status: open - closed
___
Python tracker rep...@bugs.python.org
Terry J. Reedy added the comment:
For an api, given that we have
formatargvalue(*getargvalues, ...)
formatargspec(*getfullargspec, ...)
we might add
formatsignature(signature, ...)
with the default being the same as str(signature).
I checked the first 80 hits at
Serhiy Storchaka added the comment:
I do not understand why that issue was closed. Probably Py_SETREF is not the
best name but this can be discussed. Adverse idea about Py_INCREF also looked
questionable. But many people supported the introduction of a macro for safe
replacement.
And now we
Brett Cannon added the comment:
It all seems like a good idea to me and I like the Py_REPLACE naming (I was
going to suggest Py_SWAP, but Py_XSWAP looks too weird to me).
--
nosy: +brett.cannon
___
Python tracker rep...@bugs.python.org
New submission from Terry J. Reedy:
My Win7, AMD64 Win7, Server 2003, but not x86 Win7 buildbot or any others that
run test
==
FAIL: test_split (test.test_tcl.TclTest)
Serhiy Storchaka added the comment:
What is Tcl/Tk patchlevel? It is reported somewhere in tests log.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20441
___
Terry J. Reedy added the comment:
I am running tcl8.5.2.1 and tk8.5.2.0 as installed by
Tools/buildbots/external.bat. I presume same for Windows buildbots. I did not
find 'tcl' or 'tk' other than in test names in the log I checked.
--
___
Python
Serhiy Storchaka added the comment:
We can steal icon from http://www.python.org/favicon.ico. It contains three
variants for different size (16, 32 and 48 pixels). Here is extracted and
converted to GIF images. Please try them and original favicon on Windows. Or
may be we even can cut larger
Yury Selivanov added the comment:
Stefan, is this one still relevant?
If it is, I can review it (I have a couple of things to improve) and push in
3.4, as it doesn't really change any API.
--
nosy: +yselivanov
versions: -Python 3.3
___
Python
Yury Selivanov added the comment:
Should this one be closed now?
FWIW, signature object validates this case now.
--
dependencies: +Argument Clinic rollup patch, 2014/01/25
nosy: +yselivanov
___
Python tracker rep...@bugs.python.org
Serhiy Storchaka added the comment:
As for desctop icon, see also issue1353344 and issue15869.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20406
___
Yury Selivanov added the comment:
Sadly, there is nothing we can do about it, as we simply don't have absolute
paths in __file__ attributes in your case.
--
nosy: +yselivanov
resolution: - rejected
status: open - closed
___
Python tracker
Serhiy Storchaka added the comment:
This is a duplicate of issue19320.
--
resolution: - duplicate
superseder: - Tkinter tests ran with wantobjects is false
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20441
Serhiy Storchaka added the comment:
Terry in issue20441 reported problems with same Tcl/Tk 8.5.2.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19320
___
Yury Selivanov added the comment:
This is now fixed in #17481.
--
dependencies: +inspect.getfullargspec should use __signature__
nosy: +yselivanov
resolution: - fixed
status: open - closed
___
Python tracker rep...@bugs.python.org
Yury Selivanov added the comment:
I don't think this is a good idea, as it would require those who read with the
code to know about this default. Explicit is definitely better than implicit in
this case.
--
nosy: +yselivanov
resolution: - rejected
status: open - closed
New submission from Yury Selivanov:
inspect.Signature inspect.Parameter classes lack clear documentation about
their constructors. Patch is attached.
--
files: signature_docs_01.patch
keywords: patch
messages: 209684
nosy: eric.araujo, ezio.melotti, georg.brandl, larry, ncoghlan,
Terry J. Reedy added the comment:
Older issue has more patches and more discussion.
--
nosy: +terry.reedy
resolution: - duplicate
stage: - committed/rejected
status: open - closed
superseder: - python.desktop
___
Python tracker
Terry J. Reedy added the comment:
I just closed #15869 as a duplicate of this. I has another patch and possibly
useful discussion.
To move forward, a concrete repository patch is needed. I only see here pieces
of such a patch. I do not know how much of the Windows installation files are
in
Antoine Pitrou added the comment:
Nice work, LGTM!
--
nosy: +pitrou
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20437
___
___
Python-bugs-list
Changes by Jeremy Kloth jeremy.kloth+python-trac...@gmail.com:
--
nosy: +jkloth
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20441
___
___
Changes by Jeremy Kloth jeremy.kloth+python-trac...@gmail.com:
--
nosy: +jkloth
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19320
___
___
Terry J. Reedy added the comment:
On current 3.3.4 and 3.4.0 start menus, clicking Module Docs does nothing that
I can see except add a useless entry to the Frequent Programs list.
I think the entry should be removed from the menu until it is made to work. All
it does now is frustrate people
Changes by Antoine Pitrou pit...@free.fr:
--
versions: -Python 2.7
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20373
___
___
Python-bugs-list
Antoine Pitrou added the comment:
There's not much point in changing the 2.7 tests at this point. It's reasonable
to change both 3.3 and 3.x, so as to avoid divergence.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20373
Roundup Robot added the comment:
New changeset d844b31471b5 by Antoine Pitrou in branch '3.3':
Issue #20373: generalize use of test.script_helper in test_warnings. Patch by
Arfrever.
http://hg.python.org/cpython/rev/d844b31471b5
New changeset 04b658b3fe7c by Antoine Pitrou in branch
Antoine Pitrou added the comment:
Thanks for the patch!
--
resolution: - fixed
stage: patch review - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20373
Terry J. Reedy added the comment:
Martin: is the medium 'python logo on white page' icon used in the Start menu
in the repository or otherwise accessible? If not, could you upload it?
---
I closed #15869 in favor of #1353344.
Tk does not load .ico files (I tried). idle.gif is 16x16 because
Nick Coghlan added the comment:
As Brett said - let's do a documented deprecation in 3.5.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20438
___
Changes by Yury Selivanov yselivanov...@gmail.com:
--
versions: +Python 3.5 -Python 3.4
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20438
___
R. David Murray added the comment:
Note that this is fixed in 3.4. That is, in 3.4 __file__ paths are made
absolute when the import happens.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15931
Yury Selivanov added the comment:
Hm, maybe just for the imports? This simple script, run it directly:
test.py:
def foo(): pass
print(foo.__code__.co_filename)
$ python3.4 test.py will still print relative path test.py.
Hence, if you do 'os.chdir' in the above script, the introspection
Arfrever Frehtes Taifersar Arahesis added the comment:
Some distributions have policies about not bundling external code.
ensurepip currently bundles some versions of setuptools and pip.
--
___
Python tracker rep...@bugs.python.org
Donald Stufft added the comment:
Yes I am aware of that. However ensurepip is also required to maintain
functionality of the venv module in 3.4. See the guidelines in
http://www.python.org/dev/peps/pep-0453/#recommendations-for-downstream-distributors
which explicitly mentions the fact that
R. David Murray added the comment:
__file__ is absolute for imports, yes. I didn't check co_filename, maybe that
needs to be fixed too.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15931
Yury Selivanov added the comment:
Yes. I'll create an issue for that.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15931
___
___
New submission from Yury Selivanov:
There are many issues on tracker related to the relative paths in co_filename.
Most of them are about introspection functions in inspect module--which are
usually broken after 'os.chdir'.
Test case: create a file t.py:
def foo(): pass
Changes by Yury Selivanov yselivanov...@gmail.com:
--
nosy: +ncoghlan
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20443
___
___
Python-bugs-list
Yury Selivanov added the comment:
Can we still merge this in 3.4?
--
nosy: +yselivanov
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16991
___
___
Changes by dongwm ciici...@gmail.com:
--
components: Library (Lib)
files: logging_config.patch
keywords: patch
nosy: dongwm
priority: normal
severity: normal
status: open
title: Reduce logging.config.Converting duplication of code
type: enhancement
versions: Python 2.7
Added file:
Raymond Hettinger added the comment:
Unless some known bugs are being fixed, this should be 3.4 only.
--
nosy: +rhettinger
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20440
___
Larry Hastings added the comment:
That's a really good idea! I'm still thinking about how I'd do it, but I think
I'm gonna give it a try.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20170
Changes by Yury Selivanov yselivanov...@gmail.com:
--
resolution: - fixed
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20442
___
Roundup Robot added the comment:
New changeset 0a3201aab2b8 by Yury Selivanov in branch 'default':
inspect.docs: Document constructors for Signature Parameter #20442
http://hg.python.org/cpython/rev/0a3201aab2b8
New changeset 885c709d0dde by Yury Selivanov in branch '3.3':
inspect.docs:
1 - 100 of 106 matches
Mail list logo