[issue16003] thread_PyThread_start_new_thread fails with a generic error

2012-09-23 Thread Kristján Valur Jónsson

New submission from Kristján Valur Jónsson:

If thread creation fails, for any reason, a ThreadError is returned with the 
error "can't start new thread".
No attempt is made to diagnose the issue.
In fact, for example, if we are out of resources, pthread_new() would have 
returned EAGAIN.  This should perhaps rather be classified as an OSError so 
that users can catch this and diagnose it.  ThreadError seems to be used 
otherwise exclusively to indicate problems with locking.

Can this be turned into an informative OSError, or is it to platform dependant 
for any sensible structured error handlng to be implemented?

--
messages: 171017
nosy: kristjan.jonsson
priority: normal
severity: normal
status: open
title: thread_PyThread_start_new_thread fails with a generic error
type: enhancement
versions: Python 3.4

___
Python tracker 

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



[issue15964] SyntaxError in asdl when building 2.7 with system Python 3

2012-09-23 Thread Chris Jerdonek

Chris Jerdonek added the comment:

> We should be able to add the "make touch" target to the 2.7 Makefile without 
> running afoul of the "no new features" rule.

To keep things simpler, I'm going to create a separate issue for this so that 
it can be discussed and committed independently of this doc-only issue.  If 
necessary, we can always modify the answers to existing FAQ's in that issue.

--

___
Python tracker 

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



[issue16004] Add `make touch` to 2.7 Makefile

2012-09-23 Thread Chris Jerdonek

New submission from Chris Jerdonek:

This issue is to add "make touch" to the 2.7 Makefile as suggested by Nick 
Coghlan in the following comment to issue 15964:

"We should be able to add the "make touch" target to the 2.7 Makefile without 
running afoul of the "no new features" rule."

(from http://bugs.python.org/issue15964#msg171001 )

This will make it easier to help people address certain build errors 
encountered when switching between 2.7 and 3.x branches.

--
components: Build
messages: 171019
nosy: cjerdonek, ncoghlan
priority: normal
severity: normal
status: open
title: Add `make touch` to 2.7 Makefile
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



[issue15964] SyntaxError in asdl when building 2.7 with system Python 3

2012-09-23 Thread Chris Jerdonek

Chris Jerdonek added the comment:

> We should be able to add the "make touch" target to the 2.7 Makefile without 
> running afoul of the "no new features" rule.

I created issue 16004 for this: http://bugs.python.org/issue16004

--

___
Python tracker 

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



[issue16004] Add `make touch` to 2.7 Makefile

2012-09-23 Thread Ezio Melotti

Changes by Ezio Melotti :


--
nosy: +ezio.melotti
stage:  -> needs patch
type:  -> enhancement

___
Python tracker 

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



[issue5969] setup build with Platform SDK, finding vcvarsall.bat

2012-09-23 Thread Roundup Robot

Roundup Robot added the comment:

New changeset abf23c22231e by Victor Stinner in branch 'default':
Issue #5969: faulthandler module: rename dump_tracebacks_later() to
http://hg.python.org/cpython/rev/abf23c22231e

--
nosy: +python-dev

___
Python tracker 

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



[issue15969] faulthandler: drop S from dump_tracebacks_later() function name to have consistent names

2012-09-23 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 178f9042af81 by Victor Stinner in branch 'default':
Issue #15969: Fix the issue number in Misc/NEWS
http://hg.python.org/cpython/rev/178f9042af81

--
nosy: +python-dev

___
Python tracker 

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



[issue15969] faulthandler: drop S from dump_tracebacks_later() function name to have consistent names

2012-09-23 Thread STINNER Victor

STINNER Victor added the comment:

@georg.brandl: You wrote the wrong issue number in the Misc/NEWS file of the 
3.3 repository (5969 -> 15969).

--

___
Python tracker 

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



[issue15969] faulthandler: drop S from dump_tracebacks_later() function name to have consistent names

2012-09-23 Thread Georg Brandl

Georg Brandl added the comment:

Thanks, fixed in b8b5ef366bdc.

--

___
Python tracker 

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



[issue15964] SyntaxError in asdl when building 2.7 with system Python 3

2012-09-23 Thread Chris Jerdonek

Changes by Chris Jerdonek :


--
keywords: +needs review
stage: needs patch -> patch review

___
Python tracker 

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



[issue9720] zipfile writes incorrect local file header for large files in zip64

2012-09-23 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

I see two rational solutions of the issue (all written below is applicable only 
for allowZip64=True):

1) Always write Zip64 extended information extra field. This approach always 
successful, but the zipfile size will increase by 20 bytes for each file.

The first patch (zipfile_zip64_always.patch) uses this approach.

2) Write Zip64 extended information extra field only if assumed file size is 
more than a certain limit. In very rare cases this leads to the impossibility 
of compression of the file which can be compressed the first way. However it 
produces the same file as before patch in most cases.

The second patch (zipfile_zip64_try.patch) is based on Alan's patch and uses 
the second approach. The probability of errors is reduced and they are now 
detected and does not lead to a silent data damage.

Both patches are for Python 3.3. If any patch is good, I'll backport it for the 
older versions.

--
nosy: +gregory.p.smith, loewis, ronaldoussoren
Added file: http://bugs.python.org/file27262/zipfile_zip64_always.patch

___
Python tracker 

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



[issue9720] zipfile writes incorrect local file header for large files in zip64

2012-09-23 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
stage: needs patch -> patch review
Added file: http://bugs.python.org/file27263/zipfile_zip64_try.patch

___
Python tracker 

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



[issue15952] format(value) and value.__format__() behave differently with unicode format

2012-09-23 Thread Ezio Melotti

Ezio Melotti added the comment:

``format(value, format_spec)`` merely calls
-  ``value.__format__(format_spec)``.
+  ``value.__format__(format_spec)`` and, if *format_spec* is Unicode,
+  converts the value to Unicode if it is not already Unicode.

This is correct, but should be rephrased (and "value" should be "return value").

+  The method ``value.__format__(format_spec)`` may return 8-bit strings
+  for some built-in types when *format_spec* is Unicode.

This is not limited to built-in types.  __format__() might return either str or 
unicode, and format() returns the same -- except for the aforementioned case.


This is a summary of the possible cases.


__format__ can return unicode or str:

  >>> class Uni(object):
  ...   def __format__(*args): return u'uni'
  ... 
  >>> class Str(object):
  ...   def __format__(*args): return 'str'
  ... 


format() and __format__ return the same value, except when the format_spec is 
unicode and __format__ returns str:

  >>> format(Uni(),  'd'),  Uni().__format__( 'd')  # same
  (u'uni', u'uni')
  >>> format(Uni(), u'd'),  Uni().__format__(u'd')  # same
  (u'uni', u'uni')
  >>> format(Str(),  'd'),  Str().__format__( 'd')  # same
  ('str', 'str')
  >>> format(Str(), u'd'),  Str().__format__(u'd')  # different
  (u'str', 'str')

It is also not true that the type of return value is the same of the 
format_spec, because in the first case the returned type is unicode even if the 
format_spec is str.  Therefore this part of the patch should be changed:

+   Per :pep:`3101`, the function returns a Unicode object if *format_spec* is
+   Unicode.  Otherwise, it returns an 8-bit string.

The behavior might be against PEP 3101 (see quotation in msg170669), even 
thought the wording of the PEP is somewhat lenient IMHO ("proper type" doesn't 
necessary mean "same type").

--

___
Python tracker 

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



[issue16004] Add `make touch` to 2.7 Makefile

2012-09-23 Thread Ezio Melotti

Ezio Melotti added the comment:

I'm not so sure it's worth adding it.
ISTM that this would be useful only to people that already encountered the 
problem described in #15964 and now that `make touch` is the solution.
All the others will have to google for a solution anyway, and there's no much 
difference in finding `make touch` or `touch Include/Python-ast.h 
Python/Python-ast.c`

--

___
Python tracker 

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



[issue16004] Add `make touch` to 2.7 Makefile

2012-09-23 Thread Nick Coghlan

Nick Coghlan added the comment:

The idea is to make the solution consistent, regardless of which branch you 
have checked out (in 3.x, the list of files to touch is longer and "make touch" 
already exists)

--

___
Python tracker 

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



[issue16005] smtplib.SMTP().sendmail() and rset()

2012-09-23 Thread DDarko

New submission from DDarko:

I'm trying to send an email as follows:

smtp = smtplib.SMTP(host, port=25)
smtp.ehlo()
smtp.sendmail(from_mail, to_mail, data)

The last line / command calls the raise.
I would like to know the reason why SMTP did not accept my email?
In theory, enough to capture the exception.
However, the exception of the last line returns:
"smtplib.SMTPServerDisconnected: Connection unexpectedly closed"
This is because the smtplib get replies in:
http://hg.python.org/cpython/file/default/Lib/smtplib.py
   767 (code, resp) = self.data(msg)
Then performs:
   769 self.rset()
As a result, the SMTP server disconnects the client. And instead receive info 
with reason I have information about sudden disconnection.

I do not think it should be reset, and if it is wrapped in a try.

Working snippet:
(code, resp) = self.data(msg)
if code != 250:
#self.rset()
raise SMTPDataError(code, resp)
#if we got here then somebody got our mail
return senderrs


This happens on servers mx.google.com

--
components: Library (Lib)
messages: 171029
nosy: DDarko
priority: normal
severity: normal
status: open
title: smtplib.SMTP().sendmail() and rset()
type: behavior
versions: Python 3.2

___
Python tracker 

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



[issue16004] Add `make touch` to 2.7 Makefile

2012-09-23 Thread Ezio Melotti

Ezio Melotti added the comment:

> in 3.x, the list of files to touch is longer

You mean that the attached patch is enough for 2.7?
In that case I guess it might be OK.

--
keywords: +patch
Added file: http://bugs.python.org/file27264/issue16004.diff

___
Python tracker 

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



[issue16005] smtplib.SMTP().sendmail() and rset()

2012-09-23 Thread R. David Murray

Changes by R. David Murray :


--
components: +email -Library (Lib)
nosy: +barry, r.david.murray

___
Python tracker 

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



[issue16005] smtplib.SMTP().sendmail() and rset()

2012-09-23 Thread Christian Heimes

Christian Heimes added the comment:

According to RFC 821 a smtp server must always apply with OK when it receives a 
RSET command.

RESET (RSET)

This command specifies that the current mail transaction is
to be aborted.  Any stored sender, recipients, and mail data
must be discarded, and all buffers and state tables cleared.
The receiver must send an OK reply.


It seems like your mail server violates the standards.

--
nosy: +christian.heimes

___
Python tracker 

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



[issue15899] howto/unicode.rst doctest corrections

2012-09-23 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 9c83e309 by Ezio Melotti in branch '3.2':
#15949, #15899: use \ufffd instead of ?.
http://hg.python.org/cpython/rev/9c83e309

New changeset 1aebae2f68da by Ezio Melotti in branch 'default':
#15949, #15899: merge with 3.2.
http://hg.python.org/cpython/rev/1aebae2f68da

--

___
Python tracker 

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



[issue15949] docs.python.org not getting updated

2012-09-23 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 9c83e309 by Ezio Melotti in branch '3.2':
#15949, #15899: use \ufffd instead of ?.
http://hg.python.org/cpython/rev/9c83e309

New changeset 1aebae2f68da by Ezio Melotti in branch 'default':
#15949, #15899: merge with 3.2.
http://hg.python.org/cpython/rev/1aebae2f68da

--

___
Python tracker 

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



[issue12907] Update test coverage devguide page

2012-09-23 Thread Ezio Melotti

Changes by Ezio Melotti :


--
type:  -> enhancement

___
Python tracker 

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



[issue11869] Include information about the bug tracker Rietveld code review tool

2012-09-23 Thread Ezio Melotti

Changes by Ezio Melotti :


--
assignee:  -> ezio.melotti
type:  -> enhancement

___
Python tracker 

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



[issue13440] Explain the "status quo wins a stalemate" principle in the devguide

2012-09-23 Thread Ezio Melotti

Changes by Ezio Melotti :


--
keywords: +easy
type:  -> enhancement

___
Python tracker 

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



[issue16005] smtplib.SMTP().sendmail() and rset()

2012-09-23 Thread DDarko

DDarko added the comment:

The problem is that this is not my SMTP server.
I want to connect as a client with smtplib.
For this, as I said earlier it is mx.google.com



send: 'ehlo [127.0.1.1]\r\n'
reply: b'250-mx.google.com at your service, [MYIP]\r\n'
reply: b'250-SIZE 35882577\r\n'
reply: b'250-8BITMIME\r\n'
reply: b'250-STARTTLS\r\n'
reply: b'250 ENHANCEDSTATUSCODES\r\n'
reply: retcode (250); Msg: b'mx.google.com at your service, [MYIP]\nSIZE 
35882577\n8BITMIME\nSTARTTLS\nENHANCEDSTATUSCODES'
send: 'mail FROM: size=448\r\n'
reply: b'250 2.1.0 OK o7si11249316wiz.31\r\n'
reply: retcode (250); Msg: b'2.1.0 OK o7si11249316wiz.31'
send: 'rcpt TO:\r\n'
reply: b'250 2.1.5 OK o7si11249316wiz.31\r\n'
reply: retcode (250); Msg: b'2.1.5 OK o7si11249316wiz.31'
send: 'data\r\n'
reply: b'354  Go ahead o7si11249316wiz.31\r\n'
reply: retcode (354); Msg: b'Go ahead o7si11249316wiz.31'
data: (354, b'Go ahead o7si11249316wiz.31')
send: b'Content-Type: multipart/related; 
boundary="===0969887089=="\r\nMIME-Version: 1.0\r\nFrom: 
\r\n\r\n--===0969887089==--\r\n.\r\n'
reply: b'550-5.7.1 [MYIP   7] Our system has detected that this message 
is\r\n'
reply: b'550-5.7.1 likely unsolicited mail. To reduce the amount of spam sent 
to Gmail,\r\n'
reply: b'550-5.7.1 this message has been blocked. Please visit\r\n'
reply: b'550-5.7.1 
http://support.google.com/mail/bin/answer.py?hl=en&answer=188131 for\r\n'
reply: b'550 5.7.1 more information. o7si11249316wiz.31\r\n'
reply: retcode (550); Msg: b'5.7.1 [MYIP   7] Our system has detected that 
this message is\n5.7.1 likely unsolicited mail. To reduce the amount of spam 
sent to Gmail,\n5.7.1 this message has been blocked. Please visit\n5.7.1 
http://support.google.com/mail/bin/answer.py?hl=en&answer=188131 for\n5.7.1 
more information. o7si11249316wiz.31'
data: (550, b'5.7.1 [MYIP   7] Our system has detected that this message 
is\n5.7.1 likely unsolicited mail. To reduce the amount of spam sent to 
Gmail,\n5.7.1 this message has been blocked. Please visit\n5.7.1 
http://support.google.com/mail/bin/answer.py?hl=en&answer=188131 for\n5.7.1 
more information. o7si11249316wiz.31')
send: 'rset\r\n'
---
Connection unexpectedly closed

--

___
Python tracker 

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



[issue12296] Minor clarification in devguide

2012-09-23 Thread Ezio Melotti

Changes by Ezio Melotti :


--
type:  -> enhancement

___
Python tracker 

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



[issue14218] include rendered output in addition to markup

2012-09-23 Thread Ezio Melotti

Ezio Melotti added the comment:

Another issue with this is that the devguide and the docs use different themes, 
so there's no guarantee that the output will look the same.

Some output examples (and the table I mentioned earlier) could still be added 
for a few cases though.

--
stage:  -> needs patch

___
Python tracker 

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



[issue13963] dev guide has no mention of mechanics of patch review

2012-09-23 Thread Ezio Melotti

Ezio Melotti added the comment:

See also #11869.

--
assignee:  -> ezio.melotti
stage:  -> needs patch
type:  -> enhancement

___
Python tracker 

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



[issue11869] Include information about the bug tracker Rietveld code review tool

2012-09-23 Thread Ezio Melotti

Ezio Melotti added the comment:

See also #13963.

--

___
Python tracker 

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



[issue15121] devguide doesn't document all bug tracker components

2012-09-23 Thread Ezio Melotti

Ezio Melotti added the comment:

'None' is not available from the UI, and I suspect it's automatically set for 
issues reported via email.  This might be a bug in Roundup, but I haven't 
verified it yet.

--

___
Python tracker 

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



[issue15034] Devguide should document best practices for stdlib exceptions

2012-09-23 Thread Ezio Melotti

Ezio Melotti added the comment:

I'm not sure this belongs to the devguide.
Ideally the best way to do it should be documented in the docs.
This doesn't necessary mean it should be in the tutorial, but if the way 
documented in the tutorial is "wrong", I'd rather tell users "this is the right 
way, do like this and don't worry about the details right now (but follow this 
link if you want to know more)" than "use this wrongish way that is simple but 
will break as soon as you start doing something more complex".

--

___
Python tracker 

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



[issue16002] AIX buildbot compile errors

2012-09-23 Thread Stefan Krah

Stefan Krah added the comment:

I tested --without-computed-gotos on the AIX machine and that solves
the problem.


Antoine, I understood that ./configure parameters can only be changed
on the build master. Could you add --without-computed-gotos?

--
nosy: +pitrou

___
Python tracker 

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



[issue15270] "Economy of Expression" section outdated

2012-09-23 Thread Ezio Melotti

Ezio Melotti added the comment:

IMHO the paragraph about super() can be dropped altogether.

--

___
Python tracker 

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



[issue15989] Possible integer overflow of PyLong_AsLong() results

2012-09-23 Thread Mark Dickinson

Mark Dickinson added the comment:

Looks good, in general.

_PyLong_AsInt should return -1 on overflow in all cases;  at the moment, it 
looks like it doesn't do that for values that overflow an int but not a long.

--

___
Python tracker 

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



[issue16002] AIX buildbot compile errors

2012-09-23 Thread Antoine Pitrou

Antoine Pitrou added the comment:

> Antoine, I understood that ./configure parameters can only be changed
> on the build master. Could you add --without-computed-gotos?

Done.

--

___
Python tracker 

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



[issue13440] Explain the "status quo wins a stalemate" principle in the devguide

2012-09-23 Thread Antoine Pitrou

Antoine Pitrou added the comment:

What would be the benefit of adding this to the devguide?
I'll say it again, the devguide should be short enough to be practical for 
someone learning to contribute. It is quite wordy already.

--
nosy: +pitrou

___
Python tracker 

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



[issue16003] thread_PyThread_start_new_thread fails with a generic error

2012-09-23 Thread Antoine Pitrou

Antoine Pitrou added the comment:

I'm personally ok with using a more informative error than ThreadError.

--
nosy: +pitrou

___
Python tracker 

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



[issue15989] Possible integer overflow of PyLong_AsLong() results

2012-09-23 Thread Mark Dickinson

Mark Dickinson added the comment:

I added some comments on Rietveld.

Apart from the bug in _PyLong_AsInt mentioned above, the patch mostly looks 
good.  But there are many changes, some of which will have user-visible 
effects, and I think it's somewhat risky to make all these changes in bugfix 
releases (which now includes Python 3.3).

Perhaps there could be a smaller patch aimed at the bugfix releases?  Ideally, 
each fix there should be backed by a regression test.

--
versions: +Python 3.4

___
Python tracker 

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



[issue16002] AIX buildbot compile errors

2012-09-23 Thread Stefan Krah

Stefan Krah added the comment:

Thanks!

--

___
Python tracker 

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



[issue15996] pow() for complex numbers is rough around the edges

2012-09-23 Thread Mark Dickinson

Mark Dickinson added the comment:

Reclassifying this as an enhancement; I don't think it's appropriate to rewrite 
complex_pow for the bugfix releases.

--
type: behavior -> enhancement
versions:  -Python 3.3

___
Python tracker 

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



[issue8425] a -= b should be fast if a is a small set and b is a large set

2012-09-23 Thread Michele Orrù

Michele Orrù added the comment:

Something like this would also need unit tests?

$ ./python.exe -m timeit -s "s= set(range(2000)); l = set(range(2000)); 
s=s-l"
1000 loops, best of 3: 0.0622 usec per loop
[48787 refs]
$ ./python.exe -m timeit -s "s= set(range(2000)); l = set(range(2000)); 
s-=l"
1000 loops, best of 3: 0.0591 usec per loop
[48787 refs]

--
Added file: http://bugs.python.org/file27265/issue8425.patch

___
Python tracker 

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



[issue16006] Spelling mistake in PEP 213

2012-09-23 Thread Ramchandra Apte

New submission from Ramchandra Apte:

In the first line of the "Justification" paragraph in PEP 213 "cenario" is 
used. It should be "Scenario".

--
components: None
messages: 171050
nosy: ramchandra.apte
priority: normal
severity: normal
status: open
title: Spelling mistake in PEP 213
type: enhancement

___
Python tracker 

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



[issue16007] Improved Error message for failing re expressions

2012-09-23 Thread Ling Li

New submission from Ling Li:

Hi,

I would like to make a small improvement to the exception raised when 
_compile() function fails with exception on line 245. 

Please see attached amended file. The line of code is amended from: 

raise error, v # invalid expression

to:

raise error, r'%s with pattern: %s' % (v, pattern) # invalid expression

As this is my first contribution, please let me know if this is the correct 
procedure to submit changes.

Kind regards,
Ling

--
components: Regular Expressions
files: re.py
messages: 171051
nosy: ezio.melotti, lingster, mrabarnett
priority: normal
severity: normal
status: open
title: Improved Error message for failing re expressions
type: enhancement
versions: Python 2.7
Added file: http://bugs.python.org/file27266/re.py

___
Python tracker 

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



[issue16008] [OS bug] DragonFly buildbot locale failures

2012-09-23 Thread Stefan Krah

New submission from Stefan Krah:

The locale failures on the DragonFly buildbot are caused by an OS bug:

bugs.dragonflybsd.org/issues/2415


I'm opening an issue so that this is recorded and other people hopefully
won't waste time debugging the failures. I intend to close the issue
as invalid in a couple of days.

==
FAIL: test_wide_char_separator_decimal_point (test.test_decimal.CFormatTest)
--
Traceback (most recent call last):
  File 
"/home/cpython/buildslave/3.x.snakebite-dragonfly30-amd64-1/build/Lib/test/test_decimal.py",
 line 1149, in test_wide_char_separator_decimal_point
'100\u066c000\u066c000\u066b123')
AssertionError: '1.123' != '100\u066c000\u066c000\u066b123'
- 1.123
?  ^
+ 100\u066c000\u066c000\u066b123
?+   +   ^


==
ERROR: test_basic (test.test_strptime.getlang_Tests)
--
Traceback (most recent call last):
  File 
"/home/cpython/buildslave/3.x.snakebite-dragonfly30-amd64-1/build/Lib/test/test_strptime.py",
 line 16, in test_basic
self.assertEqual(_strptime._getlang(), locale.getlocale(locale.LC_TIME))
  File 
"/home/cpython/buildslave/3.x.snakebite-dragonfly30-amd64-1/build/Lib/_strptime.py",
 line 31, in _getlang
return locale.getlocale(locale.LC_TIME)
  File 
"/home/cpython/buildslave/3.x.snakebite-dragonfly30-amd64-1/build/Lib/locale.py",
 line 524, in getlocale
return _parse_localename(localename)
  File 
"/home/cpython/buildslave/3.x.snakebite-dragonfly30-amd64-1/build/Lib/locale.py",
 line 433, in _parse_localename
raise ValueError('unknown locale: %s' % localename)
ValueError: unknown locale: ps_AF

--
keywords: buildbot
messages: 171052
nosy: skrah, trent
priority: low
severity: normal
status: open
title: [OS bug] DragonFly buildbot locale failures
type: behavior
versions: Python 3.3

___
Python tracker 

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



[issue16006] Spelling mistake in PEP 213

2012-09-23 Thread Ezio Melotti

Ezio Melotti added the comment:

Fixed in 94dbf7d100f3, thanks for the report!

--
assignee:  -> ezio.melotti
components:  -None
nosy: +ezio.melotti
resolution:  -> fixed
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



[issue16007] Improved Error message for failing re expressions

2012-09-23 Thread Benjamin Peterson

Benjamin Peterson added the comment:

Please provide a patch in unified diff format.

--
nosy: +benjamin.peterson
versions: +Python 3.4 -Python 2.7

___
Python tracker 

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



[issue16007] Improved Error message for failing re expressions

2012-09-23 Thread Ramchandra Apte

Ramchandra Apte added the comment:

> As this is my first contribution, please let me know if this is the correct 
> procedure to submit changes.

This is the correct procedure. http://docs.python.org/devguide/ (the Python 
Devlopment Guide) is a guide on how to contribute to Python.
Hope you enjoy your Python development experience!

--
nosy: +ramchandra.apte

___
Python tracker 

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



[issue16006] Spelling mistake in PEP 213

2012-09-23 Thread Ramchandra Apte

Ramchandra Apte added the comment:

That's hyper-fast.

--

___
Python tracker 

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



[issue15270] "Economy of Expression" section outdated

2012-09-23 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 100909b4def0 by Raymond Hettinger in branch 'default':
Issue #15270.  Appease critics by removing a reference to the docs for super().
http://hg.python.org/devguide/rev/100909b4def0

--
nosy: +python-dev

___
Python tracker 

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



[issue15270] "Economy of Expression" section outdated

2012-09-23 Thread Raymond Hettinger

Raymond Hettinger added the comment:

This whole discussion was inane.

--
resolution:  -> fixed
status: open -> closed

___
Python tracker 

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



[issue15955] gzip, bz2, lzma: add method to get decompressed size

2012-09-23 Thread Nadeem Vawda

Nadeem Vawda added the comment:

As far as I can tell, there is no way to find this out reliably without 
decompressing the entire file. With gzip, the file trailer contains the 
uncompressed size modulo 2^32, but this seems less than useful. It appears that 
the other two formats do not store the total uncompressed data size in any form.

For bz2 and lzma, one can get the uncompressed size by doing f.seek(0, 2) 
followed by f.tell(). However this approach is ugly and potentially very slow, 
so I would be reluctant to add a method based on it to the (BZ2|LZMA)File 
classes.

--

___
Python tracker 

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



[issue16005] smtplib.SMTP().sendmail() and rset()

2012-09-23 Thread R. David Murray

R. David Murray added the comment:

I believe that Google is technically out of compliance with the SMTP spec here. 
 What they are doing is not unreasonable, since they don't have any reason to 
want to waste resources on talking to a server they think is spamming them.

Making this work in a more useful fashion may be considered an enhancement 
rather than a bug fix, since arguably it is Google, not smtplib, that appears 
to be violating the RFC.  On the other hand, the fix is simple enough, is 
unlikely to be harmful, and it can be argued that handling this error is the 
proper action for a robust smtp client in any case, so I think we can justify 
making it a bug fix.

The rset is correct in the general case, so the fix would be to wrap it in a 
try/except and treat SMTPServerDisconnected as not-an-error.

DDarko, would you have any interest in proposing a patch with tests?

--

___
Python tracker 

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



[issue16002] AIX buildbot compile errors

2012-09-23 Thread Stefan Krah

Stefan Krah added the comment:

The compile errors are fixed, let's open separate issues for the
test failures.

--
resolution:  -> fixed
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



[issue16009] Json not handling errors correctly

2012-09-23 Thread Luka Rahne

New submission from Luka Rahne:

Example:

import json
j = json.loads(
"""
{
"phoneNumber": [
{
"type": "home",
"number": "212 555-1234"
},
}

""")
print(j)

Output>>
Traceback (most recent call last):
  File "", line 13, in 
  File "/usr/lib/python2.7/json/__init__.py", line 326, in loads
return _default_decoder.decode(s)
  File "/usr/lib/python2.7/json/decoder.py", line 366, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib/python2.7/json/decoder.py", line 384, in raw_decode
raise ValueError("No JSON object could be decoded")
ValueError: No JSON object could be decoded


My comment:
It is annoying in case of manual json editing where you can't know where jeson 
typeing error is.

--
components: Library (Lib)
messages: 171062
nosy: Luka.Rahne
priority: normal
severity: normal
status: open
title: Json not handling errors correctly
versions: Python 2.7, Python 3.2

___
Python tracker 

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



[issue16005] smtplib.SMTP().sendmail() and rset()

2012-09-23 Thread DDarko

DDarko added the comment:

I do not understand why at all reset is performed ?
If moments later raise is done.

If someone despite error SMTPSenderRefused, SMTPRecipientsRefused or 
SMTPDataError  will still want to maintain a connection and use other data with 
session is likely he will call SMTP().rset() manually.

In my opinion, the most frequent use of the library are:

smtp = smtplib.SMTP(host, port=25)
smtp.ehlo()
try:
smtp.sendmail(from_mail, to_mail, data)
except Exception as e:
print(e)

smtp.quit()


If you wish to use session despite the error:
smtp = smtplib.SMTP(host, port=25)
smtp.ehlo()
for to_mail in mail_list:
try:
smtp.sendmail(from_mail, to_mail, data)
except smtplib.SMTPRecipientsRefused as e:
smtp.rset()
print(e)

smtp.quit()

If we do not handle exception, reset does not matter.


IMHO patch should look like this:
http://hg.python.org/cpython/file/default/Lib/smtplib.py
745d744
< self.rset()
756d754
< self.rset()
760d757
< self.rset()

--

___
Python tracker 

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



[issue16009] Json not handling errors correctly

2012-09-23 Thread Luka Rahne

Luka Rahne added the comment:

For example i foun out, that just extra comma crate such error

j = json.loads("""{ "" :[{},]}""")

--

___
Python tracker 

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



[issue15034] Devguide should document best practices for stdlib exceptions

2012-09-23 Thread Terry J. Reedy

Terry J. Reedy added the comment:

I think the Library Manual's chapter 5 on exceptions, currently called Built-in 
Exceptions, would be a good place for a section on subclassing exceptions.

--

___
Python tracker 

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



[issue13440] Explain the "status quo wins a stalemate" principle in the devguide

2012-09-23 Thread Terry J. Reedy

Terry J. Reedy added the comment:

Maybe just add links to the two essays.

--

___
Python tracker 

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



[issue15034] Devguide should document best practices for stdlib exceptions

2012-09-23 Thread Chris Jerdonek

Changes by Chris Jerdonek :


--
nosy: +cjerdonek

___
Python tracker 

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



[issue13440] Explain the "status quo wins a stalemate" principle in the devguide

2012-09-23 Thread Chris Jerdonek

Changes by Chris Jerdonek :


--
nosy: +cjerdonek

___
Python tracker 

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



[issue13963] dev guide has no mention of mechanics of patch review

2012-09-23 Thread Chris Jerdonek

Chris Jerdonek added the comment:

> If this is true, we could simply add a way to specify the branch (either a 
> dropdown in the roundup UI or an X.Y in the filename).

It would be cool if this could happen even without any user action (e.g. if 
Rietveld tried default, 3.2, and 2.7 in sequence until one succeeded).

--
nosy: +cjerdonek

___
Python tracker 

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



[issue15835] HP-UX build needs to be tweaked to pick up PATH_MAX

2012-09-23 Thread Stefan Krah

Stefan Krah added the comment:

PATH_MAX seems to be a mess on HP-UX: It's only defined in limits.h
if _INCLUDE_XOPEN_SOURCE_PRE_500 is defined.

But MAXPATHLEN is always defined in sys/param.h, so I suggest to use that
(patch attached).


Other projects take a similar approach by just defining PATH_MAX as 1024:

http://lists.gnu.org/archive/html/bug-gnulib/2011-06/msg00242.html

--
keywords: +buildbot, patch
nosy: +skrah
Added file: http://bugs.python.org/file27267/issue15835.diff

___
Python tracker 

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



[issue15379] Charmap decoding of no-BMP characters

2012-09-23 Thread Antoine Pitrou

Changes by Antoine Pitrou :


--
stage: patch review -> committed/rejected

___
Python tracker 

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



[issue15379] Charmap decoding of no-BMP characters

2012-09-23 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 620d23f7ad41 by Antoine Pitrou in branch '3.2':
Issue #15379: Fix passing of non-BMP characters as integers for the charmap 
decoder (already working as unicode strings).
http://hg.python.org/cpython/rev/620d23f7ad41

New changeset c64dec45d46f by Antoine Pitrou in branch 'default':
Issue #15379: Fix passing of non-BMP characters as integers for the charmap 
decoder (already working as unicode strings).
http://hg.python.org/cpython/rev/c64dec45d46f

--
nosy: +python-dev

___
Python tracker 

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



[issue15379] Charmap decoding of no-BMP characters

2012-09-23 Thread Antoine Pitrou

Antoine Pitrou added the comment:

Thank you, I've committed the patches. There was a test failure in 
test_codeccallbacks in 3.2, which I fixed simply by replacing sys.maxunicode 
with a hardcoded 0x11.

--
resolution:  -> fixed
status: open -> closed

___
Python tracker 

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



[issue16005] smtplib.SMTP().sendmail() and rset()

2012-09-23 Thread R. David Murray

R. David Murray added the comment:

The rset just returns the connection to the "base" state, allowing a new 
message sending transaction to start from a known state.

In any case, since the library has done this in the past, it must continue to 
do this in the future, or it will break currently working code.

--

___
Python tracker 

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



[issue16009] Json error messages could provide more information about the error

2012-09-23 Thread R. David Murray

R. David Murray added the comment:

The errors are being handled correctly, but it would indeed be nice for them to 
provide more information about the specific error.  That's an enhancement, 
though.

--
nosy: +r.david.murray
stage:  -> needs patch
title: Json not handling errors correctly -> Json error messages could provide 
more information about the error
type:  -> enhancement
versions: +Python 3.4 -Python 2.7, Python 3.2

___
Python tracker 

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



[issue11454] email.message import time

2012-09-23 Thread R. David Murray

R. David Murray added the comment:

I'm really not willing to inline any of those pre-compiled regular expressions. 
 They are precompiled because for a program processing lots of email, they are 
hot spots.  We could use the same "compile on demand" dodge on them, though.

Can you explain your changes to the

--

___
Python tracker 

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



[issue11454] email.message import time

2012-09-23 Thread R. David Murray

R. David Murray added the comment:

Woops.

Can you explain your changes to the ecre regex (keeping in mind that I don't 
know much about regex syntax).

--

___
Python tracker 

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



[issue11454] email.message import time

2012-09-23 Thread R. David Murray

R. David Murray added the comment:

Oh, yeah, and the encode benchmark is very instructive, thanks Serhiy :)

--

___
Python tracker 

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



[issue16004] Add `make touch` to 2.7 Makefile

2012-09-23 Thread Arfrever Frehtes Taifersar Arahesis

Changes by Arfrever Frehtes Taifersar Arahesis :


--
nosy: +Arfrever

___
Python tracker 

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



[issue11454] email.message import time

2012-09-23 Thread Ezio Melotti

Ezio Melotti added the comment:

> They are precompiled because for a program processing lots of email,
> they are hot spots.

OK, I didn't know they were hot spots.  Note that the regex are not recompiled 
everytime: they are compiled the first time and then taken from the cache 
(assuming they don't fall out from the bottom of the cache).  This still has a 
small overhead though.

> Can you explain your changes to the ecre regex (keeping in mind
> that I don't know much about regex syntax).

-  (?P[^?]*?)   # non-greedy up to the next ? is the charset
+  (?P[^?]*)# up to the next ? is the charset
   \?# literal ?
   (?P[qb])# either a "q" or a "b", case insensitive
   \?# literal ?
-  (?P.*?)  # non-greedy up to the next ?= is the encoded string
+  (?P[^?]*)# up to the next ?= is the encoded string
   \?=   # literal ?=

At the beginning, the non-greedy *? is unnecessary because [^?]* already stops 
at the first ? found.
The second change might actually be wrong if  is allowed to contain 
lone '?'s.  The original regex used '.*?\?=', which means "match everything 
(including lone '?'s) until the first '?=')", mine means "match everything 
until the first '?'" which works fine as long as lone '?'s are not allowed.

Serhiy's suggestion is semantically different, but it might be still suitable 
if having _has_surrogate return True even for surrogates not in range 
\udc80-\udcff is OK.

--

___
Python tracker 

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



[issue11454] email.message import time

2012-09-23 Thread R. David Murray

R. David Murray added the comment:

Well, "other" surrogates will cause a different error later than with the 
current _has_surrogates logic, but it won't be any more mysterious than what 
would happen now, I think.  Normally, if I understand correctly, other 
surrogates should never occur, so I don't think it is a real issue.

Yes, lone '?'s should not stop the pattern match in an encoded string. Even 
though I don't think they are normally supposed to occur, they do occur when 
encoded words are encoded incorrectly, and we get a better error recovery 
result if we look for ?= as the end.

--

___
Python tracker 

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



[issue15989] Possible integer overflow of PyLong_AsLong() results

2012-09-23 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Thank you for review and for found bugs. I again checked the patch, corrected 
the errors and dubious places. Also I corrected the error in 
Modules/grpmodule.c (in other places gid_t parsed as signed long) and the 
possible behaviour change in Modules/_io/_iomodule.c, reversed the changes in 
Modules/pyexpat.c. If some changes cause you have doubts, you can cherry-pick 
only the most obvious fixes.

> Ideally, each fix there should be backed by a regression test.

Unfortunately I have only platforms where sizeof(int) == sizeof(long) == 
sizeof(size_t).

--
Added file: http://bugs.python.org/file27268/long_aslong_overflow-3.3_2.patch

___
Python tracker 

___diff -r c64dec45d46f Include/longobject.h
--- a/Include/longobject.h  Sun Sep 23 20:00:04 2012 +0200
+++ b/Include/longobject.h  Sun Sep 23 21:46:54 2012 +0300
@@ -26,6 +26,9 @@
 PyAPI_FUNC(size_t) PyLong_AsSize_t(PyObject *);
 PyAPI_FUNC(unsigned long) PyLong_AsUnsignedLong(PyObject *);
 PyAPI_FUNC(unsigned long) PyLong_AsUnsignedLongMask(PyObject *);
+#ifndef Py_LIMITED_API
+PyAPI_FUNC(int) _PyLong_AsInt(PyObject *);
+#endif
 PyAPI_FUNC(PyObject *) PyLong_GetInfo(void);
 
 /* It may be useful in the future. I've added it in the PyInt -> PyLong
diff -r c64dec45d46f Modules/_ctypes/stgdict.c
--- a/Modules/_ctypes/stgdict.c Sun Sep 23 20:00:04 2012 +0200
+++ b/Modules/_ctypes/stgdict.c Sun Sep 23 21:46:54 2012 +0300
@@ -335,7 +335,7 @@
 
 isPacked = PyObject_GetAttrString(type, "_pack_");
 if (isPacked) {
-pack = PyLong_AsLong(isPacked);
+pack = _PyLong_AsInt(isPacked);
 if (pack < 0 || PyErr_Occurred()) {
 Py_XDECREF(isPacked);
 PyErr_SetString(PyExc_ValueError,
diff -r c64dec45d46f Modules/_datetimemodule.c
--- a/Modules/_datetimemodule.c Sun Sep 23 20:00:04 2012 +0200
+++ b/Modules/_datetimemodule.c Sun Sep 23 21:46:54 2012 +0300
@@ -4717,7 +4717,7 @@
 if (seconds == NULL)
 goto error;
 Py_DECREF(delta);
-timestamp = PyLong_AsLong(seconds);
+timestamp = _PyLong_AsTime_t(seconds);
 Py_DECREF(seconds);
 if (timestamp == -1 && PyErr_Occurred())
 return NULL;
diff -r c64dec45d46f Modules/_io/_iomodule.c
--- a/Modules/_io/_iomodule.c   Sun Sep 23 20:00:04 2012 +0200
+++ b/Modules/_io/_iomodule.c   Sun Sep 23 21:46:54 2012 +0300
@@ -230,7 +230,8 @@
 int text = 0, binary = 0, universal = 0;
 
 char rawmode[6], *m;
-int line_buffering, isatty;
+int line_buffering;
+long isatty;
 
 PyObject *raw, *modeobj = NULL, *buffer = NULL, *wrapper = NULL;
 
@@ -376,12 +377,12 @@
 #ifdef HAVE_STRUCT_STAT_ST_BLKSIZE
 {
 struct stat st;
-long fileno;
+int fileno;
 PyObject *res = _PyObject_CallMethodId(raw, &PyId_fileno, NULL);
 if (res == NULL)
 goto error;
 
-fileno = PyLong_AsLong(res);
+fileno = _PyLong_AsInt(res);
 Py_DECREF(res);
 if (fileno == -1 && PyErr_Occurred())
 goto error;
diff -r c64dec45d46f Modules/_io/fileio.c
--- a/Modules/_io/fileio.c  Sun Sep 23 20:00:04 2012 +0200
+++ b/Modules/_io/fileio.c  Sun Sep 23 21:46:54 2012 +0300
@@ -244,7 +244,7 @@
 return -1;
 }
 
-fd = PyLong_AsLong(nameobj);
+fd = _PyLong_AsInt(nameobj);
 if (fd < 0) {
 if (!PyErr_Occurred()) {
 PyErr_SetString(PyExc_ValueError,
@@ -382,7 +382,7 @@
 goto error;
 }
 
-self->fd = PyLong_AsLong(fdobj);
+self->fd = _PyLong_AsInt(fdobj);
 Py_DECREF(fdobj);
 if (self->fd == -1) {
 goto error;
diff -r c64dec45d46f Modules/_io/textio.c
--- a/Modules/_io/textio.c  Sun Sep 23 20:00:04 2012 +0200
+++ b/Modules/_io/textio.c  Sun Sep 23 21:46:54 2012 +0300
@@ -881,7 +881,7 @@
 }
 }
 else {
-int fd = (int) PyLong_AsLong(fileno);
+int fd = _PyLong_AsInt(fileno);
 Py_DECREF(fileno);
 if (fd == -1 && PyErr_Occurred()) {
 goto error;
diff -r c64dec45d46f Modules/_sqlite/connection.c
--- a/Modules/_sqlite/connection.c  Sun Sep 23 20:00:04 2012 +0200
+++ b/Modules/_sqlite/connection.c  Sun Sep 23 21:46:54 2012 +0300
@@ -859,7 +859,7 @@
 rc = SQLITE_DENY;
 } else {
 if (PyLong_Check(ret)) {
-rc = (int)PyLong_AsLong(ret);
+rc = _PyLong_AsInt(ret);
 } else {
 rc = SQLITE_DENY;
 }
@@ -1350,7 +1350,7 @@
 goto finally;
 }
 
-result = PyLong_AsLong(retval);
+result = _PyLong_AsInt(retval);
 if (PyErr_Occurred()) {
 result = 0;
 }
diff -r c64dec45d46f Modules/grpmodule.c
--- a/Modules/grpmodule.c   Sun Sep 23 20:00:04 2012 +0200
+++ b/Mo

[issue15991] BaseHTTPServer with ThreadingMixIn serving wrong data sometimes

2012-09-23 Thread Thomas Lee

Thomas Lee added the comment:

I can reproduce this on Debian Wheezy. Both with the system Python (2.7.3rc2) 
and the 2.7 branch built from source.

--
nosy: +thomaslee

___
Python tracker 

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



[issue15996] pow() for complex numbers is rough around the edges

2012-09-23 Thread Jesús Cea Avión

Changes by Jesús Cea Avión :


--
nosy: +jcea
stage: test needed -> 
type: enhancement -> behavior

___
Python tracker 

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



[issue15996] pow() for complex numbers is rough around the edges

2012-09-23 Thread Jesús Cea Avión

Changes by Jesús Cea Avión :


--
stage:  -> test needed
type: behavior -> enhancement

___
Python tracker 

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



[issue15964] SyntaxError in asdl when building 2.7 with system Python 3

2012-09-23 Thread Martin v . Löwis

Martin v. Löwis added the comment:

> Martin meant:
>  touch Include/Python-ast.h Python/Python-ast.c

No, I *actually* meant 'make touch'.

--

___
Python tracker 

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



[issue15964] SyntaxError in asdl when building 2.7 with system Python 3

2012-09-23 Thread Martin v . Löwis

Martin v. Löwis added the comment:

> Just to clarify, in the original scenario, "python" did not refer to 
> anything.  From the original comment:
> $ python
> No such file or directory

So can you find out why asdl_c.py actually printed this error? With no python 
executable in PATH, it shouldn't even run.

--

___
Python tracker 

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



[issue16010] Some Unicode in identifiers improperly rejected

2012-09-23 Thread Joshua Landau

New submission from Joshua Landau:

"a¹ = None" is not valid, even though unicodedata.normalize("NFKC", "¹") == "1".

One would expect "a¹ = None" and "a1 = None" to be equivalent in this case, as 
with "aⁱ = None" and "ai = None".

I am not sure how many other characters exhibit the same problem.

References:
http://docs.python.org/py3k/reference/lexical_analysis.html#identifiers
http://mail.python.org/pipermail/python-list/2012-September/631420.html

"¹" === "\u00b9"
"ⁱ" === "\u2071"

--
components: Interpreter Core
messages: 171082
nosy: Joshua.Landau
priority: normal
severity: normal
status: open
title: Some Unicode in identifiers improperly rejected
versions: Python 3.2

___
Python tracker 

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



[issue15991] BaseHTTPServer with ThreadingMixIn serving wrong data sometimes

2012-09-23 Thread Antoine Pitrou

Antoine Pitrou added the comment:

I can reproduce under Debian testing, but not Debian stable nor Mageia 1.

I think this is really a bug in recent Debian/Ubuntu wget. By instrumenting 
SocketServer, I see that less requests are received than expected (e.g. ~350 
instead of 400). It seems wget is trying to send further requests on the same 
client socket, even though the server responded with a HTTP/1.0 status line and 
without a "connection: keep-alive" header, indicating it doesn't want 
keep-alive. Even explicitly sending a "connection: close" header doesn't seem 
to change wget's behaviour.

If you pass "--no-keep-alive" to wget, though, it solves the issue.

Running Wireshark would probably help confirm this.

--
nosy: +neologix, pitrou

___
Python tracker 

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



[issue15991] BaseHTTPServer with ThreadingMixIn serving wrong data sometimes

2012-09-23 Thread Antoine Pitrou

Antoine Pitrou added the comment:

Note that forcing a content length on error responses also seems to make wget 
happy:


diff --git a/Lib/BaseHTTPServer.py b/Lib/BaseHTTPServer.py
--- a/Lib/BaseHTTPServer.py
+++ b/Lib/BaseHTTPServer.py
@@ -362,14 +362,19 @@
 message = short
 explain = long
 self.log_error("code %d, message %s", code, message)
-# using _quote_html to prevent Cross Site Scripting attacks (see bug 
#1100201)
-content = (self.error_message_format %
-   {'code': code, 'message': _quote_html(message), 'explain': 
explain})
+if self.command != 'HEAD' and code >= 200 and code not in (204, 304):
+# using _quote_html to prevent Cross Site Scripting attacks (see 
bug #1100201)
+content = (self.error_message_format %
+   {'code': code, 'message': _quote_html(message), 
'explain': explain})
+else:
+content = None
 self.send_response(code, message)
 self.send_header("Content-Type", self.error_content_type)
+if content is not None:
+self.send_header("Content-Length", str(len(content)))
 self.send_header('Connection', 'close')
 self.end_headers()
-if self.command != 'HEAD' and code >= 200 and code not in (204, 304):
+if content is not None:
 self.wfile.write(content)
 
 error_message_format = DEFAULT_ERROR_MESSAGE

--

___
Python tracker 

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



[issue16011] "in" should be consistent with return value of __contains__

2012-09-23 Thread Neal Parikh

New submission from Neal Parikh:

The Python 2.7.3 documentation says the following about defining __contains__:

"Called to implement membership test operators. Should return true if item is 
in self, false otherwise. For mapping objects, this should consider the keys of 
the mapping rather than the values or the key-item pairs."

This suggests that while you should return True/False, you don't need to. Also, 
the documentation doesn't say that if you return a value other than True or 
False, it will silently coerce other values to be True or False when you use 
"in". For example:

>>> class Foo(object):
... def __contains__(self, item): return 42
... 
>>> foo = Foo()
>>> 3 in foo
True
>>> foo.__contains__(3)
42

When __contains__ is defined, "in" should return whatever __contains__ returns, 
even if this value is neither True nor False. That would be consistent with, 
for example, the comparison operators: You can return anything from __lt__ and 
"x < 4" will correctly pass along that value regardless of what it is.

--
assignee: docs@python
components: Documentation, Interpreter Core
messages: 171085
nosy: docs@python, nparikh
priority: normal
severity: normal
status: open
title: "in" should be consistent with return value of __contains__
type: behavior
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



[issue16011] "in" should be consistent with return value of __contains__

2012-09-23 Thread Christian Heimes

Christian Heimes added the comment:

The internal API is limited to flags as the sq_contains slot and the API 
function can only return an int:

  PyAPI_FUNC(int) PySequence_In(PyObject *o, PyObject *value)

In order to return the Python object we'd have to alter the API which we can't 
do as the type slot and the function is part of the stable API and ABI.

A doc update should explain why the code doesn't behave as you expect it.

--
nosy: +christian.heimes

___
Python tracker 

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



[issue1927] raw_input behavior incorrect if readline not enabled

2012-09-23 Thread Michael Domingues

Michael Domingues added the comment:

The code that dictates this behavior is in /Parser/myreadline.c and has not 
been rectified yet in either Python 2.7 
(http://hg.python.org/cpython/file/bfdf366a779a/Parser/myreadline.c#l107) or 
the default branch 
(http://hg.python.org/cpython/file/c64dec45d46f/Parser/myreadline.c#l111). 
Specifically, within these functions, references to standard error should 
actually be references to standard out.

The attached file is a proposed patch for this bug on the 2.7 branch, bringing 
interpreter behavior into accordance with the Python documentation 
(http://docs.python.org/library/functions.html#raw_input), which states that 
the prompt is written to standard out, as opposed to standard error.

--
keywords: +patch
nosy: +mdomingues
Added file: http://bugs.python.org/file27269/promptOutputFix.patch

___
Python tracker 

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



[issue1927] raw_input behavior incorrect if readline not enabled

2012-09-23 Thread Michael Domingues

Michael Domingues added the comment:

Also uploading a patch for the Python3.2 branch.

--
Added file: http://bugs.python.org/file27270/promptOutputFix3.patch

___
Python tracker 

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



[issue16010] Some Unicode in identifiers improperly rejected

2012-09-23 Thread R. David Murray

R. David Murray added the comment:

I find it unexpected that aⁱ and ai name the same variable, but I suppose that 
is a consequence of the unicode normalization rules (meaning what I really find 
surprising is the normalization).

As for the '¹', its category is No, which does not appear in the list in the 
identifiers section you link to, while 'ⁱ' is Lm, which does.

So there is no bug here.

--
nosy: +r.david.murray
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



[issue10760] tarfile doesn't handle sysfs well

2012-09-23 Thread Guy Rozendorn

Guy Rozendorn added the comment:

Here's a test case that re-creates this issue.
I chose to use mocks instead of sample files from sysfs so it would be simpler 
to run, it can be easily changed to use a file from sysfs.

The following code runs on Python2.7, requires the mock library

{code}
from unittest import TestCase
from tempfile import mkstemp
from mock import patch, Mock
from os import close, remove, write, stat
from posix import stat_result
from tarfile import TarFile

def fake_st_size_side_effect(*args, **kwargs):
src, = args
stats = stat(src)
return stat_result((stats.st_mode, stats.st_ino, stats.st_dev, 
stats.st_nlink,
   stats.st_uid, stats.st_gid, stats.st_size + 10,
   stats.st_atime, stats.st_mtime, stats.st_ctime))

class Issue10760TestCase(TestCase):
def setUp(self):
fd, self.src = mkstemp()
write(fd, '\x00' * 4)
close(fd)
fd, self.dst = mkstemp()
close(fd)

def test(self):
with patch("os.lstat") as lstat:
lstat.side_effect = fake_st_size_side_effect
tar_file = TarFile.open(self.dst, 'w:gz')
tar_file.add(self.src)

{code}

--

___
Python tracker 

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



[issue15964] SyntaxError in asdl when building 2.7 with system Python 3

2012-09-23 Thread Chris Jerdonek

Chris Jerdonek added the comment:

> So can you find out why asdl_c.py actually printed this error?

I collected some additional information.  Here is the beginning of 
Parser/asdl_c.py:

#! /usr/bin/env python
"""Generate C code from an ASDL description."""

And in the scenario of this issue I have--

$ python
-bash: 
/opt/local/Library/Frameworks/Python.framework/Versions/Current/bin/python: No 
such file or directory

But--

$ /usr/bin/env python -V
Python 3.2.3

Some more data:

$ /usr/bin/env python -c "import sys; print(sys.executable)"
/opt/local/Library/Frameworks/Python.framework/Versions/3.2/Resources/Python.app/Contents/MacOS/Python
$ echo $PATH
/opt/local/Library/Frameworks/Python.framework/Versions/Current/bin:/opt/local/bin:/opt/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin:/usr/local/git/bin:/usr/texbin
$ which python
/opt/local/bin/python
$ /opt/local/bin/python -c "import sys; print(sys.executable)"
/opt/local/Library/Frameworks/Python.framework/Versions/3.2/Resources/Python.app/Contents/MacOS/Python

It's not immediately clear to me why running `python` doesn't find python in 
the second $PATH entry even though `which python` does.  Also, creating a new 
terminal doesn't seem to exhibit the same problem, so the error state may not 
be fully reproducible after all (at least on my machine).

In any case, Christian's work-around does resolve the issue for this particular 
error state while other solutions don't.

--

___
Python tracker 

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



[issue15599] test_circular_imports() of test_threaded_import fails on FreeBSD 9.0

2012-09-23 Thread Ned Deily

Ned Deily added the comment:

OS X 10.4 (and presumably earlier versions) also does not handle the low 
switchinterval gracefully.  Monitoring system activity and running with -v, 
test_threaded_import does seem to progress but *very* slowly (I quit after 45 
minutes with the test only partially complete) at 100% CPU (mainly sys time).  
10.5 and later systems are fine.  Here's a patch that extends the FreeBSD 
solution to OS X 10.4 systems.

--
nosy: +ned.deily
Added file: http://bugs.python.org/file27271/issue15599_osx_10_4.patch

___
Python tracker 

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



[issue16011] "in" should be consistent with return value of __contains__

2012-09-23 Thread Ezio Melotti

Ezio Melotti added the comment:

http://docs.python.org/py3k/reference/datamodel.html#object.__contains__ says 
that __contain__ "Should return true if item is in self, false otherwise.".  
Here the lowercase true and false mean any true or false value, not just True 
and False and it's indeed possible to return any value.

The fact that 'in' only returns True/False, possibly converting the return 
value of __contains__, should be documented in the 'in' documentation.
http://docs.python.org/py3k/reference/expressions.html#membership-test-details 
says "For user-defined classes which define the __contains__() method, x in y 
is true if and only if y.__contains__(x) is true.".  This could be changed to 
say that the return value is converted to True/False.

--
keywords: +easy
nosy: +ezio.melotti
stage:  -> needs patch
versions: +Python 3.2, Python 3.3, Python 3.4

___
Python tracker 

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



[issue15900] Memory leak in PyUnicode_TranslateCharmap()

2012-09-23 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 89f62f143920 by Christian Heimes in branch 'default':
Issue #15900: Fixed reference leak in PyUnicode_TranslateCharmap()
http://hg.python.org/cpython/rev/89f62f143920

--

___
Python tracker 

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



[issue15895] PyRun_SimpleFileExFlags() can leak a FILE pointer

2012-09-23 Thread Roundup Robot

Roundup Robot added the comment:

New changeset fe4e6e0d6b0f by Christian Heimes in branch 'default':
Issue #15895: Fix FILE pointer leak in PyRun_SimpleFileExFlags() when filename 
points to a pyc/pyo file and closeit is false.
http://hg.python.org/cpython/rev/fe4e6e0d6b0f

New changeset 9251fb0440a0 by Christian Heimes in branch 'default':
Issue #15895: my analysis was slightly off. The FILE pointer is only leaked 
when set_main_loader() fails for a pyc file with closeit=0. In the success case 
run_pyc_file() does its own cleanup of the fp. I've changed the code to use 
another FILE ptr for pyc files and moved the fclose() to 
PyRun_SimpleFileExFlags() to make it more obvious what's happening.
http://hg.python.org/cpython/rev/9251fb0440a0

New changeset 61b1c25d55f2 by Christian Heimes in branch 'default':
Updates NEWS for issue #15895
http://hg.python.org/cpython/rev/61b1c25d55f2

--

___
Python tracker 

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



[issue15925] email.utils.parsedate() and email.utils.parsedate_tz() should return None when date cannot be parsed

2012-09-23 Thread Roundup Robot

Roundup Robot added the comment:

New changeset c1e9a1fc6931 by Georg Brandl in branch 'default':
Closes #15925: fix regression in parsedate() and parsedate_tz() that should 
return None if unable to parse the argument.
http://hg.python.org/cpython/rev/c1e9a1fc6931

--
stage: commit review -> committed/rejected

___
Python tracker 

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



[issue15926] Segmentation fault after multiple reinitializations

2012-09-23 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 6708224f8bee by Antoine Pitrou in branch 'default':
Issue #15926: Fix crash after multiple reinitializations of the interpreter.
http://hg.python.org/cpython/rev/6708224f8bee

--

___
Python tracker 

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



[issue15977] Memory leak in _ssl.c

2012-09-23 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 4cf53684e14e by Christian Heimes in branch 'default':
Issue #15977: Fix memory leak in Modules/_ssl.c when the function 
_set_npn_protocols() is called multiple times
http://hg.python.org/cpython/rev/4cf53684e14e

--

___
Python tracker 

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



[issue15973] Segmentation fault on timezone comparison

2012-09-23 Thread Roundup Robot

Roundup Robot added the comment:

New changeset ec77f8fb9958 by Georg Brandl in branch 'default':
Closes #15973: fix a segmentation fault when comparing timezone objects.
http://hg.python.org/cpython/rev/ec77f8fb9958

--

___
Python tracker 

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



[issue15969] faulthandler: drop S from dump_tracebacks_later() function name to have consistent names

2012-09-23 Thread Roundup Robot

Roundup Robot added the comment:

New changeset eede0bf3ceac by Georg Brandl in branch 'default':
Closes #15969: rename new API to have consistent names in the faulthandler 
module.
http://hg.python.org/cpython/rev/eede0bf3ceac

--
stage:  -> committed/rejected

___
Python tracker 

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



[issue15882] _decimal.Decimal constructed from tuple

2012-09-23 Thread Roundup Robot

Roundup Robot added the comment:

New changeset d22ea2aa1057 by Stefan Krah in branch 'default':
Issue #15882: Change _decimal to accept any coefficient tuple when
http://hg.python.org/cpython/rev/d22ea2aa1057

--

___
Python tracker 

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



[issue16005] smtplib.SMTP().sendmail() and rset()

2012-09-23 Thread DDarko

DDarko added the comment:

I understand, in that case:

/cpython/file/default/Lib/smtplib.py
760c760,761
< self.rset()
---
> try: self.rset()
> except: pass

Solves the problem.

--

___
Python tracker 

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



  1   2   >