[issue1086642] Compile of _socket fails on IRIX with 2.4

2010-04-03 Thread Georg Brandl
Changes by Georg Brandl : -- status: pending -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:/

[issue1542308] Nested finally in generators don't follow PEP 342

2010-04-03 Thread Georg Brandl
Changes by Georg Brandl : -- status: open -> languishing ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http

[issue1518617] PEP101/102 out of date

2010-04-03 Thread Georg Brandl
Georg Brandl added the comment: PEP 101 is up to date. I don't know about 102, it should probably be withdrawn, as 101 has all the info. -- status: open -> closed ___ Python tracker ___

[issue1944] Documentation for PyUnicode_AsString (et al.) missing.

2010-04-03 Thread Georg Brandl
Changes by Georg Brandl : -- assignee: -> georg.brandl ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://m

[issue8297] AttributeError message text should include module name

2010-04-03 Thread Ray.Allen
Ray.Allen added the comment: Yes, I agree with this feature request. And also the super(Class, obj) call should return a reasonable AttributeError message when the requested attribute is not found in one of Class's base classes, not just 'super' object has no attribute 'xxx'. -- nosy

[issue8227] Fix C API documentation: Argument parsing

2010-04-03 Thread STINNER Victor
STINNER Victor added the comment: Commited: r79654 (trunk), r79655 (2.7), blocked in py3k and 3.1 (see #8215 and #2322) -- resolution: accepted -> fixed status: open -> closed ___ Python tracker __

[issue1222585] C++ compilation support for distutils

2010-04-03 Thread Tarek Ziadé
Tarek Ziadé added the comment: LDCXXSHARED added in r79652 and r79657. Now we can work on distutils2 side -- priority: high -> normal versions: +Python 3.3 ___ Python tracker ___

[issue8297] AttributeError message text should include module name

2010-04-03 Thread Ray.Allen
Ray.Allen added the comment: In fact, there are only three types of tp_getattro functions: 1.For type objects, it is type_getattro(), in case of AttributeError, this function give the message format: type object %(type)s has no attribute %(attr)s 2.For super objects, it is supe

[issue1501108] Add write buffering to gzip

2010-04-03 Thread Charles-Francois Natali
Charles-Francois Natali added the comment: In the test script, simply changing def emit(f, data=snips): for datum in data: f.write(datum) to def gemit(f, data=snips): datas = ''.join(data) f.write(datas) improves direct gzip performance from [1.1799781322479248, 0.50524

[issue8299] Improve GIL in 2.7

2010-04-03 Thread Kristján Valur Jónsson
New submission from Kristján Valur Jónsson : This patch does several things: 1) Creates a separate lock type PyThread_type_gil and locking functions for that. This allows tweaking of the GIL without affecting regular lock behaviour. 2) Creates a uniform implementation of the GIL on windows/pthr

[issue8299] Improve GIL in 2.7

2010-04-03 Thread Martin v . Löwis
Martin v. Löwis added the comment: I think this is too late for 2.7. 2.7b1 will be released RSN, and we should not implement such a change after the first beta release. -- nosy: +loewis ___ Python tracker

[issue7559] TestLoader.loadTestsFromName swallows import errors

2010-04-03 Thread Chris Jerdonek
Chris Jerdonek added the comment: > I think in both cases the error text should state not just what module was > being imported but also what module was being imported from FYI, I filed the following report partly in response to some of the comments I made above: http://bugs.python.org/issue

[issue8279] python-gdb PyListTests fail

2010-04-03 Thread Martin v . Löwis
Martin v. Löwis added the comment: I still get failures, after applying file16727. I'm attaching the complete regrtest output. -- versions: +Python 2.7 Added file: http://bugs.python.org/file16745/failures ___ Python tracker

[issue8294] Allow Fraction constructor to accept float and decimal instances directly.

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: Merged to py3k in r79670. -- stage: -> committed/rejected status: open -> closed ___ Python tracker ___ ___

[issue8271] str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

2010-04-03 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Ezio Melotti wrote: > > Ezio Melotti added the comment: > > Here's a new patch. Should be complete but I want to test it some more before > committing. > I decided to follow RFC 3629, putting 0 instead of 5/6 for bytes in range > F5-FD (we can always pu

[issue7279] decimal.py: == and != comparisons involving NaNs

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: r79588 and r79589 were merged to py3k in r79668. -- resolution: invalid -> fixed stage: -> committed/rejected status: open -> closed ___ Python tracker ___

[issue1023290] Conversion of longs to bytes and vice-versa.

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: Closing this; it's too late for Python 2.7. -- status: open -> closed versions: -Python 2.7 ___ Python tracker ___

[issue2531] float compared to decimal is silently incorrect.

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: Merged to py3k in r79668. -- resolution: -> fixed status: open -> closed ___ Python tracker ___ ___

[issue2799] Remove _PyUnicode_AsString(), rework _PyUnicode_AsStringAndSize(), add PyUnicode_AsChar()

2010-04-03 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Updating the ticket title to what we actually have in SVN (I had renamed the APIs to mark them as private to the interpreter some time ago). -- title: Remove PyUnicode_AsString(), rework PyUnicode_AsStringAndSize(), add PyUnicode_AsChar() -> Remov

[issue1530559] struct.pack raises TypeError where it used to convert

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: Closing this; a separate feature request should be opened for the idea of adding __index__ awareness to struct.pack in py3k. -- resolution: -> fixed status: open -> closed ___ Python tracker

[issue8300] Allow struct.pack to handle objects with an __index__ method.

2010-04-03 Thread Mark Dickinson
New submission from Mark Dickinson : In Python 2.7, struct.pack with an integer format can handle non-integers that provide an __int__ method (although this *does* raise a DeprecationWarning). Python 2.7a4+ (trunk:79659:79661, Apr 3 2010, 11:28:19) [GCC 4.2.1 (Apple Inc. build 5646) (dot 1)]

[issue8300] Allow struct.pack to handle objects with an __index__ method.

2010-04-03 Thread Mark Dickinson
Changes by Mark Dickinson : -- components: +Extension Modules stage: -> test needed type: -> feature request ___ Python tracker ___ _

[issue1530559] struct.pack raises TypeError where it used to convert

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: I've opened issue 8300 for adding the __index__ handling. -- superseder: -> Allow struct.pack to handle objects with an __index__ method. ___ Python tracker ___

[issue4147] xml.dom.minidom toprettyxml: omit whitespace for text-only elements

2010-04-03 Thread Michel Samia
Michel Samia added the comment: Could you please apply that patch? People are starting to use non-standard libraries to process xml files because of this issue for example this man is using lxml or pyxml: http://ronrothman.com/public/leftbraned/xml-dom-minidom-toprettyxml-and-silly-whitespace/

[issue8299] Improve GIL in 2.7

2010-04-03 Thread David Beazley
David Beazley added the comment: Without looking at this patch, I think it would wise to proceed with caution on incorporating any kind of GIL patch into 2.X. If there is anything to be taken away from my own working studying the GIL, it's that the problem is far more tricky than it looks an

[issue1501108] Add write buffering to gzip

2010-04-03 Thread Lukas Lueg
Lukas Lueg added the comment: agreed -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.o

[issue8299] Improve GIL in 2.7

2010-04-03 Thread Kristján Valur Jónsson
Kristján Valur Jónsson added the comment: Martin: Well, this patch was originally conceived more as a demonstration of the GIL problem and an alternative fix proposal. However, it is possible to configure it so that there is no change from existing functionality, simply by not including thread

[issue8292] Incorrect condition test in platform.py

2010-04-03 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: A.M. Kuchling wrote: > > New submission from A.M. Kuchling : > > While looking at #4440, I grepped for similar problems and found one in > platform.py in the following line: > > if no_os_uname or not filter(None, (system, node, release, version, machine))

[issue8299] Improve GIL in 2.7

2010-04-03 Thread Kristján Valur Jónsson
Kristján Valur Jónsson added the comment: Antoine: Please take a look, the change is really simple, particularly the ROUNDROBIN_GIL variant which fixes the originally observed problem. the GIL is still a lock, implemented using a mutex and a semaphore. It is modified to work exactly as the l

[issue1501108] Add write buffering to gzip

2010-04-03 Thread Antoine Pitrou
Antoine Pitrou added the comment: Additionally, since issue7471 was fixed, you should be able to wrap a GzipFile in a Buffered{Reader,Writer} object for faster buffering. -- resolution: -> out of date status: open -> closed ___ Python tracker

[issue8299] Improve GIL in 2.7

2010-04-03 Thread David Beazley
David Beazley added the comment: I'm not sure where you're getting your information, but the original GIL problem *DEFINITELY* exists on multicore Windows machines. I've had numerous participants try it in training classes and workshops they've all observed severely degraded performance for

[issue8299] Improve GIL in 2.7

2010-04-03 Thread David Beazley
David Beazley added the comment: Just ran the CPU-bound GIL test on my wife's dual core Windows Vista machine. The code runs twice as slow using two threads as it does using no threads (original observed behavior in my GIL talk). -- ___ Python tra

[issue8299] Improve GIL in 2.7

2010-04-03 Thread Antoine Pitrou
Antoine Pitrou added the comment: Kristjan, I agree with Martin, it's probably too late to make such changes for 2.7. Additionally, your "round-robin" scheme only seems round-robin when there are two threads competing. Otherwise, you could have three threads A, B and C, and the GIL bouncing betw

[issue8300] Allow struct.pack to handle objects with an __index__ method.

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: Here's a patch for trunk. It combines the docs and tests from Meador Inge's patch in issue 1530559 with a C-level change to get_pylong in Modules/struct.c. -- keywords: +patch versions: +Python 2.7 Added file: http://bugs.python.org/file16746/struct_i

[issue8300] Allow struct.pack to handle objects with an __index__ method.

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: Adding Meador Inge to nosy. -- nosy: +minge ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue8301] Putting a function in a unittest.TestSuite doesn't work

2010-04-03 Thread Michael Foord
New submission from Michael Foord : Putting functions (rather than TestCase instances) directly in TestSuites was never officially supported but it used to work: >>> from unittest import TestSuite, TestResult >>> def f(): pass ... >>> s = TestSuite() >>> s.addTest(f) >>> s.run(TestResult()) Tr

[issue8302] SkipTest exception in setUpClass or setUpModule is marked as an error rather than a skip

2010-04-03 Thread Michael Foord
New submission from Michael Foord : SkipTest exception in setUpClass or setUpModule is marked as an error rather than a skip. -- assignee: michael.foord messages: 102260 nosy: michael.foord severity: normal stage: needs patch status: open title: SkipTest exception in setUpClass or setUp

[issue1441530] socket read() can cause MemoryError in Windows

2010-04-03 Thread Charles-Francois Natali
Charles-Francois Natali added the comment: $ cat /tmp/test.py import socket SIZE = 10L s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) try: s.recv(SIZE) finally: s.close() $ python /tmp/test.py Traceback (most recent call last): File "/tmp/test.py", line 8, in s.r

[issue1222585] C++ compilation support for distutils

2010-04-03 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis : Removed file: http://bugs.python.org/file16519/python-distutils-C++.patch ___ Python tracker ___ __

[issue8300] Allow struct.pack to handle objects with an __index__ method.

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: That patch was a bit hasty in many respects; here's a better one. For 2.7, the scheme is as follows: when packing a non-integer with an integer format: (1) First __index__ is tried (2) If the __index__ method doesn't exist, or the call to __index__ raises

[issue8300] Allow struct.pack to handle objects with an __index__ method.

2010-04-03 Thread Mark Dickinson
Changes by Mark Dickinson : -- priority: -> normal stage: test needed -> patch review ___ Python tracker ___ ___ Python-bugs-list mail

[issue8300] Allow struct.pack to handle objects with an __index__ method.

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: Committed this patch to trunk in r79674. Will forward port to py3k. -- ___ Python tracker ___ ___ P

[issue4256] optparse: provide a simple way to get a programmatically useful list of options

2010-04-03 Thread Andy Buckley
Andy Buckley added the comment: That sort of idea, yes: just a wild thought, but it would be really nice if this was available so that in combination with a standard bash/zsh function, getting basic automatic command completion for scripts built with optparse (and any other implementer of suc

[issue8271] str.decode('utf8', 'replace') -- conformance with Unicode 5.2.0

2010-04-03 Thread STINNER Victor
STINNER Victor added the comment: > I also found out that, according to RFC 3629, surrogates > are considered invalid and they can't be encoded/decoded, > but the UTF-8 codec actually does it. Python2 does, but Python3 raises an error. Python 2.7a4+ (trunk:79675, Apr 3 2010, 16:11:36) >>> u

[issue8215] getargs.c in Python3 contains some TODO and the documentation is outdated

2010-04-03 Thread STINNER Victor
STINNER Victor added the comment: The PEP 3118 describes some points about discontigious buffers, but there is no module nor third party libraries supporting them. PIL 1.1.7 (the last version) doesn't support the buffer API (an image can not be "exported" as a buffer, but PIL accepts a buffer

[issue8303] python -m unittest -h and python -m unittest discover -h message slightly incorrect

2010-04-03 Thread Michael Foord
New submission from Michael Foord : The usage messages for unittest from the command line are slightly incorrect. They show: "Usage: unittest [options]" when it should be "Usage: python -m unittest [options]" (or even "python -m unittest discover"). -- assignee: michael.foord messages:

[issue8303] python -m unittest -h and python -m unittest discover -h message slightly incorrect

2010-04-03 Thread Michael Foord
Michael Foord added the comment: In TestProgram.usageExit the command name comes from: self.progName = os.path.basename(argv[0]) For test discovery the usage message is auto-generated by optparse. Probably using sys.argv[0]. -- ___ Python

[issue8304] strftime and Unicode characters

2010-04-03 Thread AndiDog
New submission from AndiDog : There is inconsistent behavior in time.strftime, comparing Python 2.6 and 3.1. In 3.1, non-ASCII Unicode characters seem to get dropped whereas in 2.6 you can keep them using the necessary Unicode-to-UTF8 workaround. This should be fixed if it isn't intended behav

[issue8305] memoview[0] creates an invalid view if ndim != 1

2010-04-03 Thread STINNER Victor
New submission from STINNER Victor : memory_item() function creates a new memoryview object if ndim is different than 1. Example with numpy: from numpy import array y=array([ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]) y.shape = 3,4 view=memoryview(y) view2 = view[0] print

[issue8305] memoview[0] creates an invalid view if ndim != 1

2010-04-03 Thread STINNER Victor
STINNER Victor added the comment: Full example (using numpy) crashing Python: memoryview_crash.py -- Added file: http://bugs.python.org/file16749/memoryview_crash.py ___ Python tracker _

[issue8305] memoview[0] creates an invalid view if ndim != 1

2010-04-03 Thread STINNER Victor
Changes by STINNER Victor : -- components: +Interpreter Core type: -> crash ___ Python tracker ___ ___ Python-bugs-list mailing list U

[issue7723] sqlite only accept buffer() for BLOB objects (input/output)

2010-04-03 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- priority: release blocker -> deferred blocker ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue3928] os.mknod missing on Solaris

2010-04-03 Thread Benjamin Peterson
Benjamin Peterson added the comment: I think this small change can slip in after beta. -- nosy: +benjamin.peterson priority: release blocker -> deferred blocker ___ Python tracker __

[issue7319] Silence DeprecationWarning by default

2010-04-03 Thread Benjamin Peterson
Benjamin Peterson added the comment: Lowering priority. -- priority: release blocker -> critical ___ Python tracker ___ ___ Python-bug

[issue7092] Test suite emits many DeprecationWarnings when -3 is enabled

2010-04-03 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- priority: release blocker -> critical ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubs

[issue7755] copyright clarification for audiotest.au

2010-04-03 Thread Benjamin Peterson
Benjamin Peterson added the comment: Lowering priority. -- nosy: +benjamin.peterson priority: release blocker -> critical ___ Python tracker ___ _

[issue3778] python uninstaller leave registry entries

2010-04-03 Thread Martin v . Löwis
Martin v. Löwis added the comment: I think Installer has features to remove registry keys with no subkeys; we probably would need to declare that we create these keys, and then Installer might remove them automatically. -- ___ Python tracker

[issue8279] python-gdb PyListTests fail

2010-04-03 Thread Dave Malcolm
Dave Malcolm added the comment: It looks like all of the failures were due to gdb.Frame not having a "function" method. I did some digging, and it appears that this attribute may not yet be in the upstream version of gdb. The gdb/python integration was largely implemented by colleagues of mi

[issue7433] MemoryView memory_getbuf causes segfaults, double call to tp_releasebuffer

2010-04-03 Thread STINNER Victor
STINNER Victor added the comment: > I can try to cook up a patch fixing this. Did you wrote something? I don't see any patch attached to this issue :-/ -- nosy: +haypo ___ Python tracker __

[issue8305] memoview[0] creates an invalid view if ndim != 1

2010-04-03 Thread STINNER Victor
STINNER Victor added the comment: According to #2394, the implementation of the new buffer API is not complete. -- nosy: +teoliphant ___ Python tracker ___ __

[issue8279] python-gdb PyListTests fail

2010-04-03 Thread Martin v . Löwis
Martin v. Löwis added the comment: > What is the output of "gdb --version" on this machine? GNU gdb (GDB) 7.0.1-debian This GDB was configured as "x86_64-linux-gnu". The debian package is 7.0.1-2 > $ gdb --batch --eval-command "python print gdb.Frame.function" > --eval-command "python print d

[issue6409] 2to3 -j 4 generates malformed diffs

2010-04-03 Thread STINNER Victor
Changes by STINNER Victor : -- title: 2to3 generates malformed diffs -> 2to3 -j 4 generates malformed diffs ___ Python tracker ___ ___

[issue7696] Improve Memoryview/Buffer documentation

2010-04-03 Thread STINNER Victor
STINNER Victor added the comment: memoryview() function is not documented in library/functions.rst, whereas it's a builtin function. -- ___ Python tracker ___ __

[issue8304] strftime and Unicode characters

2010-04-03 Thread Eric Smith
Changes by Eric Smith : -- nosy: +eric.smith ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue4256] optparse: provide a simple way to get a programmatically useful list of options

2010-04-03 Thread Filip Gruszczyński
Filip Gruszczyński added the comment: I'll take a look at optparse code and try to provide a patch. But first holidays must finish and I must come back to ma usual residence, where I have programming environment. -- ___ Python tracker

[issue8108] test_ftplib fails with OpenSSL 0.9.8m

2010-04-03 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- priority: high -> release blocker ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscrib

[issue8306] ctypes.create_string_buffer should only accept bytes

2010-04-03 Thread Benjamin Peterson
New submission from Benjamin Peterson : These coercions shouldn't be allowed: import ctypes >>> buf = ctypes.create_string_buffer("hi") >>> buf.value b'hi' >>> buf.value = "23" >>> buf.value b'23' -- assignee: theller components: ctypes messages: 102282 nosy: benjamin.peterson, theller

[issue8032] Add gdb7 hooks to make it easier to debug Python

2010-04-03 Thread Benjamin Peterson
Benjamin Peterson added the comment: Could I request that the python-gdb.py script not be put in the top level directory? It's a little annoying to have another executable script starting with "python" when you're trying to test the "python" executable. -- nosy: +benjamin.peterson __

[issue8032] Add gdb7 hooks to make it easier to debug Python

2010-04-03 Thread Martin v . Löwis
Martin v. Löwis added the comment: That is tricky to do. gdb will consider it automatically only if it is called -gdb.py. I agree that there should be a better solution, though. David, is it possible to somehow hook this into .gdbinit, with an arbitrary path? Benjamin, would a .gdbinit in th

[issue8032] Add gdb7 hooks to make it easier to debug Python

2010-04-03 Thread Jeffrey Yasskin
Jeffrey Yasskin added the comment: http://sourceware.org/gdb/current/onlinedocs/gdb/Auto_002dloading.html says "If this file exists and is readable, gdb will evaluate it as a Python script." So maybe it doesn't need to be executable? -- ___ Python

[issue8032] Add gdb7 hooks to make it easier to debug Python

2010-04-03 Thread Benjamin Peterson
Benjamin Peterson added the comment: 2010/4/3 Martin v. Löwis : > Benjamin, would a .gdbinit in the top-level build directory still be annoying? That would be fine with me. -- ___ Python tracker __

[issue8218] Fix typos and phrasing in the Web servers howto

2010-04-03 Thread R. David Murray
R. David Murray added the comment: I do know something about web development, so I did a more extensive edit. I'm not saying I've brought it completely up to date or fixed any inaccuracies, but I did change the tone here and there, tightened up a bunch of the language, clarified a few things

[issue8032] Add gdb7 hooks to make it easier to debug Python

2010-04-03 Thread Martin v . Löwis
Martin v. Löwis added the comment: I have now changed Makefile.pre.in to not install python-gdb.py as a script anymore; this seems to work fine. People will still need to remove there existing python-gdb.py (or make clean) to see this change. -- __

[issue7772] test_py3kwarn fails when running the whole test suite

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: This still seems to be an issue for OS X. With the current trunk (r79716), I get: Mark-Dickinsons-MacBook-Pro:trunk dickinsm$ ./python.exe -3 ./Lib/test/regrtest.py test_macostools test_py3kwarn test_macostools /Users/dickinsm/python/svn/trunk/Lib/importlib/

[issue8299] Improve GIL in 2.7

2010-04-03 Thread Torsten Landschoff
Torsten Landschoff added the comment: Silly question, I know, but why isn't the GIL just implemented as a lock of the host operating system? After all, we want mutual exclusion, I don't see why condition variables are required for this. I have to admin that I did not look at the source, so th

[issue8299] Improve GIL in 2.7

2010-04-03 Thread David Beazley
David Beazley added the comment: It's not a simple mutex because if you did that, you would have performance problems much worse than those described in issue 7946. http://bugs.python.org/issue7946 -- ___ Python tracker

[issue8108] test_ftplib fails with OpenSSL 0.9.8m

2010-04-03 Thread Antoine Pitrou
Antoine Pitrou added the comment: I don't think this should be a release blocker for the beta, although I agree it should be one for the final release (and RCs). By the way, it doesn't affect maintenance branches. -- versions: -Python 2.6, Python 3.1 _

[issue8108] test_ftplib fails with OpenSSL 0.9.8m

2010-04-03 Thread Antoine Pitrou
Antoine Pitrou added the comment: Giampaolo, which call exactly triggers the "error: [Errno 0] Error"? It doesn't seem it can be _sslobj.shutdown itself. -- ___ Python tracker __

[issue8108] test_ftplib fails with OpenSSL 0.9.8m

2010-04-03 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- priority: release blocker -> critical ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubs

[issue8307] test_pep263 failure on OS X

2010-04-03 Thread Mark Dickinson
New submission from Mark Dickinson : I'm seeing a very peculiar test_pep263 failure when doing 'make test' on OS X 10.6.3. It's enough to run test___all__ and test_pep263, in that order: Mark-Dickinsons-MacBook-Pro:trunk dickinsm$ ./python.exe -Wd -3 -E -tt ./Lib/test/regrtest.py test___all__

[issue8307] test_pep263 failure on OS X

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: That should be "NameError" in the last line of the previous message, not "TypeError". -- ___ Python tracker ___ ___

[issue7696] Improve Memoryview/Buffer documentation

2010-04-03 Thread Antoine Pitrou
Antoine Pitrou added the comment: > This is quite obscure because there's no definition of the "buffer > protocol". You can find it at http://www.python.org/dev/peps/pep-3118/#id5 (assuming it is not outdated) > the memoryview.suboffsets attribute is not documented on the "6.10 > memoryview

[issue7696] Improve Memoryview/Buffer documentation

2010-04-03 Thread Antoine Pitrou
Antoine Pitrou added the comment: > memoryview() function is not documented in library/functions.rst You should look more carefully... See http://docs.python.org/dev/library/functions.html#max (I don't know why it doesn't have its own anchor, though) -- ___

[issue8304] strftime and Unicode characters

2010-04-03 Thread Ezio Melotti
Ezio Melotti added the comment: This seems to be fixed now, on both 3.1 and 3.2. Can you try with 3.1.2 and see if it works? What operating system are you using? -- nosy: +ezio.melotti priority: -> normal status: open -> pending versions: -Python 2.6 _

[issue8208] test_issue7820 fails: "name '?' is not defined"

2010-04-03 Thread Ned Deily
Ned Deily added the comment: Duplicated in Issue8307 -- nosy: +mark.dickinson ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue8208] test_issue7820 fails: "name '?' is not defined"

2010-04-03 Thread Ezio Melotti
Changes by Ezio Melotti : -- resolution: -> duplicate stage: -> committed/rejected status: open -> closed ___ Python tracker ___ ___

[issue8307] test_pep263 failure on OS X

2010-04-03 Thread Ezio Melotti
Ezio Melotti added the comment: See also #8208. -- components: +Tests nosy: +ezio.melotti, haypo, l0nwlf, ned.deily priority: -> normal stage: -> needs patch ___ Python tracker ___

[issue8307] test_pep263 failure on OS X

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: After some more digging, it looks as though this is due to the Tkinter import (that ends up happening as a result of test___all__) changing the locale(?), and in particular the meaning of isalpha: Python 2.7a4+ (trunk:79716, Apr 3 2010, 22:06:18) [GCC 4.2.1

[issue8307] test_pep263 failure on OS X

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: > (Is there some way that I can see the locale change more explicitly from > Python?) Found it. :) >>> locale.nl_langinfo(locale.CODESET) 'US-ASCII' [40683 refs] >>> import Tkinter [56953 refs] >>> locale.nl_langinfo(locale.CODESET) 'UTF-8' [56953 refs] ---

[issue8297] AttributeError message text should include module name

2010-04-03 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti priority: -> low stage: -> needs patch ___ Python tracker ___ ___ Python-bugs-list m

[issue8307] test_pep263 failure on OS X

2010-04-03 Thread Ned Deily
Ned Deily added the comment: Or this: Python 2.7a4+ (trunk, Apr 3 2010, 15:18:51) [GCC 4.2.1 (Apple Inc. build 5646) (dot 1)] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> import locale >>> locale.getlocale() (None, None) >>> import Tkinter >>> locale.ge

[issue8307] test_pep263 failure on OS X

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: I realize that the above doesn't really explain why the NameError is occurring: Python's token recognition algorithm, in tok_get in tokenizer.c, uses isalpha, which is locale-aware. In particular, it seems that chr(255) is considered alphabetic in the UTF-8

[issue8307] test_pep263 failure on OS X

2010-04-03 Thread Mark Dickinson
Mark Dickinson added the comment: Ned: yes, that works too. Thanks! -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsub

[issue4256] optparse: provide a simple way to get a programmatically useful list of options

2010-04-03 Thread R. David Murray
R. David Murray added the comment: Please target argparse rather than optparse, or better yet in addition to optparse. And I'm +1 for making it easier to write completion scripts. -- nosy: +bethard, r.david.murray ___ Python tracker

[issue8307] test_pep263 failure on OS X

2010-04-03 Thread Ned Deily
Ned Deily added the comment: For the record, the problem here isn't new to trunk and is not limited to OS X 10.6; it's the test that's new. It's not a problem for py3k where, as expected, the locale is always set and it seems the tokenizer is a little smarter: Python 3.2a0 (py3k, Apr 3 201

[issue8308] raw_bytes.decode('cp932') -- spurious mappings

2010-04-03 Thread John Machin
New submission from John Machin : According to the following references, the bytes 80, A0, FD, FE, and FF are not defined in cp932: http://msdn.microsoft.com/en-au/goglobal/cc305152.aspx http://www.unicode.org/Public/MAPPINGS/VENDORS/MICSFT/WINDOWS/CP932.TXT http://demo.icu-project.org/icu-bin/

[issue8308] raw_bytes.decode('cp932') -- spurious mappings

2010-04-03 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti priority: -> normal stage: -> test needed ___ Python tracker ___ ___ Python-bugs-lis

[issue8307] test_pep263 failure on OS X

2010-04-03 Thread Ned Deily
Ned Deily added the comment: Verified that r79725 fix to tokenizer.c prevents the original test failure. -- ___ Python tracker ___ ___

[issue8304] strftime and Unicode characters

2010-04-03 Thread Ezio Melotti
Ezio Melotti added the comment: Actually the bug seems related to Windows. -- components: +Windows nosy: +brian.curtin status: pending -> open versions: +Python 3.2 ___ Python tracker __

[issue8300] Allow struct.pack to handle objects with an __index__ method.

2010-04-03 Thread Meador Inge
Meador Inge added the comment: I may be missing something subtle, but how can 'PyNumber_Index(v) != NULL' *and* '!PyInt_Check(v) && !PyLong_Check(v)' both be satisfied in the 'get_pylong' mods? It seems to me that 'PyNumber_Index' only returns non-NULL when the object being returned is an 'i

  1   2   >