[issue5364] documentation in epub format

2009-02-25 Thread wrobell
New submission from wrobell : python documentation can be downloaded in pdf format (a4, us letter), html and text plain. they are useful for printing and computer based viewing, but not so good to read on ebook hardware/software (i.e. sony prs-{505,700} or stanza ebook reader). it would be nice

[issue5364] documentation in epub format

2009-02-25 Thread Senthil
Senthil added the comment: I got into thinking if sphinx-dev or docutils be the best place for this ticket? Python Documentation is nothing but ReStructured text and it is required to create a rst2epub that would convert restructured text to epub format. If you are already aware of any such to

[issue5365] add conversion table to time module docs

2009-02-25 Thread Chris Rebert
New submission from Chris Rebert : I would like the offer the table in the attached file for addition to the 'time' module documentation so as to provide a quick overview of how to convert between the various time representations. As it currently stands (at least on the current public version of

[issue5251] contextlib.nested inconsistent with, well, nested with statements due exceptions raised in __enter__

2009-02-25 Thread Nick Coghlan
Nick Coghlan added the comment: That's an interesting problem... since one of the things I like about CMs is the ability to turn pretty much any block of code into a context manager by substituting a yield statement at the appropriate point, not having the ability to skip the yield is actually s

[issue5364] documentation in epub format

2009-02-25 Thread wrobell
wrobell added the comment: probably sphinx/docutils "deserve" their own tickets, but appropriate tools support will not guarantee, that documentation in epub format is going to be published on http://docs.python.org/download.html if documentation won't be published in this format, then i s

[issue5364] documentation in epub format

2009-02-25 Thread Senthil
Senthil added the comment: On Wed, Feb 25, 2009 at 5:12 PM, wrobell wrote: > probably sphinx/docutils "deserve" their own tickets, I agree with your points and I would wait for Georg's call on this ticket. It would definitely help if you have already raised any tickets at docutils or looked f

[issue2054] add ftp-tls support to ftplib - RFC 4217

2009-02-25 Thread Giampaolo Rodola'
Giampaolo Rodola' added the comment: > Actually I have encountered a possible bug. the close() > method doesn't seem to actually close the connection... Why? What happens exactly? ___ Python tracker __

[issue4565] Rewrite the IO stack in C

2009-02-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: I just took a quick look at Lib/abc.py and there's no way *I*'ll reimplement it in C :) The only workable approach would be: 1. rename the current would-be ABCs (IOBase, RawIOBase, etc.) with a leading underscore (_IOBase, _RawIOBase, etc.) 2. call abc.ABCMeta(

[issue5366] examples for dependency keywords in setup.py

2009-02-25 Thread anatoly techtonik
New submission from anatoly techtonik : When documentation grows too large it is nice to have clear examples that stand out of text. Explanation is important to get the idea, but for a reference cookbook examples work better. Here is a patch to clarify the usage of *requires* and *provides* key

[issue5367] typo in subprocess.py

2009-02-25 Thread Joachim Ott
New submission from Joachim Ott : I saw it first in /usr/lib/python2.5/subprocess.py on two different systems, line 12 reads: r"""subprocess - Subprocesses with accessible I/O streams It's still there in 3.0.1. Is a single "r" a valid python statement? -- components: Library (Lib) mess

[issue1580] Use shorter float repr when possible

2009-02-25 Thread Preston Briggs
Preston Briggs added the comment: In all this discussion, it seems that we have not discussed the possibility of adapting David Gay's code, dtoa.c, which nicely handles both halves of the problem. It's also free and has been well exercised over the years. It's available here: http://www.netlib

[issue5368] curses patch add color_set and wcolor_set functions

2009-02-25 Thread Steve Owens
New submission from Steve Owens : Not sure what to set theType field to, this is my first patch submission. The attached files are a unit test test_curses_color_set.py and the diff color_set_diff, apparently I can only attach one fo thetwo files. -- assignee: georg.brandl components:

[issue5368] curses patch add color_set and wcolor_set functions

2009-02-25 Thread Steve Owens
Changes by Steve Owens : Added file: http://bugs.python.org/file13175/test_curses_color_set.py ___ Python tracker ___ ___ Python-bugs-list mail

[issue1580] Use shorter float repr when possible

2009-02-25 Thread Mark Dickinson
Mark Dickinson added the comment: > It'd probably have to be touched up a bit. This may be an understatement. :-) In the first 50 lines of the 3897-line dtoa.c file, I see this warning: /* On a machine with IEEE extended-precision registers, it is * necessary to specify double-precision (53-

[issue1580] Use shorter float repr when possible

2009-02-25 Thread Preston Briggs
Preston Briggs added the comment: >> It'd probably have to be touched up a bit. > This may be an understatement. :-) Probably so. Nevertheless, it's got to be easier than approaching the problem from scratch. And considering that this discussion has been going on for over a year now, it might

[issue5369] __ppc__ macro checking is incorrect

2009-02-25 Thread Arkadiusz Miskiewicz Arkadiusz Miskiewicz
New submission from Arkadiusz Miskiewicz Arkadiusz Miskiewicz : Python/ceval.c and many other places rely on __ppc__ (and __ppc64__) symbol defined like below. Unfortunately on my Linux ppc __ppc__ is never defined while __powerpc__ is. Build fortunately failed

[issue4565] Rewrite the IO stack in C

2009-02-25 Thread Benjamin Peterson
Benjamin Peterson added the comment: On Wed, Feb 25, 2009 at 10:15 AM, Antoine Pitrou wrote: > > Antoine Pitrou added the comment: > > I just took a quick look at Lib/abc.py and there's no way *I*'ll > reimplement it in C :) I don't blame you for that. :) > > The only workable approach would

[issue5229] Documentation for super() neglects to say what super() actually does

2009-02-25 Thread Raymond Hettinger
Raymond Hettinger added the comment: FWIW, I did a further update to the super docs to clarify that parent classes are search in single inheritance models and that both parent and siblings are searched in multiple inheritance models. Made the concept more concrete by relating pointing to the __

[issue5229] Documentation for super() neglects to say what super() actually does

2009-02-25 Thread Raymond Hettinger
Raymond Hettinger added the comment: See: http://docs.python.org/dev/library/functions.html#super ___ Python tracker ___ ___ Python-bugs-list

[issue5367] typo in subprocess.py

2009-02-25 Thread Benjamin Peterson
Benjamin Peterson added the comment: The prefix "r" on a string makes it a raw string, certainly a valid construct. -- nosy: +benjamin.peterson resolution: -> invalid status: open -> closed ___ Python tracker

[issue5316] Buildbot failures in test_site

2009-02-25 Thread Hirokazu Yamamoto
Hirokazu Yamamoto added the comment: Probably attached patch will fix this issue. But this patch doesn't cover other similar problematic codes. It seems this is multi inheritance problem. Following code shows B.setUp and B.tearDown are called twice respectively. (In this issue, B represents PyP

[issue1580] Use shorter float repr when possible

2009-02-25 Thread Mark Dickinson
Mark Dickinson added the comment: > I would consider compiling the library with flags appropriate to forcing > 64-bit IEEE arithmetic if possible. Using the right compiler flags is only half the battle, though. You should really be setting the rounding precision dynamically: set it to 53-bi

[issue5283] setting __class__ in __del__ is bad. mmkay. negative ref count! kaboom!

2009-02-25 Thread Gregory P. Smith
Gregory P. Smith added the comment: Could the PyObject_ClearWeakRefs(self); call in the middle of the lines del_changes_class.patch adds also be used to cause python code to set __del__ or __dict__ causing the wrong destructor or wrong dict to be DECREFed? (I'm trying to wrap my head around

[issue5084] unpickling does not intern attribute names

2009-02-25 Thread Jake McGuire
Jake McGuire added the comment: Ugh. Clearly I didn't check to see if it worked or not, as it didn't even compile. A new diff, tested and verified to work, is attached. I'll work on creating a test. Added file: http://bugs.python.org/file13178/cPickle.c.diff __

[issue5084] unpickling does not intern attribute names

2009-02-25 Thread Jake McGuire
Changes by Jake McGuire : Removed file: http://bugs.python.org/file12882/cPickle.c.diff ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue5084] unpickling does not intern attribute names

2009-02-25 Thread Jake McGuire
Changes by Jake McGuire : Removed file: http://bugs.python.org/file13169/cPickle.c.diff ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue5370] unpickling vs. __getattr__

2009-02-25 Thread Mike Meyer
New submission from Mike Meyer : The attached short file causes all of python 2.5, 2.6 and 3.0 to drop into infinite recursion trying to unpickle the created object, but the 2.5 version has the cleanest The problem appears to be that the unpickle code (C in 3.0; Python in 2.5 - I assume the other

[issue5371] Documentation of str.format in library/stdtypes shows incorrect first parameter

2009-02-25 Thread Mitchell Model
New submission from Mitchell Model : In the library documentation of standard types, the instance method str.format is shown as taking a format-specification as its first argument. I'm pretty sure that this is incorrect. When format is called through a string, it is that string that is the for

[issue5316] Buildbot failures in test_site

2009-02-25 Thread Tarek Ziadé
Tarek Ziadé added the comment: right, subclasses must use super if their superclasses do. I'll apply Hirozaku patch (thanks). I might also simplify distutil base test class to avoid Mixins. ___ Python tracker ___

[issue1580] Use shorter float repr when possible

2009-02-25 Thread Raymond Hettinger
Raymond Hettinger added the comment: Even if someone devoted the time to get possibly get this right, it would be somewhat difficult to maintain. ___ Python tracker ___ __

[issue5316] Buildbot failures in test_site

2009-02-25 Thread Tarek Ziadé
Tarek Ziadé added the comment: applied in r69976 and r69977 -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mail

[issue5229] Documentation for super() neglects to say what super() actually does

2009-02-25 Thread Daniel Stutzbach
Daniel Stutzbach added the comment: Thanks! These improvements are very helpful. The one missing notion is that "object-or-type" may be a proxy object, in which case super() returns a new proxy that additionally skips "type". Perhaps add the following sentence to the end of the first paragrap

[issue1580] Use shorter float repr when possible

2009-02-25 Thread Guido van Rossum
Guido van Rossum added the comment: What maintenance issues are you anticipating? ___ Python tracker ___ ___ Python-bugs-list mailing list Unsu

[issue1580] Use shorter float repr when possible

2009-02-25 Thread Raymond Hettinger
Raymond Hettinger added the comment: Gay's code is 3800+ lines and includes many ifdef paths that we need to get right. Mark points out that the code itself needs additional work. The discussions so far also get into setting compiler flags on different systems and I would imagine that that wou

[issue5229] Documentation for super() neglects to say what super() actually does

2009-02-25 Thread Raymond Hettinger
Raymond Hettinger added the comment: > Perhaps add the following sentence to the end of > the first paragraph: "If *object-or-type* is a proxy > object, *super* returns a new proxy that additionally > skips *type*." I'm not really sure what that even means. Nor do I think it was one of the u

[issue1580] Use shorter float repr when possible

2009-02-25 Thread Tim Peters
Tim Peters added the comment: The GNU library's float<->string routines are based on David Gay's. Therefore you can compare those to Gay's originals to see how much effort was required to make them "mostly" portable, and can look at the history of those to get some feel for the maintenance burd

[issue5229] Documentation for super() neglects to say what super() actually does

2009-02-25 Thread Daniel Stutzbach
Daniel Stutzbach added the comment: Actually, it's essential to how super() works. Here's an example using single inheritance: class A(object): def foo(self): print 'A' class B(object): def foo(self): super(B, self).foo() print 'B' class C(object): def foo(self): super(

[issue5229] Documentation for super() neglects to say what super() actually does

2009-02-25 Thread Daniel Stutzbach
Daniel Stutzbach added the comment: In the previous example, I meant to type class B(A) and class C(B) rather than having them all derive from object. That's what I get for not actually testing the code. ;-) ___ Python tracker

[issue5229] Documentation for super() neglects to say what super() actually does

2009-02-25 Thread Raymond Hettinger
Raymond Hettinger added the comment: I see what you mean but think that the docs shouldn't go into how super() is implemented. Already, they've reached an information density such that adding more explanations will make it collectively less clear. As soon as you mention proxy objects as inputs

[issue5372] Distutils inappropriately reuses .o files between extension modules

2009-02-25 Thread Collin Winter
New submission from Collin Winter : (Tarek, I've been told you're the new distutils maintainer. Feel free to unassign this if that isn't the case.) The test distutils uses to decide whether it needs to recompile an existing .o file when building extension modules is too simplistic, merely compar

[issue5371] Documentation of str.format in library/stdtypes shows incorrect first parameter

2009-02-25 Thread Benjamin Peterson
Benjamin Peterson added the comment: Fixed in r69987. -- nosy: +benjamin.peterson resolution: -> fixed status: open -> closed ___ Python tracker ___

[issue1533164] Installed but not listed *.pyo break bdist_rpm

2009-02-25 Thread Tarek Ziadé
Changes by Tarek Ziadé : Added file: http://bugs.python.org/file13181/rpm.ptch ___ Python tracker ___ ___ Python-bugs-list mailing list Unsu

[issue1533164] Installed but not listed *.pyo break bdist_rpm

2009-02-25 Thread Tarek Ziadé
Changes by Tarek Ziadé : Removed file: http://bugs.python.org/file13153/rpm.patch ___ Python tracker ___ ___ Python-bugs-list mailing list U

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

2009-02-25 Thread Collin Winter
Changes by Collin Winter : -- nosy: +collinwinter ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.py

[issue4715] optimize bytecode for conditional branches

2009-02-25 Thread Jeffrey Yasskin
Jeffrey Yasskin added the comment: Oh, and no problem with picking up the patches. Thanks for writing them in the first place. Here's the backport to trunk. I particularly enjoyed the bit in pyassem.py where I had to teach the pure-Python compiler that you can get to a block without going throu

[issue5362] Add configure option to disable Py3k warnings

2009-02-25 Thread Collin Winter
Collin Winter added the comment: Jeffrey: updated the patch to address your concerns. Martin: I'm not sure I completely understand it either, though it seems similar to issue4477. In the course of developing this patch, I tried also #ifdef'ing out all usages of the Py_Py3kWarningFlag global. Th

[issue5362] Add configure option to disable Py3k warnings

2009-02-25 Thread Collin Winter
Changes by Collin Winter : Removed file: http://bugs.python.org/file13168/no_py3k_warning.patch ___ Python tracker ___ ___ Python-bugs-list mai

[issue5362] Add configure option to disable Py3k warnings

2009-02-25 Thread Collin Winter
Collin Winter added the comment: Bah, forgot to run autoreconf. Fixed. Added file: http://bugs.python.org/file13184/no_py3k_warning.patch ___ Python tracker ___ _

[issue5362] Add configure option to disable Py3k warnings

2009-02-25 Thread Collin Winter
Changes by Collin Winter : Removed file: http://bugs.python.org/file13183/no_py3k_warning.patch ___ Python tracker ___ ___ Python-bugs-list mai

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

2009-02-25 Thread Matthew Barnett
Matthew Barnett added the comment: issue2636-features-4.diff includes: Bugfixes msg74203: duplicate capture group numbers msg74904: duplicate capture group names Added file: http://bugs.python.org/file13185/issue2636-features-4.diff ___ Python tracker

[issue5332] csv sniffer

2009-02-25 Thread Skip Montanaro
Skip Montanaro added the comment: I verified the bug. I started to work on a patch (see attached), but it quickly seems to get out-of-hand with tracebacks about stuff not supporting the buffer API. I suspect the real solution might involve doing something to convert the bytes to strings read w

[issue1006238] cross compile patch

2009-02-25 Thread Mike Frysinger
Mike Frysinger added the comment: Garrett: your configure method is overly complicated. all you need to do is set --build=binos_c3.4.3-p1.mips64-octeon-linux. autoconf will figure out all the other toolchain settings. ___ Python tracker

[issue4715] optimize bytecode for conditional branches

2009-02-25 Thread Jeffrey Yasskin
Jeffrey Yasskin added the comment: The numbers are: Intel Core 2, gcc-4.3, 32-bit 2to3: 25.24 -> 24.89: 1.38% faster Django: Min: 0.618 -> 0.607: 1.90% faster Avg: 0.621 -> 0.615: 1.04% faster PyBench: Min: 5324 -> 5280: 0.83% faster Avg: 5456 -> 5386: 1.30% faster Pickle: Min: 1.424 -> 1.37

[issue3585] pkg-config support

2009-02-25 Thread Clinton Roy
Clinton Roy added the comment: Oh, you meant for me to reply =) - Do all unix-like system support pkg-config? Yes. It even works on windows. - Is $(LIBDIR)/pkgconfig the only choice for installing this file? While pkg-config can be told to look in other directories for pc files (via modifyin

[issue1818] Add named tuple reader to CSV module

2009-02-25 Thread Rob Renaud
Rob Renaud added the comment: I am totally new to Python dev. I reinvented a NamedTupleReader tonight, only to find out that it was created a year ago. My primary motivation is that DictReader reads headers nicely, but DictWriter totally sucks at handling them. Consider doing some filtering o

[issue1818] Add named tuple reader to CSV module

2009-02-25 Thread Rob Renaud
Rob Renaud added the comment: My previous patch could write the header twice. But I am not sure about about how the writer should handle the fieldnames parameter on one hand, and the namedtuple._fields on the other. Added file: http://bugs.python.org/file13188/named_tuple_write_header2.patch

[issue1818] Add named tuple reader to CSV module

2009-02-25 Thread Rob Renaud
Changes by Rob Renaud : Removed file: http://bugs.python.org/file13187/named_tuple_write_header.patch ___ Python tracker ___ ___ Python-bugs-li