[issue6106] read_until

2009-07-27 Thread Irek Wlizlo

Irek Wlizlo  added the comment:

Hi,
I updated my profile with name - Irek Wlizlo

--

___
Python tracker 

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



[issue5833] readline update

2009-07-27 Thread Dror Levin

Dror Levin  added the comment:

This bug was reported in Arch (http://bugs.archlinux.org/task/15548) and
Gentoo (https://bugs.gentoo.org/show_bug.cgi?id=279234)

--
nosy: +spatz

___
Python tracker 

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



[issue6106] read_until

2009-07-27 Thread Jack Diederich

Jack Diederich  added the comment:

Thanks for the update Irek (and the help!). You are now listed in Misc/ACKS.

--

___
Python tracker 

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



[issue6585] configure.in forces specific autoconf version

2009-07-27 Thread Antonio Cavallo

New submission from Antonio Cavallo :

Hi,
I've seen the code change in /python/trunk/configure.in (rev.  74072): 
it enforces a specific autoconfig version (2.61) in order to build 
python.

Unfortunately OpenSuSE 11.1 (mainstream at time of writing) has an 
updated version of autoconf 2.63 (and I think is true for Mandriva as 
well). 

Wouldn't be better to force the 2.61 being the minimal version for 
autoconf allowing more up-to-date versions to be used?

You can have a look into http://pyvm.sourceforge.net/ where continuous 
build of the python interpreter are stored for further references.

--
components: Build
messages: 90980
nosy: alexandre.vassalotti, cavallo71
severity: normal
status: open
title: configure.in forces specific autoconf version
type: compile error
versions: Python 2.7

___
Python tracker 

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



[issue5992] spurious space after opening parenthesis when auto-completing

2009-07-27 Thread Antoine Pitrou

Changes by Antoine Pitrou :


--
resolution:  -> duplicate
status: open -> closed
superseder:  -> readline update

___
Python tracker 

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



[issue5833] readline update

2009-07-27 Thread Antoine Pitrou

Antoine Pitrou  added the comment:

The patch should be broken into several, one for each bug fix or
enhancement.

Remarks and questions:
- is the readline v6.x fix (which I'm interested in) compatible with
previous readline versions?
- what does "removes '~$-/' from the completer chars list to make the
next item work" mean exactly? is it a bugfix or a new feature?
- I'm not sure filename completion is uncontroversial, it's the kind of
advanced features which we usually let third-party tools (e.g. IPython)
handle if they want to; it may also cause spurious IOs and error messages

--
nosy: +pitrou
priority:  -> normal
type:  -> behavior
versions: +Python 2.7, Python 3.1, Python 3.2

___
Python tracker 

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



[issue6585] configure.in forces specific autoconf version

2009-07-27 Thread Antoine Pitrou

Antoine Pitrou  added the comment:

Does the check trigger when building Python, or only when rebuilding the
configure script itself? I think we ship a prebuilt configure script
precisely so that people don't have to care about autoconf versions and
the like.

--
nosy: +pitrou

___
Python tracker 

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



[issue6586] Documentation of os.write and os.read are inaccurate.

2009-07-27 Thread Chris Liechti

New submission from Chris Liechti :

Documentation of os.write and os.read are inaccurate, it states that the
methods work with 'str' (or strings), which is wrong.

- os.write expects an instance of bytes or buffer
- os.read returns an instance of bytes

The implementation is OK, it fits well with the new io library but the
docs don't describe the implementation.

--
assignee: georg.brandl
components: Documentation
messages: 90983
nosy: cliechti, georg.brandl
severity: normal
status: open
title: Documentation of os.write and os.read are inaccurate.
versions: Python 3.0, Python 3.1, Python 3.2

___
Python tracker 

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



[issue6585] configure.in forces specific autoconf version

2009-07-27 Thread Antonio Cavallo

Antonio Cavallo  added the comment:

Yes the rebuild does an autoreconf step.

--

___
Python tracker 

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



[issue2636] Regexp 2.7 (modifications to current re 2.2.2)

2009-07-27 Thread Matthew Barnett

Matthew Barnett  added the comment:

issue2636-20090727.zip contains regex.py, _regex.h, _regex.c and also
_regex.pyd (for Python 2.6 on Windows). For Windows machines just put
regex.py and _regex.pyd into Python's Lib\site-packages folder. I've
changed the name so that it won't hide the re module.

--
Added file: http://bugs.python.org/file14576/issue2636-20090727.zip

___
Python tracker 
<http://bugs.python.org/issue2636>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1721862] email.FeedParser.BufferedSubFile improperly handles "\r\n"

2009-07-27 Thread Neil Tallim

Changes by Neil Tallim :


Removed file: http://bugs.python.org/file14572/1721862.diff

___
Python tracker 

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



[issue2636] Regexp 2.7 (modifications to current re 2.2.2)

2009-07-27 Thread Gregory P. Smith

Gregory P. Smith  added the comment:

Agreed, a standalone release combined with a public announcement about
its availability is a must if we want to get any sort of wide spread
testing.

It'd be great if we had a fully characterized set of tests for the
behavior of the existing engine... but we don't.  So widespread testing
is important.

--

___
Python tracker 

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



[issue6573] set union method ignores arguments appearing after the original set

2009-07-27 Thread Raymond Hettinger

Raymond Hettinger  added the comment:

Good catch.  Thanks.

--
priority:  -> high

___
Python tracker 

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



[issue1721862] email.FeedParser.BufferedSubFile improperly handles "\r\n"

2009-07-27 Thread Neil Tallim

Neil Tallim  added the comment:

Confirmed in trunk and all current branches (r74225: 2.6, 2.7, 3.1, 3.2).

Patches for all four active versions will be added momentarily.

Note: my submission yesterday was mistagged, claiming to be for trunk
while it was really for 2.6, which is what this bug was actively marked
with at the time.

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

___
Python tracker 

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



[issue2636] Regexp 2.7 (modifications to current re 2.2.2)

2009-07-27 Thread A.M. Kuchling

A.M. Kuchling  added the comment:

We have lengthy sets of tests in Lib/test/regex_tests.py and
Lib/test/test_re.py.

While widespread testing of a standalone module would certainly be good,
I doubt that will exercise many corner cases and the more esoteric
features.  Most actual code probably uses relatively few regex pattern
constructs.

--

___
Python tracker 

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



[issue1721862] email.FeedParser.BufferedSubFile improperly handles "\r\n"

2009-07-27 Thread Neil Tallim

Neil Tallim  added the comment:

Attached a patch containing a unit test based on Sye van der Veen's
example and a solution for issue 1721862.

Written against Python 2.6, r74225.

--
Added file: http://bugs.python.org/file14577/1721862[2.6].diff

___
Python tracker 

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



[issue1721862] email.FeedParser.BufferedSubFile improperly handles "\r\n"

2009-07-27 Thread Neil Tallim

Neil Tallim  added the comment:

Attached a patch containing a unit test based on Sye van der Veen's
example and a solution for issue 1721862.

Written against Python 2.7, r74225.

--
Added file: http://bugs.python.org/file14578/1721862[2.7].diff

___
Python tracker 

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



[issue1721862] email.FeedParser.BufferedSubFile improperly handles "\r\n"

2009-07-27 Thread Neil Tallim

Neil Tallim  added the comment:

Attached a patch containing a unit test based on Sye van der Veen's
example and a solution for issue 1721862.

Written against Python 3.1, r74225.

--
Added file: http://bugs.python.org/file14579/1721862[3.1].diff

___
Python tracker 

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



[issue1721862] email.FeedParser.BufferedSubFile improperly handles "\r\n"

2009-07-27 Thread Neil Tallim

Neil Tallim  added the comment:

Attached a patch containing a unit test based on Sye van der Veen's
example and a solution for issue 1721862.

Written against Python 3.2, r74225.

--
Added file: http://bugs.python.org/file14580/1721862[3.2].diff

___
Python tracker 

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



[issue6550] asyncore incorrect failure when connection is refused and using async_chat channel

2009-07-27 Thread Josiah Carlson

Josiah Carlson  added the comment:

The attached patch cleans up the remnants of the "handle_expt is for 
exceptions", which isn't the case, as well as makes the "connection 
refused" fix actually work on Windows.  Nirs, could you verify this on 
*nix?

--
assignee:  -> josiahcarlson
keywords: +needs review
Added file: http://bugs.python.org/file14581/asyncore_fix_refused.patch

___
Python tracker 

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



[issue2698] Extension module build fails for MinGW: missing vcvarsall.bat

2009-07-27 Thread Hagen Fürstenau

Hagen Fürstenau  added the comment:

Seems to have been fixed around r73896.

--

___
Python tracker 

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



[issue5833] readline update

2009-07-27 Thread J. Evans

J. Evans  added the comment:

Some clarification about the rest of the patch:

-- We tested the readline fix with version 5.2 and it seemed to work, we
did not do a thorough test with it, or with any other version.

-- When I supplied the patch I supplied the patch that we use when
building python, which also included some enhancements/bug fixes
(depending on how you look at it).  By removing the '~$-/' characters
from the completer list it allows the user to perform file name
completion (with the provided file name completion code).  The file name
completion code has been very rigorously tested.  We have been using it
at our company for the past 10 years with >100 users and have had no
problems with it.

-- We put this here since it never really seemed to be an advanced
feature since readline completion will complete file names on the
command-line as well.  This seemed like a relatively low-level fix that
makes the python tab-expansion facility fully usable instead of just
partly usable.

If you would like me to resubmit the patch as smaller components I can
do that as well.

--

___
Python tracker 

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



[issue6573] set union method ignores arguments appearing after the original set

2009-07-27 Thread Raymond Hettinger

Raymond Hettinger  added the comment:

Fixed.  See r74226, r74227, r74228 and r74229.

--
resolution:  -> fixed
status: open -> closed
versions: +Python 2.6, Python 2.7, Python 3.1, Python 3.2

___
Python tracker 

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



[issue6585] configure.in forces specific autoconf version

2009-07-27 Thread R. David Murray

R. David Murray  added the comment:

My understanding is that the reason that this particular version of
autoconf is required is that newer versions introduce mixed line endings
into the generated file, which causes problems with storing it in svn.

The introduction of the version check was prompted by the fact that
several developers used the wrong autoconf version when regenerating the
configure script because they weren't aware of this issue.  In addition
to this, however, having different developers regenerate the file using
different autoconf versions would result in the checked-in configure
script ping-ponging because of differing autoconf output.  Thus it seems
it is better in the general case to require that the configure script be
built with a specified version of autoconf.

--
nosy: +r.david.murray
priority:  -> normal
resolution:  -> invalid
stage:  -> committed/rejected
status: open -> closed

___
Python tracker 

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



[issue6587] interrupts during long writes cause connection corruption with SSL module

2009-07-27 Thread Bill Janssen

New submission from Bill Janssen :

The behavior when a write or send is interrupted is suboptimal.  If the
write buffer moves before a retry is attempted in response to
SSL_ERROR_WANT_OUTPUT, OpenSSL rejects the retry attempt.  See

http://www.mail-archive.com/openssl-us...@openssl.org/msg07806.html.

Looks like a simple fix.

--
assignee: janssen
messages: 90999
nosy: janssen
priority: high
severity: normal
stage: needs patch
status: open
title: interrupts during long writes cause connection corruption with SSL module
type: behavior
versions: Python 2.6, Python 2.7, Python 3.0, Python 3.1, Python 3.2

___
Python tracker 

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



[issue5673] Add timeout option to subprocess.Popen

2009-07-27 Thread Sridhar Ratnakumar

Changes by Sridhar Ratnakumar :


--
nosy: +srid

___
Python tracker 

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



[issue6588] insert cookies into cookie jar - cookielib.py

2009-07-27 Thread Jon Debonis

New submission from Jon Debonis :

Added ability to insert cookies into cookie jar.

Fixed problem where some domain names are prepended with '.' and others 
were not.

Fixed problem with _LWPCookieJar.py to handle case where version = None


import urllib2, urllib, time
import cookielib

req_url = 'http://google.com'

## OPEN COOKIE JAR - Optional
cj = cookielib.CookieJar()

cookie_handler = urllib2.HTTPCookieProcessor(cj)
opener = urllib2.build_opener(cookie_handler)
urllib2.install_opener(opener)

req = urllib2.Request(url=req_url)

cj.add_cookie(req, 'cname2', 'cval2',
{'expires':  int(time.time()) + 3600,})

cj.add_cookie(req, 'cname3', 'cval3') 

print "-" * 45
print "Cookies before first request is sent:"
for index, cookie in enumerate(cj):
print index, '  :  ', cookie

res = urllib2.urlopen(req)
# Google will redirect, and clear the additional cookies
print "-" * 45
print "Cookies after first request is sent:"
print "(google cleared extra cookies)"
for index, cookie in enumerate(cj):
print index, '  :  ', cookie
---

--
components: Library (Lib)
files: cookie_update.diff
keywords: patch
messages: 91000
nosy: jondebonis
severity: normal
status: open
title: insert cookies into cookie jar - cookielib.py
type: feature request
versions: Python 2.6
Added file: http://bugs.python.org/file14582/cookie_update.diff

___
Python tracker 

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



[issue5673] Add timeout option to subprocess.Popen

2009-07-27 Thread Sridhar Ratnakumar

Sridhar Ratnakumar  added the comment:

See http://code.google.com/p/python-process/ for some ideas.

--

___
Python tracker 

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



[issue6589] smtpd.SMTPServer can cause asyncore.loop to enter infinite event loop

2009-07-27 Thread Casey McGinty

New submission from Casey McGinty :

When subclass of smtpd.SMTPServer, it is possible the get asyncore.loop
to enter an infinite loop where the following output is shown:

.
warning: unhandled write event
warning: unhandled read event
warning: unhandled write event
warning: unhandled read event
warning: unhandled write event
warning: unhandled read event
warning: unhandled write event
warning: unhandled read event
warning: unhandled write event
warning: unhandled read event
warning: unhandled write event
warning: unhandled read event


To reproduce:
1) Init SMTPServer class instance inside of Thread class and call
asyncore.loop()
2) Init second SMTPServer class instance from a second Thread class,
binding to the same address and port. The SMTPServer instance will raise
an exception that socket cannot bind to the port in use. The socket
exception must be caught at some level, and the program execution
allowed to continue.
3) First SMTPServer thread will enter infinite event loop.


Analysis:
When the exception is raised in the second SMTPServer instance, the new
instance has already registered itself with the asyncore library (ex:
'asyncore.dispatcher.__init__(self)'). There is no code in the
SMTPServere.__init__ method that catches the exception raised, caused by
the failed bind attempt. After the exception is caught, the first thread
continues to run, but asyncore is in an invalid state because it still
has the registration of the second SMTPServer instance that never completed.

Workaround and Proposed Fix:
A viable workaround seems to be catching the raised exception in
__init__ method of the SMTPServer subclass, and call self.close() before
re-raising the exception:

class MySmtpServer( smtpd.SMTPServer, object ):
   def __init__( self, **kwargs ):
  try:
 super( _SmtpSink, self).__init__(**kwargs)
  except Exception as e:
 self.close()   # cleanup asyncore after failure
 raise

For a long term fix, I would recommend performing the
asyncore.dispatcher.close() method call in the SMTPServer.__init__() method.

--
components: Library (Lib)
messages: 91002
nosy: cmcginty
severity: normal
status: open
title: smtpd.SMTPServer can cause asyncore.loop to enter infinite event loop
versions: Python 2.6

___
Python tracker 

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