[issue6070] Python 2.6 makes .pyc/.pyo bytecode files executable

2009-06-23 Thread Marco
Marco marcu...@gmail.com added the comment: Thank you David.. sorry for my errors :) but this is my first patch :P I've recompiled py2.6 and it works fine on my Debian. As you can see: -rwxr-xr-x 1 marco marco81822 30 set 2008 setup.py ./python -c import setup -rw-r--r-- 1 marco marco

[issue6288] Update contextlib.nested docs in light of deprecation

2009-06-23 Thread Nick Coghlan
Nick Coghlan ncogh...@gmail.com added the comment: Docstring updated in r73518 (2.7) and r73520 (3.1) -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6288

[issue6326] Add a swap method to list

2009-06-23 Thread Kristján Valur Jónsson
New submission from Kristján Valur Jónsson krist...@ccpgames.com: It is sometimes useful to be able to swap the contents of two lists and this patch provides a way to do so using the fastest way possible. a = [1, 2] b = [3] id(a), id(b) (100, 101) a.swap(b) a [3] b [1, 2] id(a), id(b)

[issue6327] [mimetext] long lines get cut with exclamation mark and newline

2009-06-23 Thread Martijn Otto
New submission from Martijn Otto martijn...@gmail.com: When using mimetext, long lines are cut at character 990, at which place an exclamation mark, a newline and a space are inserted. After this the line continues... For example, this line: 0148

[issue5230] pydoc reports misleading failure if target module raises an ImportError

2009-06-23 Thread Lucas Prado Melo
Lucas Prado Melo lukepada...@gmail.com added the comment: I think this patch is ok. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5230 ___ ___

[issue6328] login() function failed in smtplib with message argument 1 must be bytes or buffer, not str

2009-06-23 Thread Gehua Yang
New submission from Gehua Yang yangge...@gmail.com: Hi folks, I encountered the following error with this Python code snippet. (I ran it with Python 3.0.1). Judging from the error as shown in IDLE debugger, the error was buried inside python. try: server =

[issue5230] pydoc reports misleading failure if target module raises an ImportError

2009-06-23 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: Removed file: http://bugs.python.org/file14338/issue5230.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5230 ___

[issue5230] pydoc reports misleading failure if target module raises an ImportError

2009-06-23 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Here is an updated patch that cleans up the unit test (I wasn't correctly restoring sys.path). -- Added file: http://bugs.python.org/file14343/issue5230.patch ___ Python tracker

[issue6328] login() function failed in smtplib with message argument 1 must be bytes or buffer, not str

2009-06-23 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: This is a duplicate of issue5259, and has been fixed in 3.1. -- components: +Library (Lib) dependencies: +smtplib is broken in Python3 nosy: +r.david.murray priority: - low resolution: - out of date stage: - committed/rejected

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

2009-06-23 Thread Akira Kitada
Akira Kitada akit...@gmail.com added the comment: Thanks for this great work! Does Regexp 2.7 include Unicode Scripts support? http://www.regular-expressions.info/unicode.html Perl and Ruby support it and it's pretty handy. -- nosy: +akitada ___

[issue6326] Add a swap method to list

2009-06-23 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: One application of this is to make help a performance problem when one wants to upgrade a list instance into a subclass instance. Since this bypasses the subclass's __init__ and other methods, doesn't it risk violating

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

2009-06-23 Thread Matthew Barnett
Matthew Barnett pyt...@mrabarnett.plus.com added the comment: It includes Unicode character properties, but not the Unicode script identification, because the Python Unicode database contains the former but not the latter. Although they could be added to the re module, IMHO their proper place

[issue6326] Add a swap method to list

2009-06-23 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: There are clearly enough subtleties to this proposal that it should be discussed on python-ideas first. If a consensus is reached you can reopen this ticket, referencing the discussion thread. -- nosy: +r.david.murray priority:

[issue6326] Add a swap method to list

2009-06-23 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: FWIW, the technique is useful and fast, but it is complicated in its effects. I used something similar in the set_swap_bodies() internal code for set and frozenset objects but avoided exposing the behavior externally.

[issue6329] Fix iteration for memoryviews

2009-06-23 Thread Raymond Hettinger
New submission from Raymond Hettinger rhettin...@users.sourceforge.net: Despite being a sequence (with both __getitem__ and __len__ defined), memoryview objects were not recognized as being iterable. The docs say that all such sequences are iterable, so this is a bug. b = b'abcde' m =

[issue6290] cPickle can misread data type

2009-06-23 Thread Alex James
Alex James ac.ja...@shaw.ca added the comment: Your test prints: '(1p1\nF1.#INF\naF-1.#INF\naF-1.IND\na.' [inf, -inf, nan] My installation is Python 2.6.2 as currently distributed. Specifying protocol 1 or 2 does circumvent the error. Thank you. -- components: +Documentation,

[issue6290] cPickle can misread data type

2009-06-23 Thread Alex James
Changes by Alex James ac.ja...@shaw.ca: -- components: +Library (Lib) -Documentation, Extension Modules, Windows ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6290 ___

[issue6326] Add a swap method to list

2009-06-23 Thread Kristján Valur Jónsson
Kristján Valur Jónsson krist...@ccpgames.com added the comment: Indeed, I realized that it does allow overriding all kinds of behaviour and as such may be dangerous for the unwary. But isn't it possible to do so anyway? One way to increase safety would be to require that the other list is

[issue6330] trunk does not build with --enable-unicode=ucs4

2009-06-23 Thread Eric Smith
New submission from Eric Smith e...@trueblade.com: This was reported a few weeks ago by Benjamin Peterson, but I haven't gotten around to fixing it. This is a reminder to myself to do it. This is due to a bug in Objects/stringlib/formatter.h. Before I fix it trunk, I need to backport some 3.1

[issue6326] Add a swap method to list

2009-06-23 Thread Raymond Hettinger
Changes by Raymond Hettinger rhettin...@users.sourceforge.net: Added file: http://bugs.python.org/file14345/mview2.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6326 ___

[issue6326] Add a swap method to list

2009-06-23 Thread Raymond Hettinger
Changes by Raymond Hettinger rhettin...@users.sourceforge.net: Removed file: http://bugs.python.org/file14345/mview2.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6326 ___

[issue6329] Fix iteration for memoryviews

2009-06-23 Thread Raymond Hettinger
Changes by Raymond Hettinger rhettin...@users.sourceforge.net: Added file: http://bugs.python.org/file14346/mview2.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6329 ___

[issue6329] Fix iteration for memoryviews

2009-06-23 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Given that the original code being copied is correct, it looks to me like the revision is fine. The memoryview tests pass for me with the patch applied. -- assignee: r.david.murray - rhettinger resolution: - accepted

[issue6329] Fix iteration for memoryviews

2009-06-23 Thread Raymond Hettinger
Changes by Raymond Hettinger rhettin...@users.sourceforge.net: Added file: http://bugs.python.org/file14347/mview3.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6329 ___

[issue6331] Add unicode script info to the unicode database

2009-06-23 Thread Walter Dörwald
New submission from Walter Dörwald wal...@livinglogic.de: This patch adds a function unicodedata.script() that returns information about the script of the Unicode character. -- components: Unicode files: unicode-script.diff keywords: patch messages: 89642 nosy: doerwalter severity:

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

2009-06-23 Thread Walter Dörwald
Walter Dörwald wal...@livinglogic.de added the comment: http://bugs.python.org/6331 is a patch that adds unicode script info to the unicode database. -- nosy: +doerwalter ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2636

[issue6329] Fix iteration for memoryviews

2009-06-23 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: Applied in r73531 and r73532. -- status: open - closed versions: +Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6329

[issue6332] typo on man page warning control

2009-06-23 Thread Lie Ryan
New submission from Lie Ryan lie.1...@gmail.com: A minor typo on the man page -W argument ... such as inside a loop); module to print each warning *only only* ... -- assignee: georg.brandl components: Documentation files: onlyonly.diff keywords: patch messages: 89645 nosy:

[issue6305] islice doesn't accept large stop values

2009-06-23 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: Clarified the error message in r73535. Leaving open as a feature request to support arbitrarily large indices. -- components: +Extension Modules type: behavior - feature request versions: +Python 2.7, Python 3.2

[issue6331] Add unicode script info to the unicode database

2009-06-23 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: I think the patch is incorrect: the default value for the script property ought to be Unknown, not Common (despite UCD.html saying the contrary; see UTR#24 and Scripts.txt). I'm puzzled why you use a hard-coded list of script names. The set

[issue2622] Import errors in email.message.py

2009-06-23 Thread Barry A. Warsaw
Barry A. Warsaw ba...@python.org added the comment: The patch looks pretty good, except that you should not change test_email.py. It specifically tests the old names, while test_email_renamed.py tests the new names. There's no point in fixing Python 2.5 since there won't be another maintenance

[issue6331] Add unicode script info to the unicode database

2009-06-23 Thread Akira Kitada
Changes by Akira Kitada akit...@gmail.com: -- nosy: +akitada ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6331 ___ ___ Python-bugs-list mailing

[issue6332] typo on man page warning control

2009-06-23 Thread Lie Ryan
Lie Ryan lie.1...@gmail.com added the comment: Bored, I grepped the trunk for a few more stuffs that has similar consecutive duplicate typos. The dup.diff patch corrects these typos. Not opening a new issue since all of them are minor. -- Added file:

[issue1100942] Add datetime.time.strptime and datetime.date.strptime

2009-06-23 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Here is an updated patch, with tests. The only thing that bugs me is the name of the method: date.strptime() seems a bit odd, given that it cannot accept a time part... OTOH 'strptime' refers to the format specification: %Y-%m-%d

[issue1677] Ctrl-C will exit out of Python interpreter in Windows

2009-06-23 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Removing the Windows part: on my machine, repeated Ctrl-C's don't exit the 3.1 interpreter, probably because the io module is now written in C. -- assignee: - ronaldoussoren components: +Macintosh -Interpreter Core, Windows

[issue2622] Import errors in email.message.py

2009-06-23 Thread Mads Kiilerich
Mads Kiilerich m...@kiilerich.com added the comment: I have updated the patch. (Applied to 2.6 where it seems like some casings had been fixed, so I dropped all the rejects. Changes to test_email.py has been.) -- Added file: http://bugs.python.org/file14352/emailcasings2.patch

[issue6333] logging: ValueError: I/O operation on closed file

2009-06-23 Thread Sridhar Ratnakumar
New submission from Sridhar Ratnakumar sridh...@activestate.com: The logging module has a bug that tries to call `flush' on a closed file handle (sys.std[out|err] to be specific). This bug was introduced by ConsoleHandler as defined in http://code.activestate.com/ recipes/576819/ The fix is

[issue6333] logging: ValueError: I/O operation on closed file

2009-06-23 Thread Sridhar Ratnakumar
Sridhar Ratnakumar sridh...@activestate.com added the comment: BTW, this only happens when running the tests via py.test - http:// pytest.org ... perhaps threading/multiprocess issue. -- ___ Python tracker rep...@bugs.python.org

[issue1677] Ctrl-C will exit out of Python interpreter in Windows

2009-06-23 Thread Ronald Oussoren
Ronald Oussoren ronaldousso...@mac.com added the comment: I cannot reproduce this on my machine (running OSX) using 2.5, 2.6 and 3.1 (latest rc). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1677