[issue5863] bz2.BZ2File should accept other file-like objects.

2009-04-27 Thread MizardX
New submission from MizardX : bz2.BZ2File should, like gzip.GzipFile, accept a fileobj argument. If implemented, you could much more easily pipe BZ2-data from other sources, such as stdin or a socket. -- components: IO, Library (Lib) messages: 86716 nosy: MizardX severity: normal statu

[issue5862] multiprocessing 'using a remote manager' example errors and possible 'from_address' code leftover

2009-04-27 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- assignee: georg.brandl -> jnoller ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscrib

[issue5857] Return namedtuples from tokenize token generator

2009-04-27 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- assignee: -> rhettinger ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:

[issue5862] multiprocessing 'using a remote manager' example errors and possible 'from_address' code leftover

2009-04-27 Thread R. David Murray
New submission from R. David Murray : The 'Using a remote manager' section of the multiprocessing docs has an example of calling the (documented) 'from_address' class method of BaseManager. However, no such method appears to exist. I don't know if this is a doc bug or a code bug. The __reduce__

[issue5861] test_urllib fails on windows

2009-04-27 Thread Hirokazu Yamamoto
Changes by Hirokazu Yamamoto : -- dependencies: +urllib doesn't correct server returned urls ___ Python tracker ___ ___ Python-bugs-lis

[issue5861] test_urllib fails on windows

2009-04-27 Thread Hirokazu Yamamoto
Hirokazu Yamamoto added the comment: Python 2.7a0 (trunk, Apr 28 2009, 10:23:56) [MSC v.1200 32 bit (Intel)] on win32 Type "help", "copyright", "credits" or "license" for more information. >>> import urllib >>> urllib.pathname2url("c:/foo") '///C|//foo' When "|" above is quoted, urllib.urlopen

[issue5861] test_urllib fails on windows

2009-04-27 Thread Hirokazu Yamamoto
New submission from Hirokazu Yamamoto : Hello. I noticed test_urllib fails on windows. == ERROR: test_copy (__main__.urlretrieve_FileTests) -- Traceback (most r

[issue1662] [patch] assert tp_traverse in PyType_GenericAlloc()

2009-04-27 Thread Bryan Silverthorn
Changes by Bryan Silverthorn : Removed file: http://bugs.python.org/file8998/bcs_typeobject_assert.patch ___ Python tracker ___ ___ Python-bugs

[issue1662] [patch] assert tp_traverse in PyType_GenericAlloc()

2009-04-27 Thread Bryan Silverthorn
Bryan Silverthorn added the comment: Well, there's no Python bug per se, hence no test case; this patch just adds a single additional assert that might catch a particular extension implementation mistake. It was prompted by tracking down the bug in pygtk mentioned above. I've attached an update

[issue1755841] Patch for [ 735515 ] urllib2 should cache 301 redir

2009-04-27 Thread Skip Montanaro
Changes by Skip Montanaro : -- nosy: -skip.montanaro ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://

[issue2223] regrtest.py -R not working

2009-04-27 Thread Daniel Diniz
Changes by Daniel Diniz : -- nosy: +michael.foord stage: -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsu

[issue2091] file accepts 'rU+' as a mode

2009-04-27 Thread Daniel Diniz
Changes by Daniel Diniz : -- nosy: +benjamin.peterson, pitrou ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: ht

[issue2091] file accepts 'rU+' as a mode

2009-04-27 Thread Daniel Diniz
Changes by Daniel Diniz : -- components: +IO stage: -> patch review versions: +Python 3.1 -Python 2.5 ___ Python tracker ___ ___ Pytho

[issue481171] Hang using files named prn.txt, etc

2009-04-27 Thread Daniel Diniz
Daniel Diniz added the comment: Cannot reproduce the hang in 2.6.2 (Windows XP) for nul (opening and reading returns an empty string), prn or coml. Reading from con.xxx "hangs", but it looks like it's waiting for data and Ctrl+C interrupts it. -- nosy: +ajaksu2 priority: normal -> low s

[issue1707753] get status output fix for Win32

2009-04-27 Thread Daniel Diniz
Changes by Daniel Diniz : -- stage: -> test needed versions: +Python 3.1 ___ Python tracker ___ ___ Python-bugs-list mailing list U

[issue1763] Winpath module - easy access to Windows directories like My Documents

2009-04-27 Thread Daniel Diniz
Changes by Daniel Diniz : -- stage: -> patch review versions: +Python 2.7, Python 3.1 -Python 2.6 ___ Python tracker ___ ___ Python-bu

[issue1524938] PEP MemoryError with a lot of available memory gc not called

2009-04-27 Thread Daniel Diniz
Changes by Daniel Diniz : -- versions: +Python 2.7, Python 3.1 -Python 2.6 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue1602] windows console doesn't print utf8 (Py30a2)

2009-04-27 Thread Daniel Diniz
Changes by Daniel Diniz : -- nosy: +ezio.melotti, haypo stage: -> test needed versions: +Python 3.1 ___ Python tracker ___ ___ Python-

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

2009-04-27 Thread Daniel Diniz
Changes by Daniel Diniz : -- stage: -> test needed versions: +Python 3.1 -Python 2.4, Python 2.5, Python 3.0 ___ Python tracker ___ __

[issue1522] pyvm module patch

2009-04-27 Thread Benjamin Peterson
Benjamin Peterson added the comment: I'm afraid it's too late for this. -- nosy: +benjamin.peterson resolution: -> rejected status: open -> closed ___ Python tracker ___ ___

[issue1522] pyvm module patch

2009-04-27 Thread Daniel Diniz
Daniel Diniz added the comment: Could this be useful for the "make other Python implementors lives easier" plan? -- nosy: +ajaksu2 stage: -> test needed type: -> feature request versions: +Python 2.7, Python 3.1 -Python 3.0 ___ Python tracker

[issue1662] [patch] assert tp_traverse in PyType_GenericAlloc()

2009-04-27 Thread Daniel Diniz
Daniel Diniz added the comment: Bryan: can you provide a test case without external dependencies? If not, confirming this is still valid in 2.6 would also help. -- nosy: +ajaksu2 stage: -> test needed ___ Python tracker

[issue1266570] PEP 349: allow str() to return unicode

2009-04-27 Thread Daniel Diniz
Daniel Diniz added the comment: Maybe something useful for 2.7? -- components: +Unicode -None nosy: +ajaksu2, ezio.melotti, haypo stage: -> test needed type: -> feature request versions: +Python 2.7 ___ Python tracker

[issue735515] urllib / urllib2 should cache 301 redirections

2009-04-27 Thread Daniel Diniz
Daniel Diniz added the comment: Patch in issue 1755841. -- dependencies: +Patch for [ 735515 ] urllib2 should cache 301 redir nosy: +ajaksu2 versions: +Python 2.7 ___ Python tracker __

[issue1755841] Patch for [ 735515 ] urllib2 should cache 301 redir

2009-04-27 Thread Daniel Diniz
Changes by Daniel Diniz : -- nosy: +jjlee stage: -> patch review type: -> feature request versions: +Python 2.7 -Python 2.6 ___ Python tracker ___ ___

[issue1734234] Fast path for unicodedata.normalize()

2009-04-27 Thread Antoine Pitrou
Antoine Pitrou added the comment: Committed in r72054, r72055. Thanks for the patch! -- resolution: accepted -> fixed status: open -> closed ___ Python tracker ___ ___

[issue5860] TextIOWrapper: bad error reporting when write() is forbidden

2009-04-27 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- resolution: -> duplicate status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing

[issue5860] TextIOWrapper: bad error reporting when write() is forbidden

2009-04-27 Thread DSM
DSM added the comment: See also http://bugs.python.org/issue5844 , which contains a patch to test. -- nosy: +dsm001 ___ Python tracker ___ ___

[issue5844] internal error on write while reading

2009-04-27 Thread Daniel Diniz
Changes by Daniel Diniz : -- priority: normal -> critical stage: test needed -> needs patch ___ Python tracker ___ ___ Python-bugs-list

[issue5857] Return namedtuples from tokenize token generator

2009-04-27 Thread Raymond Hettinger
Raymond Hettinger added the comment: I strongly prefer that there not be inner named tuples. That is going overboard. FWIW, row/col order is very common convention especially when the row refers to a line number in a text block and column refers to a character position within the row. ---

[issue5322] Python 2.6 object.__new__ argument calling autodetection faulty

2009-04-27 Thread Trundle
Trundle added the comment: See also issue #1694663. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://m

[issue5857] Return namedtuples from tokenize token generator

2009-04-27 Thread Vaibhav Mallya
Vaibhav Mallya added the comment: Well, the reason I put in the inner row/col namedtuple initially was because the first mistake I made with the original module was mixing up the row/col indices for a particular case. It certainly caused all sorts of weird headaches. :o) I mean, it seems like t

[issue5860] TextIOWrapper: bad error reporting when write() is forbidden

2009-04-27 Thread Antoine Pitrou
New submission from Antoine Pitrou : Opening an existing file in read-only text mode and trying to write to it: >>> f = open("LICENSE") >>> f.write("") Traceback (most recent call last): File "", line 1, in SystemError: null argument to internal routine Binary files get it right though: >>>

[issue5857] Return namedtuples from tokenize token generator

2009-04-27 Thread Raymond Hettinger
Raymond Hettinger added the comment: Comments on the earlier patch: * No need for an inner row/col namedtuple. That would add little value. * The name "Token" is already used in the module for a different purpose. * The wrapper is nice looking, but it is better to in-line this patch. Attaching

[issue5793] Rationalize isdigit / isalpha / tolower / ... uses throughout Python source

2009-04-27 Thread Eric Smith
Eric Smith added the comment: Checked in to trunk (rr72040) and py3k (r72044). Windows buildbots look okay, closing. -- resolution: -> accepted status: open -> closed ___ Python tracker __

[issue5858] Make complex repr and str more like float repr and str

2009-04-27 Thread Mark Dickinson
Mark Dickinson added the comment: > This should probably be discussed somewhat that all the numpy/numeric > folks can see it. Good point; I'll post something to the numpy/scipy mailing list and see if I can get some reactions. > Also note that any changes to representations tend to break peop

[issue5853] mimetypes.guess_type() hits recursion limit

2009-04-27 Thread Antoine Pitrou
Antoine Pitrou added the comment: Committed a fix in r72045. Thanks for the report! -- resolution: -> fixed status: open -> closed ___ Python tracker ___ ___

[issue5853] mimetypes.guess_type() hits recursion limit

2009-04-27 Thread Antoine Pitrou
Antoine Pitrou added the comment: For the record, here is a test script showcasing the problem. -- Added file: http://bugs.python.org/file13798/mimetest.py ___ Python tracker ___

[issue5858] Make complex repr and str more like float repr and str

2009-04-27 Thread Raymond Hettinger
Raymond Hettinger added the comment: This should probably be discussed somewhat that all the numpy/numeric folks can see it (since they likely comprise the largest group of users of complex numbers). Also note that any changes to representations tend to break peoples doctests. Those are partic

[issue5859] Remove implicit '%f' -> '%g' switch from float formatting.

2009-04-27 Thread Mark Dickinson
New submission from Mark Dickinson : Currently, Python switches from %f to %g formatting at 1e50. This applies both to the old-style percent formatting, and to the newer PEP 3101-style formatting: >>> '%f' % 2.**166 '93536104789177786765035829293842113257979682750464.00' >>> '%f' % 2.**16

[issue5858] Make complex repr and str more like float repr and str

2009-04-27 Thread Mark Dickinson
New submission from Mark Dickinson : In all current versions of Python, the str or repr of a float always includes *either* an exponent, or a decimal point and at least one digit after the decimal point. I propose making the str or repr of a complex number behave in the same way. That is, in

[issue5857] Return namedtuples from tokenize token generator

2009-04-27 Thread Vaibhav Mallya
New submission from Vaibhav Mallya : Returning an anonymous 5-tuple seems like a suboptimal interface since it's so easy to accidentally confuse, for example, the indices of start and end. I've used tokenize.py for several scripts in the past few weeks and I've always ended up writing some sort o

[issue4685] IDLE will not open (2.6.1 on WinXP pro)

2009-04-27 Thread Ilan
Ilan added the comment: I basically have been running IDLE without the subprocess. (In C:\Python24\Lib\idlelib\PyShell.py and at line 1272 change use_subprocess = True to use_subprocess = False Save PyShell.py, restart IDLE, and you will see a message in the shell window that IDLE is now ru

[issue4385] Py_Object_HEAD_INIT in Py3k

2009-04-27 Thread Georg Brandl
Georg Brandl added the comment: Actually, seeing that other macro docs do that as well, I'm okay with it. -- ___ Python tracker ___ __

[issue5840] "Thread State and the Global Interpreter Lock" section of the docs doesn't cover TLS APIs

2009-04-27 Thread Georg Brandl
Georg Brandl added the comment: Committed init.rst.diff in r72037. Next step: document TLS APIs. -- ___ Python tracker ___ ___ Python

[issue5846] Deprecate obsolete functions in unittest

2009-04-27 Thread Georg Brandl
Georg Brandl added the comment: I guess adding a standard DeprecationWarning is fine in these cases. -- nosy: +georg.brandl ___ Python tracker ___ ___

[issue1588] str.format() wrongly formats complex() numbers (Py30a2)

2009-04-27 Thread Eric Smith
Eric Smith added the comment: > More specifically, how about allowing widths, and the > '<', '>' and '^' alignment specifiers, but not '=', or > '0' for zero-padding. That sounds correct. > I suppose that thousands separators should be permitted > here too? Though it's difficult to imagine an

[issue5850] Full example for emulating a container type

2009-04-27 Thread Raymond Hettinger
Raymond Hettinger added the comment: I think we've got this covered with the examples for the collections module ABCs. We have one for ListBasedSet and are adding a link for to an OrderedSet recipe. The ABCs themselves provide a clear path on how to implement major container types. The UserD

[issue5848] Minor unittest doc patch

2009-04-27 Thread Georg Brandl
Georg Brandl added the comment: Committed as r72036. -- nosy: +georg.brandl resolution: -> accepted status: open -> closed ___ Python tracker ___ ___

[issue1588] str.format() wrongly formats complex() numbers (Py30a2)

2009-04-27 Thread Mark Dickinson
Mark Dickinson added the comment: > I think a ValueError would be best. That way if we decide to give it > some meaning in the future, we know it won't change any working code. Agreed. It also fits with the way that other non-numeric types seem to behave, as in: >>> format("boris", "030s") T

[issue1588] str.format() wrongly formats complex() numbers (Py30a2)

2009-04-27 Thread Eric Smith
Eric Smith added the comment: > This sounds good to me. I assume a '+' would still affect > the sign of the real part? Forgot to reply to this part. Yes, a '+', '-', or ' ' would still affect the real part, but the imaginary part would always use '+'. --

[issue1588] str.format() wrongly formats complex() numbers (Py30a2)

2009-04-27 Thread Mark Dickinson
Mark Dickinson added the comment: More specifically, how about allowing widths, and the '<', '>' and '^' alignment specifiers, but not '=', or '0' for zero-padding. I suppose that thousands separators should be permitted here too? Though it's difficult to imagine anyone actually using them. I

[issue1588] str.format() wrongly formats complex() numbers (Py30a2)

2009-04-27 Thread Eric Smith
Eric Smith added the comment: > I don't see any problem with dealing with width, alignment > and padding with a user-specified fill character; I think we > should keep these if possible. It's just zero padding where > it's not clear what should happen. You're correct. It's just zero padding t

[issue1588] str.format() wrongly formats complex() numbers (Py30a2)

2009-04-27 Thread Mark Dickinson
Mark Dickinson added the comment: > How about this: > - we have a single specifier with the same format as floats > - we force the sign on the imaginary part to be '+', no >matter what was specified > - we add a 'j' after the imaginary part This sounds good to me. I assume a '+' would sti

[issue1492860] Integer bit operations performance improvement.

2009-04-27 Thread Mark Dickinson
Mark Dickinson added the comment: I agree issue 1087418 is related, but why is it marked as a dependency for this issue? It seems to me that either of these feature requests could be implemented independently of the other: this one applies only to 2.x ints, while issue 1087418 applies only

[issue5836] Clean up float parsing code for nans and infs

2009-04-27 Thread Mark Dickinson
Mark Dickinson added the comment: Done in r71967 (py3k), r71969 (trunk). -- resolution: -> fixed status: open -> closed ___ Python tracker ___ __

[issue1496032] test_float segfaults with SIGFPE on FreeBSD 6.0 / Alpha

2009-04-27 Thread Mark Dickinson
Mark Dickinson added the comment: No problem! I'll close this as out of date, then. -- resolution: -> out of date status: open -> closed ___ Python tracker ___ _

[issue5019] Specifying common controls DLL in manifest

2009-04-27 Thread Robin Dunn
Robin Dunn added the comment: Update: I finally worked out what needed to be done for wxPython and while simply changing Python's manifest would have been immensely easier what I have does seem to work well so I thought I should give some info here for posterity. I went back and experimented a

[issue2572] 3.0 pickle docs -- what about old-style classes?

2009-04-27 Thread Georg Brandl
Georg Brandl added the comment: Okay, as the original submitter I withdraw this request. -- resolution: -> rejected status: open -> closed ___ Python tracker ___ ___

[issue5856] Minor typo in traceback example

2009-04-27 Thread Georg Brandl
Georg Brandl added the comment: Fixed in r72007, thanks! -- resolution: -> fixed status: open -> closed ___ Python tracker ___ ___ Py

[issue1496032] test_float segfaults with SIGFPE on FreeBSD 6.0 / Alpha

2009-04-27 Thread Bob Ippolito
Bob Ippolito added the comment: I don't even recall where I had access to a FreeBSD 6.0 Alpha machine, sorry. -- ___ Python tracker ___ __

[issue1496032] test_float segfaults with SIGFPE on FreeBSD 6.0 / Alpha

2009-04-27 Thread Mark Dickinson
Changes by Mark Dickinson : -- assignee: -> marketdickinson ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue1467929] %-formatting and dicts

2009-04-27 Thread Eric Smith
Eric Smith added the comment: The patch incorrectly raises an exception for: '%(a)s %%' % {'a':'xyz'} I'll look into fixing it. -- ___ Python tracker ___

[issue1496032] test_float segfaults with SIGFPE on FreeBSD 6.0 / Alpha

2009-04-27 Thread Mark Dickinson
Mark Dickinson added the comment: Bob, can you still reproduce the originally reported SIGFPE? -- ___ Python tracker ___ ___ Python

[issue5856] Minor typo in traceback example

2009-04-27 Thread DSM
DSM added the comment: There's more than a typo wrong with the example there-- "import traceback" doesn't bring format_list into scope, and so it should be traceback.format_list. Patch attached which turns the example into something which passes a doctest. -- keywords: +patch nosy: +ds

[issue5793] Rationalize isdigit / isalpha / tolower / ... uses throughout Python source

2009-04-27 Thread Eric Smith
Eric Smith added the comment: I'll implement this by adding a pyctype.h and pyctype.c, mimicking . I'll essentially copy and rename the methods in bytes_methods.[ch], then change bytes_methods.h to refer to the new versions, for backward compatibility. -- assignee: -> eric.smith _

[issue5853] mimetypes.guess_type() hits recursion limit

2009-04-27 Thread Antoine Pitrou
Antoine Pitrou added the comment: In the meantime, hgweb could probably call mimetypes.init() at the beginning (before spawning threads). -- ___ Python tracker ___ __

[issue5853] mimetypes.guess_type() hits recursion limit

2009-04-27 Thread Antoine Pitrou
Antoine Pitrou added the comment: The plan is to replace init() with something like: _db = None def init(): global _db db = ... # initialize database # set it to global only when it's fully ready _db = db and guess_type() with: def guess_type(): if _db is None:

[issue5853] mimetypes.guess_type() hits recursion limit

2009-04-27 Thread Antoine Pitrou
Antoine Pitrou added the comment: The function monkeypatching hack should be replaced with something more robust. (what might happen here is that init() is first called from another thread, sets `inited` to True and then crashes for whatever reason, so guess_type() isn't actually monkeypatched)

[issue5853] mimetypes.guess_type() hits recursion limit

2009-04-27 Thread djc
djc added the comment: This could well be due to the SocketServer.ThreadingMixIn that's being used by the hg serve built-in web server (since it doesn't show on REPL or, as far as I can see, when used from within Apache + mod_wsgi). -- ___ Python tra

[issue5854] logging module's __all__ attribute not in sync with documentation

2009-04-27 Thread Vinay Sajip
Vinay Sajip added the comment: Fix checked in to trunk, release26-maint and py3k. -- resolution: -> fixed status: open -> closed ___ Python tracker ___ _

[issue5856] Minor typo in traceback example

2009-04-27 Thread Niels de Vos
New submission from Niels de Vos : The last example of traceback (found on release 2.6.2) contains a typo. >>> theError = IndexError('tuple indx out of range') >>> traceback.format_exception_only(type(theError), theError) ['IndexError: tuple

[issue1777398] IDLE Freezes After Running Scripts

2009-04-27 Thread Ross Peoples
Ross Peoples added the comment: I just did a fresh install of Ubuntu Jaunty in a virtual machine, copied and pasted the code. It ran the first time without a problem. But the second time I ran it, the application would not exit and IDLE is frozen. So I still have to force quit. This is with Pyth

[issue5845] rlcompleter should be enabled automatically

2009-04-27 Thread Antoine Pitrou
Antoine Pitrou added the comment: He, adding completion is also something I find myself adding on every box on which I use Python... -- nosy: +pitrou ___ Python tracker ___ _

[issue5855] Perhaps exponential performance of sum(listoflists, [])

2009-04-27 Thread Antoine Pitrou
Antoine Pitrou added the comment: No wonder it's quadratic (rather than exponential), since summing will invoke the + operator and therefore produce a new list object at every iteration. If you use "f = f + l" in your explicit version, it becomes quadratic too. -- nosy: +pitrou resoluti

[issue1467929] %-formatting and dicts

2009-04-27 Thread Eric Smith
Changes by Eric Smith : -- assignee: jafo -> eric.smith versions: +Python 2.7 -Python 2.6 ___ Python tracker ___ ___ Python-bugs-lis

[issue5855] Perhaps exponential performance of sum(listoflists, [])

2009-04-27 Thread sjohn
New submission from sjohn : To flatten lists of lists, e.g. [[0], [1], [2], ...], I found the short and quite python-like one-liner "sum(listoflists, [])". This, however, has absolutely awful performance: while the equivalent way of iterating by hand and extending a flat list is longer and uglier

[issue1588] str.format() wrongly formats complex() numbers (Py30a2)

2009-04-27 Thread Eric Smith
Changes by Eric Smith : -- assignee: -> eric.smith ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.

[issue5835] Deprecate PyOS_ascii_formatd

2009-04-27 Thread Eric Smith
Eric Smith added the comment: Checked in for trunk (r71938) and py3k (r71989). -- resolution: -> accepted status: open -> closed ___ Python tracker ___ _

[issue5854] logging module's __all__ attribute not in sync with documentation

2009-04-27 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- assignee: -> vsajip nosy: +vsajip ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscri

[issue1588] str.format() wrongly formats complex() numbers (Py30a2)

2009-04-27 Thread Eric Smith
Eric Smith added the comment: Mark Dickinson wrote: >> What should the format specifier mini-language for complex numbers look >> like? >> Should it look like the existing mini-language for floats, but have >> the format specified twice, with some sort of delimiter? > > This sounds clumsy to me

[issue5854] logging module's __all__ attribute not in sync with documentation

2009-04-27 Thread R. David Murray
R. David Murray added the comment: The addition of __all__ was made by raymond.hettinger in r60851. 'from xxx import *' is not a recommended style, but irregardless of that __all__ certainly should list all of the public APIs. -- keywords: +easy nosy: +r.david.murray, rhettinger priorit

[issue5852] can't use "glog" to find the path with square bracket

2009-04-27 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: The bug tracker is not here to get help. Please ask this kind of question on the comp.lang.python newsgroup. (they will tell you that [ is a special character for glob(), and how to escape it) -- nosy: +amaury.forgeotdarc resolution: -> invalid s

[issue5854] logging module's __all__ attribute not in sync with documentation

2009-04-27 Thread Floris Bruynooghe
New submission from Floris Bruynooghe : The logging module in Python 2.6 has started to use the __all__ method. However it does not list all the symbols that are described in the documentation. Most notably the getLogger function is not in the __all__ list, but there are others like addLevelNam

[issue1588] str.format() wrongly formats complex() numbers (Py30a2)

2009-04-27 Thread Mark Dickinson
Mark Dickinson added the comment: > What should the format specifier mini-language for complex numbers look > like? > Should it look like the existing mini-language for floats, but have > the format specified twice, with some sort of delimiter? This sounds clumsy to me. I'd guess that in most

[issue1588] str.format() wrongly formats complex() numbers (Py30a2)

2009-04-27 Thread Eric Smith
Eric Smith added the comment: I agree this is a feature request. It comes down to: What should the format specifier mini-language for complex numbers look like? Should it look like the existing mini-language for floats, but have the format specified twice, with some sort of delimiter? Or just

[issue5853] mimetypes.guess_type() hits recursion limit

2009-04-27 Thread djc
djc added the comment: georg.brandl remarked it might be due to demandimport. That doesn't seem to be the case: >>> from mercurial import demandimport >>> demandimport.enable() >>> import mimetypes >>> mimetypes.guess_type('/home/djc/src/hg/crew/templates/static/hglogo.png') ('image/png', None)

[issue5853] mimetypes.guess_type() hits recursion limit

2009-04-27 Thread djc
New submission from djc : I've got hgweb (the Mercurial web app) crashing on guess_type() in 2.6.2, but not in 2.5.4. I'm passing in a filename like '/home/djc/src/hg/crew/templates/static/hglogo.png'. Doesn't happen on the REPL, but happens in side the hg serve web server. Traceback (most recen

[issue5852] can't use "glog" to find the path with square bracket

2009-04-27 Thread winterTTr
New submission from winterTTr : I want to list the file with glob . The path( which is a directory ) is contain square bracket as "[ab]xxx" . However , i can't find how to do it rightly with glob . with the coding : {{{ import glob glob.glob('[ab]xxx' ) }}} and with the path "[ab]xxx" really