[issue10220] Make generator state easier to introspect

2010-11-20 Thread Rodolpho Eckhardt
Rodolpho Eckhardt added the comment: This patch adds the getgeneratorstate function and related tests. -- keywords: +patch nosy: +Rodolpho.Eckhardt Added file: http://bugs.python.org/file19705/getgeneratorstate.patch ___ Python tracker

[issue3709] BaseHTTPRequestHandler innefficient when sending HTTP header

2010-11-20 Thread endian
endian added the comment: Ready for review. Added test_header_buffering which fails without the BaseHTTPRequestHandler patch and passes with it. -- Added file: http://bugs.python.org/file19704/issue3709.diff ___ Python tracker

[issue3709] BaseHTTPRequestHandler innefficient when sending HTTP header

2010-11-20 Thread endian
Changes by endian : Removed file: http://bugs.python.org/file19689/issue3709.diff ___ Python tracker ___ ___ Python-bugs-list mailing list Unsu

[issue3709] BaseHTTPRequestHandler innefficient when sending HTTP header

2010-11-20 Thread endian
Changes by endian : Removed file: http://bugs.python.org/file19692/issue3709.diff ___ Python tracker ___ ___ Python-bugs-list mailing list Unsu

[issue9305] Don't use east/west of UTC in date/time documentation

2010-11-20 Thread Henrique Bastos
Henrique Bastos added the comment: To clarify: 1) "we" means henriquebastos, rbp, Rodolpho.Eckhardt. 2) Mentioning fdrake I was trying to say that we followed his suggestion to only submit the specific changes on this patch, leaving further documentation changes to another issue. Sorry abou

[issue10471] include documentation in python docs and under python -h for other commandline options

2010-11-20 Thread Georg Brandl
Georg Brandl added the comment: -tt is documented on the page you link to. -b and -bb are only available in Python 3, and are documented there: . -b and -bb also show up in python -h. In the contrary, -t and -tt have been removed in Python 3 (-tt

[issue10469] test_socket fails

2010-11-20 Thread Daniel Albeseder
Daniel Albeseder added the comment: c:\Program Files\Microsoft Visual Studio 10.0\VC\include\errno.h The content of my errno.h: ... #define EILSEQ 42 #define STRUNCATE 80 #endif #endif /* Support EDEADLOCK for compatibility with older MS-C versions */ #define EDEADLOCK ED

[issue9500] urllib2: Content-Encoding

2010-11-20 Thread R. David Murray
R. David Murray added the comment: Issue 1508475 has a patch, though it still needs updated. -- resolution: -> duplicate stage: unit test needed -> committed/rejected status: open -> closed superseder: -> transparent gzip compression in liburl2 ___

[issue7804] test_readline failure

2010-11-20 Thread Antoine Pitrou
Antoine Pitrou added the comment: I can't reproduce anymore (Debian 5.0.6). Barry? -- status: open -> pending ___ Python tracker ___ _

[issue9721] urlparse.urljoin() cuts off last base character with semicolon at url start

2010-11-20 Thread Wes Chow
Wes Chow added the comment: New patch (urlparse-9721-3.2.patch) against 3.2 which fixes the erroneous test. -- Added file: http://bugs.python.org/file19706/urlparse-9721-3.2.patch ___ Python tracker ___

[issue10407] missing errno import in distutils/dir_util.py

2010-11-20 Thread Éric Araujo
Éric Araujo added the comment: Fixed in r86601 and r86605 (py3k), r86606 (3.1), r86609 (2.7). Thanks! -- resolution: -> fixed stage: -> committed/rejected status: pending -> closed ___ Python tracker __

[issue9721] urlparse.urljoin() cuts off last base character with semicolon at url start

2010-11-20 Thread Wes Chow
Wes Chow added the comment: Patch against 2.7 (urlparse-9721-2.7.patch). -- Added file: http://bugs.python.org/file19707/urlparse-9721-2.7.patch ___ Python tracker ___ __

[issue1508475] transparent gzip compression in urllib

2010-11-20 Thread Éric Araujo
Changes by Éric Araujo : -- components: -Extension Modules nosy: +eric.araujo -BreamoreBoy title: transparent gzip compression in liburl2 -> transparent gzip compression in urllib ___ Python tracker ___

[issue10453] Add -h/--help option to compileall

2010-11-20 Thread Michele Orrù
Changes by Michele Orrù : Added file: http://bugs.python.org/file19708/issue10453_final.patch ___ Python tracker ___ ___ Python-bugs-list mail

[issue3709] BaseHTTPRequestHandler innefficient when sending HTTP header

2010-11-20 Thread Bruno Gola
Bruno Gola added the comment: applied the patch on py3k on trunk and everything seems fine (works here) -- nosy: +brunogola ___ Python tracker ___ ___

[issue7094] Add alternate float formatting styles to new-style formatting.

2010-11-20 Thread Eric Smith
Eric Smith added the comment: Also note that if # is added for float and Decimal, it should be added for complex. My Bug Day sprint group will have a patch for this shortly. -- ___ Python tracker _

[issue10470] python -m unittest ought to default to discovery

2010-11-20 Thread Éric Araujo
Éric Araujo added the comment: The existing discover subcommand would enter the deprecation process, right? -- nosy: +eric.araujo ___ Python tracker ___

[issue10469] test_socket fails

2010-11-20 Thread Martin v . Löwis
Martin v. Löwis added the comment: Oops, I was confused. My copy is VS 2008, of course. So that's another incompatible change in VS 2010. Tcl, Ruby, and curl are ahead of us, here: http://redmine.ruby-lang.org/issues/show/3092 http://sourceforge.net/tracker/index.php?func=detail&aid=3019634&gr

[issue10470] python -m unittest ought to default to discovery

2010-11-20 Thread Éric Araujo
Changes by Éric Araujo : -- keywords: +easy stage: -> needs patch ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscrib

[issue10453] Add -h/--help option to compileall

2010-11-20 Thread Bruno Gola
Bruno Gola added the comment: applied the patch on an ubuntu 10.04 64bits, py3k (trunk) test_force fails as following: == FAIL: test_force (__main__.CommandLineTests) ---

[issue7325] tempfile.mkdtemp() does not return absolute pathname when relative dir is specified

2010-11-20 Thread Éric Araujo
Éric Araujo added the comment: Looks good to me, with one exception: if temp_dir_abspath.startswith('./'): Wouldn’t this be better: if not _os.path.isabs(temp_dir_abspath) (P.S. file is not a builtin anymore in 3.x, it’s used for example as an argument to the print function.) --

[issue9305] Don't use east/west of UTC in date/time documentation

2010-11-20 Thread Rodrigo Bernardo Pimentel
Rodrigo Bernardo Pimentel added the comment: 1. Done (it's on the patch I'm uploading). Sorry. 3. Ok, we've rewritten that sentence. As Henrique mentioned, we're working on a larger patch to make datetime documentation clearer, and we can include a definition of "standard time" there. 2. I

[issue10472] Strange tab key behaviour in interactive python 2.7 OSX 10.6.2

2010-11-20 Thread Daniel Harper
New submission from Daniel Harper : Hi there. I recently downloaded the python 2.7 installer from the python website and installed it on my Mac. When I run python2.7 in interactive mode, the tab key doesn't seem to behave as how it did in 2.6. For example >> def helloWorld(name):

[issue10469] test_socket fails

2010-11-20 Thread Daniel Albeseder
Daniel Albeseder added the comment: Only in the "system_error" file. (http://msdn.microsoft.com/en-us/library/ee372194.aspx) Seem to be a C++0X standard header file. http://msdn.microsoft.com/en-us/library/5814770t.aspx talks about the Posix codes only for compatibility reasons. --

[issue6007] distutils tricks you into thinking you can build extensions with mingw

2010-11-20 Thread Chris Lambacher
Chris Lambacher added the comment: I just compiled the zope.interface c speedups with MinGW on Python 2.7 and 2.6. There is a patch being tracked in the MinGW patch tracker related to the localtime l

[issue10473] Strange behavior for socket.timeout

2010-11-20 Thread Roy Smith
New submission from Roy Smith : While investigating issue7322, I wrote a test case to demonstrate the issue. I made a mistake and called settimeout() on the wrong socket, but the result appears to demonstrate a different bug. When I run the attached test-issue7322.py on my OSX-10.6.5 machine

[issue10469] test_socket fails

2010-11-20 Thread Martin v . Löwis
Martin v. Löwis added the comment: > Only in the "system_error" file. > (http://msdn.microsoft.com/en-us/library/ee372194.aspx) > Seem to be a C++0X standard header file. (I assume you have actually scanned the crt\src folder as well) Then it's indeed safe to ignore. > http://msdn.microsoft

[issue10220] Make generator state easier to introspect

2010-11-20 Thread Éric Araujo
Éric Araujo added the comment: Looks good, modulo two nitpicks: 1) Using literals for constants would avoid a lookup and call of range. 2) Please remove four leading spaces in your docstring. -- nosy: +eric.araujo ___ Python tracker

[issue10453] Add -h/--help option to compileall

2010-11-20 Thread Michele Orrù
Michele Orrù added the comment: Yes, I was discussing about that on IRC. That's a matter of platform -on mine for example works-. He gave me a hand in solving this failure; now -I think- he's gonna apply that. -- ___ Python tracker

[issue9909] request for calendar.dayofyear() function

2010-11-20 Thread Abhay Saxena
Abhay Saxena added the comment: The test is incorrect on leap years for February 29, due to the way it constructs its list of dates. The function itself appears to give the right answer. -- nosy: +ark3 ___ Python tracker

[issue10453] Add -h/--help option to compileall

2010-11-20 Thread Michele Orrù
Michele Orrù added the comment: *discussing that on IRC with R. David Murray -- ___ Python tracker ___ ___ Python-bugs-list mailing l

[issue1520831] urrlib2 max_redirections=0 disables redirects

2010-11-20 Thread John J Lee
John J Lee added the comment: Oops, I hadn't noticed that max_redirections isn't part of the API. In that case, I agree that it's not strictly a bug. I'd also agree it's not very important. FWIW: "want[ing] to see all redirects" is not the same thing as printing URLs -- I assume he simply

[issue10453] Add -h/--help option to compileall

2010-11-20 Thread R. David Murray
Changes by R. David Murray : -- assignee: eric.araujo -> r.david.murray stage: needs patch -> commit review ___ Python tracker ___ ___

[issue9909] request for calendar.dayofyear() function

2010-11-20 Thread Abhay Saxena
Abhay Saxena added the comment: Quick hack alternative test. It would look nicer if the test used the datetime module, but I'm not sure that would be appropriate. def test_dayofyear(self):

[issue7322] Socket timeout can cause file-like readline() method to lose data

2010-11-20 Thread Roy Smith
Roy Smith added the comment: I'm looking into this now. In the meantime, I've opened a marginally-related bug, issue10473 -- nosy: +roysmith ___ Python tracker ___

[issue10399] AST Optimization: inlining of function calls

2010-11-20 Thread Dave Malcolm
Dave Malcolm added the comment: Thanks for reading through this. > There are a couple places you mention not doing the optimization when > specific functions are used (e.g. dir, globals, locals), how exactly do you > verify that, given those functions could be bound to any name? I don't: I'm o

[issue10220] Make generator state easier to introspect

2010-11-20 Thread Rodrigo Bernardo Pimentel
Changes by Rodrigo Bernardo Pimentel : -- nosy: +rbp ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue7322] Socket timeout can cause file-like readline() method to lose data

2010-11-20 Thread Roy Smith
Roy Smith added the comment: Ataching a test case which demonstrates the bug. -- Added file: http://bugs.python.org/file19711/test-issue7322.py ___ Python tracker ___ ___

[issue10220] Make generator state easier to introspect

2010-11-20 Thread Rodolpho Eckhardt
Rodolpho Eckhardt added the comment: Done, thank you! Second version attached. -- Added file: http://bugs.python.org/file19712/getgeneratorstate_v2.patch ___ Python tracker ___

[issue10220] Make generator state easier to introspect

2010-11-20 Thread Éric Araujo
Éric Araujo added the comment: Nice. Now you can sit back, relax and wait for Nick to commit the patch or make further comments. -- stage: needs patch -> patch review ___ Python tracker _

[issue10453] Add -h/--help option to compileall

2010-11-20 Thread R. David Murray
R. David Murray added the comment: Patch committed with minor formatting changes and one fixed test (test_force) in r86611. Thanks, Michele! -- resolution: -> accepted stage: commit review -> committed/rejected status: open -> closed ___ Python tr

[issue4246] execution model - clear and complete example in documentation

2010-11-20 Thread Cherniavsky Beni
Cherniavsky Beni added the comment: The FAQ for this was much improved in 2009 (issue 7290): http://docs.python.org/py3k/faq/programming.html#why-am-i-getting-an-unboundlocalerror-when-the-variable-has-a-value To support the claim that this keeps biting people, at least the following bug repo

[issue4246] execution model - clear and complete example in documentation

2010-11-20 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +d...@python -georg.brandl ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: htt

[issue10469] test_socket fails

2010-11-20 Thread Daniel Albeseder
Daniel Albeseder added the comment: Ok I did switched the preference for all "new" defines inside VC++ errno.h to use the WSA* alternatives if available. Now test_socket passes for me, and the test_asyncore which did block before, now passes without a problem. -- Added file: http://b

[issue809163] Can't add files with spaces

2010-11-20 Thread John Keyes
John Keyes added the comment: I see that distutils.tests.support.TempdirManager uses tempfile for directory creation. What's the best course of action here? 1. Use TESTFN or 2. Use TempdirManager or 3. Change the test to use TempdirManager and change TempdirManager to use TESTFN instead of

[issue10399] AST Optimization: inlining of function calls

2010-11-20 Thread Neal Norwitz
Neal Norwitz added the comment: There is some precedent for allowing minor differences in -O mode. http://mail.python.org/pipermail/python-dev/2008-February/077193.html I think we should push this to see how practical we can make it. Dave, this is great work, I'm really interested to see you co

[issue10472] Strange tab key behaviour in interactive python 2.7 OSX 10.6.2

2010-11-20 Thread Ned Deily
Ned Deily added the comment: The problem you see is with the 2.7 64-/32-bit OS X installer and is documented and will be fixed with the patch in Issue9907. In the meantime, a workaround is to delete the installed 2.7 framework and install the 32-bit-only version which is built with GNU readl

[issue9746] All sequence types support .index and .count

2010-11-20 Thread Iuri Diniz
Iuri Diniz added the comment: Is this bug valid? I have checked that only bytearray, bytes, list, range, str and tuple are valid sequence types [using issubclass(type, collections.Sequence)] and all of them has index and count methods... I'm working on a script to discovery what types that

[issue6007] distutils tricks you into thinking you can build extensions with mingw

2010-11-20 Thread Chris Lambacher
Chris Lambacher added the comment: I'm attaching a patch that includes a disclaimer about some extensions not being able to compile and mentioning some of Martin's specifics. I also reorganized the instructions to more directly reflect the current state. This puts the common instructions fron

[issue809163] Can't add files with spaces

2010-11-20 Thread Éric Araujo
Éric Araujo added the comment: TempdirManager hasn’t caused buildbots failures so far, so there is no need to change it. You can use it, it’s convenient and works :) -- ___ Python tracker __

[issue7804] test_readline failure

2010-11-20 Thread Barry A. Warsaw
Barry A. Warsaw added the comment: I can't reproduce it either any more on Ubuntu 10.10 in either 2.6 or py3k. -- resolution: -> out of date status: pending -> closed ___ Python tracker ___

[issue6007] distutils tricks you into thinking you can build extensions with mingw

2010-11-20 Thread Éric Araujo
Éric Araujo added the comment: distutils docs only get changes that fix a bug (e.g. an example that does not work), not improvements or reorganization. Your patch is in a gray area; I think we should not accept it in distutils but re-target it at distutils2. Even if you refresh it against d

[issue10367] "python setup.py sdist upload --show-response" can fail with "UnboundLocalError: local variable 'result' referenced before assignment"

2010-11-20 Thread Phillip J. Eby
Phillip J. Eby added the comment: It looks to me as though this patch reintroduces issue9199, as it passes multiple arguments to self.announce() once again. The patch needs to be made against the SVN version of Python, not the released version. -- ___

[issue10448] Add Mako template benchmark to Python Benchmark Suite

2010-11-20 Thread Antoine Pitrou
Antoine Pitrou added the comment: Pushed in 40e80cede832, thank you. (2to3'ed Mako appears 3x slower than on 2x, but it's not obvious whether it's Python 3 itself or the constructs added by 2to3; I think running 2to3ed benchmarks is a bit pointless in itself, because it's not idiomatic code)

[issue9746] All sequence types support .index and .count

2010-11-20 Thread SilentGhost
SilentGhost added the comment: Here is the patch for the table in Doc/library/stdtypes.rst .count on range by some reason returns a boolean. Should it not be an int? -- keywords: +patch nosy: +SilentGhost Added file: http://bugs.python.org/file19715/stdtypes.rst.diff _

[issue9746] All sequence types support .index and .count

2010-11-20 Thread Éric Araujo
Éric Araujo added the comment: Doc patch looks good. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://

[issue4493] urllib2 doesn't always supply / where URI path component is empty

2010-11-20 Thread Wes Chow
Wes Chow added the comment: Attached is a patch against 3.2 that replaces empty paths with '/' in HTTPConnection. I do not totally understand the ; syntax in URIs, and so this implementation may break that, as it splits urls and unsplits them if needed. The Python docs seem to indicate there

[issue10469] test_socket fails using Visual Studio 2010

2010-11-20 Thread Daniel Albeseder
Changes by Daniel Albeseder : -- title: test_socket fails -> test_socket fails using Visual Studio 2010 ___ Python tracker ___ ___ Pyt

[issue1043134] mimetypes.guess_extension('text/plain') == '.ksh' ???

2010-11-20 Thread Chris Lambacher
Chris Lambacher added the comment: While I agree that getting .ksh is an unfortunate guess, I am not sure how you can guess in the face of many options (especially when the those options are parsed out of a mimetypes file or the windows registry). Perhaps there should be a "resonable_default

[issue10474] range.count returns boolean

2010-11-20 Thread SilentGhost
New submission from SilentGhost : >>> a = range(5) >>> a.count(5) False >>> a.count(2) True I believe this is related to the issue9213 that introduced count and index method on the range object. According to the documentation accompanying that fix it should return an integer. -- compo

[issue10441] some stdlib modules need to be updated to handle SSL certificate validation

2010-11-20 Thread Antoine Pitrou
Antoine Pitrou added the comment: Martin, > You misunderstood. I was not proposing that scripts provide a CA > list, but that users might deploy a CA list into their Python > installation, which is then picked up in the same way as you are asking > for on Ubuntu. Could you elaborate on what ki

[issue1043134] mimetypes.guess_extension('text/plain') == '.ksh' ???

2010-11-20 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.py

[issue9746] All sequence types support .index and .count

2010-11-20 Thread Iuri Diniz
Iuri Diniz added the comment: Well, I think that script not more necessary count problem: Issue10474 -- ___ Python tracker ___ ___ Py

[issue10474] range.count returns boolean

2010-11-20 Thread Daniel Urban
Changes by Daniel Urban : -- nosy: +durban ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.o

[issue10474] range.count returns boolean

2010-11-20 Thread Benjamin Peterson
Benjamin Peterson added the comment: r86618 -- nosy: +benjamin.peterson resolution: -> fixed ___ Python tracker ___ ___ Python-bugs-

[issue10474] range.count returns boolean

2010-11-20 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:/

[issue10474] range.count returns boolean

2010-11-20 Thread SilentGhost
SilentGhost added the comment: Benjamin, the docs say that it's possible to have count more than 1, depending on comparison rules. If that's the case, I'm afraid your solution might need to be adjusted. -- ___ Python tracker

[issue10043] UnboundLocalError with local variable set by setattr, caused by code run later

2010-11-20 Thread Cherniavsky Beni
Cherniavsky Beni added the comment: Hi Steven. Please confirm if we can mark the bug closed; if you need farther advice, posting your full code (not just the error case) on comp.lang.python or StackOverflow would be more effective. The documentation is indeed correct but hard to find (you're

[issue6007] distutils tricks you into thinking you can build extensions with mingw

2010-11-20 Thread Martin v . Löwis
Martin v. Löwis added the comment: The changes look fine to me. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscrib

[issue10474] range.count returns boolean

2010-11-20 Thread Benjamin Peterson
Benjamin Peterson added the comment: 2010/11/20 SilentGhost : > > SilentGhost added the comment: > > Benjamin, the docs say that it's possible to have count more than 1, > depending on comparison rules. If that's the case, I'm afraid your solution > might need to be adjusted. Produce a case

[issue10474] range.count returns boolean

2010-11-20 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: SilentGhost, Benjamin's fix only affect the optimized path when the argument is int or bool. Exotic comparison rules are handled in the else clause. -- nosy: +belopolsky ___ Python tracker

[issue10453] Add -h/--help option to compileall

2010-11-20 Thread Éric Araujo
Éric Araujo added the comment: Invocation without arguments does not work. I have a fix, I’ll add a test and commit. -- ___ Python tracker ___

[issue10292] tarinfo should use relative symlinks

2010-11-20 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue10453] Add -h/--help option to compileall

2010-11-20 Thread Michele Orrù
Michele Orrù added the comment: Sorry. -- Added file: http://bugs.python.org/file19717/issue10453_noargs.patch ___ Python tracker ___ ___

[issue6011] python doesn't build if prefix contains non-ascii characters

2010-11-20 Thread Éric Araujo
Éric Araujo added the comment: Regarding your fix to copy_script, I will have to ask python-dev about PEP 291 in py3k (i.e., should 3.2 code really be compatible with 2.3?). -- ___ Python tracker _

[issue809163] Can't add files with spaces

2010-11-20 Thread John Keyes
John Keyes added the comment: This patch uses TempdirManager to handle the temporary directory and file creation. -- Added file: http://bugs.python.org/file19718/issue809163v2.diff ___ Python tracker ___

[issue6007] distutils tricks you into thinking you can build extensions with mingw

2010-11-20 Thread Chris Lambacher
Chris Lambacher added the comment: Eric, This documentation is "Installing Python Modules" which is focused on Distutils, but presumably we would continue to want such a document and account for both Disutils and Disutils2 (once people start using it). I think my patch addresses the mislead

[issue8646] PyUnicode_EncodeDecimal is undocumented

2010-11-20 Thread Alexander Belopolsky
Changes by Alexander Belopolsky : -- resolution: -> duplicate status: open -> closed superseder: -> Document unicode C-API in reST ___ Python tracker ___ ___

[issue8645] PyUnicode_AsEncodedObject is undocumented

2010-11-20 Thread Alexander Belopolsky
Changes by Alexander Belopolsky : -- resolution: -> duplicate status: open -> closed superseder: -> Document unicode C-API in reST ___ Python tracker ___ ___

[issue8647] PyUnicode_GetMax is undocumented

2010-11-20 Thread Alexander Belopolsky
Changes by Alexander Belopolsky : -- resolution: -> duplicate superseder: -> Document unicode C-API in reST ___ Python tracker ___ __

[issue10043] UnboundLocalError with local variable set by setattr, caused by code run later

2010-11-20 Thread Eric Smith
Eric Smith added the comment: Closing, as I don't think there's any action item here. -- resolution: -> invalid stage: needs patch -> committed/rejected status: open -> closed ___ Python tracker _

[issue9746] All sequence types support .index and .count

2010-11-20 Thread Raymond Hettinger
Raymond Hettinger added the comment: Patch is fine. Go ahead and apply. -- nosy: +rhettinger resolution: -> accepted ___ Python tracker ___

[issue8647] PyUnicode_GetMax is undocumented

2010-11-20 Thread Éric Araujo
Changes by Éric Araujo : -- stage: needs patch -> committed/rejected status: open -> closed ___ Python tracker ___ ___ Python-bugs-list

[issue3709] BaseHTTPRequestHandler innefficient when sending HTTP header

2010-11-20 Thread R. David Murray
R. David Murray added the comment: Thanks for the patch and test. They look good. A doc update is also needed, since the docs are currently written in such a way that buffering the header lines makes the documentation no longer true. Also, send_response_only writes directly to the output str

[issue3709] BaseHTTPRequestHandler innefficient when sending HTTP header

2010-11-20 Thread R. David Murray
Changes by R. David Murray : -- stage: -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://m

[issue809163] Can't add files with spaces

2010-11-20 Thread R. David Murray
R. David Murray added the comment: TempdirManager is new, which is why I forgot about it. It works with the buildbots because it is a context manager, so if things go badly the cleanup code is still going to run and delete the cruft. Since the distutils tests are unlikely to hang (which is

[issue10475] hardcoded compilers for LDSHARED/LDCXXSHARED on NetBSD

2010-11-20 Thread Nicolas Joly
New submission from Nicolas Joly : The configure script do hardcode compilers for LDSHARED/LDCXXSHARED on NetBSD, which should be avoided. [...] checking for gcc... gcc checking whether gcc accepts -g... yes [...] checking SO... .so checking LDSHARED... cc -shared checking CCSHARED... -fPIC [.

[issue10242] unittest's assertItemsEqual() method makes too many assumptions about its input

2010-11-20 Thread Mark Roddy
Mark Roddy added the comment: Adding patch for py3k which implements Raymond's suggested fix which utilizes collections.Counter. Have not changed the name of the assertion method as this seems as though it may be outside the scope of this issue, but I can produce another patch with the nam

[issue10242] unittest's assertItemsEqual() method makes too many assumptions about its input

2010-11-20 Thread Mark Roddy
Mark Roddy added the comment: Adding patch for release27-maint branch which implements Raymond's suggested fix which utilizes collections.Counter. Has the same issues addressed with the py3k patch. -- Added file: http://bugs.python.org/file19721/py27.10242.patch ___

[issue10476] __iter__ on a byte file object using a method to return an iterator

2010-11-20 Thread Julian
New submission from Julian : Iterating over a byte file object using __iter__ is rather useless, and a bit confusing perhaps. It'd be nice to propose two things: 1. Having __iter__ raise an exception if the file was opened with the "b" flag. 2. Adding a new by_bytes() method to file objects,

[issue9746] All sequence types support .index and .count

2010-11-20 Thread Éric Araujo
Éric Araujo added the comment: Patch committed in r86625 (py3k), r86627 (3.1) and r86627 (2.7). Regarding API conformance, I ran this simple test, courtesy of Daniel in msg109784: >>> for cls in str, bytes, bytearray, list, tuple, range: ... print(cls, [method for method in set(dir(collec

[issue10476] __iter__ on a byte file object using a method to return an iterator

2010-11-20 Thread Raymond Hettinger
Raymond Hettinger added the comment: FWIW, an idiom I use in Py2.x is: for block in iter(partial(f.read, BLKSIZ), ''): . . . This works with both single bytes at time and multiple bytes at a time. -- nosy: +rhettinger ___ Python tracker

[issue10476] __iter__ on a byte file object using a method to return an iterator

2010-11-20 Thread Benjamin Peterson
Benjamin Peterson added the comment: BufferedIOBase readline and __iter__ has to stay for backwards compatibility (especially with python 2). As for by_bytes(), I suggest you post it to python-ideas. -- nosy: +benjamin.peterson resolution: -> rejected status: open -> closed

[issue9909] request for calendar.dayofyear() function

2010-11-20 Thread Raymond Hettinger
Raymond Hettinger added the comment: "We already got one, and it's very nice-a" ISTM, this should be done with regular date arithmetic in the datetime module. >>> date(1964, 7, 31) - date(1963, 12, 31) datetime.timedelta(213) I don't see why we need a new function for this or why it would be

[issue6799] mimetypes does not give cannonical extension for guess_extension with text/plain

2010-11-20 Thread Chris Lambacher
Chris Lambacher added the comment: This is a dup of #1043134 -- nosy: +lambacck ___ Python tracker ___ ___ Python-bugs-list mailing li

[issue6799] mimetypes does not give canonical extension for guess_extension with text/plain

2010-11-20 Thread Éric Araujo
Changes by Éric Araujo : -- resolution: -> duplicate stage: needs patch -> committed/rejected status: open -> closed superseder: -> mimetypes.guess_extension('text/plain') == '.ksh' ??? title: mimetypes does not give cannonical extension for guess_extension with text/plain -> mimetype

[issue6434] buffer overflow in Zipfile when wrinting more than 2gig file

2010-11-20 Thread Chris Lambacher
Chris Lambacher added the comment: This should be closed as a dup of #1182788 which the OP identified as being the same bug and which is now fixed due to the implementation. of ZIP64. -- nosy: +lambacck ___ Python tracker

[issue9435] test_distutils fails without zlib

2010-11-20 Thread Éric Araujo
Éric Araujo added the comment: This can be kept open as a separate report, since it was caused by the Big Distutils Revert in 3.2. We’ve already discussed how to fix that in private email and IRC thanks to Ezio. Because of compat requirements, we’ll probably have to use if+return instead of

[issue10367] "python setup.py sdist upload --show-response" can fail with "UnboundLocalError: local variable 'result' referenced before assignment"

2010-11-20 Thread Éric Araujo
Changes by Éric Araujo : -- superseder: distutils upload command crashes when displaying server response -> ___ Python tracker ___ __

[issue7094] Add alternate float formatting styles to new-style formatting.

2010-11-20 Thread Eric Smith
Eric Smith added the comment: This is the patch developed today at the DCPython sprint. I have not reviewed it very well. I know that at least: - formatting is not consistent - the docs need reviewing - I want to add more tests - Misc/NEWS and Misc/ACKS need updating But I'm uploading it here

<    1   2   3   4   >