[issue9646] Mutable default function parameter warning

2010-08-19 Thread Sérgio Surkamp
New submission from Sérgio Surkamp : The documentation states that the default value of function parameter, if mutable, can change it's default value at runtime due to be evaluated only once on function object creation. I would like to suggest the inclusion of an default language warning

[issue7779] smtplib SASL PLAIN authentication error

2010-01-25 Thread Sérgio Surkamp
Sérgio Surkamp added the comment: Got your point. Sorry. -- ___ Python tracker <http://bugs.python.org/issue7779> ___ ___ Python-bugs-list mailing list Unsub

[issue7779] smtplib SASL PLAIN authentication error

2010-01-25 Thread Sérgio Surkamp
Sérgio Surkamp added the comment: The SASL protocol says that the encoded base64 should be formed from: null + login + null + password The smtplib is not doing it, instead its "converting" the \012 (\0 + 2 first chars from password) in the char "\n", and it's right

[issue7779] smtplib SASL PLAIN authentication error

2010-01-25 Thread Sérgio Surkamp
New submission from Sérgio Surkamp : There is bug in PLAIN mechanism's of smtplib. The generated base64 string fail when the password start with numbers. As long as I could find, the error occur in method encode_plain. Using the null character (\0) in hexadecimal representation (\x00)

[issue7390] inconsistent type return

2009-11-24 Thread Sérgio Surkamp
New submission from Sérgio Surkamp : The type function returns inconsistent value depending on class hierarchy. >>> class X: ... pass ... >>> x = X() >>> type(x) >>> class Y(object): ... pass ... >>> x = Y() >>> type(x) >>

[issue4177] Crash in MIMEText on FreeBSD

2008-10-28 Thread Sérgio Surkamp
Sérgio Surkamp <[EMAIL PROTECTED]> added the comment: Ok. Something is very wrong with our code too. I have dumped the text that's cousing the "freeze" and run it using the test case scripts. It worked slow, but worked. It seems that our application is eating too many memo

[issue4177] Crash in MIMEText on FreeBSD

2008-10-24 Thread Sérgio Surkamp
Sérgio Surkamp <[EMAIL PROTECTED]> added the comment: When I first saw the problem, the email system queue was stopped about 2 days (weekend) :-( The email system control the number of open threads, so I wasn't opening new threads too and issuing many warnings about it on logs Anyw

[issue4177] Crash in MIMEText on FreeBSD

2008-10-24 Thread Sérgio Surkamp
Sérgio Surkamp <[EMAIL PROTECTED]> added the comment: - FreeBSD version? FreeBSD 7.0-RELEASE - CPU, memory? CPU: 2 x Pentium III 1.133 GHz Memory: 512 Mbytes - Full Python version? Python 2.5.2 (r252:60911, Oct 2 2008, 10:03:50) [GCC 4.2.1 20070719 [FreeBSD]] on freebsd7 > O

[issue4177] Crash in MIMEText on FreeBSD

2008-10-24 Thread Sérgio Surkamp
Sérgio Surkamp <[EMAIL PROTECTED]> added the comment: > Your text file is ~40 MB. Python may allocate mutiple objects bigger than 40 MB to create the email content. The algorithm should be changed to work on a stream (process small chunks, eg. 4 KB) instead of manipule the full text

[issue4177] Crash in MIMEText on FreeBSD

2008-10-23 Thread Sérgio Surkamp
Sérgio Surkamp <[EMAIL PROTECTED]> added the comment: Testing on Linux: $ ulimit -m 128000 $ ulimit -v 196000 $ python test_MIMEText.py [...] Traceback (most recent call last): File "test_MIMEText.py", line 23, in txt = MIMEText(buffer, _subtype="plain", _ch

[issue4177] Crash in MIMEText on FreeBSD

2008-10-22 Thread Sérgio Surkamp
New submission from Sérgio Surkamp <[EMAIL PROTECTED]>: If you try to create a MIMEText object from a very large string (test case include a 40Mbytes string), the program just eat all the CPU and with high memory usage or raise a MemoryError. Sometimes it just deadlocks when using _c