[issue12502] 100% cpu usage when using asyncore with UNIX socket

2011-07-15 Thread Charles-François Natali

Charles-François Natali neolo...@free.fr added the comment:

Patch committed, closing.
Alexey, thanks for reporting this.
(I'll open a separate issue to increase the tests coverage).

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

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



[issue12569] sqlite3 segfaults and bus errors when given certain unicode strings as queries

2011-07-15 Thread Ned Deily

Ned Deily n...@acm.org added the comment:

0xD800 does not represent a valid Unicode character; it's a surrogate code 
point (see 
http://en.wikipedia.org/wiki/Mapping_of_Unicode_characters#Surrogates).  If you 
use a code point that does represent a Unicode character, say 0xA800, there is 
no error.  If there is a bug here, it's that the Python 2 version does not 
report an error for this edge case.

--

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



[issue12502] 100% cpu usage when using asyncore with UNIX socket

2011-07-15 Thread Giampaolo Rodola'

Changes by Giampaolo Rodola' g.rod...@gmail.com:


--
versions: +Python 2.7, Python 3.1, Python 3.3

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



[issue12502] 100% cpu usage when using asyncore with UNIX socket

2011-07-15 Thread Giampaolo Rodola'

Changes by Giampaolo Rodola' g.rod...@gmail.com:


--
versions:  -Python 3.1

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



[issue12502] 100% cpu usage when using asyncore with UNIX socket

2011-07-15 Thread STINNER Victor

Changes by STINNER Victor victor.stin...@haypocalc.com:


--
Removed message: http://bugs.python.org/msg140388

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



[issue12502] 100% cpu usage when using asyncore with UNIX socket

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

Woops, I don't know how, but I removed a neologix's message:

Patch committed, closing.
Alexey, thanks for reporting this.
(I'll open a separate issue to increase the tests coverage).

--
nosy: +haypo

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



[issue12571] Python built on Linux 3.0 doesn't include DLFCN

2011-07-15 Thread Dirkjan Ochtman

New submission from Dirkjan Ochtman dirk...@ochtman.nl:

This seems similar to issue 12326, but it doesn't seem similar enough to 
include it there: the DLFCN module seems to not be built when running against a 
3.0 kernel. See https://bugs.gentoo.org/show_bug.cgi?id=374579.

--
messages: 140391
nosy: djc
priority: normal
severity: normal
status: open
title: Python built on Linux 3.0 doesn't include DLFCN

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



[issue12571] Python built on Linux 3.0 doesn't include DLFCN

2011-07-15 Thread Dirkjan Ochtman

Changes by Dirkjan Ochtman dirk...@ochtman.nl:


--
versions: +Python 2.7, Python 3.2

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



[issue12326] Linux 3: tests should avoid using sys.platform == 'linux2'

2011-07-15 Thread Dirkjan Ochtman

Changes by Dirkjan Ochtman dirk...@ochtman.nl:


--
nosy: +djc

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



[issue12555] PEP 3151 implementation

2011-07-15 Thread Dirkjan Ochtman

Changes by Dirkjan Ochtman dirk...@ochtman.nl:


--
nosy: +djc

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



[issue12569] sqlite3 segfaults and bus errors when given certain unicode strings as queries

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

I already fixed this issue in Python 3.1, 3.2 and 3.3: issue #6697 (e.g. commit 
7ba851d1b46e).

$ ./python 
Python 3.3.0a0 (default:ab162f925761, Jul 15 2011, 09:36:17) 
 import sqlite3
 c = sqlite3.connect(:memory:)
 table_name = '' + chr(0xD800) + ''
 c.execute(create table  + table_name +  (bar))
Traceback (most recent call last):
  File stdin, line 1, in module
UnicodeEncodeError: 'utf-8' codec can't encode character '\ud800' in position 
14: surrogates not allowed

@jeremybanks: I don't think that you use sqlite3 coming from Python 3 but the 
third party module.

--
nosy: +haypo

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



[issue12569] sqlite3 segfaults and bus errors when given certain unicode strings as queries

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

 I already fixed this issue in Python 3.1, 3.2 and 3.3:
 issue #6697 (e.g. commit 7ba851d1b46e).

Oh, wrong: the bug was only fixed in Python 3.2 and 3.3. There was already a 
check after _PyUnicode_AsStringAndSize(), but the test was on the wrong 
variable (operation vs operation_cstr).

Because only security bugs can be fixed in Python 3.1, I think that this issue 
should be closed. Or do you consider dereferencing a NULL pointer in sqlite3 as 
a security vulnerability?

--

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



[issue12326] Linux 3: tests should avoid using sys.platform == 'linux2'

2011-07-15 Thread Charles-François Natali

Charles-François Natali neolo...@free.fr added the comment:

Here we go, first Linux3-related bug report:
https://bugs.gentoo.org/show_bug.cgi?id=374579 (see issue #12571).

--

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



[issue12569] sqlite3 segfaults and bus errors when given certain unicode strings as queries

2011-07-15 Thread Amaury Forgeot d'Arc

Amaury Forgeot d'Arc amaur...@gmail.com added the comment:

It seems that a fix was merged in the 3.1 branch, somewhere between 3.1.2 and 
3.1.3.

--
nosy: +amaury.forgeotdarc

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



[issue12571] Python built on Linux 3.0 doesn't include DLFCN

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

This issue is related to issue #12326.

--
nosy: +haypo

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



[issue12326] Linux 3: tests should avoid using sys.platform == 'linux2'

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

 Here we go, first Linux3-related bug report:
 https://bugs.gentoo.org/show_bug.cgi?id=374579 (see issue #12571).

Oh, some people use the DLFCN module :-)

--

I'm still in favor of keeping sys.platform == 'linux3', and you?

For plat-linux3, should we regenerate this directory (I cannot do that, I don't 
have Linux 3.0 yet) or can we just use a symbolic link? I read that Linux 3.0 
doesn't break the API, so I suppose that constants are the same. Or can we try 
by copying plat-linux2 to plat-linux3?

--

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



[issue12569] sqlite3 segfaults and bus errors when given certain unicode strings as queries

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

 It seems that a fix was merged in the 3.1 branch,
 somewhere between 3.1.2 and 3.1.3.

Which fix? The code is still wrong in Mercurial (branch 3.1):

   493 operation_cstr = _PyUnicode_AsStringAndSize(operation, 
operation_len);
   494 if (operation == NULL)
   495 goto error;

http://hg.python.org/cpython/file/42ec507815d2/Modules/_sqlite/cursor.c

--

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



[issue1813] Codec lookup failing under turkish locale

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

The decimal module has been fixed in Python 2.7, 3.2 and 3.3 for Turkish local: 
issue #11830.

--

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



[issue12569] sqlite3 segfaults and bus errors when given certain unicode strings as queries

2011-07-15 Thread Amaury Forgeot d'Arc

Amaury Forgeot d'Arc amaur...@gmail.com added the comment:

The fix was c073f3c3276e (thanks to hg bisect)
the variable operation_cstr is not used before the call to 
pysqlite_cache_get(), which also tries to encode the statement into utf8 and 
correctly raises an exception.
In early 3.1.2, the segfault came from the DECREF of an uninitialized member...

--

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



[issue12544] Avoid using a pseudo-dict for _type_equality_funcs in unittest

2011-07-15 Thread Michael Foord

Michael Foord mich...@voidspace.org.uk added the comment:

I wouldn't object to having a cyclic reference test for TestCase, although if 
it ever becomes a problem for the development of unittest we may have to 
disable it again. I think Benjamin said he would like to modify the test from 
Martin's patch.

--

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



[issue6721] Locks in python standard library should be sanitized on fork

2011-07-15 Thread Nir Aides

Nir Aides n...@winpdb.org added the comment:

Here is a morning reasoning exercise - please help find the flaws or refine it:


5) Sanitizing worker threads in the multiprocessing module

Sanitizing a worker thread in the context of this problem is to make sure it 
can not create a state that may deadlock another thread that calls fork(); or 
in other words fork-safe.
Keep in mind that in Python os.fork() is never called from a POSIX signal 
handler.
So what are examples of a fork-safe thread?

a) A thread that spins endlessly doing nothing in a C for(;;) loop is safe.

Another thread may call fork() without restrictions.

b) A Python thread that only calls function that do not yield the GIL and that 
does not acquire locks that are held beyond a Python tick is safe.

An example for such a lock is a critical-section lock acquired by a lower level 
third party library for the duration of a function call.
Such a lock will be released by the time os.fork() is called because of the GIL.

c) A Python thread that in addition to (2) also acquires a lock that is handled 
at fork is safe.

d) A Python thread that in addition to (2) and (3) calls function that yield 
the GIL but while the GIL is released only calls async-signal-safe code.

This is a bit tricky. We know that it is safe for thread A to fork and call 
async-signal-safe functions regardless of what thread B has been doing, but I 
do not know that thread A can fork and call non async-signal-safe functions if 
thread B was only calling async-signal-safe functions.

Nevertheless it makes sense: For example lets assume it isn't true, and that 
hypothetical thread A forked while thread B was doing the async-signal-safe 
function safe_foo(), and then thread A called non async-signal-safe function 
unsafe_bar() and deadlocked.

unsafe_bar() could have deadlocked trying to acquire a lock that was acquired 
by safe_foo(). But if this is so, then it could also happen the other way 
around.
Are there other practical possibilities?

Either way, we could double check and white list the async-signal-safe 
functions we are interested in, in a particular implementation.

e) Socket related functions such as bind() accept() send() and recv(), that 
Python calls without holding the GIL, are all async-signal-safe.

This means that in principle we can have a fork-safe worker thread for the 
purpose of communicating with a forked process using a socket.

--

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



[issue12568] Add functions to get the width in columns of a character

2011-07-15 Thread Nicholas Cole

Changes by Nicholas Cole nicholas.c...@gmail.com:


--
nosy: +Nicholas.Cole

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



[issue6755] Patch: new method get_wch for ncurses bindings: accept wide characters (unicode)

2011-07-15 Thread Nicholas Cole

Nicholas Cole nicholas.c...@gmail.com added the comment:

 Nobody wanted to take the responsability of the choice for get_wch(): add a 
 new method or patch getch() ;-)

I suspect that a new method is the right way to go, here.  

I see it has been moved to committed/rejected status - does that mean that it 
might still go in, or that it is rejected?

 I think that the Unicode support of curses in Python 3 is just completly 
 broken

It certainly is less than ideal. ;-)

--

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



[issue6755] Patch: new method get_wch for ncurses bindings: accept wide characters (unicode)

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

 I see it has been moved to committed/rejected
 status - does that mean that it might still go in, or that
 it is rejected?

I commited the new method, did you see my commit dec10ad41b2a?

I propose to continue the discussion on issue #12567 (for example, to decide if 
we need unget_wch or not).

--

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



[issue12568] Add functions to get the width in columns of a character

2011-07-15 Thread Christian Hofstaedtler

Changes by Christian Hofstaedtler ch+pythonb...@zeha.at:


--
nosy: +zeha

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



[issue12567] curses implementation of Unicode is wrong in Python 3

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

Oh, by the way: do all platforms have wide character functions? I don't see any 
failure on our Python 3.x buildbots, but test_curses is skipped on many 
buildbots.

--

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



[issue12567] curses implementation of Unicode is wrong in Python 3

2011-07-15 Thread Nicholas Cole

Nicholas Cole nicholas.c...@gmail.com added the comment:

I think that some platforms do not have wide character support, though I could 
be wrong.  The FAQ here: http://invisible-island.net/ncurses/ncurses.faq.html  
has a list of those that do and those that don't, but I don't know how up to 
date it is.

--

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



[issue12559] gzip.open() needs an optional encoding argument

2011-07-15 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

If we go this way, the errors and newline argument should be added as well.

--
nosy: +pitrou
stage:  - patch review

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



[issue6755] Patch: new method get_wch for ncurses bindings: accept wide characters (unicode)

2011-07-15 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

/home/antoine/cpython/default/Modules/_cursesmodule.c: In function 
‘PyCursesWindow_Get_WCh’:
/home/antoine/cpython/default/Modules/_cursesmodule.c:919:9: attention : 
implicit declaration of function ‘wget_wch’
/home/antoine/cpython/default/Modules/_cursesmodule.c:926:9: attention : 
implicit declaration of function ‘mvwget_wch’
gcc -pthread -shared 
build/temp.linux-x86_64-3.3-pydebug/home/antoine/cpython/default/Modules/_cursesmodule.o
 -L/usr/local/lib -lncurses -o 
build/lib.linux-x86_64-3.3-pydebug/_curses.cpython-33dm.so
*** WARNING: renaming _curses since importing it failed: 
build/lib.linux-x86_64-3.3-pydebug/_curses.cpython-33dm.so: undefined symbol: 
mvwget_wch
*** WARNING: importing extension _curses_panel failed with class 
'SystemError': initialization of _curses_panel raised unreported exception

Failed to build these modules:
_curses_curses_panel

--
nosy: +pitrou
status: closed - open

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



[issue6755] Patch: new method get_wch for ncurses bindings: accept wide characters (unicode)

2011-07-15 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

Also compilation warnings on some buildbots:

/var/lib/buildslave/3.x.murray-gentoo-wide/build/Modules/_cursesmodule.c: In 
function 'PyCursesWindow_Get_WCh':
/var/lib/buildslave/3.x.murray-gentoo-wide/build/Modules/_cursesmodule.c:919: 
warning: implicit declaration of function 'wget_wch'
/var/lib/buildslave/3.x.murray-gentoo-wide/build/Modules/_cursesmodule.c:926: 
warning: implicit declaration of function 'mvwget_wch'

--

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



[issue6755] Patch: new method get_wch for ncurses bindings: accept wide characters (unicode)

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

 implicit declaration of function ‘wget_wch’

Oh oh, I expected such error: it means that your ncurses library don't have the 
wide character API. The compiler command confirm that: gcc ... -lncurses  
You use libncurses and not libncursesw.

Antoine told me that libncursesw is available on its OS, but Python chose 
libncurses. I suppose that it's because readline is linked to libncurses (and 
not libncursesw) = see issue #7384.

Antoine setup is not rare: many Linux distro link readline to libncurses, and 
so Python cannot use libncursesw.

For this issue, it's not a problem: we can just add a test to check if get_wch 
is available or not, and only define the Python function if the C function does 
exist. But for #12567, it's a bigger problem because it means that we cannot 
always use the wide character functions if the argument is Unicode 
(character/string).

--

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



[issue12567] curses implementation of Unicode is wrong in Python 3

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

 by the way: do all platforms have wide character functions?

See msg140408 and msg140409: Antoine Pitrou (OS=Mageia 1) and some buildbots 
don't have get_wch().

--

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



[issue2506] Add mechanism to disable optimizations

2011-07-15 Thread Éric Araujo

Changes by Éric Araujo mer...@netwok.org:


--
title: Add mechanism to diasable optimizations - Add mechanism to disable 
optimizations

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



[issue6755] Patch: new method get_wch for ncurses bindings: accept wide characters (unicode)

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

 ... I suppose that it's because readline is linked to libncurses
 (and not libncursesw) = see issue #7384.

See also the issue #9408.

--

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



[issue12544] Avoid using a pseudo-dict for _type_equality_funcs in unittest

2011-07-15 Thread Benjamin Peterson

Benjamin Peterson benja...@python.org added the comment:

Done.

2011/7/15 Michael Foord rep...@bugs.python.org:

 Michael Foord mich...@voidspace.org.uk added the comment:

 I wouldn't object to having a cyclic reference test for TestCase, although if 
 it ever becomes a problem for the development of unittest we may have to 
 disable it again. I think Benjamin said he would like to modify the test from 
 Martin's patch.

 --

 ___
 Python tracker rep...@bugs.python.org
 http://bugs.python.org/issue12544
 ___


--

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



[issue12544] Avoid using a pseudo-dict for _type_equality_funcs in unittest

2011-07-15 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

FTR, some assertions about GC are embedded in the tests, for example test_set.

--

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



[issue3177] Add shutil.open

2011-07-15 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

 as long as it's implemented and it's in the standard library, and
 people don't have to use subprocess to run open or xdg-open themselves
 as I currently do.

This new function would call os.startfile on Windows, xdg-open where 
applicable, and open on Mac OS X (using a subprocess for these last two).

I found the python-ideas thread: 
http://mail.python.org/pipermail/python-ideas/2011-July/010674.html
There was only limited support.

--
dependencies: +Finding programs in PATH, adding shutil.which
title: implement os.startfile on posix and MacOSX - Add shutil.open

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



[issue444582] Finding programs in PATH, adding shutil.which

2011-07-15 Thread STINNER Victor

Changes by STINNER Victor victor.stin...@haypocalc.com:


--
nosy: +haypo

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



[issue3177] Add shutil.open

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

 dependencies: + Finding programs in PATH, adding shutil.which

Why did you add this dependency? For example, subprocess is able to locate a 
program if the program has no full path. We don't need a which function.

--
nosy: +haypo

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



[issue1301512] desktop module (providing startfile as open, all platforms)

2011-07-15 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

This was proposed anew as #3177.

--
nosy: +eric.araujo

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



[issue3177] Add shutil.open

2011-07-15 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

See also lengthy discussion on #1301512.

--

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



[issue3177] Add shutil.open

2011-07-15 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

 dependencies: + Finding programs in PATH, adding shutil.which
 Why did you add this dependency? For example, subprocess is able to
 locate a program if the program has no full path. We don't need a
 which function.

While the Windows API call is part of Windows and the open program always 
present on Mac OS X, xdg-open is an optional program on free OSes, so I thought 
we’d need shutil.which to look before we leap.  The alternative is to call 
Popen(['xdg-open', etc.]) and check if we get ENOENT, but I don’t know if this 
would be non-ambiguous (for example, do we get ENOENT if xdg-open exists but 
not the file?).

A related question: what to do when we’re not on Windows nor Mac and xdg-open 
doesn’t exist?  Raise NotImplemented?

--

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



[issue6786] readline and zero based indexing

2011-07-15 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

 I'd be writing a patch which would allow a programmer the option to
 explicitly use/instantiate the library in a zero-based way. [...]
 Would this be reasonable?

I think not.  Mark already stated his opposition to “a crazy level of micro 
control”.  Such a patch would not be trivial but would not bring much.

I hope you’ll find other bugs that motivate you for a patch! :)

--
nosy: +eric.araujo

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



[issue12561] Compiler workaround for wide string constants in Modules/getpath.c (patch)

2011-07-15 Thread Jim Schneider

Jim Schneider jim.schnei...@dataflux.com added the comment:

I am attaching an updated patch.  This version specifically checks for __hpux, 
and the macro name has been changed to avoid clashing with other uses.

--
Added file: http://bugs.python.org/file22663/getpath.patch

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



[issue1813] Codec lookup failing under turkish locale

2011-07-15 Thread Arfrever Frehtes Taifersar Arahesis

Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com:


--
nosy: +Arfrever

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



[issue12571] Python built on Linux 3.0 doesn't include DLFCN

2011-07-15 Thread Arfrever Frehtes Taifersar Arahesis

Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com:


--
nosy: +Arfrever

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



[issue12561] Compiler workaround for wide string constants in Modules/getpath.c (patch)

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

Use L CONSTANT to decode a byte string to a character string doesn't work 
with non-ASCII strings. _Py_char2wchar() should be used instead: see for 
example this fix, commit 5b6e13b6b473.

--
nosy: +haypo

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread Jim Schneider

New submission from Jim Schneider jim.schnei...@dataflux.com:

The C compiler that comes with HP/UX 11 has some shortcomings that prevent 
building Python 3.2.1 out of the box.  I am attaching patches here as I work 
through issues.

The first patch fixes namespace shortcomings when trying to use struct termios.

--
components: Build
files: termios.patch
keywords: patch
messages: 140423
nosy: jschneid
priority: normal
severity: normal
status: open
title: HP/UX compiler workarounds
type: compile error
versions: Python 3.2
Added file: http://bugs.python.org/file22664/termios.patch

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



[issue12561] Compiler workaround for wide string constants in Modules/getpath.c (patch)

2011-07-15 Thread Jim Schneider

Jim Schneider jim.schnei...@dataflux.com added the comment:

I am collecting HP/UX compiler bug workarounds in issue 12572.

Stinner - is the patch you mentioned in a released version of Python 3.2?  
Also, how is it affected by the fact that the (wide char) strings in question 
are constants?

--

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



[issue9408] curses: Link against libncursesw instead of libncurses

2011-07-15 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

For the record, I filed the following bug against Mageia's libreadline:
https://bugs.mageia.org/show_bug.cgi?id=2156

--
nosy: +pitrou

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



[issue5999] compile error on HP-UX 11.22 ia64 - 'mbstate_t' is used as a type, but has not been defined as a type

2011-07-15 Thread Jim Schneider

Jim Schneider jim.schnei...@dataflux.com added the comment:

I am collecting HP/UX compiler workarounds in issue 12572.  I will be adding 
patches to it as I produce them, including a patch to fix this on HP/UX.

--

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread STINNER Victor

Changes by STINNER Victor victor.stin...@haypocalc.com:


--
nosy: +haypo

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



[issue5999] compile error on HP-UX 11.22 ia64 - 'mbstate_t' is used as a type, but has not been defined as a type

2011-07-15 Thread STINNER Victor

Changes by STINNER Victor victor.stin...@haypocalc.com:


--
nosy: +haypo

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



[issue12417] Inappropriate copyright on profile files

2011-07-15 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

I don’t have clones of 2.6 and 3.1, so Benjamin, would you commit this?

--
status: closed - open

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



[issue12167] test_packaging reference leak

2011-07-15 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

It looks like we don’t have refleaks anymore!  I still have one question.

Victor reported some time ago that packaging.util._path_created was a cache 
that was never cleared; I fixed that in 27a70dfc38cc, but recently I’ve found 
that regrtest itself clears the similar distutils.util._path_created; I wonder 
which approach is better: one global cleaning in regrtest or piecemeal cleanup 
in each leaking test case?

I’ve also made a patch to register the caches used by packaging.database with 
the regrtest unclean environment warning; can someone review it?

--
Added file: http://bugs.python.org/file22665/packaging-caches.diff

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread Jim Schneider

Jim Schneider jim.schnei...@dataflux.com added the comment:

This patch works around the problem underlying issue 5999 by making sure the 
__STDC_VERSION__ macro is defined and has a value of at least 199901

--
Added file: http://bugs.python.org/file22666/fileutils.patch

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

You may the number of this issue in a comment of your patch.

--

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

Oops. You may *add* the number of this issue in a comment of your patch.

--

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



[issue6743] pprint.pprint should support no objects to print blank lines allow args

2011-07-15 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

Here’s a first draft at a patch.  I’ve added a module-level print function and 
a PrettyPrinter.print method which does the real work.

The functions have a signature compatible with print, but I have changed one 
default value: sep defaults to ',\n', because I think that the output is more 
useful and more pleasing (otherwise you’d have strange-looking indentation with 
containers).

If this looks good, I’ll work on doc and tests.  I guess I’ll reuse the helpers 
in test_print.

--
keywords: +patch
stage:  - needs patch
Added file: http://bugs.python.org/file22667/pprint-print.diff

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread Jim Schneider

Jim Schneider jim.schnei...@dataflux.com added the comment:

Workaround for compiler bug; HP/UX compiler refuses to past (implicitly char *) 
string constants with wide (wchar_t *) string constants.  This patch is also 
pasted to issue 12561 (which should be closed).

Note:  There is disagreement as to the best way to proceed on this issue.  
Stinner (aka haypo) has a patch that should work with non ASCII character sets, 
and my patch will almost certainly not work in those cases.  YMMV.

--
Added file: http://bugs.python.org/file22668/getpath.patch

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



[issue6743] Add function compatible with print to pprint module

2011-07-15 Thread Éric Araujo

Changes by Éric Araujo mer...@netwok.org:


--
title: pprint.pprint should support no objects to print blank lines  allow 
args - Add function compatible with print to pprint module

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

I think that getpath.patch is wrong (it's just a workaround hiding a real bug): 
see msg140422 of the issue #12561.

--

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread Jim Schneider

Jim Schneider jim.schnei...@dataflux.com added the comment:

This patch just reduces compiler noise by explicitly casting pointers to void 
*.  I expect the Visual Studio C/C++ compiler suite also issued these warnings, 
too.

--
Added file: http://bugs.python.org/file22669/typeobject.patch

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread Jim Schneider

Jim Schneider jim.schnei...@dataflux.com added the comment:

Sorry - last comment should have been compiler refuses to past*e*, not past.

--

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



[issue1626300] 'Installing Python Modules' does not work for Windows

2011-07-15 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

In distutils docs, I’ve mentioned “setup.py thing” as an alternative to “python 
setup.py thing” on Windows.  For packaging, the situation is different: there 
is no local script anymore, people will have to invoke the global pysetup 
command.  Would it work if I add a note like this:

  In order to run pysetup commands, you need to add the Python Scripts
  directory to your PATH *include link to relevant section of
  docs.python.org/using*.

BTW, do scripts work without file extensions, or does the installer add .py?  
If it’s the latter, then my doc note will need to mention that too.

--
nosy: +terry.reedy
versions: +Python 3.3 -Python 3.1

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



[issue12141] sysconfig.get_config_vars('srcdir') fails in specific cases

2011-07-15 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

BTW, doesn’t the change to Makefile.pre.in need to be ported to the MSI build 
system too?

--

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread Jim Schneider

Jim Schneider jim.schnei...@dataflux.com added the comment:

The HP/UX C compiler grumbles when a symbol that is declared static is later 
defined without the static storage class specifier.  The attached patch just 
adds the missing static keywords.

--
Added file: http://bugs.python.org/file22670/Python-ast.patch

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



[issue12394] packaging: generate scripts from callable (dotted paths)

2011-07-15 Thread Éric Araujo

Changes by Éric Araujo mer...@netwok.org:


--
hgrepos: +42

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread Jim Schneider

Jim Schneider jim.schnei...@dataflux.com added the comment:

I'm adding the original listeners for issue 5999 to this one.

The fileutils.patch patch attached to this issue directly addresses what's 
wrong in issue 5999; I'd consider it closed, but as I didn't open it, and I'm 
not actually part of the python project, that's not my call to make.

--
nosy: +eric.araujo, loewis, srid, terry.reedy

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



[issue12561] Compiler workaround for wide string constants in Modules/getpath.c (patch)

2011-07-15 Thread STINNER Victor

STINNER Victor victor.stin...@haypocalc.com added the comment:

 Stinner - is the patch you mentioned in a released version
 of Python 3.2?

Yes, Python 3.2.1. (It's not part of Python 3.1.)

 Also, how is it affected by the fact that the (wide char) strings
 in question are constants?

I don't remember exactly. My patch uses the locale encoding at runtime instead 
of using the locale encoding of the compiler. See issue #6011 for the details.

--

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread Jim Schneider

Jim Schneider jim.schnei...@dataflux.com added the comment:

From issue 12561 (which I will be closing):

Author: STINNER Victor (haypo) *  Date: 2011-07-15 15:36  
Use L CONSTANT to decode a byte string to a character string doesn't work 
with non-ASCII strings. _Py_char2wchar() should be used instead: see for 
example this fix, commit 5b6e13b6b473. 

This is in reference to getpath.patch.  I have no need to support 
internationalized versions of the constant strings my patch addresses, so 
Stinner's commit is overkill for me.

--

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

Minor note: we prefer unified diffs, and when possible, all related changes in 
one file.  See http://docs.python.org/devguide/

I can’t review the patches, as I don’t know C nor HP/UX.  I’m not sure why you 
opened this report instead of following on the other one :)

--

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



[issue12526] packaging.pypi.Crawler and resulting objects have a circular API

2011-07-15 Thread Éric Araujo

Éric Araujo mer...@netwok.org added the comment:

Thanks for the report.  I noticed similar strangeness in the API when working 
on the documentation.  Alexis is quite busy these weeks, but he will with no 
doubt comment on this later.

I’m not sure the force argument is a good idea; I think we should ask ourselves 
what is the behavior that would be most intuitive for users, and implement 
that.  If there are performance or caching issues, we’ll see.

--

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



[issue12561] Compiler workaround for wide string constants in Modules/getpath.c (patch)

2011-07-15 Thread Jim Schneider

Jim Schneider jim.schnei...@dataflux.com added the comment:

Constant initializers are required to be constants, not function calls, so 
_Py_char2wchar cannot be used in the definition of lib_python (line #138 of 
Modules/getpath.c).

--

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread Jim Schneider

Jim Schneider jim.schnei...@dataflux.com added the comment:

Update to getpath.patch (issue 12561) - this version uses _Py_char2wchar where 
possible.  Unfortunately, as lib_python is declared and defined statically, 
this can't be used in both cases where the HP/UX compiler has issues.

--
Added file: http://bugs.python.org/file22671/getpath.patch

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



[issue12556] Disable size checks in mmap.mmap()

2011-07-15 Thread Charles-François Natali

Charles-François Natali neolo...@free.fr added the comment:

A couple remarks:
- if st_size == 0, then you have to specify an explicit length (your example 
passes 0, which would fail with EINVAL without the check)
- most enties in /proc don't support mmap file operation, so it's likely to 
fail anyway (with ENODEV, EACCESS...). Do you have an example of a /proc entry 
with st_size == 0 that can be mmapped (mapping /proc/sys/debug/exception-trace 
fails with EACCESS)?

 How about adding a keyword argument to `mmap.mmap()`, which disables
 fstat-based size checks?

I don't like the idea of adding an argument which doesn't have a counterpart in 
the POSIX version (especially to address such corner cases).

--

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



[issue11254] distutils doesn't byte-compile .py files to __pycache__ during installation

2011-07-15 Thread Dave Malcolm

Dave Malcolm dmalc...@redhat.com added the comment:

FWIW, I've filed a bug about this issue for Fedora 15's python3 package here: 
https://bugzilla.redhat.com/show_bug.cgi?id=722578

Looks like this has led to an extra .pyc in the old location for every Python 3 
.py file in Fedora 15's various python3-* rpm packages (as generated by 
distutils).  

rpm's post-processing has been generating .pyc files in the (correct) 
__pycache__ location (via rpmbuild's brp-python-bytecompile script, which uses 
compileall).

For examples, see that Fedora bug report; so far it's affected every built rpm 
I've looked at.

I believe the impact of the extra .pyc files is merely wasted disk space within 
our rpm-packaged Python 3.2 stack.

I'm thinking of applying the patch to our downstream python3.src.rpm

--
nosy: +dmalcolm

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



[issue12524] change httplib docs POST example

2011-07-15 Thread Petri Lehtinen

Petri Lehtinen pe...@digip.org added the comment:

There's also http://httpstat.us/. You can send any request (also POST) to 
http://httpstat.us/200 and it gives you a 200 OK response.

I recall seeing other similar services, but didn't find them quickly.

--
nosy: +petri.lehtinen

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



[issue12551] Provide data for TLS channel binding

2011-07-15 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

 This patch is functionally equivalent, but advertises 'tls-unique'
 support in a bit different way.
 
 HAS_TLS_UNIQUE is not exposed in the python 'ssl' module, instead a
 list 'CHANNEL_BINDING_TYPES' is provided (empty when 'tls-unique' is
 not supported). get_channel_binding raises ValueError if the argument
 is not on this list. This way the API can be extended to other channel
 binding types without adding new constants or functions. Adding a new
 channel binding type would not need any modifications in the API
 client code (if it is designed to use arbitrary cb types).

Thanks, this is a good idea. I'm trying to get advice on the
openssl-users mailing-list about this and will commit if I don't get any
contradicting info soon ;)

--

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



[issue12167] test_packaging reference leak

2011-07-15 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

 I’ve also made a patch to register the caches used by
 packaging.database with the regrtest unclean environment warning; can
 someone review it?

I would call .copy() on the original dicts rather than remembering an
explicit empty dict.

--

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



[issue1626300] 'Installing Python Modules' does not work for Windows

2011-07-15 Thread Terry J. Reedy

Terry J. Reedy tjre...@udel.edu added the comment:

On Windows, scripts run with whatever name -- no extension or other extensions. 
I have tested this from both IDLE and command line.

--

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



[issue12529] cgi.parse_header fails on double quotes and semicolons

2011-07-15 Thread Petri Lehtinen

Petri Lehtinen pe...@digip.org added the comment:

Attached a patch against 2.7. It adds Ben's example as a test case, and his 
one-line change to the _parseparam helper function to fix the issue.

--
components: +Library (Lib)
keywords: +needs review, patch
nosy: +petri.lehtinen
stage:  - patch review
versions: +Python 2.7, Python 3.2
Added file: http://bugs.python.org/file22672/issue12529.patch

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



[issue12572] HP/UX compiler workarounds

2011-07-15 Thread Terry J. Reedy

Terry J. Reedy tjre...@udel.edu added the comment:

The fileutils.patch patch attached to this issue directly addresses what's 
wrong in issue 5999; I'd consider it closed, ...

When an patch is committed that fixes that issue, say so there and I or someone 
will close it.

From issue 12561 (which I will be closing):...
so Stinner's commit is overkill for me.

Issues sometimes expand beyond the original request. It is unclear to me 
whether Victor thinks that that issue is finished. If he thinks more should be 
done, then I think it should be left open.

--

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



[issue10910] pyport.h FreeBSD/Mac OS X fix causes errors in C++ compilation

2011-07-15 Thread Nasos Dousis

Nasos Dousis ndou...@gmail.com added the comment:

Ronald,

Thanks much for your help and insight.  I tried the patch but unfortunately it 
didn't work for me-- this might be because I have Python extensions written in 
C++.

Any other suggestions?  Should I wait for the next version of boost.python?

Thanks and regards,
Nasos

--

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



[issue12541] Accepting Badly formed headers in urllib HTTPBasicAuth

2011-07-15 Thread Petri Lehtinen

Changes by Petri Lehtinen pe...@digip.org:


--
nosy: +petri.lehtinen

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



[issue11343] Make errors due to full parser stack identifiable

2011-07-15 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

This looks like a rather good idea, although I'm not sure it deserves a new 
global exception type.

--
nosy: +benjamin.peterson, ncoghlan, pitrou
stage:  - patch review

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



[issue11824] freeze.py broken due to ABI flags

2011-07-15 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

Barry?

Additionally, if would be nice if we got some tests for the freeze tool, 
otherwise I fear we will keep breaking it.

--
nosy: +pitrou
priority: normal - high
stage:  - patch review

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



[issue12570] BaseHTTPServer.shutdown() locks if the last request 404'd

2011-07-15 Thread Petri Lehtinen

Changes by Petri Lehtinen pe...@digip.org:


--
nosy: +petri.lehtinen

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



[issue11829] inspect.getattr_static code execution with meta-metaclasses

2011-07-15 Thread Antoine Pitrou

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


--
nosy: +ncoghlan
stage:  - patch review

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



[issue11813] inspect.getattr_static doesn't get module attributes

2011-07-15 Thread Antoine Pitrou

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


--
stage:  - patch review

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



[issue11770] inspect.dir_static

2011-07-15 Thread Antoine Pitrou

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


--
stage: needs patch - patch review
type: behavior - feature request

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



[issue11321] 9th import of module _pickle always crashes

2011-07-15 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset 1ae0b7b8de0b by Antoine Pitrou in branch '3.2':
Issue #11321: Fix a crash with multiple imports of the _pickle module when
http://hg.python.org/cpython/rev/1ae0b7b8de0b

New changeset 6674272754da by Antoine Pitrou in branch 'default':
Issue #11321: Fix a crash with multiple imports of the _pickle module when
http://hg.python.org/cpython/rev/6674272754da

--
nosy: +python-dev

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



[issue11321] 9th import of module _pickle always crashes

2011-07-15 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

Should be fixed now, thank you!

--
resolution:  - fixed
stage:  - committed/rejected
status: open - closed
versions:  -Python 3.1

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



[issue11627] segfault raising an arbitrary object as an exception

2011-07-15 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset 8d05f697acd4 by Benjamin Peterson in branch '3.2':
catch nasty exception classes with __new__ that doesn't return a exception 
(closes #11627)
http://hg.python.org/cpython/rev/8d05f697acd4

New changeset bc1fbd6f667a by Benjamin Peterson in branch 'default':
merge 3.2 (#11627)
http://hg.python.org/cpython/rev/bc1fbd6f667a

--
nosy: +python-dev
resolution:  - fixed
stage:  - committed/rejected
status: open - closed

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



[issue11627] segfault raising an arbitrary object as an exception

2011-07-15 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset 45b1ae1ef318 by Benjamin Peterson in branch '2.7':
port 8d05f697acd4 (#11627)
http://hg.python.org/cpython/rev/45b1ae1ef318

--

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



[issue12559] gzip.open() needs an optional encoding argument

2011-07-15 Thread Daniel Urban

Daniel Urban urban.dani...@gmail.com added the comment:

 If we go this way, the errors and newline argument should be added
 as well.

Yeah, I thought about that. I can make a new patch, that implement this, if 
needed. Though it seems there is a real problem, the one that Amaury Forgeot 
d'Arc mentioned. I can't think of a way to solve it in a backwards compatible 
way.

--

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



[issue11603] Python crashes or hangs when rebinding __repr__ as __str__

2011-07-15 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset b488e027c952 by Antoine Pitrou in branch '3.1':
Issue #11603: Fix a crash when __str__ is rebound as __repr__.
http://hg.python.org/cpython/rev/b488e027c952

New changeset 8b52ac4a0c9f by Antoine Pitrou in branch '3.2':
Issue #11603: Fix a crash when __str__ is rebound as __repr__.
http://hg.python.org/cpython/rev/8b52ac4a0c9f

New changeset 0a040aa9bb34 by Antoine Pitrou in branch 'default':
Issue #11603: Fix a crash when __str__ is rebound as __repr__.
http://hg.python.org/cpython/rev/0a040aa9bb34

--
nosy: +python-dev

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



[issue11603] Python crashes or hangs when rebinding __repr__ as __str__

2011-07-15 Thread Roundup Robot

Roundup Robot devn...@psf.upfronthosting.co.za added the comment:

New changeset cd9eca1bf531 by Antoine Pitrou in branch '2.7':
Issue #11603: Fix a crash when __str__ is rebound as __repr__.
http://hg.python.org/cpython/rev/cd9eca1bf531

--

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



[issue11603] Python crashes or hangs when rebinding __repr__ as __str__

2011-07-15 Thread Antoine Pitrou

Antoine Pitrou pit...@free.fr added the comment:

Should be fixed, now, thank you!

--
nosy: +pitrou
resolution:  - fixed
stage: test needed - committed/rejected
status: open - closed
versions:  -Python 2.6

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



[issue12531] documentation index entries for * and **

2011-07-15 Thread Terry J. Reedy

Terry J. Reedy tjre...@udel.edu added the comment:

This is just the tip of the iceberg as far as needed symbol index entries goes. 
Nearly 3 years ago, I wrote a Python 3 symbol glossary Python3 Syntax Symbol 
Uses that was complete as far as I knew then. I think most of the entries 
there should have a corresponding index entry in the official docs. Link to 
download/view is

https://code.google.com/p/xploro/downloads/detail?name=PySymbols.htmlcan=1q=

That has 7 entries for '*':
  *: In function parameter list, make following unstarred names keyword only.
P *parameter_name: Function parameter bound to a tuple of extra positional 
arguments, any following unstarred names are keyword only.
P *iterable: In a call, unpack iterable items as arguments.
P *assignment_target: Starred target in assignment statement gets extra items 
from iterable.
I number1 * number2: Number multiplication operator.
I n * sequence or sequence * n: Operator to concatenate n copies of sequence.
S from module import *: Import all public (non-private) names from the module. 

 /P/I/S == 'nofix', prefix, infix, suffix.

I have been planning to work on a patch 'sometime', but would be happy if 
someone else grabbed the above and ran with it (and expanded the title of this 
issue).

I believe existing docs can get additions like this.

--
nosy: +terry.reedy
versions: +Python 2.7, Python 3.2

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



  1   2   >