[issue6845] Restart support in binary upload for ftplib

2009-09-10 Thread Pablo Mouzo
Pablo Mouzo added the comment: I'm changing the title to something clearer (I hope). The patch I submitted adds the retr optional parameter to the storbinary method. -- title: ftplib rest support for storbinary -> Restart support in binary upload for ftplib Added file: http://bugs.pyth

[issue6845] ftplib rest support for storbinary

2009-09-10 Thread Pablo Mouzo
Changes by Pablo Mouzo : Removed file: http://bugs.python.org/file14841/issue6845.patch ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue6880] class needs forward reference

2009-09-10 Thread Gene Ratzlaff
New submission from Gene Ratzlaff : http://docs.python.org/tutorial/errors.html#user-defined-exceptions class mechanism used in 8.5 before classes are explained in chapter 9. Suggest first use of word "class" be a forward link to "9. Classes": http://docs.python.org/tutorial/classes.html#classe

[issue6879] misstatement in example explanation using raise

2009-09-10 Thread Gene Ratzlaff
New submission from Gene Ratzlaff : v2.6.2 Python Tutorial http://docs.python.org/tutorial/errors.html#raising-exceptions Section 8. Errors and Exceptions 8.4. Raising Exceptions It appears that in the example, the original may have been: raise(NameError('HiThere')) and was then changed to raise

[issue1578269] Add os.link() and os.symlink() and os.path.islink() support for Windows

2009-09-10 Thread Jason R. Coombs
Changes by Jason R. Coombs : Removed file: http://bugs.python.org/file14860/smime.p7s ___ Python tracker ___ ___ Python-bugs-list mailing li

[issue6617] During compiling python 3.1 getting error Undefined symbol libintl_bind_textdomain_codeset

2009-09-10 Thread Sandip Thorat
Sandip Thorat added the comment: Which file do i edit to add LDFLAGS=-lintl ? and at what place? -- ___ Python tracker ___ ___ Pytho

[issue2848] Remove mimetools usage from the stdlib

2009-09-10 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +Merwok ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org

[issue6713] Integer & Long types: Performance improvement of 1.6x to 2x for base 10 conversions

2009-09-10 Thread STINNER Victor
STINNER Victor added the comment: I don't understand the following comment in patch3: /* convert: base 2 in pin -> base 10 in pout */ I think that pin base is 2^30 / 2^15 and pout base is 10^9 / 10 ^ 4, not 10. -- ___ Python tracker

[issue6713] Integer & Long types: Performance improvement of 1.6x to 2x for base 10 conversions

2009-09-10 Thread Mark Dickinson
Mark Dickinson added the comment: One more iteration of the patch is attached: I rewrote the conversion algorithm to do the base PyLong_BASE to base 10**e conversion first, then output the base 10**e array as individual digits. For OS X/Intel, this seems to speed things up significantly. (Firs

[issue6817] char buffer in function posix_getcwdu should not be fix length

2009-09-10 Thread Boya Sun
Boya Sun added the comment: Victor, I corrected both issues of the patch according to your first comment. This patch did not fix the Windows implementation. It seems that there will not be buffer overflow in the Windows implementation, since if the buffer is small for GetCurrentDirectoryW(),

[issue6873] posix_lchown: possible overflow of uid, gid

2009-09-10 Thread Boya Sun
Changes by Boya Sun : Removed file: http://bugs.python.org/file14869/patch.diff ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubs

[issue6873] posix_lchown: possible overflow of uid, gid

2009-09-10 Thread Boya Sun
Boya Sun added the comment: Martin, The reason why I think there is a possible overflow is that according to issue 5705, uid/gid overflows are fixed in the following functions: posix_setegid, posix_setreuid(), posix_setregid(), posix_setgid(). So I think a similar fix should also be applied to

[issue6878] outdated docstring in tkinter.Canvas.coords

2009-09-10 Thread SilentGhost
New submission from SilentGhost : Doc string for tkinter/__init__.py Canvas.coords (line 2115 in python3.1.1) reads: """Return a list of coordinates for the item given in ARGS.""" actual code: return map(...etc...) I actually don't know whether it's an outdated docstring, may be coords should r

[issue6786] readline and zero based indexing

2009-09-10 Thread James
James added the comment: i found this: http://tiswww.case.edu/php/chet/readline/history.html search for: "Variable: int history_base" perhaps we can set this to 0 in the python bindings. more so, perhaps someone is using 1 because they made a mistake? -- ___

[issue6786] readline and zero based indexing

2009-09-10 Thread James
James added the comment: @mark: thanks for the comment; i suppose we should investigate why and if c readline is 1 based... -- ___ Python tracker ___

[issue6872] Support system readline on OS X 10.6

2009-09-10 Thread James
James added the comment: it seems to me, that any and all readline interfaces should/could standardize to the indexing scheme as used by the language; maybe i'm wrong, but since python is zero based, so could the readline interfaces. it's definitely more logical for a python programmer to expec

[issue6713] Integer & Long types: Performance improvement of 1.6x to 2x for base 10 conversions

2009-09-10 Thread Mark Dickinson
Mark Dickinson added the comment: Sorry: ignore that last message; I was talking through my hat. I think I must have been unwittingly building in debug mode. Ahem. After a 'make distclean', I get the following results (same specs as above, on a 2.53Ghz MacBook Pro / Core 2 Duo). original

[issue6713] Integer & Long types: Performance improvement of 1.6x to 2x for base 10 conversions

2009-09-10 Thread Mark Dickinson
Mark Dickinson added the comment: Thanks for those results, Collin. > By benchmark should be reproduced on a 64 bits CPU with 2^15 and 2^30 > bases for the long type. On OS X 10.6 (64-bit Python non-debug non-framework build with gcc 4.2 from Apple, 30-bit long digits, straight ./configure &&

[issue6877] enable compilation of readline module on Mac OS X 10.5 and 10.6

2009-09-10 Thread Zvezdan Petkovic
Zvezdan Petkovic added the comment: > It would also be nice if one could programmaticly detect if readline > is linked to libedit There's this rl_library_version constant defined in editline/readline C libraries that the attached patch uses. Perhaps, if we can expose its value from the Python

[issue6713] Integer & Long types: Performance improvement of 1.6x to 2x for base 10 conversions

2009-09-10 Thread Collin Winter
Collin Winter added the comment: I ran this patch against Unladen Swallow's slowspitfire template benchmark, which does more int->string conversions than any of our other benchmarks. When run against Python trunk r74737, I get these results: slowspitfire: Min: 0.888772 -> 0.867427: 2.46% fast

[issue6872] Support system readline on OS X 10.6

2009-09-10 Thread Eric Smith
Changes by Eric Smith : -- nosy: +eric.smith ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue6877] enable compilation of readline module on Mac OS X 10.5 and 10.6

2009-09-10 Thread Ronald Oussoren
Ronald Oussoren added the comment: I'm +1 on merging this functionality. See also: issue6872 As I mentioned there we should ensure that readline linked to libedit has the same semantics as readline linked to GNU readline, and because the configuration file of libedit has a different format a

[issue6872] Support system readline on OS X 10.6

2009-09-10 Thread Zvezdan Petkovic
Zvezdan Petkovic added the comment: Also, the patch from issue 6877 changes setup.py in a way that enables build of the readline module on Leopard as well. Such build is used for about two years already (Python 2.4) by several people in my company and nobody noticed any issues on Mac OS X Leo

[issue6872] Support system readline on OS X 10.6

2009-09-10 Thread Zvezdan Petkovic
Zvezdan Petkovic added the comment: This patch could potentially break non-Mac OS X systems. Fortunately, I have a patch that works with systems that use GNU readline and systems that use editline emulation. See issue 6877. Unfortunately, I was lingering for over a year with opening a tracker

[issue6247] should we include argparse

2009-09-10 Thread Michael Foord
Michael Foord added the comment: This was rejected prior to Steven Bethard becoming involved, so I'm reopening. +1 from me - argparse is a great module to use. -- nosy: +michael.foord resolution: rejected -> status: closed -> open ___ Python tracke

[issue6877] enable compilation of readline module on Mac OS X 10.5 and 10.6

2009-09-10 Thread Zvezdan Petkovic
Zvezdan Petkovic added the comment: When testing the patch make sure that your readline module has been actually linked against editline library rather then some copy of GNU readline from MacPorts or Fink. Assuming --prefix=${HOME}/opt, the output of otool -L ~/opt/lib/python2.4/lib-dynl

[issue4204] Cannot build _multiprocessing, math, mmap and readline of Python 2.6 on FreeBSD 4.11 w/ gcc 2.95.4

2009-09-10 Thread Zvezdan Petkovic
Zvezdan Petkovic added the comment: I worked around the issue mentioned in msg82619. The readline patch (issue 6877) is not adversely affected by the patch applied in this issue. This issue can remain closed AFAIC. -- ___ Python tracker

[issue6877] enable compilation of readline module on Mac OS X 10.5 and 10.6

2009-09-10 Thread Zvezdan Petkovic
Zvezdan Petkovic added the comment: Changed type to "crash" because compilation of readline module without this patch was causing Python to crash with BusError. -- type: compile error -> crash ___ Python tracker _

[issue6877] enable compilation of readline module on Mac OS X 10.5 and 10.6

2009-09-10 Thread Zvezdan Petkovic
New submission from Zvezdan Petkovic : The attached patch enables compilation and use of the readline module on Mac OS X 10.5 (Leopard) and 10.6 (Snow Leopard). It utilizes the native editline library (used for emulation of the readline library on Mac). I used the patch for almost two years al

[issue6875] add os.close() suggestion to mkstemp documentation

2009-09-10 Thread Vincent Legoll
Vincent Legoll added the comment: Or a review of the markup I used -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubsc

[issue6876] readline documentation example error

2009-09-10 Thread Stefan Schwarzburg
New submission from Stefan Schwarzburg : In the last example in the readline documentation (http://docs.python.org/library/readline.html), the line code.InteractiveConsole.__init__(self) should be changed to code.InteractiveConsole.__init__(self, locals, filename) to work properly.

[issue6875] add os.close() suggestion to mkstemp documentation

2009-09-10 Thread Vincent Legoll
New submission from Vincent Legoll : As per the blog entry http://www.logilab.org/blogentry/17873 I think the tempfile.mkstemp() documentation could be more helpful by suggesting the use of os.close() appropriately. If some native english speaker could give a review of the language I used in th

[issue6873] posix_lchown: possible overflow of uid, gid

2009-09-10 Thread Martin v . Löwis
Martin v. Löwis added the comment: The patch is incorrect. Why do you think there is an overflow? There is none in the call to ParseTuple: the i argument parser expects a signed int*; passing a long* will break on systems where sizeof(int)!=sizeof(long) (such as typical 64-bit Unix). In addi

[issue6872] Support system readline on OS X 10.6

2009-09-10 Thread Martin v . Löwis
Martin v. Löwis added the comment: I also agree that this is desirable to have, and that the readline module should provide the GNU semantics even with a different implementation. -- nosy: +loewis ___ Python tracker

[issue6871] decimal.py: more format issues

2009-09-10 Thread Stefan Krah
Stefan Krah added the comment: Issue 3 is nonsense, '-' means left-justified in C. Sorry. -- ___ Python tracker ___ ___ Python-bugs-li

[issue6873] posix_lchown: possible overflow of uid, gid

2009-09-10 Thread STINNER Victor
STINNER Victor added the comment: posix modules contains a lot of function parsing uid_t / gid_t types. I would be nice to factorize the code: create a function to get an uid_t, and another to get a gid_t. I don't know the name of such callback, but it's used with: PyArg_ParseTuple(args, "...O&.

[issue6713] Integer & Long types: Performance improvement of 1.6x to 2x for base 10 conversions

2009-09-10 Thread STINNER Victor
STINNER Victor added the comment: > If you're working with huge integers and care about speed, then > you should probably be using gmpy or similar I disagree with you, mark. The patch is around 20 lines and does optimize all cases, not only the "huge integers". See my benchmark: conversion for