[issue5374] optparse special usage tokens conflict with formatting characters

2009-02-26 Thread Tim Gordon
Tim Gordon tim...@aleph17.co.uk added the comment: Try escaping the '%prog' in your usage string (i.e. use '%%prog' instead) so you don't get the error when you substitute values in. -- nosy: +QuantumTim ___ Python tracker rep...@bugs.python.org

[issue5242] eval() function in List Comprehension doesn't work

2009-02-13 Thread Tim Gordon
Tim Gordon tim...@aleph17.co.uk added the comment: If you know what variable you are going to be eval-ing, or at least, have a list of those that might be eval-ed, you can get around this issue by making sure they are explicitly referenced in the inner scope (i.e., in the list comprehension

[issue4633] file.tell() gives wrong result

2008-12-11 Thread Tim Gordon
Tim Gordon [EMAIL PROTECTED] added the comment: Try using the readline method instead of next. I don't think that applies the same buffering. ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue4633

[issue4115] split() method

2008-10-13 Thread Tim Gordon
Tim Gordon [EMAIL PROTECTED] added the comment: This is the intended behaviour. See http://www.python.org/doc/2.5.2/lib/string-methods.html for details. -- nosy: +QuantumTim ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue4115

[issue4031] 08 value popups an stdin error, no date handle allowed

2008-10-03 Thread Tim Gordon
Tim Gordon [EMAIL PROTECTED] added the comment: By prefixing a number with 0, you're actually using octal rather than decimal (i.e., only digits 0 to 7 are valid). For example, try: print 030 24 print 077 63 patricio wrote: New submission from patricio [EMAIL PROTECTED]: a = 08

[issue4031] 08 value popups an stdin error, no date handle allowed

2008-10-03 Thread Tim Gordon
Tim Gordon [EMAIL PROTECTED] added the comment: Whoops, I thought the tracker automatically removed quoted text! :z ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue4031

[issue2294] Bug in Pickle protocol involving __setstate__

2008-03-15 Thread Tim Gordon
Tim Gordon [EMAIL PROTECTED] added the comment: You've missed off the two underscores after the name __setstate__ :p -- nosy: +QuantumTim __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue2294

[issue1271] Raw string parsing fails with backslash as last character

2007-10-12 Thread Tim Gordon
New submission from Tim Gordon: If you have a raw string with a backslash as the last character, the parser thinks the following quote, actually used to mark the end of the string, is being quoted by the backslash. For example, r'\' should be the string with one backslash, but... print r

[issue1271] Raw string parsing fails with backslash as last character

2007-10-12 Thread Tim Gordon
Tim Gordon added the comment: So basically raw strings are useless if you need to end a string with a backslash, as there is no way to quote the backslash to make it not do this... This surely can't be too hard to fix if one considers it a problem (which I do), and just because even the docs

[issue1240] str.split bug

2007-10-05 Thread Tim Gordon
Changes by Tim Gordon: -- title: str.split possible bug - str.split bug __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1240 __ ___ Python-bugs-list mailing list

[issue1240] str.split possible bug

2007-10-05 Thread Tim Gordon
New submission from Tim Gordon: From the docs for str.split: If sep is not specified or is None... First, whitespace characters are stripped from both ends. Then, words are separated by arbitrary length strings of whitespace characters. However, ' a b c '.split(None, 1) returns ['a', 'b c

[issue1240] str.split bug when using sep = None and maxsplit

2007-10-05 Thread Tim Gordon
Changes by Tim Gordon: -- title: str.split bug - str.split bug when using sep = None and maxsplit __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1240 __ ___ Python-bugs