[issue1261] PEP 3137: make bytesobject.c methods

2007-10-16 Thread Gregory P. Smith
Gregory P. Smith added the comment: Committed revision 58493 -- resolution: - accepted status: open - closed __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1261 __ ___

[issue1285] setp.py error The process cannot access the file ...

2007-10-16 Thread Ulrich Weber
New submission from Ulrich Weber: When creating a windows installer using setup.py an error message is displayed: error: c:\docume~1\uweber\loca1s~1\temp\tmppnj1gz .zip: The process cannot access the file because it is being used by another process. The installer is created nevertheless and

[issue1286] fileinput, StringIO, and cStringIO do not support the with protocol

2007-10-16 Thread Yitz Gale
New submission from Yitz Gale: The standard idiom for opening a file is now with open... So I think it should be a goal that this should work with any built-in file-like object that needs to be closed, without having to explicitly wrap it in closing(). It certainly should work for fileinput and

[issue1259] string find and rfind methods give a TypeError that is misleading

2007-10-16 Thread Wummel
Wummel added the comment: I also hit this bug. The .index() methods have the same issue, as well as the methods in the string and strop modules: 123.index(2, None) Traceback (most recent call last): File stdin, line 1, in ? TypeError: slice indices must be integers or None import strop,

[issue1287] os.environ.pop doesn't work

2007-10-16 Thread Gustavo Niemeyer
New submission from Gustavo Niemeyer: import os os.system(echo $ASD) 0 os.environ[ASD] = asd os.system(echo $ASD) asd 0 os.environ.pop(ASD) 'asd' os.system(echo $ASD) asd 0 __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1287

[issue1258] Removal of basestring type

2007-10-16 Thread Guido van Rossum
Guido van Rossum added the comment: Committed revision 58495. Thanks Christian!!! -- resolution: - accepted status: open - closed __ Tracker [EMAIL PROTECTED] http://bugs.python.org/issue1258 __

[issue1287] os.environ.pop doesn't work

2007-10-16 Thread Gustavo Niemeyer
Changes by Gustavo Niemeyer: -- nosy: niemeyer severity: normal status: open title: os.environ.pop doesn't work versions: Python 2.1.1, Python 2.1.2, Python 2.2, Python 2.2.1, Python 2.2.2, Python 2.2.3, Python 2.3, Python 2.4, Python 2.5, Python 2.6, Python 3.0

[issue1267] Py3K cannot run as ``python -S``

2007-10-16 Thread Christian Heimes
Christian Heimes added the comment: Christian Heimes wrote: * removed unused import of open in initstdio() * fixed infinite loop in PyTokenizer_FindEncoding() by checking tok-done == E_OK I found another bug in Python/import.c:call_find_method. The function mustn't set an encoding of

[issue1267] Py3K cannot run as ``python -S``

2007-10-16 Thread Guido van Rossum
Guido van Rossum added the comment: Does this mean I should hold off reviewing the patch? On 10/16/07, Christian Heimes [EMAIL PROTECTED] wrote: Christian Heimes added the comment: Christian Heimes wrote: * removed unused import of open in initstdio() * fixed infinite loop in

[issue1267] Py3K cannot run as ``python -S``

2007-10-16 Thread Christian Heimes
Christian Heimes added the comment: Update since last patch * removed unnecessary const from const char* PyTokenizer_FindEncoding(FILE *fp) * Fixed bug in find_module whith binary files Please review the patch. __ Tracker [EMAIL PROTECTED]

[issue1287] os.environ.pop doesn't work

2007-10-16 Thread Raghuram Devarakonda
Raghuram Devarakonda added the comment: The following patch solves the problem (with the latest from trunk). I only tested on Linux. I couldn't reproduce the problem with latest py3k (again, on Linux). === --- Lib/os.py (revision

[issue1205] urllib fail to read URL contents, urllib2 crash Python

2007-10-16 Thread Michael Torrie
Michael Torrie added the comment: I had a situation where I was talking to a Sharp MFD printer. Their web server apparently does not serve chunked data properly. However the patch posted here put it in an infinite loop. Somewhere around line 525 in the python 2.4 version of httplib.py, I had

[issue1288] dict.fromkeys - Odd logic when passing second dict.fromkeys as value

2007-10-16 Thread Adam Doherty
New submission from Adam Doherty: Hello: I'm am trying to conduct some tests on a list of data that checks for the position of values in list elements using the bisect module. To store the results of these tests for output to a template I have build a dictionary with 47 keys the values of

[issue1288] dict.fromkeys - Odd logic when passing second dict.fromkeys as value

2007-10-16 Thread Raymond Hettinger
Raymond Hettinger added the comment: This isn't a bug. Writing dict.fromkeys(xrange(1,48),dict.fromkeys(xrange(1,8),0)) results in the inner expression being evaluated just once and then passed to the outer function call as a fully evaluated argument. As a result, the *same* dictionary is

[issue1631171] implement warnings module in C

2007-10-16 Thread Brett Cannon
Brett Cannon added the comment: Attached is a new version of _warnings.c that checks to see if 'warnings' has been imported, and if so, uses the attributes from that module for onceregistry and 'filters'. I did it in such a way so that 'warnings' is in no way required nor imported through