[issue9639] urllib2's AbstractBasicAuthHandler is limited to 6 requests

2010-11-30 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: Grr. Why wasn't this fix backported to the release maintenance branch before 2.6.6 was released? I've just had an application break as a result of upgrading from 2.6.5 to 2.6.6. Oh well, too late now. :-( /grumble -- nosy:

[issue9639] urllib2's AbstractBasicAuthHandler is limited to 6 requests

2010-11-30 Thread Senthil Kumaran
Senthil Kumaran orsent...@gmail.com added the comment: Ouch. My mistake. Had not realize then, that code that actually broke things was merged in 2.6.x and it had to be fixed too. :( -- ___ Python tracker rep...@bugs.python.org

[issue9639] urllib2's AbstractBasicAuthHandler is limited to 6 requests

2010-11-30 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: Ah well, it turned out to be fairly easy to work around, at least. :-) Just in case any other urllib2 users have to deal with this in 2.6.6 (and also manage to find their way to this bug report :-): it's easy to monkeypatch your way around

[issue10588] imp.find_module raises unexpected SyntaxError

2010-11-30 Thread Emile Anclin
New submission from Emile Anclin emile.anc...@logilab.fr: Considering following file: $ cat pylint/test/input/func_unknown_encoding.py # -*- coding: IBO-8859-1 -*- check correct unknown encoding declaration __revision__ = '' $ When we try to find that module, imp.find_module raises

[issue9709] test_distutils warning: initfunc exported twice on Windows

2010-11-30 Thread Stefan Krah
Stefan Krah stefan-use...@bytereef.org added the comment: Without the patch, you see the warning if test_build_ext is run in verbose mode. With the patch, the warning disappears. -- ___ Python tracker rep...@bugs.python.org

[issue3243] Support iterable bodies in httplib

2010-11-30 Thread Xuanji Li
Xuanji Li xua...@gmail.com added the comment: pitrou: actually that seems a bit suspect now... you need to handle 'data' differently depending on its type, and while you can determine the type by finding out when 'data' throws certain exceptions, it doesn't seem like what exceptions were

[issue10537] OS X IDLE 2.7rc1 from 64-bit installer hangs when you paste something.

2010-11-30 Thread Ned Deily
Ned Deily n...@acm.org added the comment: More data points: using the 2.7.1 release source tarball, the problem is reproducible on 10.6 when dynamically linked to the Apple Tcl/Tk 8.5 and executing in either 64-bit or 32-bit mode. It is not reproducible when using ActiveState Tcl/Tk 8.5.9,

[issue10464] netrc module not parsing passwords containing #s.

2010-11-30 Thread Xuanji Li
Xuanji Li xua...@gmail.com added the comment: bumping...can someone review this? The reported bug seems valid enough. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10464 ___

[issue10576] Add a progress callback to gcmodule

2010-11-30 Thread Kristján Valur Jónsson
Kristján Valur Jónsson krist...@ccpgames.com added the comment: Hi, as I stated, the original patch was simply our original implementation. Here is a new patch. It is simpler: 1) it exposes a gc.callbacks list where users can register themselves, in the spirit of sys.meta_path 2) One can have

[issue10576] Add a progress callback to gcmodule

2010-11-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Let's start bikeshedding the calling signature. I like having a single callback, since multiple callables are a nuisance to manage. IMO the callback should have a second argument as a dict containing various statistics that we can expand over

[issue10576] Add a progress callback to gcmodule

2010-11-30 Thread Kristján Valur Jónsson
Kristján Valur Jónsson krist...@ccpgames.com added the comment: You are right, Antoine. How about a string and a dict? the string can be start and stop and we can add interesting information to the dict as you suggest. -- ___ Python tracker

[issue3243] Support iterable bodies in httplib

2010-11-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: pitrou: actually that seems a bit suspect now... you need to handle 'data' differently depending on its type, Yes, but you can't know all appropriate types in advance, so it's better to try and catch the TypeError. I don't understand your

[issue3243] Support iterable bodies in httplib

2010-11-30 Thread Xuanji Li
Xuanji Li xua...@gmail.com added the comment: I don't fully understand Lib/urllib/request.py either, I just ported it and ran the unittests... it seems like what it does is that if you send an iterator through as 'data' you can't know the length in advance, and rather than let the len(data)

[issue10588] imp.find_module raises unexpected SyntaxError

2010-11-30 Thread Ron Adam
Changes by Ron Adam ron_a...@users.sourceforge.net: -- nosy: +ron_adam ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10588 ___ ___

[issue3243] Support iterable bodies in httplib

2010-11-30 Thread Davide Rizzo
Davide Rizzo sor...@gmail.com added the comment: len(data) will raise anyway. No, it won't, if the iterable happens to be a sequence. -- nosy: +davide.rizzo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue3243

[issue3243] Support iterable bodies in httplib

2010-11-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: len(data) will raise anyway. No, it won't, if the iterable happens to be a sequence. Well, it seems the patch is confused between iterable and iterator. Only iterators have a __next__, but they usually don't have a __len__. The patch should

[issue9873] urllib.parse: Allow bytes in some APIs that use string literals internally

2010-11-30 Thread Nick Coghlan
Nick Coghlan ncogh...@gmail.com added the comment: Committed in r86889 The docs changes should soon be live at: http://docs.python.org/dev/library/urllib.parse.html If anyone would like to suggest changes to the wording of the docs for post beta1, or finds additional corner cases that the new

[issue3243] Support iterable bodies in httplib

2010-11-30 Thread Xuanji Li
Xuanji Li xua...@gmail.com added the comment: davide: yeah, hasattr(lol, '__next__') == False, even though strings are Iterable; so for strings and other such sequences the len(data) line will be executed. So technically we shouldn't say No Content-Length specified for iterable body but we

[issue3243] Support iterable bodies in httplib

2010-11-30 Thread Senthil Kumaran
Senthil Kumaran orsent...@gmail.com added the comment: Xuanji, a wording which does convey the approximate meaning is fine. I think, the Exception error messages will help the people based on the Context. - Lets have the ValueError raised from the urllib/request.py. Changing it to

[issue3243] Support iterable bodies in httplib

2010-11-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: One way to check that it's bytes-compatible is to take a memoryview of it: memoryview(babc) memory at 0x1cf5120 memoryview(bytearray(babc)) memory at 0x1cf55a0 memoryview(array.array('b', babc)) memory at 0x1cf52a0 memoryview([babc])

[issue3243] Support iterable bodies in httplib

2010-11-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: - Lets have the ValueError raised from the urllib/request.py. Changing it to isinstance(data,collections.Iterable) as Antoine suggested is okay here too. Xuanji is right: it's not. We want bytes to be accepted, and it's an iterable.

[issue10576] Add a progress callback to gcmodule

2010-11-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: You are right, Antoine. How about a string and a dict? the string can be start and stop and we can add interesting information to the dict as you suggest. Looks good to me. -- ___ Python tracker

[issue10576] Add a progress callback to gcmodule

2010-11-30 Thread Daniel Stutzbach
Daniel Stutzbach stutzb...@google.com added the comment: How about a string and a dict? the string can be start and stop and we can add interesting information to the dict as you suggest. I like where this is headed. How about putting the string in the dict, too? d['phase'] = 'start'

[issue3243] Support iterable bodies in httplib

2010-11-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Answering to myself, sorry. memoryview() does return the right answer of whether the object supports the buffer interface, *however* it doesn't mean the len() will be right. For example, take an array.array of ints: memoryview(array.array(I,

[issue1079] decode_header does not follow RFC 2047

2010-11-30 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: -- assignee: - r.david.murray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1079 ___ ___

[issue10552] Tools/unicode/gencodec.py error

2010-11-30 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: Committed in revision 86891. Keeping open to address Mac issue. -- assignee: - belopolsky components: +Macintosh priority: normal - low stage: commit review - needs patch ___

[issue6280] calendar.timegm() belongs in time module, next to time.gmtime()

2010-11-30 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: I am going to close this as rejected unless someone objects. The benefit is too small to make users suffer through the deprecation process. -- resolution: - rejected status: open - pending

[issue10574] email.header.decode_header fails if the string contains multiple directives

2010-11-30 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Note that none of your examples are valid encoded words, so given that email currently does strict parsing, the fact that it is not attempting to decode those words is technically correct. However, I agree that it would be better for

[issue1170] shlex have problems with parsing unicode

2010-11-30 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: Adding #10587 because we need to figure out the exact meaning of str.isspace() etc. first. It is possible that for proper operation shlex should consult unicodedata directly. -- dependencies: +Document the

[issue1706039] Added clearerr() to clear EOF state

2010-11-30 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: I don't know how to reproduce the issue and without unit tests this patch cannot be committed. -- assignee: belopolsky - ___ Python tracker rep...@bugs.python.org

[issue3243] Support iterable bodies in httplib

2010-11-30 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: hasattr(lol, '__next__') == False, even though strings are Iterable FYI, magic methods are looked up on the class, not on the instance. That’s why ABCs are the right thing to use here.

[issue1706039] Added clearerr() to clear EOF state

2010-11-30 Thread Scott Dial
Scott Dial sc...@scottdial.com added the comment: The patch includes unittests; the issue is that the tests pass without the changes. That is an entirely different state to be in. The tests should be committed unless somebody wants to object to the behavior that they are testing (although I

[issue9598] untabify.py fails on files that contain non-ascii characters

2010-11-30 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: Committed revision 86893 that makes untabify.py respect encoding cookie in the files it processes. I don't think there is anything else that needs to be done here. -- resolution: - fixed stage: -

[issue10551] mimetypes read from the registry should not overwrite standard mime mappings

2010-11-30 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Kovid: so essentially what you are saying is that the windows platform is broken with respect to MIME types and with respect to its security model. Why am I not surprised? :) You would have the same problem if software installation

[issue10551] mimetypes read from the registry should not overwrite standard mime mappings

2010-11-30 Thread Kovid Goyal
Kovid Goyal ko...@kovidgoyal.net added the comment: It is, of course, your decision, but IMO, since the mimetypes database in windows appears to be always broken, the default behavior of the mimetypes module in python 2.7 on windows is broken for most (all?) windows installs. For me

[issue10551] mimetypes read from the registry should not overwrite standard mime mappings

2010-11-30 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: I would expect that it would not be people new to mimetypes that would have the issues, but people like you for whom the behavior on Windows has changed. And this is indeed a concern. The people involved in making the windows mimetypes

[issue10587] Document the meaning of str methods

2010-11-30 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: What is the issue that you are reporting? that the status quo should be documented, or that isalpha is wrong? These are independent - don't mix them. -- nosy: +loewis ___ Python tracker

[issue10551] mimetypes read from the registry should not overwrite standard mime mappings

2010-11-30 Thread Kovid Goyal
Kovid Goyal ko...@kovidgoyal.net added the comment: I actually had in mind people that (like me) develop primarily on unix and assume that mimetypes works the same way on both windows and unix. Of course, the changed behavior is also a concern. At the very least, I would encourage the

[issue1170] shlex have problems with parsing unicode

2010-11-30 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: The key requirement to consider for in POSIX compatible mode is, well, POSIX compatibility, which is defined in http://www.opengroup.org/onlinepubs/009695399/utilities/xcu_chap02.html

[issue10589] I/O ABC docs should specify which methods have implementations

2010-11-30 Thread Daniel Stutzbach
New submission from Daniel Stutzbach stutzb...@google.com: The I/O ABC documentation has a blanket disclaimer at the top: The abstract base classes also provide default implementations of some methods in order to help implementation of concrete stream classes. For example, BufferedIOBase

[issue10589] I/O ABC docs should specify which methods have implementations

2010-11-30 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- nosy: +pitrou ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10589 ___ ___ Python-bugs-list mailing

[issue10587] Document the meaning of str methods

2010-11-30 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: On Tue, Nov 30, 2010 at 1:53 PM, Martin v. Löwis rep...@bugs.python.org wrote: .. What is the issue that you are reporting? that the status quo should be documented, or that isalpha is wrong? These are independent -

[issue7830] Flatten nested functools.partial

2010-11-30 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: Alexander, I don't see anything wrong with patch, nor anything compelling about it either. It's your choice whether or not to apply. -- ___ Python tracker rep...@bugs.python.org

[issue10590] Parameter type error for xml.sax.parseString(string, ...)

2010-11-30 Thread Thomas Ryan
New submission from Thomas Ryan tom.a.r...@gmail.com: In 3.1.3, 3.1.2, maybe earlier... xml.sax.parseString(string, handler, error_handler=handler.ErrorHandler()) Source code requires bytes, not a string as implied by function name and by the documentation. Exception thrown for strings.

[issue7830] Flatten nested functools.partial

2010-11-30 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: The original motivation for the patch was that if partial() objects are guaranteed to be flat, it would simplify code that deals with them. See issue4331 for one example. With a conservative patch, however, it will

[issue8084] pep-0370 on osx duplicates existing functionality

2010-11-30 Thread Glyph Lefkowitz
Glyph Lefkowitz gl...@twistedmatrix.com added the comment: Would it be possible to have this reverted for 2.7.2 / 3.2.1, and restore ~/.local _and_ ~/Library as equally valid locations for python code? As I tried to explain on the mailing list, this change basically introduces a regression,

[issue8685] set(range(100000)).difference(set()) is slow

2010-11-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Raymond, unless you object, I'd like to commit this before beta1. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8685 ___

[issue8685] set(range(100000)).difference(set()) is slow

2010-11-30 Thread Philip Jenvey
Changes by Philip Jenvey pjen...@underboss.org: -- nosy: +pjenvey ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8685 ___ ___ Python-bugs-list

[issue8685] set(range(100000)).difference(set()) is slow

2010-11-30 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: Thx. -- assignee: rhettinger - pitrou resolution: - accepted ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8685 ___

[issue10262] Add --soabi option to `configure`

2010-11-30 Thread Barry A. Warsaw
Barry A. Warsaw ba...@python.org added the comment: Of course, you don't change configure directly, you change configure.in and let autoconf update the configure (but you already know that I'm sure :). The patch looks fairly reasonable, though I haven't tried it. One question: does $SO have

[issue10262] Add --soabi option to `configure`

2010-11-30 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The value of get_config_var(SO) is the same as before, something like .cpython-32.so by default on Linux. (see, I just moved the line SO=.$SOABI$SO at the bottom of the patch). In the C file dynload_shlib.c, I chose the names SO_BASE

[issue10589] I/O ABC docs should specify which methods have implementations

2010-11-30 Thread Daniel Stutzbach
Daniel Stutzbach stutzb...@google.com added the comment: +io and doc people Attached is a simple patch to add a table to the documentation summarizing the I/O ABCs. -- keywords: +patch nosy: +benjamin.peterson, ezio.melotti, georg.brandl Added file:

[issue9915] speeding up sorting with a key

2010-11-30 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: +1 on the basic idea of moving elements in the keys and values arrays at the same time thereby eliminating the fragmented memory overhead of the sortwrapper indirection. I would like the patch to be restricted to just that

[issue10589] I/O ABC docs should specify which methods have implementations

2010-11-30 Thread Fred L. Drake, Jr.
Changes by Fred L. Drake, Jr. fdr...@acm.org: -- nosy: +d...@python, fdrake ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10589 ___ ___

[issue8685] set(range(100000)).difference(set()) is slow

2010-11-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Modified patch committed in r86905. Thanks! -- resolution: accepted - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org

[issue10589] I/O ABC docs should specify which methods have implementations

2010-11-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: What does unsupported mean? Abstract would look more exact. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10589 ___

[issue10589] I/O ABC docs should specify which methods have implementations

2010-11-30 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Not sure what unsupported methods means. E.g. readinto is listed as provided by RawIOBase in the doc text. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10589

[issue10591] test_os failure in refleak runs

2010-11-30 Thread Antoine Pitrou
New submission from Antoine Pitrou pit...@free.fr: $ ./python -m test.regrtest -R 3:2 test_os [1/1] test_os [35351 refs] [35351 refs] [35352 refs] beginning 5 repetitions 12345 [35351 refs] [35351 refs] [35352 refs] test test_os failed -- Traceback (most recent call last): File

[issue10262] Add --soabi option to `configure`

2010-11-30 Thread Barry A. Warsaw
Barry A. Warsaw ba...@python.org added the comment: On Nov 30, 2010, at 10:12 PM, Amaury Forgeot d'Arc wrote: The value of get_config_var(SO) is the same as before, something like .cpython-32.so by default on Linux. (see, I just moved the line SO=.$SOABI$SO at the bottom of the patch). Cool,

[issue10262] Add --soabi option to `configure`

2010-11-30 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Let's test Linux at least, then. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10262 ___

[issue10589] I/O ABC docs should specify which methods have implementations

2010-11-30 Thread Daniel Stutzbach
Daniel Stutzbach stutzb...@google.com added the comment: What does unsupported mean? Abstract would look more exact. It means they raise io.UnsupportedOperation when called (unless the subclass overrides them to do something else). They are not marked with @abstractmethod, so Abstract

[issue10589] I/O ABC docs should specify which methods have implementations

2010-11-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: What does unsupported mean? Abstract would look more exact. It means they raise io.UnsupportedOperation when called (unless the subclass overrides them to do something else). They are not marked with @abstractmethod, so Abstract would

[issue10464] netrc module not parsing passwords containing #s.

2010-11-30 Thread Ned Deily
Ned Deily n...@acm.org added the comment: Patch looks good to me. Supplied test fails before and works after fix applied. -- nosy: +ned.deily stage: patch review - commit review ___ Python tracker rep...@bugs.python.org

[issue10464] netrc module not parsing passwords containing #s.

2010-11-30 Thread Ned Deily
Changes by Ned Deily n...@acm.org: Removed file: http://bugs.python.org/file19666/issue_10231_testcase.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10464 ___

[issue10589] I/O ABC docs should specify which methods have implementations

2010-11-30 Thread Daniel Stutzbach
Daniel Stutzbach stutzb...@google.com added the comment: Other suggestions for a better name for that column are certainly welcome. :-) Stub Methods? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10589

[issue10589] I/O ABC docs should specify which methods have implementations

2010-11-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Other suggestions for a better name for that column are certainly welcome. :-) Stub Methods? Fine with me. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10589

[issue10478] Ctrl-C locks up the interpreter

2010-11-30 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- nosy: +stutzbach ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10478 ___ ___ Python-bugs-list mailing

[issue1649329] Extract file-finding and language-handling code from gettext.find

2010-11-30 Thread Shannon -jj Behrens
Shannon -jj Behrens jji...@users.sourceforge.net added the comment: Sorry, I just had a baby on Saturday. Hence, I'm a bit late getting to this. It might take me a couple weeks. -- ___ Python tracker rep...@bugs.python.org

[issue8425] a -= b should be fast if a is a small set and b is a large set

2010-11-30 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: Deferring to 3.3. -- priority: normal - low versions: +Python 3.3 -Python 2.7, Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8425

[issue6422] timeit called from within Python should allow autoranging

2010-11-30 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: This does not conflict with the other proposed changes to timeit and it is in-line with Guido's desire that to expose useful parts currently buried in the command-line logic. Amaury, you've shown an interest. Would you

[issue6594] json C serializer performance tied to structure depth on some systems

2010-11-30 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: Antoine, what do you want to do with the one? Without a good test case the OP's original issue is undiagnosable. -- assignee: rhettinger - pitrou versions: +Python 3.1 ___ Python

[issue8425] a -= b should be fast if a is a small set and b is a large set

2010-11-30 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: Any new logic should make maximum use of existing tools: def __isub__(self, other) if len(other) len(self)*8: other = self other . . . # rest of isub unchanged -- stage: patch review - needs

[issue6594] json C serializer performance tied to structure depth on some systems

2010-11-30 Thread Shawn
Shawn swal...@opensolaris.org added the comment: I specifically mentioned *SPARC* as the performance problem area, but the reply about 0.5s to dump fails to mention on what platform they tested My problem is not undiagnosable. I'll be happy to provide you with even more data files. But I

[issue8743] set() operators don't work with collections.Set instances

2010-11-30 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: Daniel, do you have time to work on this one? If so, go ahead an make setobject.c accept any instance of collections.Set and make the corresponding change to the ABCs: def __or__(self, other): if not

[issue10591] test_os failure in refleak runs

2010-11-30 Thread Brian Curtin
Brian Curtin cur...@acm.org added the comment: Fixed in r86906. Split the shared setUp/tearDown into individual methods for each part. -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker

[issue8743] set() operators don't work with collections.Set instances

2010-11-30 Thread Daniel Stutzbach
Daniel Stutzbach stutzb...@google.com added the comment: Yes, I can take a stab at it. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8743 ___

[issue8743] set() operators don't work with collections.Set instances

2010-11-30 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: No need to rush this for the beta. It's a bug fix and can go in at any time. The important thing is that we don't break the C code. The __ror__ magic method would still need to do the right thing and the C code needs to

[issue10592] pprint module doesn't work well with OrderedDicts

2010-11-30 Thread Elias Zamaria
New submission from Elias Zamaria mikez...@gmail.com: If I try to pretty-print an ordered dictionary, it doesn't show nicely. Instead of having each key-value pair on its own line, the whole thing shows up on one long line, which wraps many times and is hard to read. I can provide an example

[issue1649329] Extract file-finding and language-handling code from gettext.find

2010-11-30 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Congratulations. Take the time you’ll need, if this doesn’t go into 3.2 it’ll just be in 3.3. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1649329

[issue10592] pprint module doesn't work well with OrderedDicts

2010-11-30 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: I’m afraid there is no way, but a robust solution will be designed. See #7434. -- nosy: +eric.araujo resolution: - duplicate stage: - committed/rejected status: open - closed superseder: - general pprint rewrite

[issue10535] Enable warnings by default in unittest

2010-11-30 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: Committed in r86908. I'll leave this open because there still a few things (proposed in the previous message) that can be changed/improved. -- ___ Python tracker rep...@bugs.python.org

[issue10593] LRU Cache with maxsize=None

2010-11-30 Thread Raymond Hettinger
New submission from Raymond Hettinger rhettin...@users.sourceforge.net: Nick, I may have found a straight-forward way to incorporate your idea for the cache to support maxsize=None. Let me know what you think. -- assignee: ncoghlan components: Library (Lib) files: cache.diff keywords:

[issue10593] LRU Cache with maxsize=None

2010-11-30 Thread Raymond Hettinger
Changes by Raymond Hettinger rhettin...@users.sourceforge.net: Added file: http://bugs.python.org/file19887/cache2.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10593 ___

[issue10593] LRU Cache with maxsize=None

2010-11-30 Thread Raymond Hettinger
Changes by Raymond Hettinger rhettin...@users.sourceforge.net: Removed file: http://bugs.python.org/file19886/cache.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10593 ___

[issue7434] general pprint rewrite

2010-11-30 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: Attaching a rough concept of how to make the existing pprint module extendible without doing a total rewrite. The actual handler is currently bogus (no thought out), so focus on the @guard decorator and the technique for

[issue10593] LRU Cache with maxsize=None

2010-11-30 Thread Nick Coghlan
Nick Coghlan ncogh...@gmail.com added the comment: Nice! You may still need to use the lock even for the simple unbounded case though - incrementing hits and misses isn't atomic, so the statistics may be miscounted if you get a hit or miss in different threads at the same time.

[issue3243] Support iterable bodies in httplib

2010-11-30 Thread Xuanji Li
Xuanji Li xua...@gmail.com added the comment: So, reading all your comments, I gather that my proposed patch for client.py which is try: self.sock.sendall(data) except TypeError: if isinstance(data, collections.Iterable): for d in t: self.sock.sendall(d)

[issue10273] Clean-up Unittest API

2010-11-30 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: s/regexp/regex/ done in r86910. -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10273

[issue6594] json C serializer performance tied to structure depth on some systems

2010-11-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Raymond, I'll follow up in private with Shawn. All the recent performance improvements done on JSON (in 3.2) mean the issue can be closed IMO. -- resolution: - out of date status: open - closed ___

[issue3243] Support iterable bodies in httplib

2010-11-30 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: just to confirm: we WANT array.array(I, [1,2,3]) to have a content- length of 12, right? Yes, since it will emit 12 bytes in the body (you could actually have a test for it). -- ___ Python tracker

[issue10594] Typo in PyList_New doc.

2010-11-30 Thread INADA Naoki
New submission from INADA Naoki songofaca...@gmail.com: http://docs.python.org/c-api/list.html#PyList_New Note: If length is greater than zero, ... s/length/len/ -- assignee: d...@python components: Documentation messages: 122974 nosy: d...@python, naoki priority: normal severity:

[issue10594] Typo in PyList_New doc.

2010-11-30 Thread INADA Naoki
INADA Naoki songofaca...@gmail.com added the comment: http://docs.python.org/c-api/list.html#PyList_GetItem Return the object at position pos in the list pointed to by p s/p/list/ -- ___ Python tracker rep...@bugs.python.org

[issue10594] Typo in PyList_New doc.

2010-11-30 Thread INADA Naoki
INADA Naoki songofaca...@gmail.com added the comment: http://docs.python.org/c-api/list.html#PyList_GetItem Return the object at position pos in the list pointed to by p s/pos/index/ -- ___ Python tracker rep...@bugs.python.org

[issue10594] Typo in PyList_New doc.

2010-11-30 Thread Ezio Melotti
Changes by Ezio Melotti ezio.melo...@gmail.com: -- nosy: +ezio.melotti ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10594 ___ ___

[issue10593] LRU Cache with maxsize=None

2010-11-30 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: Applied in r86911. -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10593 ___

[issue10594] Typo in PyList_New doc.

2010-11-30 Thread Eli Bendersky
Eli Bendersky eli...@gmail.com added the comment: Thanks for the report, Attaching a patch for Doc/c-api/list.rst in Python 3.2 If this is OK, I can backport the patch to other versions as well. -- keywords: +patch nosy: +eli.bendersky Added file:

[issue5088] optparse: inconsistent default value for append actions

2010-11-30 Thread Eli Bendersky
Eli Bendersky eli...@gmail.com added the comment: I fuzzily recall there was somewhere a decision to use the American spelling of some words, like s/behaviour/behavior/ appearing in this patch. Is this right, or was it decided that it doesn't matter? -- nosy: +eli.bendersky status:

[issue5088] optparse: inconsistent default value for append actions

2010-11-30 Thread Eli Bendersky
Eli Bendersky eli...@gmail.com added the comment: Éric, also re your previous message, I personally would prefer seeing contrary to what one can think removed altogether. IMHO it's too chatty for an official document and doesn't really add new information over the sentence it follows.

[issue10594] Typo in PyList_New doc.

2010-11-30 Thread INADA Naoki
INADA Naoki songofaca...@gmail.com added the comment: OK, please. On Wed, Dec 1, 2010 at 12:46 PM, Eli Bendersky rep...@bugs.python.org wrote: Eli Bendersky eli...@gmail.com added the comment: Thanks for the report, Attaching a patch for Doc/c-api/list.rst in Python 3.2 If this is OK, I

[issue10592] pprint module doesn't work well with OrderedDicts

2010-11-30 Thread Elias Zamaria
Elias Zamaria mikez...@gmail.com added the comment: I forgot to mention, someone came up with this suggestion (http://stackoverflow.com/questions/4301069/any-way-to-properly-pretty-print-ordered-dictionaries-in-python/4303996#4303996). It is not the best, but the output is better than how it

  1   2   >