[issue13119] Newline for print() is \n on Windows, and not \r\n as expected

2012-08-16 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

 +  newline is '' or '\n', no translation takes place. If newline is 
 any\n

Non-escaped \n.

--
nosy: +storchaka
status: closed - open

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



[issue13119] Newline for print() is \n on Windows, and not \r\n as expected

2012-08-16 Thread Georg Brandl

Georg Brandl added the comment:

Would be nice to be a bit more specific *where* that line comes from.

--

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



[issue13119] Newline for print() is \n on Windows, and not \r\n as expected

2012-08-16 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

 Would be nice to be a bit more specific *where* that line comes from.

Modules/_io/textio.c, changesets 243ad1a6f638 and 083776adcacc.

--

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



[issue13119] Newline for print() is \n on Windows, and not \r\n as expected

2012-08-16 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Oops, I got the wrong issue, sorry.

--
status: open - closed

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



[issue15679] HTMLParser can fail on unquoted attributes.

2012-08-16 Thread Julien Palard

New submission from Julien Palard:

This is accepted by browsers but raises an exception in HTMLParser :

from HTMLParser import HTMLParser
HTMLParser().feed(a onclick=foo({bar:42}); class=baz)

--
components: Library (Lib)
messages: 168352
nosy: JulienPalard
priority: normal
severity: normal
status: open
title: HTMLParser can fail on unquoted attributes.
type: enhancement
versions: Python 2.6

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



[issue15680] PEP 3121 refactoring applied to audioop module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 have now been applied to the audioop module!

--
components: Extension Modules
files: audioop_pep3121_v0.patch
keywords: patch
messages: 168353
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121 refactoring applied to audioop module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26842/audioop_pep3121_v0.patch

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



[issue15681] PEP 3121 refactoring applied to binascii module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 have now been applied to the binascii module!

--
components: Extension Modules
files: binascii_pep3121_v0.patch
keywords: patch
messages: 168354
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121 refactoring applied to binascii module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26843/binascii_pep3121_v0.patch

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



[issue15682] PEP 3121 refactoring applied to fpectl module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 have now been applied to the fpectl module!

--
components: Extension Modules
files: fpectl_pep3121_v0.patch
keywords: patch
messages: 168355
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121 refactoring applied to fpectl module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26844/fpectl_pep3121_v0.patch

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



[issue15683] add decorator for make functions partial applicable

2012-08-16 Thread Arvin Moezzi

New submission from Arvin Moezzi:

I am not sure if this is the right way to do it but IMHO it would be great to
have a function decorator/transformer to make functions partial applicable
using functools.partial. Like


from functools import partial

class partial_applicable():
def __call__(self, func):
def __wrapper(*args, **kvargs):
try:
return func(*args, **kvargs)
except TypeError:
return partial(func, *args, **kvargs)

return __wrapper

Then you could do like:

@partial_applicable()
def substract(left, right):
return left - right

substract(10, 100) 
 = -90

rclose = substract(right = 1000)
 = rclose(10) = -990

lclose = substract(1)
 = lclose(10) = -9

What do you think?

--
components: Library (Lib)
messages: 168356
nosy: Arvin.Moezzi
priority: normal
severity: normal
status: open
title: add decorator for make functions partial applicable
type: enhancement
versions: Python 2.6

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



[issue15684] PEP 3121 refactoring applied to fpetest module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the fpetest 
module!

--
components: Extension Modules
files: fpetest_pep3121_v0.patch
keywords: patch
messages: 168357
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121 refactoring applied to fpetest module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26845/fpetest_pep3121_v0.patch

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



[issue15683] add decorator for make functions partial applicable

2012-08-16 Thread Arvin Moezzi

Arvin Moezzi added the comment:

Or maybe even

class partial_applicable():
def __call__(self, func):
def __wrapper(*args, **kvargs):
try:
return func(*args, **kvargs)
except TypeError:
partial_func = partial(func, *args, **kvargs)
return partial_applicable()(partial_func)

return __wrapper

--

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



[issue15685] PEP 3121, 384 Refactoring applied to itertools module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the itertools 
module!

--
components: Extension Modules
files: itertools_pep3121-384_v0.patch
keywords: patch
messages: 168359
nosy: Robin.Schreiber, rhettinger
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to itertools module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26846/itertools_pep3121-384_v0.patch

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



[issue15686] PEP 3121, 384 Refactoring applied to md5 module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the md5 module!

--
components: Extension Modules
files: md5_pep3121-384_v0.patch
keywords: patch
messages: 168360
nosy: Robin.Schreiber, gregory.p.smith
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to md5 module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26847/md5_pep3121-384_v0.patch

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



[issue15687] PEP 3121, 384 Refactoring applied to mmap module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the mmap module!

--
components: Extension Modules
files: mmap_pep3121-384_v0.patch
keywords: patch
messages: 168361
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to mmap module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26848/mmap_pep3121-384_v0.patch

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



[issue15688] PEP 3121 Refactoring applied to nis module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the nis module!

--
components: Extension Modules
files: nis_pep3121_v0.patch
keywords: patch
messages: 168362
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121 Refactoring applied to nis module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26849/nis_pep3121_v0.patch

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



[issue15689] PEP 3121, 384 Refactoring applied to operator module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the operator 
module!

--
components: Extension Modules
files: operator_pep3121-384_v0.patch
keywords: patch
messages: 168363
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to operator module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26850/operator_pep3121-384_v0.patch

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



[issue15690] PEP 3121, 384 Refactoring applied to parser module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the parser 
module!

--
components: Extension Modules
files: parser_pep3121-384_v0.patch
keywords: patch
messages: 168364
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to parser module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26851/parser_pep3121-384_v0.patch

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



[issue15625] Support u and w codes in memoryview

2012-08-16 Thread Martin v . Löwis

Martin v. Löwis added the comment:

 My current inclination is still to apply Victor's patch from #13072  
 (which changes array to export the appropriate integer typecodes for  
 'u' arrays) and otherwise punt on this for 3.3 and try to sort out  
 the mess for 3.4.

I think this would be the worst choice. It would mean that we change
the format for exported array.arrays now for 3.3, and then change it
in 3.4 again. So anybody who cares about this would have to deal
with three different behaviors.

Note that the array module had been using 'u' and 'w' essentially
forever (i.e. since 3.0).

 For 3.4, I'm inclined to favour Stefan's proposal of C, U, W mapping  
 to multi-point sequences of UCS-1, UCS-2, UCS-4 code points (with  
 corresponding typecodes in the array module).

Fine with me in principle, although I see a problem when NumPy uses
'U' for UCS-4, yet CPython declares it to be UCS-2. I also think that
Travis' explicit agreement must be sought.

--

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



[issue11062] mailbox fails to round-trip a file to a Babyl mailbox

2012-08-16 Thread Petri Lehtinen

Petri Lehtinen added the comment:

Tests are now passing on Windows, too. Closing.

--
resolution:  - fixed
status: open - closed

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



[issue15691] PEP 3121, 384 Refactoring applied to posix module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the posix 
module!

--
components: Extension Modules
files: posix_pep3121-384_v0.patch
keywords: patch
messages: 168367
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to posix module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26852/posix_pep3121-384_v0.patch

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



[issue15625] Support u and w codes in memoryview

2012-08-16 Thread Nick Coghlan

Nick Coghlan added the comment:

I wouldn't change the export formats used for the 'u' typecode at all in 3.4 - 
I'd add new typecodes to array that match any new struct format characters and 
are exported accordingly. 'u' would *never* become a formally defined struct 
character, instead lingering in the array module as a legacy of the narrow/wide 
build distinction.

And good point that U would need to match UCS-4 to be consistent with NumPy. 
Perhaps we can just add 'U' in 3.4 and forget about UCS-2 entirely?

--

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



[issue13072] Getting a buffer from a Unicode array uses invalid format

2012-08-16 Thread Nick Coghlan

Nick Coghlan added the comment:

Adding a link to #15625, which is discussing the other end of this issue 
(whether or not memorview should support 'u' as a typecode).

--

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



[issue15625] Support u and w codes in memoryview

2012-08-16 Thread Martin v . Löwis

Martin v. Löwis added the comment:

 I wouldn't change the export formats used for the 'u' typecode at  
 all in 3.4 - I'd add new typecodes to array that match any new  
 struct format characters and are exported accordingly. 'u' would  
 *never* become a formally defined struct character, instead  
 lingering in the array module as a legacy of the narrow/wide build  
 distinction.

I think it is a desirable property that for an array A and an index
I, that A[I] == memoryview(A)[I]. Exporting the elements of an 'u'
array as integers would break that property.

So if we do want to support Unicode arrays (which some people apparently
want to see - I haven't heard anybody saying they actually *need* such
a type), the buffer type of it should be unicode, in some form, not
number.

I would be fine with deprecating the 'u' type arrays, acknowledging
that the Py_UNICODE element type is even more useless now than before.
If that is done, there is no point in fixing anything about it. If
it exports using the 'u' and 'w' codes - fine. If then memoryview
doesn't work properly - fine; this is a deprecated feature.

It should be fixed only if we want to support it properly (which I
believe this patch would do).

--

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



[issue15625] Support u and w codes in memoryview

2012-08-16 Thread Nick Coghlan

Nick Coghlan added the comment:

I guess the main alternative to deprecation that preserves the invariant you 
describe would be to propagate the u == Py_UNICODE definition to memoryview. 
Since we're trying to phase out Py_UNICODE, deprecation seems the more sensible 
course.

Perhaps just a documented deprecation for now, like the rest of the Py_UNICODE 
based APIs?

--

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



[issue15625] Support u and w codes in memoryview

2012-08-16 Thread Stefan Krah

Stefan Krah added the comment:

Martin v. Loewis rep...@bugs.python.org wrote:
 I would be fine with deprecating the 'u' type arrays, acknowledging
 that the Py_UNICODE element type is even more useless now than before.
 If that is done, there is no point in fixing anything about it. If
 it exports using the 'u' and 'w' codes - fine. If then memoryview
 doesn't work properly - fine; this is a deprecated feature.

From the perspective of memoryview backwards compatibility, deprecation is 
fine.
In 3.2, memoryview could really only handle one-dimensional buffers of unsigned
bytes:

 import array
 a = array.array('u', ABC)
 x = memoryview(a)
 a[0] == x[0]
False
 a[0]
'A'

# Indexing returns bytes instead of str:
 x[0]
b'A\x00'
 

# Index assignment attempts to do slice assignment:
 x[0] = 'Z'
Traceback (most recent call last):
  File stdin, line 1, in module
TypeError: 'str' does not support the buffer interface
 

I'm +1 for deprecating 'u' and 'w' in the array module, accept that memoryview
cannot handle 'u' and 'w' and fix the situation properly in 3.4. I agree that
the latter would require people to come up with actual use cases.

--

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



[issue13072] Getting a buffer from a Unicode array uses invalid format

2012-08-16 Thread Martin v . Löwis

Martin v. Löwis added the comment:

Based on the discussion in #15625, it seems that the consensus is to take no 
action on the format codes in this issue for 3.3, and reconsider in 3.4, to 
determine in what way the struct module should support Unicode.

Instead, the 'u' array code will be deprecated, in the same way in which the 
rest of the Py_UNICODE API is deprecated.

--

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



[issue15625] Support u and w codes in memoryview

2012-08-16 Thread Stefan Krah

Stefan Krah added the comment:

Well, apparently people do use 'u', see #15035.

--
nosy: +ronaldoussoren

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



[issue15035] array.array of UCS2 values

2012-08-16 Thread Stefan Krah

Stefan Krah added the comment:

This one should be fixed by #13072. Could you check again?

--

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



[issue15035] array.array of UCS2 values

2012-08-16 Thread Nick Coghlan

Nick Coghlan added the comment:

As Stefan noted, so long as Py_UNICODE is 16 bits in the Mac OS X builds, then 
this should now be back to the 3.2 behaviour.

--
nosy: +ncoghlan
priority: low - high

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



[issue15625] Support u and w codes in memoryview

2012-08-16 Thread Martin v . Löwis

Martin v. Löwis added the comment:

#15035 indicates that there is a need for UCS-2 arrays, using 'u' arrays was 
technically incorrect, since it is based on Py_UNICODE, whereas the API in 
question uses UniChar (which apparently is a two-byte type).

--

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



[issue15035] array.array of UCS2 values

2012-08-16 Thread Martin v . Löwis

Martin v. Löwis added the comment:

It's not back to the 3.2 behavior. In 3.3, Py_UNICODE is always equal to 
wchar_t, which is a 4-byte type on Darwin. However, CFString is based on 
UniChar, which is a 2-byte type.

That this worked in 3.2 was by accident - it would work only in narrow 
builds. Python's configure in 3.2 and before wouldn't default to using wchar_t 
on Darwin since it didn't consider wchar_t usable, which in turn happened 
because wchar_t is signed on Darwin, but Py_UNICODE was understood to be 
unsigned.

Since it's too late to add an 'U' code to 3.3, as a work-around, you would have 
to use a 'H' array, and initialize it with map(ord, the_string)).

Chances are good that a proper UCS-2 array code gets added to 3.4.

--
nosy: +loewis

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



[issue15035] array.array of UCS2 values

2012-08-16 Thread Ronald Oussoren

Ronald Oussoren added the comment:

Py_UNICODE is an typedef for wchar_t and that type is 4 bytes long:

 a.tobytes()
b'h\x00\x00\x00e\x00\x00\x00l\x00\x00\x00l\x00\x00\x00o\x00\x00\x00 
\x00\x00\x00w\x00\x00\x00o\x00\x00\x00r\x00\x00\x00l\x00\x00\x00d\x00\x00\x00'
 a = array.array('u', 'bar')
 a.tobytes()
b'b\x00\x00\x00a\x00\x00\x00r\x00\x00\x00'
 len(a.tobytes())
12
 

This is with a checkout that was created yesterday.

The issue is not resolved, there now is no way to easily create a UCS2 buffer; 
while there was in earlier releases of Python (with the default narrow build)

--

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



[issue15625] Support u and w codes in memoryview

2012-08-16 Thread Stefan Krah

Stefan Krah added the comment:

Martin v. L??wis rep...@bugs.python.org wrote:
 #15035 indicates that there is a need for UCS-2 arrays, using 'u' arrays was 
 technically incorrect, since it is based on Py_UNICODE, whereas the API in 
 question uses UniChar (which apparently is a two-byte type).

Right, thanks for clearing that up. Then #15035 would indeed support deprecating
'u' and 'w' and moving on to UCS2 and UCS4 arrays.

--

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



[issue15679] HTMLParser can fail on unquoted attributes.

2012-08-16 Thread R. David Murray

R. David Murray added the comment:

This is fixed in more recent versions of Python (2.7, 3.2+).

--
nosy: +r.david.murray
resolution:  - out of date
stage:  - committed/rejected
status: open - closed

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



[issue15683] add decorator for make functions partial applicable

2012-08-16 Thread R. David Murray

R. David Murray added the comment:

YAGNI, is what I think.  Or if you do need it, put it in your application.  (To 
tell you the truth, it just looks confusing to me...it strikes me as too 
magical.)

Regardless, this is more of a python-ideas kind of issue, so I suggest raising 
it there if you want to pursue it.

--
nosy: +r.david.murray
stage:  - committed/rejected
status: open - closed

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



[issue15586] Provide some examples for usage of ElementTree methods/attributes

2012-08-16 Thread Daniel Ellis

Daniel Ellis added the comment:

Made changes in structure in 2.7 branch to match 3.3 based on Eli's comments.  
Updated input prompt in examples per Ezio's review (though the default branch 
will still need this update).

--
Added file: http://bugs.python.org/file26853/2.7_branch_etree_doc_3.patch

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



[issue15692] Unexpected exponentiation in lambda function

2012-08-16 Thread Björn Dahlgren

New submission from Björn Dahlgren:

Hi, I hope this is not a false positive but I cannot help thinking this is a 
bug, consider:

Python 2.7.3 (default, Aug  1 2012, 05:14:39) 
[GCC 4.6.3] on linux2
Type help, copyright, credits or license for more information.
 -3.2**0
-1.0
 sign=lambda x: x**0
 sign(-3.2)
1.0

Python 3.2.3 (default, May  3 2012, 15:51:42) 
[GCC 4.6.3] on linux2
Type help, copyright, credits or license for more information.
 -3.2**0
-1.0
 sign=lambda x: x**0
 sign(-3.2)
1.0


Or is this expected?

Best regards,
Björn Dahlgren

--
components: None
messages: 168384
nosy: bjodah
priority: normal
severity: normal
status: open
title: Unexpected exponentiation in lambda function
versions: Python 2.7, Python 3.2

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



[issue15683] add decorator for make functions partial applicable

2012-08-16 Thread Arvin Moezzi

Arvin Moezzi added the comment:

Thanks for your feedback.

--

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



[issue15683] add decorator for make functions partial applicable

2012-08-16 Thread R. David Murray

R. David Murray added the comment:

Thanks for your suggestion, even though I'm rejecting the suggestion as a bug 
tracker issue.  (I should have said that at the start of my answer.)

--

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



[issue15692] Unexpected exponentiation in lambda function

2012-08-16 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

-3.2**0 == -(3.2**0)

 (-3.2)**0
1.0

--
nosy: +storchaka
resolution:  - invalid
status: open - closed

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



[issue15693] expose glossary link on hover

2012-08-16 Thread R. David Murray

R. David Murray added the comment:

I think it probably should be filed with sphinx instead, rather than also.

--
nosy: +r.david.murray

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



[issue14669] test_multiprocessing failure on OS X Tiger

2012-08-16 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 4307b985209b by Richard Oudkerk in branch 'default':
Issue #14669: Fix pickling of connections and sockets on MacOSX
http://hg.python.org/cpython/rev/4307b985209b

--

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



[issue15693] expose glossary link on hover

2012-08-16 Thread Chris Jerdonek

New submission from Chris Jerdonek:

It would be nice if hovering over the right side of the header to a glossary 
entry would expose a link in the same way that it does for function 
definitions, etc.

http://docs.python.org/dev/glossary.html#glossary

Otherwise, there doesn't seem to be a convenient way to get a direct link to a 
glossary entry.

I'm not sure if this issue should also be filed with Sphinx.

--
assignee: docs@python
components: Documentation
messages: 168388
nosy: cjerdonek, docs@python
priority: normal
severity: normal
status: open
title: expose glossary link on hover
type: enhancement
versions: Python 3.3

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



[issue15694] link to file object glossary entry in open() and io docs

2012-08-16 Thread Chris Jerdonek

New submission from Chris Jerdonek:

It would be nice if the first sentence of the documentation for the open() 
built-in function:

Open file and return a corresponding stream. If the file cannot be opened, an 
OSError is raised.

http://docs.python.org/dev/library/functions.html#open

linked to the glossary entry for file object:

http://docs.python.org/dev/glossary.html#term-file-object

Incidentally, this would be similar to what was done 2.7 documentation of 
open():

http://docs.python.org/library/functions.html#open

Similarly, the introductory overview section of the io module should also link 
to the glossary entry for file object:

Concrete objects belonging to any of these categories will often be called 
streams; another common term is file-like objects.

(from http://docs.python.org/dev/library/io.html#overview )

--
assignee: docs@python
components: Documentation
messages: 168392
nosy: cjerdonek, docs@python
priority: normal
severity: normal
status: open
title: link to file object glossary entry in open() and io docs
type: enhancement
versions: Python 3.3

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



[issue15694] link to file object glossary entry in open() and io docs

2012-08-16 Thread Chris Jerdonek

Changes by Chris Jerdonek chris.jerdo...@gmail.com:


--
keywords: +easy

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



[issue15693] expose glossary link on hover

2012-08-16 Thread Chris Jerdonek

Chris Jerdonek added the comment:

Do we pin the version of Sphinx that we use to generate the documentation?  If 
Sphinx fixes the issue, would we need to make a corresponding change here to 
reflect the fix?

--

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



[issue15693] expose glossary link on hover

2012-08-16 Thread R. David Murray

R. David Murray added the comment:

We do pin it, but we generally have no problem with upgrading.  I think we 
generally upgrade it exactly when there is a new Sphinx feature we want for our 
docs :)  We don't maintain local patches to Sphinx (though we do have code that 
is specific to our docs, using Sphinx's extension mechanisms).

--

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



[issue15693] expose glossary link on hover

2012-08-16 Thread Chris Jerdonek

Chris Jerdonek added the comment:

 I think we generally upgrade it exactly when there is a new Sphinx feature we 
 want for our docs :)

:)  Would the appropriate way to handle it be then to create an issue to 
upgrade Sphinx when XXX issue is resolved and link to the corresponding 
Sphinx issue?

I also see value in Python being able to track and possibly assist Sphinx in 
fixing an issue that we want.

Incidentally, issue 15455 may fall into the same category now that I know more.

--

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



[issue15693] expose glossary link on hover

2012-08-16 Thread R. David Murray

R. David Murray added the comment:

Well, I think it depends on what we consider the priority of the issue.  So, I 
personally would count this one as low, and would be happy that it gets fixed 
whenever we happen to upgrade to a version of Sphinx that fixes it.  If it is 
an issue we consider higher priority, then yes linking to the corresponding 
Sphinx issue here would be appropriate, and we have done that in the past.  (My 
notions are of course not the sole determining factor on the priority.)

In case you don't know, Georg is the primary author/maintainer of Sphinx, and 
I'm sure he'll be happy for any help you (or others) want to provide :).

By the way, although I use it on my own site I'm not by any means a Sphinx 
expert, so my thoughts about where this should be changed could be wrong.

--

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



[issue6484] No unit test for mailcap module

2012-08-16 Thread Petri Lehtinen

Petri Lehtinen added the comment:

Any reason why this hasn't been backported to 3.2 or 2.7?

--
nosy: +petri.lehtinen

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



[issue6484] No unit test for mailcap module

2012-08-16 Thread R. David Murray

R. David Murray added the comment:

There are divided opinions about the advisability of backporting tests that are 
not part of a bug fix.  In this case, there is also the fact that it includes a 
test that fails without a bug fix that was not backported.

--

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



[issue15693] expose glossary link on hover

2012-08-16 Thread Chris Jerdonek

Chris Jerdonek added the comment:

I created a Sphinx issue for this here:

https://bitbucket.org/birkenfeld/sphinx/issue/996/expose-glossary-entry-link-on-hover

--

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



[issue15695] Correct __sizeof__ support for StgDict

2012-08-16 Thread Serhiy Storchaka

New submission from Serhiy Storchaka:

Here is a patch that implements correct __sizeof__ for StgDict (a dictionary 
subclass used in ctypes).

There are no tests because I don't know how to create and use StgDict. So I'm 
not sure that the code works correctly. Please help me with tests.

--
components: Library (Lib)
files: stgdict_sizeof-3.3.patch
keywords: patch
messages: 168399
nosy: amaury.forgeotdarc, belopolsky, meador.inge, storchaka
priority: normal
severity: normal
stage: patch review
status: open
title: Correct __sizeof__ support for StgDict
type: behavior
versions: Python 2.7, Python 3.2, Python 3.3
Added file: http://bugs.python.org/file26854/stgdict_sizeof-3.3.patch

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



[issue15695] Correct __sizeof__ support for StgDict

2012-08-16 Thread Serhiy Storchaka

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


Added file: http://bugs.python.org/file26855/stgdict_sizeof-3.2.patch

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



[issue15695] Correct __sizeof__ support for StgDict

2012-08-16 Thread Serhiy Storchaka

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


--
stage: patch review - test needed
Added file: http://bugs.python.org/file26856/stgdict_sizeof-2.7.patch

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



[issue15455] index entries not showing up in glossary

2012-08-16 Thread Chris Jerdonek

Chris Jerdonek added the comment:

I created a Sphinx issue for this here:

https://bitbucket.org/birkenfeld/sphinx/issue/997/index-targets-not-getting-created-in

--

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



[issue15694] link to file object glossary entry in open() and io docs

2012-08-16 Thread Chris Jerdonek

Chris Jerdonek added the comment:

Attaching patch.  I also added two index entries for file object and made a 
couple wording adjustments to the intro paragraph of the io module.

--
keywords: +patch
stage:  - patch review
versions: +Python 3.2
Added file: http://bugs.python.org/file26857/issue-15694-1.patch

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



[issue15696] Correct __sizeof__ support for mmap

2012-08-16 Thread Serhiy Storchaka

New submission from Serhiy Storchaka:

Here is a patch that implements correct __sizeof__ for mmap under Windows.

I have not tested it because it is Windows-only issue. Please test it.

--
components: Library (Lib), Windows
files: mmap_sizeof-3.x.patch
keywords: patch
messages: 168402
nosy: storchaka
priority: normal
severity: normal
status: open
title: Correct __sizeof__ support for mmap
versions: Python 2.7, Python 3.2, Python 3.3
Added file: http://bugs.python.org/file26858/mmap_sizeof-3.x.patch

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



[issue15696] Correct __sizeof__ support for mmap

2012-08-16 Thread Serhiy Storchaka

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


Added file: http://bugs.python.org/file26859/mmap_sizeof-2.7.patch

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



[issue15696] Correct __sizeof__ support for mmap

2012-08-16 Thread Serhiy Storchaka

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


--
stage:  - patch review
type:  - behavior

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



[issue15625] Support u and w codes in memoryview

2012-08-16 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/issue15625
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15035] array.array of UCS2 values

2012-08-16 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/issue15035
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15697] PEP 3121 refactoring applied to pwd module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 have now been applied to the pwd module!

--
components: Extension Modules
files: pwd_pep3121_v0.patch
keywords: patch
messages: 168403
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121 refactoring applied to pwd module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26860/pwd_pep3121_v0.patch

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



[issue15698] PEP 3121, 384 Refactoring applied to pyexpat module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the pyexpat 
module!

--
components: Extension Modules
files: pyexpat_pep3121-384_v0.patch
keywords: patch
messages: 168404
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to pyexpat module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26861/pyexpat_pep3121-384_v0.patch

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



[issue15699] PEP 3121, 384 Refactoring applied to readline module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the readline 
module!

--
components: Extension Modules
files: readline_pep3121-384_v0.patch
keywords: patch
messages: 168405
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to readline module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26862/readline_pep3121-384_v0.patch

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



[issue15700] PEP 3121, 384 Refactoring applied to resource module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the resource 
module!

--
components: Extension Modules
files: resource_pep3121-384_v0.patch
keywords: patch
messages: 168406
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to resource module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26863/resource_pep3121-384_v0.patch

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



[issue15701] AttributeError from HTTPError when using digest auth

2012-08-16 Thread Jody McIntyre

New submission from Jody McIntyre:

I attempted to connect to a site using urllib2 and digest authentication and it 
raised an HTTPError (due to an incorrect username and password, which is 
expected).  I attempted to run the info() method of the HTTPError to get more 
information, but it failed with an AttributeError (this is the bug).

$ ./reproducer.py 
Traceback (most recent call last):
  File ./reproducer.py, line 16, in module
print e.info()
  File /usr/lib/python2.6/urllib.py, line 987, in info
return self.headers
AttributeError: 'HTTPError' object has no attribute 'headers'

$ python --version
Python 2.6.6

--
files: reproducer.py
messages: 168407
nosy: scjody
priority: normal
severity: normal
status: open
title: AttributeError from HTTPError when using digest auth
type: crash
versions: Python 2.6
Added file: http://bugs.python.org/file26864/reproducer.py

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



[issue15702] Multiprocessing Pool deadlocks on join after empty map operation

2012-08-16 Thread James Hutchison

New submission from James Hutchison:

Following code deadlocks on Windows 7 64-bit, Python 3.2.3

If you have a pool issue a map operation over an empty iterable then try to 
join later, it will deadlock. If there is no map operation or blah in the code 
below isn't empty, it does not deadlock

from multiprocessing import Pool

def main():
p = Pool();
blah = [];
print(Mapping);
p.map(dummy, blah);
p.close();
p.join(); # deadlocks here
print(Done);

def dummy(x):
pass;

if __name__ == __main__:
main();

--
components: Library (Lib)
messages: 168408
nosy: Jimbofbx
priority: normal
severity: normal
status: open
title: Multiprocessing Pool deadlocks on join after empty map operation
type: behavior
versions: Python 3.2

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



[issue15702] Multiprocessing Pool deadlocks on join after empty map operation

2012-08-16 Thread Antoine Pitrou

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


--
nosy: +sbt

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



[issue11062] mailbox fails to round-trip a file to a Babyl mailbox

2012-08-16 Thread Andrew Svetlov

Andrew Svetlov added the comment:

Thank you, Petri.

--

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



[issue15703] PEP 3121, 384 Refactoring applied to select module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the select 
module!

--
components: Extension Modules
files: select_pep3121-384_v0.patch
keywords: patch
messages: 168410
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to select module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26865/select_pep3121-384_v0.patch

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



[issue15704] PEP 3121, 384 Refactoring applied to sha1 module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the sha1 module!

--
components: Extension Modules
files: sha1_pep3121-384_v0.patch
keywords: patch
messages: 168411
nosy: Robin.Schreiber, gregory.p.smith
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to sha1 module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26866/sha1_pep3121-384_v0.patch

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



[issue6696] Profile objects should be documented

2012-08-16 Thread Andrew Svetlov

Changes by Andrew Svetlov andrew.svet...@gmail.com:


--
nosy: +asvetlov

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



[issue15705] PEP 3121, 384 Refactoring applied to sha256 module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the sha256 
module!

--
components: Extension Modules
files: sha256_pep3121-384_v0.patch
keywords: patch
messages: 168412
nosy: Robin.Schreiber, gregory.p.smith
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to sha256 module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26867/sha256_pep3121-384_v0.patch

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



[issue15706] PEP 3121, 384 Refactoring applied to sha512 module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the sha512 
module!

--
components: Extension Modules
files: sha512_pep3121-384_v0.patch
keywords: patch
messages: 168413
nosy: Robin.Schreiber, gregory.p.smith
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to sha512 module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26868/sha512_pep3121-384_v0.patch

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



[issue15702] Multiprocessing Pool deadlocks on join after empty map operation

2012-08-16 Thread Jeff Knupp

Jeff Knupp added the comment:

This is a duplicate of http://bugs.python.org/issue12157, which was fixed.

--
nosy: +Jeff.Knupp

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



[issue15707] PEP 3121, 384 Refactoring applied to signal module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the signal 
module!

--
components: Extension Modules
files: signal_pep3121-384_v0.patch
keywords: patch
messages: 168415
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to signal module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26869/signal_pep3121-384_v0.patch

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



[issue15708] PEP 3121, 384 Refactoring applied to socket module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the socket 
module!

--
components: Extension Modules
files: socket_pep3121-384_v0.patch
keywords: patch
messages: 168416
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to socket module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26870/socket_pep3121-384_v0.patch

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



[issue15709] PEP 3121, 384 Refactoring applied to termios module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the termios 
module!

--
components: Extension Modules
files: termios_pep3121-384_v0.patch
keywords: patch
messages: 168417
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to termios module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26871/termios_pep3121-384_v0.patch

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



[issue15710] logging module crashes in Python 2.7.3 for handler.setLevel(long)

2012-08-16 Thread Tobin Baker

New submission from Tobin Baker:

I'm using a 3rd-party library (ESAPI) which defines a log level as the literal 
-2**31. This worked fine until I upgraded to Python 2.7.3, which, unlike all 
previous versions of Python, coerces that literal to long rather than int. The 
following code in the logging module then throws a TypeError:

def _checkLevel(level):
if isinstance(level, int):
rv = level
elif str(level) == level:
if level not in _levelNames:
raise ValueError(Unknown level: %r % level)
rv = _levelNames[level]
else:
raise TypeError(Level not an integer or a valid string: %r % level)
return rv

Although this is certainly an unusual use case, it seems that as just a matter 
of principle, the module should be using the check isinstance(level, (int, 
long)) rather than just isinstance(level, int).

Here's the relevant part of the traceback:

  File /usr/lib/python2.7/logging/__init__.py, line 710, in setLevel
self.level = _checkLevel(level)
  File /usr/lib/python2.7/logging/__init__.py, line 190, in _checkLevel
raise TypeError(Level not an integer or a valid string: %r % level)
TypeError: Level not an integer or a valid string: -2147483648L

--
components: Library (Lib)
messages: 168418
nosy: tobin.baker
priority: normal
severity: normal
status: open
title: logging module crashes in Python 2.7.3 for handler.setLevel(long)
type: crash
versions: Python 2.7

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



[issue15710] logging module crashes in Python 2.7.3 for handler.setLevel(long)

2012-08-16 Thread Antoine Pitrou

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


--
nosy: +vinay.sajip

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



[issue15711] PEP 3121, 384 Refactoring applied to time module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the time module!

--
components: Extension Modules
files: time_pep3121-384_v0.patch
keywords: patch
messages: 168419
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to time module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26872/time_pep3121-384_v0.patch

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



[issue15712] PEP 3121, 384 Refactoring applied to unicodedata module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the unicodedata 
module!

--
components: Extension Modules
files: unicodedate_pep3121-384_v0.patch
keywords: patch
messages: 168420
nosy: Robin.Schreiber, effbot, lemburg, loewis
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to unicodedata module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26873/unicodedate_pep3121-384_v0.patch

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



[issue15713] PEP 3121, 384 Refactoring applied to zipimport module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the zipimport 
module!

--
components: Extension Modules
files: zipimport_pep3121-384_v0.patch
keywords: patch
messages: 168421
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to zipimport module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26874/zipimport_pep3121-384_v0.patch

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



[issue15714] PEP 3121, 384 Refactoring applied to grp module

2012-08-16 Thread Robin Schreiber

New submission from Robin Schreiber:

Changes proposed in PEP3121 and PEP384 have now been applied to the grp module!

--
components: Extension Modules
files: grp_pep3121-384_v0.patch
keywords: patch
messages: 168422
nosy: Robin.Schreiber
priority: normal
severity: normal
status: open
title: PEP 3121, 384 Refactoring applied to grp module
type: resource usage
versions: Python 3.4
Added file: http://bugs.python.org/file26875/grp_pep3121-384_v0.patch

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



[issue15715] __import__ now raises with non-existing items in fromlist in 3.3

2012-08-16 Thread Simon Feltman

New submission from Simon Feltman:

This came up while trying to build pygobject with Python 3.3. The problem is 
there are some erroneous imports in the fromlist with these bindings that can 
easily be fixed. But it is a behavioral change so I just wanted to raise 
awareness if it is not already known.

$ python3.2 -c __import__('http', fromlist=['blah'])
(works)

$ python3.3 -c __import__('http', fromlist=['blah'])
Traceback (most recent call last):
  File string, line 1, in module
ImportError: No module named 'http.blah'


Note this is also the case when using the C API: PyImport_ImportModuleEx

--
components: None
messages: 168423
nosy: sfeltman
priority: normal
severity: normal
status: open
title: __import__ now raises with non-existing items in fromlist in 3.3
versions: Python 3.3

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



[issue15715] __import__ now raises with non-existing items in fromlist in 3.3

2012-08-16 Thread Simon Feltman

Changes by Simon Feltman s.felt...@gmail.com:


--
type:  - behavior

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



[issue15715] __import__ now raises with non-existing items in fromlist in 3.3

2012-08-16 Thread Eric Snow

Eric Snow added the comment:

While this is a regression, 3.3 definitely puts an increased emphasis on using 
importlib.import_module() instead of builtins.__import__().  Any reason why 
import_module() isn't used?

As to the regression, while the current behavior makes more sense, it is 
contrary to a common idiom when using __import__().  However, given the push 
away from using __import__(), perhaps it can just stay this way.  Oh backward 
compatibility...

--
nosy: +brett.cannon, eric.snow

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



[issue15715] __import__ now raises with non-existing items in fromlist in 3.3

2012-08-16 Thread Simon Feltman

Simon Feltman added the comment:

I think pygobject still supports Python 2.5 which it look like importlib is 
available.

I've submitted a patch to pygobject which will work regardless of if this 
regression is fixed or not: https://bugzilla.gnome.org/show_bug.cgi?id=682051

--

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



[issue15715] __import__ now raises with non-existing items in fromlist in 3.3

2012-08-16 Thread Simon Feltman

Simon Feltman added the comment:

Should have been ...Python 2.5 which it looks like importlib is NOT available.

--

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



[issue15715] __import__ now raises with non-existing items in fromlist in 3.3

2012-08-16 Thread Antoine Pitrou

Antoine Pitrou added the comment:

Unless it is difficult to fix, I think this regression should be addressed 
before 3.3 final. Georg?

--
components: +Interpreter Core, Library (Lib) -None
nosy: +pitrou
priority: normal - release blocker
stage:  - needs patch

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



[issue15715] __import__ now raises with non-existing items in fromlist in 3.3

2012-08-16 Thread Antoine Pitrou

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


--
nosy: +georg.brandl

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



[issue13475] Add '-p'/'--path0' command line option to override sys.path[0] initialisation

2012-08-16 Thread Gregory P. Smith

Gregory P. Smith added the comment:

I'd also like a command line flag to override PYTHONPATH (which could also be 
used in combination with -E so that you could still set the PYTHONPATH while 
ignoring everything else).  I'll file a separate feature request for that.

--
nosy: +gregory.p.smith

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



[issue15716] Ability to specify the PYTHONPATH via a command line flag

2012-08-16 Thread Gregory P. Smith

New submission from Gregory P. Smith:

I'd like a command line flag to override PYTHONPATH.  It could also be used in 
combination with -E so that you could still set the PYTHONPATH while ignoring 
everything else from the environment.

--
messages: 168429
nosy: gregory.p.smith
priority: normal
severity: normal
status: open
title: Ability to specify the PYTHONPATH via a command line flag

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



[issue15716] Ability to specify the PYTHONPATH via a command line flag

2012-08-16 Thread Eric Snow

Changes by Eric Snow ericsnowcurren...@gmail.com:


--
nosy: +eric.snow

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



[issue15355] generator docs should mention already-executing exception

2012-08-16 Thread R. David Murray

R. David Murray added the comment:

Chris, if Nick is too busy to reply right now and you want to move this along, 
you could write some tests (not necessarily for inclusion in the test suite) to 
confirm that the doc you are adding is correct.  I don't know enough about 
generators to comment myself, I'd have to write tests :)

--
nosy: +r.david.murray

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



[issue4253] Maildir dumpmessage on

2012-08-16 Thread Petri Lehtinen

Petri Lehtinen added the comment:

No reply in two years, closing.

--
nosy: +petri.lehtinen
resolution:  - invalid
status: open - closed

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



[issue15715] __import__ now raises with non-existing items in fromlist in 3.3

2012-08-16 Thread Eric Snow

Eric Snow added the comment:

The failure output with -v:

...
# /home/esnow/projects/cpython/Lib/http/__pycache__/__init__.cpython-33.pyc 
matches /home/esnow/projects/cpython/Lib/http/__init__.py
# code object from 
/home/esnow/projects/cpython/Lib/http/__pycache__/__init__.cpython-33.pyc
import 'http' # _frozen_importlib.SourceFileLoader object at 0x7ff82770d450
Traceback (most recent call last):
  File string, line 1, in module
  File frozen importlib._bootstrap, line 1578, in _handle_fromlist
  File frozen importlib._bootstrap, line 310, in _call_with_frames_removed
  File frozen importlib._bootstrap, line 1530, in _find_and_load
  File frozen importlib._bootstrap, line 1494, in _find_and_load_unlocked
ImportError: No module named 'http.blah'
...

--

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



[issue15715] __import__ now raises with non-existing items in fromlist in 3.3

2012-08-16 Thread Eric Snow

Eric Snow added the comment:

Here's a simple patch the allows bogus names in the fromlist.  I'm going to 
verify that this matches the 3.2 semantics, which may not be so cut-and-dry.

--
keywords: +patch
Added file: http://bugs.python.org/file26876/issue15715.diff

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