[issue20326] Argument Clinic should use a non-error-prone syntax to mark text signatures

2014-01-30 Thread Stefan Behnel

Stefan Behnel added the comment:

I stumble over this because I had already adapted our doctests in Cython to the 
changed Py3.4 behaviour, so they started failing now because the automatic 
signature extraction was essentially reverted in CPython.

I had started to consider it a feature that CPython 3.4 was finally smart 
enough to pick up signatures from docstrings, at least for documentation 
purposes, much the same way that tools like epydoc or Sphinx do it. Cython has 
a feature to embed signatures for that reason, and so far, they happily ended 
up in __text_signature__ in Py3.4.

I understand the problem that not all of these signatures are valid Python 
signatures. What Cython currently generates certainly isn't.

The new sig= is not supported by any of the existing documentation tools. 
Having Cython follow here would mean that they would no longer be able to read 
the signatures, and it's clearly more important for the time being to keep 
*them* working nicely. This change actually facilitates that, because it leaves 
the embedded signatures untouched, so that these tools can normally pick them 
up again. So I agree that the reverted behaviour is in fact better than what 
Py3.4 previously did.

FWIW, I think the best way to go forward would be to try to find a way to map 
Cython's C signatures directly to a reasonable version of a __signature__ 
object. This hasn't appeared entirely trivial so far, but my guess is that the 
recent requirements on and improvements to the argument clinic should also have 
made this mapping a little less hard, because there are at least a bit of an 
infrastructure and some precedents around. Still, Cython's coverage of C/C++ 
types (also in signatures) is hugely broader than what ac would ever want to 
support, so we'll have to see what stumbling blocks remain on that road.

--
nosy: +scoder

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20326
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue12187] subprocess.wait() with a timeout uses polling on POSIX

2014-01-30 Thread Giampaolo Rodola'

Giampaolo Rodola' added the comment:

 The new asyncio module doesn't have this performance issue
 On Unix, the default implementation sets an handler for SIGCHLD signal which 
 calls waitpid(pid, WNOHANG) on all processes to detect process exit. But it 
 has 
 also a faster implementation which calls waitpid(-1, WNOHANG) only once.

But that is still a busy loop, no?
My understanding was that the goal of this ticket was to figure out a strategy 
to get rid of that.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue12187
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18321] Multivolume support in tarfile module

2014-01-30 Thread Lars Gustäbel

Lars Gustäbel added the comment:

At first, I'd like to take back my comment on this patch being too complex for 
too little benefit. That is no real argument.

Okay, I gave it a shot and I have a few more remarks:

The patch does not support iterating over a multi-volume tar archive, e.g. for 
TarFile.list(). You must implement this.

In my opinion, a tar archive is one logical unit even if it spans across 
multiple volumes. Thus, it is vital to have .getmembers() and .getnames() 
reflect the entirety of the archive, e.g. to support if filename in 
.getnames(). I think it could be a good idea to store the volume number along 
each TarInfo object for random-access.

By the way, which standard are you referring to? The only one I know of is 
POSIX pax which doesn't say anything about multiple volumes.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18321
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20445] HAVE_BROKEN_NICE detected incorrectly due to configure.ac typo

2014-01-30 Thread George Kouryachy

New submission from George Kouryachy:

It's declared in pyconfig.h that HAVE_BROKEN_NICE is set if nice() returns 
success/failure instead of the new priority.

But configure checks just opposite (as for 
http://hg.python.org/cpython/file/03fc7449f204/configure.ac#l4234):

  if (val1 != -1  val1 == nice(2))
exit(0);

We need val1 != nice(2) instead (to ensure that nicelevel is increased) or 
val1 == nice(2)+2 (to check increment is proper; this can be tricky in some 
cases).

--
components: Build
messages: 209712
nosy: George.Kouryachy
priority: normal
severity: normal
status: open
title: HAVE_BROKEN_NICE detected incorrectly due to configure.ac typo
type: behavior
versions: Python 2.7

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20445
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20440] Use Py_REPLACE/Py_XREPLACE macros

2014-01-30 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

 Unless some known bugs are being fixed, this should be 3.4 only.

For example here is a bug very similar to a bug fixed in issue16447.

class Nasty(str):
def __del__(self):
C.__qualname__ = other

class C:
pass

C.__qualname__ = Nasty(abc)
C.__qualname__ = normal
C.__qualname__ = normal

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20440
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20446] ipaddress: hash similarities for ipv4 and ipv6

2014-01-30 Thread flambda

New submission from flambda:

Hi,

I am a bit unsure if this is a problem but bear with me:

Using ipaddress I noticed that: 
hash(ipaddress.ip_address(0.0.0.1)) == hash(ipaddress.ip_address(::1))

which makes sense as ipaddress uses this:
(http://hg.python.org/cpython/file/default/Lib/ipaddress.py)
def __hash__(self):
return hash(hex(int(self._ip)))
as the hash.

This means that in a mixed environment (ipv4 and ipv6 addresses), hashtables 
with hash(hex(int(b))), int(b)2**32 will be filled more then tables with 
int(b)2**32 due to the ipv4 and ipv6 address space overlapping in the first 
32bits.

If this is intended behaviour, I am sorry to have bothered you.
Have a nice evening.

--
components: Interpreter Core
messages: 209714
nosy: flambda
priority: normal
severity: normal
status: open
title: ipaddress: hash similarities for ipv4 and ipv6
type: behavior
versions: Python 3.3

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20446
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20440] Use Py_REPLACE/Py_XREPLACE macros

2014-01-30 Thread Serhiy Storchaka

Changes by Serhiy Storchaka storch...@gmail.com:


--
priority: normal - high
type: behavior - crash

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20440
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20445] HAVE_BROKEN_NICE detected incorrectly due to configure.ac typo

2014-01-30 Thread George Kouryachy

George Kouryachy added the comment:

It seems to be permanent typo through all branches :(

--
versions: +Python 3.1, Python 3.2, Python 3.3, Python 3.4, Python 3.5

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20445
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20415] Could method isinstance take a list as parameter?

2014-01-30 Thread Jakub Wilk

Changes by Jakub Wilk jw...@jwilk.net:


--
nosy: +jwilk

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20415
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue12187] subprocess.wait() with a timeout uses polling on POSIX

2014-01-30 Thread STINNER Victor

STINNER Victor added the comment:

 But that is still a busy loop, no?

No, it's not. asyncio uses a selector which waits for events on file
descriptors. It uses signal.set_wakeup_fd() which writes
asynchronously on a file descriptor. So asyncio is suspended until a
file descriptor gets data.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue12187
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16202] sys.path[0] security issues

2014-01-30 Thread Jakub Wilk

Changes by Jakub Wilk jw...@jwilk.net:


--
nosy: +jwilk

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16202
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20447] doctest.debug_script: insecure use of /tmp

2014-01-30 Thread Jakub Wilk

New submission from Jakub Wilk:

The doctest.debug_script function creates temporary files in an insecure way:

srcfilename = tempfile.mktemp(.py, doctestdebug)
f = open(srcfilename, 'w')

This is already fixed for Python = 3.2, although for reasons other than 
security: issue12451

--
components: Library (Lib)
messages: 209717
nosy: jwilk
priority: normal
severity: normal
status: open
title: doctest.debug_script: insecure use of /tmp
type: security
versions: Python 2.7, Python 3.1

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20447
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20448] Adds missing backslash to devguide setup page

2014-01-30 Thread Saimadhav Heblikar

New submission from Saimadhav Heblikar:

This is a simple typofix.
On line 224 and 225,there were unescaped backslashes,which resulted in the 
external.bat and external-amd64.bat appeared as Tools\buildbotexternal.bat and 
Tools\buildbotexternal-amd64.bat respectively.
this patch escapes the two back-slashes,so that the text appears correctly as
Tools\buildbot\external.bat or Tools\buildbot\external-amd64.bat

--
components: Devguide
files: mywork.patch
keywords: patch
messages: 209718
nosy: ezio.melotti, sahutd
priority: normal
severity: normal
status: open
title: Adds missing backslash to devguide setup page
type: enhancement
versions: Python 3.4
Added file: http://bugs.python.org/file33810/mywork.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20448
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17162] Py_LIMITED_API needs a PyType_GenericDealloc

2014-01-30 Thread Martin v . Löwis

Martin v. Löwis added the comment:

If the set of slots gets extended, extensions would have to opt-in to use the 
newer slots, i.e. the availability of slot numbers should be conditional at 
compile-time.

Returning 0 for slots not supported in a version seems fine to me as well 
(after reconsideration), as this is also what you would get if you just 
recompiled the old type with the new Python headers (i.e. all fields added at 
the end are 0-initialized).

As for slots added to 3.4: it would certainly possible to add them to the 
stable ABI, if we indeed trust that they are stable (i.e. won't go away until 
4.0). That would have to be decided on a slot-by-slot case, preferably in 
individual roundup issues.

--
Added file: http://bugs.python.org/file33811/getslot2.diff

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17162
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20444] Reduce logging.config.Converting duplication of code

2014-01-30 Thread R. David Murray

Changes by R. David Murray rdmur...@bitdance.com:


--
nosy: +vinay.sajip

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20444
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20448] Adds missing backslash to devguide setup page

2014-01-30 Thread Saimadhav Heblikar

Saimadhav Heblikar added the comment:

http://hg.python.org/devguide/rev/99419f310cf1

--
resolution:  - duplicate
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20448
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue12015] possible characters in temporary file name is too few

2014-01-30 Thread Jakub Wilk

Changes by Jakub Wilk jw...@jwilk.net:


--
nosy: +jwilk

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue12015
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18673] Add O_TMPFILE to os module

2014-01-30 Thread Jakub Wilk

Changes by Jakub Wilk jw...@jwilk.net:


--
nosy: +jwilk

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18673
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20448] Adds missing backslash to devguide setup page

2014-01-30 Thread R. David Murray

Changes by R. David Murray rdmur...@bitdance.com:


--
resolution: duplicate - fixed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20448
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20449] _overlapped: read_buffer and write_buffer are misused

2014-01-30 Thread STINNER Victor

New submission from STINNER Victor:

I found an issue in overlapped.c: read_buffer and write_buffer attributes are 
defined in an union, but they are sometimes use even if the type is not good. I 
found this issue while trying to get a BrokenPipeError on Windows when the 
stdin stream of a subprocess is full but the process exited.

Could you please review attached patch, especially the change in 
Overlapped_getresult?

Another option would be to use two real attributes (remove the union), but I 
like the usage of union :-)

All Tulip unit tests of my subprocess_stream pass on Linux and Windows with the 
patch.

--
files: overlapped.patch
keywords: patch
messages: 209721
nosy: gvanrossum, haypo, larry, pitrou, sbt
priority: release blocker
severity: normal
status: open
title: _overlapped: read_buffer and write_buffer are misused
versions: Python 3.4
Added file: http://bugs.python.org/file33812/overlapped.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20449
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17162] Py_LIMITED_API needs a PyType_GenericDealloc

2014-01-30 Thread Larry Hastings

Larry Hastings added the comment:

I thought I replied to this... weird.

Do I understand correctly that it's basically impossible to write a proper 
custom deallocator in the limited API right now, because you can't get access 
to your base class's tp_free?

(If so, why didn't anybody notice?)

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17162
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17162] Py_LIMITED_API needs a PyType_GenericDealloc

2014-01-30 Thread Larry Hastings

Larry Hastings added the comment:

Also, isn't it reasonable to pass in non-heap type objects?  I realize 
supporting this would complicate the implementation a great deal.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17162
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20448] Adds missing backslash to devguide setup page

2014-01-30 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 7d95a62513ce by Zachary Ware in branch 'default':
Issue #20448: Escape backslashes.  Caught by Saimadhav Heblikar.
http://hg.python.org/devguide/rev/7d95a62513ce

--
nosy: +python-dev

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20448
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20448] Adds missing backslash to devguide setup page

2014-01-30 Thread Zachary Ware

Zachary Ware added the comment:

Actually, this was still an issue :)

Thanks for the report and patch!  If you intend to ever contribute more than 
the simplest of patches, please consider signing a contributor agreement: 
http://www.python.org/psf/contrib/

--
nosy: +zach.ware
stage:  - committed/rejected
versions:  -Python 3.4

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20448
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17159] Remove explicit type check from inspect.Signature.from_function()

2014-01-30 Thread Yury Selivanov

Yury Selivanov added the comment:

Stefan,

I'm attaching a reviewed patch--was a bit easier to rebase it on the new code 
and fix the remaining issues.

Please review.

BTW, do cython functions have __name__ attribute?

--
assignee:  - yselivanov
Added file: http://bugs.python.org/file33813/sig_func_ducktype_01.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17159
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20445] HAVE_BROKEN_NICE detected incorrectly due to configure.ac typo

2014-01-30 Thread Benjamin Peterson

Benjamin Peterson added the comment:

Are you sure? The configure test sets ac_cv_broken_nice=1 if val1 == nice(2). 
That is if the call returns the same succesful value each time.

--
nosy: +benjamin.peterson

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20445
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17159] Remove explicit type check from inspect.Signature.from_function()

2014-01-30 Thread Stefan Behnel

Stefan Behnel added the comment:

LGTM, thanks!

And works nicely with Cython:


import inspect

def test_isfunction():

 test_isfunction()
True

return inspect.isfunction(test_isfunction)

def test_signature():

 test_signature()   # doctest: +ELLIPSIS
inspect.Signature object ...

return inspect.signature(test_signature)


 BTW, do cython functions have __name__ attribute?

Yes, they have everything that can possibly be emulated (although not
everything currently contains useful information). If your question is
whether that should be tested for, too, then I'd say yes.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17159
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17159] Remove explicit type check from inspect.Signature.from_function()

2014-01-30 Thread Yury Selivanov

Yury Selivanov added the comment:

Attached is a second patch (sig_func_ducktype_02.patch), with a bit improved 
tests (and a small bug fixed).

Larry, do you think it's OK if I merge this one in 3.4? Technically, it's a 
feature that we start to support Cython functions in inspect.signature, but 
from the standpoint of the API everything is the same.

--
nosy: +larry
stage:  - patch review
type: behavior - enhancement
Added file: http://bugs.python.org/file33814/sig_func_ducktype_02.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17159
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue19320] Tkinter tests ran with wantobjects is false

2014-01-30 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Looks as dicts before 8.5.5 were converted to lists through string. Here are 
patches for 3.4 and 2.7.

--
stage: committed/rejected - patch review
Added file: http://bugs.python.org/file33815/test_tcl_split_dict-3.4.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19320
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20441] Test_tcl.TclTest.test_split(list) failures on Windows, 2.7.

2014-01-30 Thread Serhiy Storchaka

Changes by Serhiy Storchaka storch...@gmail.com:


--
stage: needs patch - committed/rejected
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20441
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue19320] Tkinter tests ran with wantobjects is false

2014-01-30 Thread Serhiy Storchaka

Changes by Serhiy Storchaka storch...@gmail.com:


Added file: http://bugs.python.org/file33816/test_tcl_split_dict-2.7.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19320
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18378] locale.getdefaultlocale() fails on Mac OS X with default language set to English

2014-01-30 Thread Ronald Oussoren

Ronald Oussoren added the comment:

I just ran into this problem myself. 

On fresh installs of OSX 10.9 LC_CTYPE is set to UTF-8 (at least for english 
language users), and now sphinx won't work :-(

Is Dimitrys patch acceptable (either as is, or with my suggestion of checking 
for sys.platform == darwin)?

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18378
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20398] stem crashes python

2014-01-30 Thread lothar

lothar added the comment:

you are right: windows native python 3.3.3 from your link runs the program 
properly - and without crashing.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20398
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20406] Use application icon for IDLE

2014-01-30 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

I think that all icons used in Windows installer are in the repository. All 
four ico-files in the PC directory contains 7 images: 16, 32 and 48 pixels size 
and 4-, 8- and 32-bits per pixel. Three of them (except PC/launcher.ico) were 
added in issue1490384.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20406
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20444] Reduce logging.config.Converting duplication of code

2014-01-30 Thread Vinay Sajip

Changes by Vinay Sajip vinay_sa...@yahoo.co.uk:


--
assignee:  - vinay.sajip
versions: +Python 3.3, Python 3.4

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20444
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20444] Reduce logging.config.Converting duplication of code

2014-01-30 Thread Roundup Robot

New submission from Roundup Robot:

New changeset 03b399c807d6 by Vinay Sajip in branch '2.7':
Issue #20444: Reduced code duplication. Thanks to dongwm for the report and 
patch.
http://hg.python.org/cpython/rev/03b399c807d6

--
nosy: +python-dev

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20444
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20444] Reduce logging.config.Converting duplication of code

2014-01-30 Thread Vinay Sajip

Vinay Sajip added the comment:

I'll keep this issue open to remind me to patch 3.3 / 3.4 at the appropriate 
time.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20444
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20450] hg touch fails on System Z Linux buildbot

2014-01-30 Thread Serhiy Storchaka

New submission from Serhiy Storchaka:

Touching generated files failed step fails on System Z Linux buildbot 
(http://buildbot.python.org/all/builders/System%20Z%20Linux%203.x/builds/1157/steps/shell/logs/stdio):

hg --config extensions.touch=Tools/hg/hgtouch.py touch -v
** unknown exception encountered, details follow
** report bug details to http://www.selenic.com/mercurial/bts
** or mercur...@selenic.com
** Mercurial Distributed SCM (version 1.0.2)
Traceback (most recent call last):
  File /usr/bin/hg, line 20, in module
mercurial.dispatch.run()
  File /usr/lib64/python2.6/site-packages/mercurial/dispatch.py, line 20, in 
run
sys.exit(dispatch(sys.argv[1:]))
  File /usr/lib64/python2.6/site-packages/mercurial/dispatch.py, line 29, in 
dispatch
return _runcatch(u, args)
  File /usr/lib64/python2.6/site-packages/mercurial/dispatch.py, line 45, in 
_runcatch
return _dispatch(ui, args)
  File /usr/lib64/python2.6/site-packages/mercurial/dispatch.py, line 299, in 
_dispatch
cmd, func, args, options, cmdoptions = _parse(lui, args)
  File /usr/lib64/python2.6/site-packages/mercurial/dispatch.py, line 187, in 
_parse
args = fancyopts.fancyopts(args, c, cmdoptions)
  File /usr/lib64/python2.6/site-packages/mercurial/fancyopts.py, line 29, in 
fancyopts
for short, name, default, comment in options:
ValueError: too many values to unpack
make: *** [touch] Error 1

I think upgrading Mercurial should fix this issue.

--
components: Tests
messages: 209736
nosy: ezio.melotti, michael.foord, pitrou, serhiy.storchaka
priority: normal
severity: normal
status: open
title: hg touch fails on System Z Linux buildbot

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20450
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20449] _overlapped: read_buffer and write_buffer are misused

2014-01-30 Thread STINNER Victor

STINNER Victor added the comment:

Patch commited as 73dbb884eb09 in Python 3.4. (No need to backport, it's a new 
module in Python 3.4).

Thanks for the review Richard.

--
resolution:  - fixed
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20449
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6478] time.tzset does not reset _strptime's locale time cache

2014-01-30 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

May be System Z Linux buildbot fails due to this bug 
(http://buildbot.python.org/all/builders/System%20Z%20Linux%203.x/builds/1154/steps/test/logs/stdio):

==
ERROR: test_strptime (test.datetimetester.TestDateTime_Pure)
--
Traceback (most recent call last):
  File 
/home/dje/cpython-buildarea/3.x.edelsohn-zlinux-z/build/Lib/test/datetimetester.py,
 line 1879, in test_strptime
dt = strptime(dtstr, %z %Z)
  File 
/home/dje/cpython-buildarea/3.x.edelsohn-zlinux-z/build/Lib/datetime.py, line 
1593, in strptime
return _strptime._strptime_datetime(cls, date_string, format)
  File 
/home/dje/cpython-buildarea/3.x.edelsohn-zlinux-z/build/Lib/_strptime.py, 
line 500, in _strptime_datetime
tt, fraction = _strptime(data_string, format)
  File 
/home/dje/cpython-buildarea/3.x.edelsohn-zlinux-z/build/Lib/_strptime.py, 
line 337, in _strptime
(data_string, format))
ValueError: time data '-0500 EST' does not match format '%z %Z'

--

--
nosy: +serhiy.storchaka

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6478
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue19856] shutil.move() can't move a directory in non-empty directory on Windows

2014-01-30 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

I suppose this patch should fix a bug on Windows.

--
keywords: +patch
stage: needs patch - patch review
Added file: http://bugs.python.org/file33817/shutil_move_dir_altsep.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19856
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18916] Various out-of-date Lock text in 3.2+

2014-01-30 Thread Christopher Welborn

Christopher Welborn added the comment:

Hello, my name is Chris Welborn (or Cj). I've been looking for opportunities to 
work on python. I figured a little Doc fix would be perfect for my first patch, 
as you originally planned. I ran the python unit-tests and `make test`, plus a 
'patchcheck'. Even though I really only changed a couple strings, I wanted to 
be sure. I hope this patch is acceptable, but if it's not I would be glad to 
tidy it up in whatever way you see fit.

Thanks for leaving this for someone like me :)

-Cj

--
keywords: +patch
nosy: +cjwelborn
Added file: http://bugs.python.org/file33818/threading.lock.docs.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18916
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20319] concurrent.futures.wait() can block forever even if Futures have completed

2014-01-30 Thread Glenn Langford

Glenn Langford added the comment:

An idea for a different possible fix - rather than cleaning up waiters in 
wait() and as_completed(), could they be removed in Future.set_result() and 
Futures.set_exception() ? 

I'm not certain if any waiter should ever be notified twice; if not, perhaps 
set_result() and set_exception() could just include

self._waiters = []

after all waiters have been signalled.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20319
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20398] stem crashes python

2014-01-30 Thread Antoine Pitrou

Antoine Pitrou added the comment:

Thanks for the feedback! Then I suggest you report the issue to the cygwin 
Python packagers.

--
resolution:  - invalid
stage:  - committed/rejected
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20398
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue2292] Missing *-unpacking generalizations

2014-01-30 Thread Chris Angelico

Changes by Chris Angelico ros...@gmail.com:


--
nosy: +Rosuav

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue2292
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18916] Various out-of-date Lock text in 3.2+

2014-01-30 Thread R. David Murray

R. David Murray added the comment:

Thanks for working on this.  The patch looks pretty good.  I would prefer to 
flow the two lines in the Lock docstring as a paragraph, rather than have once 
sentence per line.  Also, the OP mentions that the docs for type(Lock) mention 
PyThread_allocate_lock...do you want to look at fixing that as well?  As 
mentioned, it should reference Lock() instead.  The reference to 
PyThread_allocate_lock should be moved into comments in the type, IMO.

Also, this patch may be affected by the Argument Clinic Derby.  I don't know if 
the threading module is one of the ones that is being converted or not.  You 
can just ignore that issue since the full patch is needed for 3.3, but if you 
feel like figuring it out, and it is affected, you could produce an additional 
patch for 3.4.  Otherwise whoever applies your patch will figure out how to 
merge it.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18916
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16991] Add OrderedDict written in C

2014-01-30 Thread Antoine Pitrou

Changes by Antoine Pitrou pit...@free.fr:


--
versions: +Python 3.5 -Python 3.4

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16991
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16991] Add OrderedDict written in C

2014-01-30 Thread Antoine Pitrou

Antoine Pitrou added the comment:

It's much too late for such a disruptive change in 3.4.

--
nosy: +pitrou

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16991
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue19658] inspect.getsource weird case

2014-01-30 Thread Berker Peksag

Changes by Berker Peksag berker.pek...@gmail.com:


--
stage:  - committed/rejected
superseder:  - inspect.findsource raises undocumented error for code objects 
with empty filename

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue19658
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18916] Various out-of-date Lock text in 3.2+

2014-01-30 Thread Christopher Welborn

Christopher Welborn added the comment:

Yep, I missed the PyThread_allocate_lock reference. As far as the Argument 
Clinic Derby, I've been following the python-dev list and reading about 
Argument Clinic, but I don't know enough about it to do the conversion. It's a 
really good tool from what I can tell. I'll have to study it some more so in 
the future I can possibly help with the conversions.

I see the threading module listed in a 
href=http://bugs.python.org/issue20185;Issue #20185/a (Derby #17), but no 
patch for it yet.

Forgive my newbness, but I omitted putting a reference to 
PyThread_allocate_lock in the comments because I was confused about what kind 
of reference you were talking about. Something about making sure Python users 
see threading.Lock instead of PyThread_allocate_lock, or moving a statement 
like to create a lock in C, call the PyThread_allocate_lock function into the 
comments. If it's important for it to be there, could you let me know so I can 
make the edit?

Hopefully I have been of some help, instead of just wasting your time.

--
Added file: http://bugs.python.org/file33819/threading.lock.docs3.3.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18916
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18916] Various out-of-date Lock text in 3.2+

2014-01-30 Thread Christopher Welborn

Changes by Christopher Welborn cjwelb...@live.com:


Removed file: http://bugs.python.org/file33818/threading.lock.docs.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18916
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18916] Various out-of-date Lock text in 3.2+

2014-01-30 Thread R. David Murray

R. David Murray added the comment:

Yes, the latter: since someone thought it was important to mention, but only 
people working with the C code would benefit, it ought to be a comment in the C 
source.

If there's no AC patch for threading yet, then there's no problem with that, 
and your patch will be good for both 3.3 and 3.4.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18916
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20406] Use application icon for IDLE

2014-01-30 Thread Terry J. Reedy

Terry J. Reedy added the comment:

I see. MS Paint just pulled out one of the 16-pixel images. Photoshop (like Tk) 
refused to open the file. However, I found the following:

iconbitmap = wm_iconbitmap(self, bitmap=None, default=None)
Set bitmap for the iconified widget to BITMAP. Return
the bitmap if None is given.
 
Under Windows, the DEFAULT parameter can be used to set the icon
for the widget and any descendents that don't have an icon set
explicitly.  DEFAULT can be the relative path to a .ico file
(example: root.iconbitmap(default='myicon.ico') ).

This works* with default=py.ico for Windows and is available in 2.7, while 
wm_iconphoto is not. I think we should use it for Windows. (I get the 
impression from the help text that default= only works for Windows, but I 
cannot test this.) See uploaded 3.4 patch. I plan to apply this before the next 
release.

Someone else will have to add tested elif: clauses for other systems. For X, 
iconphoto might be better, as it accepts multiple bitmaps (of various sizes) 
and packages them for X. Images could be extracted from py.ico for this 
purpose. Or maybe just the 32-bit 32 pixel image in py.ico, save as the best 
quality .gif, would be enough. Iconphoto help says it does not work for Macs; 
the iconbitmap help says nothing, so maybe it does.

* The title icon I see is better than than the 16 pixel gif extracted from 
py.ico, so I presume it is downsized from a 32 pixel version. Unlike any .gif, 
transparency is handled correctly. However, Tk somehow distorts the colors and 
it is much darker than the same-size Start menu icon. For the white page part, 
I like the darker outline and page holes.better. For the two snakes, it is much 
worse. The bright yellow-orange snake is instead a dull brownish orange and not 
properly recognizable as the Python snake. I renamed py.ico to idle.ico so 
someone could edit the colors to look better when run through Tk without having 
to rename the file and change the code later. (I would want to rename after 
editing so no one would think it identical to PC/py.ico.)  But I do not think a 
commit should wait on an image edit.

--
stage: patch review - commit review
Added file: http://bugs.python.org/file33820/20406-34.diff

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20406
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20451] os.exec* mangles argv on windows (splits on spaces, etc)

2014-01-30 Thread Florian Bruhin

New submission from Florian Bruhin:

The os.exec* functions seem to mangle arguments on Windows. So far I noticed 
the supplied argv gets split on spaces, and double-quotes get stripped when not 
escaped.

Example, on Windows 7:

 platform.platform()
'Windows-7-6.1.7601-SP1'
 os.execlp('python', 'python', '-c', 
 sys=__import__('sys');print(sys.argv), 'Hello World')
['-c', 'Hello', 'World']

Same on Archlinux: ['-c', 'Hello World'] as expected.

Both running Python 3.3.3.

--
components: Library (Lib), Windows
messages: 209748
nosy: The Compiler
priority: normal
severity: normal
status: open
title: os.exec* mangles argv on windows (splits on spaces, etc)
type: behavior
versions: Python 3.3

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue20451
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com