[issue3041] autodoc does not support unicode docstrings

2008-06-05 Thread Christophe de Vienne
New submission from Christophe de Vienne [EMAIL PROTECTED]: If I define unicode docstrings in my python source, autodoc crash because it tries to decode them, which force a ascii encode first. A trivial patch fix the issue : Index: sphinx/ext/autodoc.py

[issue3039] tarfile.TarFileCompat.writestr(ZipInfo, str) raises AttributeError

2008-06-05 Thread Lars Gustäbel
Changes by Lars Gustäbel [EMAIL PROTECTED]: -- assignee: - lars.gustaebel nosy: +lars.gustaebel ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue3039 ___

[issue3042] Add PEP 8 compliant aliases to threading module

2008-06-05 Thread Nick Coghlan
New submission from Nick Coghlan [EMAIL PROTECTED]: PEP 371 highlighted the non-PEP 8 compliant nature of the threading API. Since part of that PEP involves updating the multiprocessing API to be PEP 8 compliant before addition the standard library, the threading API should also be updated to be

[issue643841] New class special method lookup change

2008-06-05 Thread Nick Coghlan
Nick Coghlan [EMAIL PROTECTED] added the comment: I've attached the latest version of the module as an actual patch against Python SVN. It differs slightly from the last version uploaded as separate files, in that in-place operations on a proxied object will no longer strip the proxy wrapper

[issue643841] New class special method lookup change

2008-06-05 Thread Nick Coghlan
Nick Coghlan [EMAIL PROTECTED] added the comment: Note that I'll be offline for the next few days, so I want be able to respond to any comments until some time next week. ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue643841

[issue3004] Bug in slice.indices()

2008-06-05 Thread Mark Dickinson
Mark Dickinson [EMAIL PROTECTED] added the comment: I agree that those -1s should really be 0s. Do you have any examples of real-life code that's affected by this bug? It doesn't seem like something that would be a problem in practice. -- nosy: +marketdickinson priority: - normal

[issue3042] Add PEP 8 compliant aliases to threading module

2008-06-05 Thread Benjamin Peterson
Benjamin Peterson [EMAIL PROTECTED] added the comment: Is this what you were looking for? (in the patch) What I did could also be done with metaclasses, but I thought that would be overkill. Warning: this patch causes test threading to crash when run with the -3 flag. -- keywords:

[issue1628484] Python 2.5 64 bit compile fails on Solaris 10/gcc 4.1.1

2008-06-05 Thread Peter N
Peter N [EMAIL PROTECTED] added the comment: Martin, On solaris 10 x86, this patch makes it possible to build python 2.5.x. Without it, there is no way for the automated build to work. I believe that your characterization of it as Therefore, I claim that this makes things more complex, and

[issue3042] Add PEP 8 compliant aliases to threading module

2008-06-05 Thread Benjamin Peterson
Benjamin Peterson [EMAIL PROTECTED] added the comment: Attaching a patch which fixes everything. Added file: http://bugs.python.org/file10523/new_threading_api2.patch ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue3042

[issue3038] Return results from Python callbacks to Tcl as Tcl objects, please backport it.

2008-06-05 Thread Benjamin Peterson
Changes by Benjamin Peterson [EMAIL PROTECTED]: -- assignee: - loewis nosy: +loewis ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue3038 ___ ___

[issue3041] autodoc does not support unicode docstrings

2008-06-05 Thread Georg Brandl
Georg Brandl [EMAIL PROTECTED] added the comment: Thanks, fixed in r63958. -- resolution: - fixed status: open - closed ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue3041 ___

[issue643841] New class special method lookup change

2008-06-05 Thread Adam Olsen
Adam Olsen [EMAIL PROTECTED] added the comment: The inplace operators aren't right for weakref proxies. If a new object is returned there likely won't be another reference to it and the weakref will promptly be cleared. This could be fixed with another property like _target, which by default

[issue1628484] Python 2.5 64 bit compile fails on Solaris 10/gcc 4.1.1

2008-06-05 Thread Martin v. Löwis
Martin v. Löwis [EMAIL PROTECTED] added the comment: So, since this patch allows python to be built 64-bit on a biarch system, and without it, the build doesn't work This is simply not true. I can build Python 2.5 just fine for 64-bit SPARC, using gcc, with CC=gcc -m64 ./configure make Or,

[issue2799] Remove PyUnicode_AsString(), rework PyUnicode_AsStringAndSize(), add PyUnicode_AsChar()

2008-06-05 Thread Alexandre Vassalotti
Alexandre Vassalotti [EMAIL PROTECTED] added the comment: I now think the proposed changes wouldn't be bad thing, after all. I have been bitten myself by the confusing naming of the Unicode API. So, there is definitely a potential for errors. The main problem with PyUnicode_AsString(), as

[issue1628484] Python 2.5 64 bit compile fails on Solaris 10/gcc 4.1.1

2008-06-05 Thread Martin v. Löwis
Martin v. Löwis [EMAIL PROTECTED] added the comment: Your method is just flat wrong - equivalent to using a sledgehammer. The libraries fail to link not because gcc install is wrong but because the -m64 flag needs to be passed to the linker. And indeed, the flag *is* passed to the linker.

[issue1628484] Python 2.5 64 bit compile fails on Solaris 10/gcc 4.1.1

2008-06-05 Thread Bob Atkins
Bob Atkins [EMAIL PROTECTED] added the comment: Martin, Your method is just flat wrong - equivalent to using a sledgehammer. The libraries fail to link not because gcc install is wrong but because the -m64 flag needs to be passed to the linker. Your method just fixes the compilation stage.

[issue1628484] Python 2.5 64 bit compile fails on Solaris 10/gcc 4.1.1

2008-06-05 Thread Martin v. Löwis
Martin v. Löwis [EMAIL PROTECTED] added the comment: Just to demonstrate there is really a problem with the gcc installation (gcc version 3.4.3 (csl-sol210-3_4-branch+sol_rpath)), here is the linker line: gcc -m64 -shared

[issue1628484] Python 2.5 64 bit compile fails on Solaris 10/gcc 4.1.1

2008-06-05 Thread Bob Atkins
Bob Atkins [EMAIL PROTECTED] added the comment: I rest my case - you found /_*one*_/ of the problems which you are blaming on gcc but in fact is not gcc's fault. You /_*must*_/ specify the correct -L and -R paths to the various alternate 64 bit libs. Don't expect the compiler to figure it

=?utf-8?q?[issue2799]_Remove_PyUnicode=5FAsString(), =09rework_PyUnicode=5FAsStringAndSize(), _add_PyUnicode=5FAsChar()?=

2008-06-05 Thread Marc-Andre Lemburg
Marc-Andre Lemburg [EMAIL PROTECTED] added the comment: On 2008-06-05 21:14, Alexandre Vassalotti wrote: Alexandre Vassalotti [EMAIL PROTECTED] added the comment: I now think the proposed changes wouldn't be bad thing, after all. I have been bitten myself by the confusing naming of the

[issue2799] Remove PyUnicode_AsString(), rework PyUnicode_AsStringAndSize(), add PyUnicode_AsChar()

2008-06-05 Thread Martin v. Löwis
Martin v. Löwis [EMAIL PROTECTED] added the comment: How about PyUnicode_GetUTF8Buffer() or just PyUnicode_UTF8() ?! -1 Note that the function *must* check the UTF-8 buffer for embedded NUL bytes and then raise an exception if it finds one. Otherwise, the API would silently cause

[issue3043] Recursion bug in deepcopy

2008-06-05 Thread Tyler Laing
New submission from Tyler Laing [EMAIL PROTECTED]: With the following code: class Vertex: def __init__(self, type): self.type = type self.color=-1 self.edges=[] class Edge: def __init__(self, V1, V2):

[issue3043] Recursion bug in deepcopy

2008-06-05 Thread Tyler Laing
Tyler Laing [EMAIL PROTECTED] added the comment: Whoops, sorry, correction, when there are 100 vertexes and 500 edges. ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue3043 ___

[issue3043] Recursion bug in deepcopy

2008-06-05 Thread Guilherme Polo
Guilherme Polo [EMAIL PROTECTED] added the comment: This should have been fixed at 2.2, as long as you change your classes to new-style classes. If it still happens, post a sample code using your new code that uses new-style classes. -- nosy: +gpolo

[issue3043] Recursion bug in deepcopy

2008-06-05 Thread Tyler Laing
Tyler Laing [EMAIL PROTECTED] added the comment: Same problem, even with new-style classes. Here, I'll show the function I use to generate the graph as well. class Vertex(object): def __init__(self, type): self.type = type self.color=-1

[issue3004] Bug in slice.indices()

2008-06-05 Thread Arnaud Bergeron
Arnaud Bergeron [EMAIL PROTECTED] added the comment: It's for code that I am developping. I developped a class to allow full slicing over iterators (like what islice does, but with negative indexes). When I have a positive step I just foward the call to isclice using slice.indices() to compute

[issue3044] Simplify the Integral ABC

2008-06-05 Thread Raymond Hettinger
New submission from Raymond Hettinger [EMAIL PROTECTED]: See attached patches. The PEP is also updated for Exact/Inexact which were removed a good while ago. -- assignee: gvanrossum components: Library (Lib) files: numbers.diff keywords: patch messages: 67734 nosy: gvanrossum,

[issue3044] Simplify the Integral ABC

2008-06-05 Thread Raymond Hettinger
Changes by Raymond Hettinger [EMAIL PROTECTED]: Added file: http://bugs.python.org/file10529/pep.diff ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue3044 ___

[issue3044] Simplify the Integral ABC

2008-06-05 Thread Guido van Rossum
Guido van Rossum [EMAIL PROTECTED] added the comment: Looks like you accidentally removed 2-arg __pow__ from the Complex ABC. This should stay of course. Also, please add the binary operators back in a new ABC called Binary deriving from Integral. ___

[issue2582] Unpickling of range objects fail in Py3k

2008-06-05 Thread Alexandre Vassalotti
Alexandre Vassalotti [EMAIL PROTECTED] added the comment: Weird. I wonder why it succeeds to pickle to range object at all. It seems the __reduce_ex__ method emits bogus value. r.__reduce_ex__(2) (function __newobj__ at 0xb7bfdc94, (class 'range',), None, None, None) Anyway, that is easy

[issue2582] Unpickling of range objects fail in Py3k

2008-06-05 Thread Alexandre Vassalotti
Alexandre Vassalotti [EMAIL PROTECTED] added the comment: Oh, here is a slightly more efficient version. Added file: http://bugs.python.org/file10531/fix_range_pickling-2.patch ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue2582

[issue3044] Simplify the Integral ABC

2008-06-05 Thread Raymond Hettinger
Raymond Hettinger [EMAIL PROTECTED] added the comment: Apologies. Didn't know you wanted to go that direction. Will leave this for someone who wants to expand numbers.py rather than simplifying it. -- resolution: - rejected status: open - closed

[issue2582] Unpickling of range objects fail in Py3k

2008-06-05 Thread Alexandre Vassalotti
Alexandre Vassalotti [EMAIL PROTECTED] added the comment: xrange() in Python 2.x is also affected by this bug. So, here is the fix. -- versions: +Python 2.5, Python 2.6 Added file: http://bugs.python.org/file10532/fix_xrange_pickling.patch ___ Python

[issue3044] Simplify the Integral ABC

2008-06-05 Thread Guido van Rossum
Guido van Rossum [EMAIL PROTECTED] added the comment: Excuse me? Have you actually been following the thread? ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue3044 ___

[issue3008] Let bin() show floats

2008-06-05 Thread Alexandre Vassalotti
Alexandre Vassalotti [EMAIL PROTECTED] added the comment: Kind of a cool hack. I am not sure how useful it is though. Personally, I find ``struct.pack('d', f)`` slightly more educative (more useful too), but that is just me. And if you allow bin() to accept floats, will you make Python accept

[issue3042] Add PEP 8 compliant aliases to threading module

2008-06-05 Thread Nick Coghlan
Nick Coghlan [EMAIL PROTECTED] added the comment: The code changes in the patch look pretty good to me (although you probably want to actually use @wraps inside _old_api!) There are obviously also documentation and test suite changes that will be needed. ___

[issue643841] New class special method lookup change

2008-06-05 Thread Nick Coghlan
Nick Coghlan [EMAIL PROTECTED] added the comment: Ah, that would answer my #XXX comment regarding that in the patch. Agreed, the best answer will be to factor out the _rewrap operation into a new class method. (Next week though...) ___ Python tracker [EMAIL

[issue3042] Add PEP 8 compliant aliases to threading module

2008-06-05 Thread Benjamin Peterson
Benjamin Peterson [EMAIL PROTECTED] added the comment: On Thu, Jun 5, 2008 at 8:56 PM, Nick Coghlan [EMAIL PROTECTED] wrote: Nick Coghlan [EMAIL PROTECTED] added the comment: The code changes in the patch look pretty good to me (although you probably want to actually use @wraps inside

[issue3042] Add PEP 8 compliant aliases to threading module

2008-06-05 Thread Adam Olsen
Changes by Adam Olsen [EMAIL PROTECTED]: -- nosy: +Rhamphoryncus ___ Python tracker [EMAIL PROTECTED] http://bugs.python.org/issue3042 ___ ___ Python-bugs-list mailing

[issue3045] Windows online help broken when spaces in TEMP environ

2008-06-05 Thread Peter Whaite
New submission from Peter Whaite [EMAIL PROTECTED]: If the environ vars TEMP or TMP contain spaces on w32 the on-line help will not work. e.g. help('or') gives the message The system cannot find the file specified. This is because pydoc.tempfilepager sets filename=tempfile.mktemp() which