[issue7139] Incorrect serialization of end-of-line characters in attribute values

2009-10-15 Thread Moriyoshi Koizumi

New submission from Moriyoshi Koizumi mozo+pyt...@mozo.jp:

ElementTree doesn't correctly serialize end-of-line characters (#xa, 
#xd) in attribute values.  Since bare end-of-line characters are 
converted to #x20 by the parser according to the specification [1], such 
characters that are represented as character references in the original 
document must be serialized in the same form.

[1] http://www.w3.org/TR/xml11/#AVNormalize   

### sample code

from xml.etree.ElementTree import ElementTree
from cStringIO import StringIO

# builder = ElementTree(file=StringIO(foo\x0d/foo))
# out = StringIO()
# builder.write(out)
# print out.getvalue()

out = StringIO()
ElementTree(file=StringIO(
'''?xml version=1.0 encoding=UTF-8 ?
!DOCTYPE foo [
!ELEMENT foo (#PCDATA)
!ATTLIST foo attr CDATA 
]
foo attr=   test
#13;test#32; test#10;a  #10;/foo
''')).write(out)
# should be foo attr=   test #13;test  test#10;a  \x0a/foo
print out.getvalue()

out = StringIO()
ElementTree(file=StringIO(
'''?xml version=1.0 encoding=UTF-8 ?
!DOCTYPE foo [
!ELEMENT foo (#PCDATA)
!ATTLIST foo attr NMTOKENS 
]
foo attr=   test
#13;test#32; test#10;a  #10;/foo
''')).write(out)
# should be foo attr=test #13;test test#10;a\x0a/foo
print out.getvalue()

--
components: XML
messages: 94074
nosy: moriyoshi
severity: normal
status: open
title: Incorrect serialization of end-of-line characters in attribute values
type: behavior
versions: Python 2.6

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



[issue7139] ElementTree: Incorrect serialization of end-of-line characters in attribute values

2009-10-15 Thread Moriyoshi Koizumi

Changes by Moriyoshi Koizumi mozo+pyt...@mozo.jp:


--
title: Incorrect serialization of end-of-line characters in attribute values - 
ElementTree: Incorrect serialization of end-of-line characters in attribute 
values

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



[issue7138] elementtree segfaults on invalid xml declaration

2009-10-15 Thread Ezio Melotti

Ezio Melotti ezio.melo...@gmail.com added the comment:

Confirmed on 3.1 on Windows too.

--
assignee:  - effbot
nosy: +effbot, ezio.melotti
priority:  - high
versions: +Python 3.1 -Python 2.5

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



[issue7139] ElementTree: Incorrect serialization of end-of-line characters in attribute values

2009-10-15 Thread Ezio Melotti

Changes by Ezio Melotti ezio.melo...@gmail.com:


--
assignee:  - effbot
nosy: +effbot
priority:  - normal

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



[issue7138] elementtree segfaults on invalid xml declaration

2009-10-15 Thread chuck

chuck jan.hos...@gmail.com added the comment:

I'm seeing this on the built-in python on os x 10.6, too:
Python 2.6.1 (r261:67515, Jul  7 2009, 23:51:51) 
[GCC 4.2.1 (Apple Inc. build 5646)] on darwin


But neither with the trunk
Python 2.7a0 (trunk:75433M, Oct 15 2009, 08:27:13) 
[GCC 4.2.1 (Apple Inc. build 5646)] on darwin

nor with a ports installation
Python 2.6.3 (r263:75183, Oct  7 2009, 07:05:03) 
[GCC 4.2.1 (Apple Inc. build 5646)] on darwin

--
nosy: +chuck

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



[issue7139] ElementTree: Incorrect serialization of end-of-line characters in attribute values

2009-10-15 Thread Moriyoshi Koizumi

Moriyoshi Koizumi mozo+pyt...@mozo.jp added the comment:

Tabs must be converted to character references as well.

--

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



[issue5243] Missing dependency in distutils build

2009-10-15 Thread Tarek Ziadé

Tarek Ziadé ziade.ta...@gmail.com added the comment:

It looks like there's a missing part in the patch: get_outputs(), and
get_inputs() should also return files created in build()

Now something I don't understand is how reportlab distribution is doing
to copy the compiled extensions when install is called.

Could you point me please to the package so I can test that ?

Thanks !

--
priority:  - normal
resolution:  - accepted
versions: +Python 3.0, Python 3.2 -Python 2.4, Python 2.5

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



[issue7080] locale.strxfrm raises MemoryError

2009-10-15 Thread egreen

egreen egr...@operamail.com added the comment:

Could someone triage this?  And review my simple fix?  I think it should
be a release blocker.

It seems to me to be a problem on all 64-bit non-Windows platforms, or
any platform if using UCS-4.  The 4 high-order bytes of an 8-byte
Py_ssize_t variable are not initialized.

Thanks.

--
components: +Extension Modules -Library (Lib)

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



[issue7138] elementtree segfaults on invalid xml declaration

2009-10-15 Thread Walter Dörwald

Walter Dörwald wal...@livinglogic.de added the comment:

Here is a stacktrace of the crash with the system Python 2.6.1 on Mac OS
X 10.6.1:

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_INVALID_ADDRESS at address: 0x00010100
0x7fff810f96b8 in XML_SetEncoding ()
(gdb) bt
#0  0x7fff810f96b8 in XML_SetEncoding ()
#1  0x7fff810ecad0 in XML_GetCurrentLineNumber ()
#2  0x0001005c2150 in initpyexpat ()
#3  0x0001005c3516 in initpyexpat ()
#4  0x0001000891df in PyEval_EvalFrameEx ()
#5  0x000100089330 in PyEval_EvalFrameEx ()
#6  0x000100089330 in PyEval_EvalFrameEx ()
#7  0x00010008accf in PyEval_EvalCodeEx ()
#8  0x00010008ad62 in PyEval_EvalCode ()
#9  0x0001000a265a in Py_CompileString ()
#10 0x0001000a44dd in PyRun_InteractiveOneFlags ()
#11 0x0001000a4615 in PyRun_InteractiveLoopFlags ()
#12 0x0001000a4685 in PyRun_AnyFileExFlags ()
#13 0x0001000b0286 in Py_Main ()
#14 0x00010e6c in ?? ()

--
nosy: +doerwalter

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



[issue7123] Multiprocess Process does not always exit when run from a thread.

2009-10-15 Thread Peter Saunders

Peter Saunders p...@fodder.org.uk added the comment:

Tested on Linux, and repeated the issue - just to confirm this isn't a
Solaris specific issue.

Tested using dummy_threading - bug does not appear when that is used.

Added _verbose=True to threads, and log_to_stderr(SUBDEBUG) set for Process.

Attached is the output of the script with those set. 

Other odd things to notice, and some point, more than 2 children
sometimes exist.. 

isalive PID: 7646 : True
isalive PID: 7652 : True
isalive PID: 7653 : True
isalive PID: 7646 : True
isalive PID: 7652 : True
isalive PID: 7653 : True
isalive PID: 7646 : True
isalive PID: 7653 : True

The code starts 2 threads, which start 2 processes. Both threads are
joined before new ones are started.. So, in theroy, only 2 should be
able to exist at once.. ?

--
Added file: http://bugs.python.org/file15132/results1.txt

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



[issue7140] imp.new_module does not function correctly if the module is returned from a function and used directly

2009-10-15 Thread Jamie Kirkpatrick

New submission from Jamie Kirkpatrick j...@kirkconsulting.co.uk:

See the testcase included.  If you instead assign the result of the 
get_module() call to a variable and then make the call to the function 
defined in that module it works as expected.

--
components: Library (Lib)
files: testcase.py
messages: 94082
nosy: jkp
severity: normal
status: open
title: imp.new_module does not function correctly if the module is returned 
from a function and used directly
type: behavior
versions: Python 2.5, Python 2.6
Added file: http://bugs.python.org/file15133/testcase.py

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



[issue6973] subprocess.Popen.send_signal doesn't check whether the process has terminated

2009-10-15 Thread Ezio Melotti

Changes by Ezio Melotti ezio.melo...@gmail.com:


--
nosy: +ezio.melotti
priority:  - normal
stage:  - needs patch

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



[issue7140] imp.new_module does not function correctly if the module is returned from a function and used directly

2009-10-15 Thread Jamie Kirkpatrick

Jamie Kirkpatrick j...@kirkconsulting.co.uk added the comment:

Updated the testcase to show that the __dict__ for the module is incorrect 
unless the module is assigned to a temp variable.

--
Added file: http://bugs.python.org/file15134/testcase.py

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



[issue7138] elementtree segfaults on invalid xml declaration

2009-10-15 Thread Amaury Forgeot d'Arc

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

This has already been fixed with r74429, but no issue was filed at the time.

It should be backported to 2.6 and 3.1 at least.
And probably to 2.5 as well, because a crash on XML input can be
considered as a security issue.

Raising to deferred blocker so that it does not block 2.6.4.

--
nosy: +amaury.forgeotdarc, barry
priority: high - deferred blocker

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



[issue7080] locale.strxfrm raises MemoryError

2009-10-15 Thread Antoine Pitrou

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

Nice catch. I wonder why not all of our modules are PY_SSIZE_T_CLEAN in
py3k.
This function is not actually tested, could you add a test to the
regression suite?

--
nosy: +pitrou
priority:  - high

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



[issue7138] elementtree segfaults on invalid xml declaration

2009-10-15 Thread Antoine Pitrou

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

Is our copy of expat in sync with upstream? How does maintenance happen?

--
nosy: +pitrou

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



[issue7138] elementtree segfaults on invalid xml declaration

2009-10-15 Thread Ralf Schmitt

Changes by Ralf Schmitt sch...@gmail.com:


--
nosy: +schmir

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



[issue7138] elementtree segfaults on invalid xml declaration

2009-10-15 Thread Amaury Forgeot d'Arc

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

The same thing had been discovered in expat 12 months before:
http://expat.cvs.sourceforge.net/viewvc/expat/expat/lib/xmltok_impl.c?r1=1.13r2=1.15
But expat hasn't made any release since 2.0.1, in June 2007...

Are you suggesting to update our copy of expat with its latest cvs revision?

--

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



[issue7138] elementtree segfaults on invalid xml declaration

2009-10-15 Thread Antoine Pitrou

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

I don't know really. I wonder how Linux distributions handle maintenance
of that library.
Perhaps Fred Drake can help us?

--
assignee: effbot - 
nosy: +fdrake

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



[issue7138] elementtree segfaults on invalid xml declaration

2009-10-15 Thread Amaury Forgeot d'Arc

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

FWIW, the latest Debian package: http://packages.debian.org/sid/libexpat1
is also vulnerable (I checked in the sources expat_2.0.1.orig.tar.gz,
and it's not corrected in expat_2.0.1-4.diff.tgz)

--

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



[issue7120] logging depends on multiprocessing

2009-10-15 Thread Barry A. Warsaw

Barry A. Warsaw ba...@python.org added the comment:

Please apply this for 2.6.4rc2

--
priority:  - release blocker
resolution: fixed - accepted
status: pending - open

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



[issue6973] subprocess.Popen.send_signal doesn't check whether the process has terminated

2009-10-15 Thread Marco Buccini

Marco Buccini marcu...@gmail.com added the comment:

I agree with Milko. 

However, I think Popen.send_signal should poll() before sending any
signals, without resetting any variables to zero (or None).
In this way, if you poll() before sending a signal, if the return code
is None, the child is still running. If the poll return code is
different than None, the child has been terminated, so you must not send
anything to the child process.

In this way, instead of polling before sending signals to check if the
child has been terminated, we can make Python do the work for us.

I've provided a patch. All the tests pass.
A new test has been added: test_terminate_already_terminated_child.
This method asserts `terminate()` (through `send_signal`) raises an
OSError exception. 

However, even though you try the old version of subprocess.py all the
tests pass. This happens because the method `send_signal` calls
os.kill() (or Terminate for Windows systems) that can raise an OSError
exception if the process to which it send the signal does not exist. 
`send_signal` has been fixed to be a safer method, so that it raises an
OSError exception if the child has been terminated.

--
keywords: +patch
nosy: +markon
Added file: http://bugs.python.org/file15135/subprocess.patch

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



[issue6973] subprocess.Popen.send_signal doesn't check whether the process has terminated

2009-10-15 Thread Marco Buccini

Changes by Marco Buccini marcu...@gmail.com:


Added file: http://bugs.python.org/file15136/test_subprocess.patch

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



[issue6973] subprocess.Popen.send_signal doesn't check whether the process has terminated

2009-10-15 Thread Marco Buccini

Changes by Marco Buccini marcu...@gmail.com:


Removed file: http://bugs.python.org/file15136/test_subprocess.patch

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



[issue6973] subprocess.Popen.send_signal doesn't check whether the process has terminated

2009-10-15 Thread Marco Buccini

Changes by Marco Buccini marcu...@gmail.com:


Added file: http://bugs.python.org/file15137/test_subprocess.patch

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



[issue7080] locale.strxfrm raises MemoryError

2009-10-15 Thread egreen

egreen egr...@operamail.com added the comment:

All right.

The function strcoll also isn't tested (except for issue #3303).  I'll
look into that one, too.

--

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



[issue7141] 2to3 should add from __future__ import print_statement

2009-10-15 Thread Daniel Stutzbach

New submission from Daniel Stutzbach dan...@stutzbachenterprises.com:

I'm in the process of converting several Python scripts so that they
work under both Python 2.6 and 3.1.  For the most part, 2to3 does an
amazing job.  Great tool.

One little feature request: could we make it add from __future__ import
print_statement to the top of files?

That one change is enough to make 95% of my converted scripts work fine
under 2.6 and 3.1 instead of just 3.1.

--
components: 2to3 (2.x to 3.0 conversion tool)
messages: 94093
nosy: stutzbach
severity: normal
status: open
title: 2to3 should add from __future__ import print_statement
type: feature request
versions: Python 2.7, Python 3.2

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



[issue7141] 2to3 should add from __future__ import print_statement

2009-10-15 Thread Georg Brandl

Changes by Georg Brandl ge...@python.org:


--
assignee:  - benjamin.peterson
nosy: +benjamin.peterson

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



[issue7142] __repr__ of memoryview object has type unicode; should be str.

2009-10-15 Thread Mark Dickinson

New submission from Mark Dickinson dicki...@gmail.com:

Objects/memoryobject.c makes calls to PyUnicode_FromString and 
PyUnicode_FromFormat.  This prevents building of Python with the --
disable-unicode option.

Here's a patch.

--
assignee: pitrou
components: Interpreter Core
files: memoryview.patch
keywords: patch
messages: 94094
nosy: mark.dickinson, pitrou
severity: normal
stage: patch review
status: open
title: __repr__ of memoryview object has type unicode; should be str.
type: behavior
versions: Python 2.7
Added file: http://bugs.python.org/file15138/memoryview.patch

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



[issue7140] imp.new_module does not function correctly if the module is returned from a function and used directly

2009-10-15 Thread Benjamin Peterson

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

Fixed in r75437.

--
nosy: +benjamin.peterson
resolution:  - fixed
status: open - closed

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



[issue7142] __repr__ of memoryview object has type unicode; should be str.

2009-10-15 Thread Antoine Pitrou

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

Looks good, obviously.

--

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



[issue7142] __repr__ of memoryview object has type unicode; should be str.

2009-10-15 Thread Mark Dickinson

Mark Dickinson dicki...@gmail.com added the comment:

Thanks, Antoine.  Fixed in r75438.

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

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



[issue2054] add ftp-tls support to ftplib - RFC 4217

2009-10-15 Thread Lance Edgar

Changes by Lance Edgar la...@edbob.org:


--
nosy: +lgedgar

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



[issue2054] add ftp-tls support to ftplib - RFC 4217

2009-10-15 Thread Giampaolo Rodola'

Giampaolo Rodola' billiej...@users.sourceforge.net added the comment:

Are there chances to see this reviewed?

--

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



[issue2054] add ftp-tls support to ftplib - RFC 4217

2009-10-15 Thread Antoine Pitrou

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


Removed file: http://bugs.python.org/file9775/unnamed

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



[issue2054] add ftp-tls support to ftplib - RFC 4217

2009-10-15 Thread Antoine Pitrou

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


Removed file: http://bugs.python.org/file9782/unnamed

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



[issue2054] add ftp-tls support to ftplib - RFC 4217

2009-10-15 Thread Antoine Pitrou

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


Removed file: http://bugs.python.org/file9783/unnamed

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



[issue2054] add ftp-tls support to ftplib - RFC 4217

2009-10-15 Thread Antoine Pitrou

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


Removed file: http://bugs.python.org/file9807/unnamed

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



[issue2054] add ftp-tls support to ftplib - RFC 4217

2009-10-15 Thread Antoine Pitrou

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


Removed file: http://bugs.python.org/file10784/unnamed

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



[issue2054] add ftp-tls support to ftplib - RFC 4217

2009-10-15 Thread Antoine Pitrou

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


Removed file: http://bugs.python.org/file13161/unnamed

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



[issue2054] add ftp-tls support to ftplib - RFC 4217

2009-10-15 Thread Antoine Pitrou

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


Removed file: http://bugs.python.org/file13171/unnamed

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



[issue2054] add ftp-tls support to ftplib - RFC 4217

2009-10-15 Thread Antoine Pitrou

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

Well, first some tests should be added.
As for reviewing, it needs to be done by someone competent with FTP and
SSL/TLS. If no such person is available and you are confident that the
patch is ok (and ready to do necessary maintenance), then perhaps you
can commit it. But please add tests first. It is really too easy to
accidentally break a functionality which is not exercised by the test suite.

Oh, and you need to update the documentation too :)

--
stage:  - patch review
versions: +Python 2.7, Python 3.2 -Python 2.6, Python 3.0

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



[issue7143] get_payload(decode=True) eats last newline

2009-10-15 Thread Andreas Thomas

New submission from Andreas Thomas raed...@gmail.com:

The attachment of my sample email contains '123\n', but get_payload
(decode=True) returns '123'.
The source of this error is the function _bdecode from the email.utils 
module, which gets called for decoding base64 encoded payloads. Here 
the last \n gets stripped away, because (comment in the function):

# We can't quite use base64.encodestring() since it tacks on a courtesy
# newline.  Blech!

I don't think that's true. At least not for Python 2.5.4 and upwards. 
Also note the encodestring instead of decodestring.
In fact calling

base64.decodestring(part.get_payload())

returns the correct value, so I propose to remove this function 
completely and just use the standard decoding method.
Please note that base64.encodestring really tacks on a \n.

--
components: Library (Lib)
files: test.eml
messages: 94100
nosy: athomas
severity: normal
status: open
title: get_payload(decode=True) eats last newline
type: behavior
versions: Python 2.5, Python 2.6, Python 2.7, Python 3.0, Python 3.1, Python 3.2
Added file: http://bugs.python.org/file15139/test.eml

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



[issue2054] add ftp-tls support to ftplib - RFC 4217

2009-10-15 Thread Giampaolo Rodola'

Giampaolo Rodola' billiej...@users.sourceforge.net added the comment:

I can surely write tests altough I think that issue 3890 might cause 
some problems since the test server I included some months ago is 
asyncore-based and hence asynchronous.

I have a good knowledge of the FTP protocol but someone with a good 
knowledge of SSL willing to review the patch would surely be useful.


In particular I would ask Bill an update about this comment:

 Probably what I should do is fix httplib, that would  provide an 
 example we could extend to the rest of the modules.
 Bill

I don't follow the development of other stdlib modules that use ssl so 
I'm not sure how to proceed to conform with them.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue2054
___
___
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

2009-10-15 Thread Antoine Pitrou

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

Rather than having a kind of global module registry, locks could keep
track of what was the last PID, and reinitialize themselves if it changed.
This is assuming getpid() is fast :-)

--
nosy: +pitrou

___
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



[issue2054] add ftp-tls support to ftplib - RFC 4217

2009-10-15 Thread Antoine Pitrou

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

From a quick look at the patch, if you call login() twice, the socket
will be wrapped twice as well? Perhaps auth_tls() should have a
protection against this.

In prot_p() and prot_c(), it seems that self._prot_p is updated
unconditionally, regardless of the FTP response.

In retrbinary(), retrlines(), storbinary() and storlines(), you
certainly want some try/finally blocks so that the data connection
always gets closed at the end.

--

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



[issue2054] add ftp-tls support to ftplib - RFC 4217

2009-10-15 Thread Antoine Pitrou

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

One more question, why is ssl_version=ssl.PROTOCOL_TLSv1 hardwired?

--

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



[issue3890] ssl.SSLSocket.recv() implementation may not work with non-blocking sockets

2009-10-15 Thread Jean-Paul Calderone

Jean-Paul Calderone exar...@divmod.com added the comment:

Antoine asked me to give my opinion on the non-blocking SSL API.  I can
say that the current behavior of SSLSocket.recv is certainly not very
good and probably makes SSLSocket useless for any non-blocking
application.  Letting the underlying want-read/want-write error bubble
up to the caller definitely makes more sense than blocking.

I haven't had a chance to look into the new SSL code in depth, so don't
construe this as a thorough review of the change, though.

--

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



[issue7144] imp.load_module in thread causes core dump on OSX 10.6

2009-10-15 Thread Pete Hunt

New submission from Pete Hunt floydoph...@gmail.com:

Apologies if I mess up the formatting - my first bug report submitted.

Steps to reproduce (OSX Snow Leopard, 2.6.3)

 import threading, imp
 def doit():
... print imp.load_module(cherrypy, None, 
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-
packages/CherryPy-3.1.2-py2.6.egg/cherrypy, ('', '', 5))
... 
 threading.Thread(target=doit).start()
 Trace/BPT trap

--
assignee: ronaldoussoren
components: Extension Modules, Interpreter Core, Macintosh
messages: 94106
nosy: peterhunt, ronaldoussoren
severity: normal
status: open
title: imp.load_module in thread causes core dump on OSX 10.6
versions: Python 2.6

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



[issue7144] imp.load_module in thread causes core dump on OSX 10.6

2009-10-15 Thread Ronald Oussoren

Ronald Oussoren ronaldousso...@mac.com added the comment:

This seems to be a known issue: importing extensions in a thread fails on 
OSX 10.6 (with a hard crash of the interpreter). The crash in inside the 
initialisation function for an Apple framework. 

I haven't been able to determine if the problem is in Python or OSX, 
although it likely is a problem in the OS and is definitely a regression 
in OSX (it works on 10.5 but crashes on 10.6).

--

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



[issue7145] UTF-16 BOM is not written by socket.makefile (but is expected by read)

2009-10-15 Thread Yang Zhang

New submission from Yang Zhang yaa...@gmail.com:

When I call s.makefile('r',encoding='utf-16').read(), this expects a BOM, 
but s.makefile('w',encoding='utf-16').write('hello') doesn't produce it. 
This is asymmetric.

BTW is there a way to prevent the reading file from expecting a BOM?

--
components: Library (Lib)
messages: 94108
nosy: yang
severity: normal
status: open
title: UTF-16 BOM is not written by socket.makefile (but is expected by read)
type: behavior
versions: Python 3.2

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



[issue7145] UTF-16 BOM is not written by socket.makefile (but is expected by read)

2009-10-15 Thread Yang Zhang

Yang Zhang yaa...@gmail.com added the comment:

To answer my own question: specify UTF-16BE or UTF-16LE

--

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



[issue7128] cPickle looking for non-existent package copyreg

2009-10-15 Thread Amaury Forgeot d'Arc

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

Here is a test+patch.
This does not apply to py3k: restricted mode does not exist there.

--
keywords: +patch
nosy: +amaury.forgeotdarc
Added file: http://bugs.python.org/file15140/cpickle_restricted.patch

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



[issue6973] subprocess.Popen.send_signal doesn't check whether the process has terminated

2009-10-15 Thread Marco Buccini

Changes by Marco Buccini marcu...@gmail.com:


Removed file: http://bugs.python.org/file15135/subprocess.patch

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



[issue6973] subprocess.Popen.send_signal doesn't check whether the process has terminated

2009-10-15 Thread Marco Buccini

Changes by Marco Buccini marcu...@gmail.com:


Added file: http://bugs.python.org/file15141/subprocess.patch

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



[issue6973] subprocess.Popen.send_signal doesn't check whether the process has terminated

2009-10-15 Thread Marco Buccini

Changes by Marco Buccini marcu...@gmail.com:


Removed file: http://bugs.python.org/file15141/subprocess.patch

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



[issue6973] subprocess.Popen.send_signal doesn't check whether the process has terminated

2009-10-15 Thread Marco Buccini

Changes by Marco Buccini marcu...@gmail.com:


Removed file: http://bugs.python.org/file15137/test_subprocess.patch

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



[issue6973] subprocess.Popen.send_signal doesn't check whether the process has terminated

2009-10-15 Thread Marco Buccini

Changes by Marco Buccini marcu...@gmail.com:


Added file: http://bugs.python.org/file15142/test_subprocess.patch

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



[issue6973] subprocess.Popen.send_signal doesn't check whether the process has terminated

2009-10-15 Thread Marco Buccini

Changes by Marco Buccini marcu...@gmail.com:


Added file: http://bugs.python.org/file15143/subprocess.patch

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



[issue7138] elementtree segfaults on invalid xml declaration

2009-10-15 Thread Ryan Williams

Ryan Williams r...@lindenlab.com added the comment:

Adding 2.5 back, looks like it was removed accidentally.

Also, here's a list of strings for testing purposes: 

['?xml \xee\xae\x94 ?', '?xml \xc4\x9d ?', '?xml \xc8\x84 ?',
'?xml \xd9\xb5 ?', '?xml \xd9\xaa ?', '?xml \xc9\x88 ?', '?xml
\xcb\x8c ?']

--
versions: +Python 2.5

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



[issue7146] [PATCH] platform.uname()[4] returns 'amd64' on Windows and 'x86-64' on Linux

2009-10-15 Thread Zooko O'Whielacronx

New submission from Zooko O'Whielacronx zo...@zooko.com:

Looking at http://bugs.python.org/setuptools/issue1 and reading the
source of Lib/platform.py, it appears to me that uname() returns
different strings identifying the amd64 architecture depending on what
operating system is running.  It would seem to me that it would be
better to report the same arch with the same string on all platforms.

Could someone with win64 report the output of:

python -c 'import platform;print platform.uname()[4]'

Here is a patch against trunk that just replaces any 'x86_64' with 'amd64':

HACK yukyuk:~/playground/python/trunk$ svn diff
Index: Lib/platform.py
===
--- Lib/platform.py (revision 75443)
+++ Lib/platform.py (working copy)
@@ -1225,6 +1225,9 @@
 system = 'Windows'
 release = 'Vista'

+#  normalize 'amd64' arch
+if machine == 'x86_64':
+machine = 'amd64'
 _uname_cache = system,node,release,version,machine,processor
 return _uname_cache

--
components: Library (Lib)
messages: 94112
nosy: zooko
severity: normal
status: open
title: [PATCH] platform.uname()[4] returns 'amd64' on Windows and 'x86-64' on 
Linux

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



[issue7147] Remove WITHOUT_COMPLEX from 3.x trunk

2009-10-15 Thread Skip Montanaro

New submission from Skip Montanaro s...@pobox.com:

I raised the topic of the use of WITHOUT_COMPLEX in python-dev.  Here's
a patch to remove it from the 3.x trunk.

--
components: Interpreter Core
files: nocomplex.diff
keywords: easy, needs review, patch, patch
messages: 94113
nosy: skip.montanaro
priority: normal
severity: normal
stage: patch review
status: open
title: Remove WITHOUT_COMPLEX from 3.x trunk
type: feature request
versions: Python 3.2
Added file: http://bugs.python.org/file15144/nocomplex.diff

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



[issue7146] [PATCH] platform.uname()[4] returns 'amd64' on Windows and 'x86-64' on Linux

2009-10-15 Thread Philip Jenvey

Changes by Philip Jenvey pjen...@underboss.org:


--
nosy: +lemburg, loewis

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



[issue3079] sys.exit() called from optparse - bad, bad, bad

2009-10-15 Thread Phillip M. Feldman

Phillip M. Feldman pfeld...@verizon.net added the comment:

The current behavior of optparse is contrary to how most of Python
works. optparse should throw a named exception that can be trapped and
identified by the calling program.  Doing a SystemExit is unacceptable.
 I can't believe that this is such a hard thing to fix.

--
nosy: +pfeld...@verizon.net

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue3079
___
___
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

2009-10-15 Thread Gregory P. Smith

Gregory P. Smith g...@krypto.org added the comment:

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

 Rather than having a kind of global module registry, locks could keep
 track of what was the last PID, and reinitialize themselves if it changed.
 This is assuming getpid() is fast :-)

Locks can't blindly release themselves because they find themselves
running in another process.

If anything if a lock is held and finds itself running in a new
process any attempt to use the lock should raise an exception so that
the bug is noticed.

I'm not sure a PID check is good enough.  old linux using linuxthreads
had a different pid for every thread, current linux with NPTL is more
like other oses with the same pid for all threads.

--

___
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



[issue3079] sys.exit() called from optparse - bad, bad, bad

2009-10-15 Thread R. David Murray

R. David Murray rdmur...@bitdance.com added the comment:

There was recently a long discussion of this on python-dev (in the
context of a proposal to add argparse to the stdlib; argparse does the
same thing).  The conclusion was that the current behavior is the most
useful behavior, and that if you don't want to exit you can either
subclass or catch SystemExit.

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

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



[issue1759169] clean up Solaris port and allow C99 extension modules

2009-10-15 Thread Zooko O'Whielacronx

Zooko O'Whielacronx zo...@zooko.com added the comment:

I just tried to port a library of mine -- zfec -- to Nexenta (the Ubuntu
variant built on top of OpenSolaris).  I hit this bug because the
Nexenta folks don't use all the patches that are applied to Python by
the Solaris folks.  My port of my library is blocked until the Nexenta
folks apply this patch to their package of Python:

https://bugs.launchpad.net/python/+bug/452667 # can't compile Python
modules that use C99

--

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



[issue7148] socket.py: r75412 broke build

2009-10-15 Thread Kurt B. Kaiser

New submission from Kurt B. Kaiser k...@shore.net:

buildbots failing since r75412:

testSocketServer (test.test_ssl.ThreadedTests) ... Traceback (most 
recent call last):
  File /home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/
SocketServer.py, line 282, in _handle_request_noblock
self.process_request(request, client_address)
  File /home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/
SocketServer.py, line 308, in process_request
self.finish_request(request, client_address)
  File /home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/
SocketServer.py, line 321, in finish_request
self.RequestHandlerClass(request, client_address, self)
  File /home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/
SocketServer.py, line 639, in __init__
self.finish()
  File /home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/
SocketServer.py, line 692, in finish
self.wfile.flush()
  File /home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/
socket.py, line 300, in flush
self._sock.sendall(view[write_offset:write_offset+buffer_size])
  File /home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/
ssl.py, line 203, in sendall
v = self.send(data[count:])
  File /home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/
ssl.py, line 94, in lambda
self.send = lambda data, flags=0: SSLSocket.send(self, data, flags)
  File /home/buildslave/python-trunk/trunk.norwitz-x86/build/Lib/
ssl.py, line 174, in send
v = self._sslobj.write(data)
TypeError: must be string or read-only buffer, not memoryview

--
assignee: pitrou
components: Library (Lib)
messages: 94118
nosy: kbk, pitrou
priority: high
severity: normal
status: open
title: socket.py: r75412 broke build
type: behavior
versions: Python 2.7

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



[issue7148] socket.py: r75412 broke build

2009-10-15 Thread R. David Murray

R. David Murray rdmur...@bitdance.com added the comment:

This is a duplicate of issue 7133, where Antoine has already proposed a
patch.

--
nosy: +r.david.murray
resolution:  - duplicate
stage:  - committed/rejected
status: open - closed
superseder:  - test_ssl failure

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



[issue6941] Socket error when launching IDLE

2009-10-15 Thread Kurt B. Kaiser

Kurt B. Kaiser k...@shore.net added the comment:

08jpurcell  unresponsive, ignoring for now (but see suggestions below)

bdouglasoz: had a firewall blocking the subprocess, apparently works 
for her now.  I'd point out that Notepad is just an editor, IDLE gives 
you much more.  Linux is great, but IDLE works fine with Windows XP and 
since most people use Windows, we have to be sure that it does!

adgprogramming: first, bring up your task manager and make sure there 
are no python processes running.  2.6.x subprocesses can get stuck.  
Then make sure that your firewall isn't blocking socket access to 
localhost.  Then restart IDLE.  IDLE 3.1.1 may work for you since it 
has the recent enhancement that allows multiple copies of IDLE to run 
simultaneously, but it still needs interprocess access via sockets.

--
nosy: +kbk
priority:  - normal
resolution:  - works for me
status: open - pending

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



[issue7148] socket.py: r75412 broke build

2009-10-15 Thread Kurt B. Kaiser

Kurt B. Kaiser k...@shore.net added the comment:

bah.  I looked twice for a prior bug and missed it!  Sorry

--

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



[issue3079] sys.exit() called from optparse - bad, bad, bad

2009-10-15 Thread Phillip M. Feldman

Phillip M. Feldman pfeld...@verizon.net added the comment:

Thanks for the response!

I can indeed catch SystemExit, but I would like to be able to take one 
action (terminate the program) if the user supplied an unknown option, 
and another action (prompt for a new value) if the user supplied a bad 
value for an option.  I suspect that I can achieve this by subclassing, 
but I'm not yet at that level of Python sophistication.

Yours,

Phillip

R. David Murray wrote:
 R. David Murray rdmur...@bitdance.com added the comment:

 There was recently a long discussion of this on python-dev (in the
 context of a proposal to add argparse to the stdlib; argparse does the
 same thing).  The conclusion was that the current behavior is the most
 useful behavior, and that if you don't want to exit you can either
 subclass or catch SystemExit.

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

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



--

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



[issue7133] test_ssl failure

2009-10-15 Thread Kurt B. Kaiser

Kurt B. Kaiser k...@shore.net added the comment:

Reviewed, built, tests ok.

Linux trader 2.6.18-ARCH #1 SMP PREEMPT Sun Nov 19 09:14:35 CET 2006 
i686 Intel(R) Pentium(R) 4 CPU 2.40GHz GenuineIntel GNU/Linux

vote +1  weight +0.1 :-)

--
nosy: +kbk
priority:  - normal

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



[issue7149] 2.6.4rc1 regression: test_urllib2 fails on OS X with UnboundLocalError

2009-10-15 Thread Ned Deily

New submission from Ned Deily n...@acm.org:

Possible Release Blocker

A number of proxy test cases in test_urllib2 are now failing with:

ERROR: test_proxy (test.test_urllib2.HandlerTests)
--
Traceback (most recent call last):
  File 
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/test/te
st_urllib2.py, line 940, in test_proxy
r = o.open(req)
  File 
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/urllib2
.py, line 389, in open
response = self._open(req, data)
  File 
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/urllib2
.py, line 407, in _open
'_open', req)
  File 
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/urllib2
.py, line 367, in _call_chain
result = func(*args)
  File 
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/urllib2
.py, line 696, in lambda
meth(r, proxy, type))
  File 
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/urllib2
.py, line 705, in proxy_open
if req.host and proxy_bypass(req.host):
  File 
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/urllib.
py, line 1398, in proxy_bypass
return proxy_bypass_macosx_sysconf(host)
  File 
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/urllib.
py, line 1367, in proxy_bypass_macosx_sysconf
if hostIP is None:
UnboundLocalError: local variable 'hostIP' referenced before assignment

The root cause is the problem identified in Issue7044.  This is now 
showing up in test_urllib2 because of the changes in urllib2 introduced 
by Issue6894 which was checked into the release-26maint branch during 
the window between the release of 2.6.3 and the freezing for 2.6.4.

--
assignee: ronaldoussoren
components: Library (Lib), Macintosh
messages: 94124
nosy: barry, ned.deily, orsenthil, ronaldoussoren
severity: normal
status: open
title: 2.6.4rc1 regression: test_urllib2 fails on OS X with UnboundLocalError
versions: Python 2.6

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



[issue7044] urllib.urlopen crashes when used on Mac OS 10.6.1 through a proxy

2009-10-15 Thread Ned Deily

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

See also Issue7149.

--
nosy: +ned.deily

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



[issue7044] urllib.urlopen crashes when used on Mac OS 10.6.1 through a proxy

2009-10-15 Thread Senthil Kumaran

Changes by Senthil Kumaran orsent...@gmail.com:


--
nosy: +orsenthil

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



[issue7149] 2.6.4rc1 regression: test_urllib2 fails on OS X with UnboundLocalError

2009-10-15 Thread Ronald Oussoren

Ronald Oussoren ronaldousso...@mac.com added the comment:

Barry: this should be a release blocker, I introduced the problem around 
or after 2.6.3 :-(

When do you cut rc2? I probably won't be able to provide a patch myself 
until Saturday afternoon (CEST).

--
priority:  - release blocker

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



[issue7149] 2.6.4rc1 regression: test_urllib2 fails on OS X with UnboundLocalError

2009-10-15 Thread Senthil Kumaran

Senthil Kumaran orsent...@gmail.com added the comment:

In the Issue7044, the reporter has identified the root cause and
possible fix too.

In Python 2.6.3 on Mac OS 10.6.1, there is a bug in 
lib/python2.6/urllib.py, line 1367. The variable hostIP is used before 
it's defined. You can fix it by adding hostIP = None at around line 
1355.


That change might fix both the issues. 

I don't have a OS X to verify the fix tough.

--

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