[issue7946] Convoy effect with I/O bound threads and New GIL

2010-04-15 Thread Charles-Francois Natali
Charles-Francois Natali neolo...@free.fr added the comment: Please disregard my remark on COND_TIMED_WAIT not updating timeout_result, it's wrong (it's really a macro, not a function...) -- ___ Python tracker rep...@bugs.python.org

[issue8408] need console/pager module

2010-04-15 Thread anatoly techtonik
New submission from anatoly techtonik techto...@gmail.com: Many many Python tools have duplicating code related to getting console properties like width and height to provide pagination and cute progress bars. While the issue seems minor, making such features work crossplatform way requires

[issue8326] Cannot import name SemLock on Ubuntu lucid

2010-04-15 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: As an aside, I don't really understand why the sem_open check is failing on the build machine. 'man sem_overview' says: On a system with Linux 2.6 and a glibc that provides the NPTL threading implementation, a complete implementation of

[issue8406] Make some setup.py paths exclude-able

2010-04-15 Thread Ned Deily
Ned Deily n...@acm.org added the comment: I think this is essentially a duplicate of Issue7713. (Also there doesn't seem to be an attached.) -- nosy: +ned.deily ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8406

[issue5651] OS X Installer: add checks to ensure proper Tcl configuration during build

2010-04-15 Thread Ned Deily
Changes by Ned Deily n...@acm.org: -- assignee: - ronaldoussoren components: +Macintosh versions: +Python 3.2 -Python 3.0 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5651 ___

[issue5651] OS X Installer: add checks to ensure proper Tk configuration during build

2010-04-15 Thread Ned Deily
Changes by Ned Deily n...@acm.org: -- title: OS X Installer: add checks to ensure proper Tcl configuration during build - OS X Installer: add checks to ensure proper Tk configuration during build ___ Python tracker rep...@bugs.python.org

[issue8408] need console/pager module

2010-04-15 Thread anatoly techtonik
anatoly techtonik techto...@gmail.com added the comment: How to get console width: http://stackoverflow.com/questions/566746/how-to-get-console-window-width-in-python http://code.activestate.com/recipes/440694-determine-size-of-console-window-on-windows/ PDCurses may contain some public domain

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread Julian Scheid
Julian Scheid julian...@googlemail.com added the comment: Having this in 2.6/2.7 would be great. I don't think the ELLIPSIS workaround suggested by Barry works, have you actually tried it? Below is an example where ELLIPSIS doesn't seem to help (run in 2.6.5). I have also tried ...Error:

[issue8406] Make some setup.py paths exclude-able

2010-04-15 Thread Skip Montanaro
Skip Montanaro s...@pobox.com added the comment: Let's try this again. -- keywords: +patch Added file: http://bugs.python.org/file16930/setup.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8406

[issue8406] Make some setup.py paths exclude-able

2010-04-15 Thread Skip Montanaro
Skip Montanaro s...@pobox.com added the comment: The patches referenced in issue7713 just unconditionally delete certain directories from the search path(s). This patch (now attached) allows the user to control that. I presume, for instance, if the MacPorts folks don't want /usr/X11/... in

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread Lennart Regebro
Lennart Regebro rege...@gmail.com added the comment: The ellipsis doesn't work, because when you have an ellipsis at the beginning of the message, doctest will not understand that it's supposed to be an Exception, so it doesn't even try to match exceptions, and it will therefore always fail.

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread Julian Scheid
Julian Scheid julian...@googlemail.com added the comment: Here's a better example that you can cut and paste. import optparse def foo(): foo() #doctest: +ELLIPSIS Traceback (most recent call last): . . . ...OptionError: option bar: foo raise

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread Julian Scheid
Julian Scheid julian...@googlemail.com added the comment: Ah, right... so there is no easy workaround at present? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7490 ___

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread Lennart Regebro
Lennart Regebro rege...@gmail.com added the comment: Sure: Catch the exception in the test, and fail if it isn't catched. try: ... do_something_that_raises_exception() ... raise Assertionerror(Exception Blah was not raised) ... except Blah: ... pass Ugly, yes, but easy. To make it

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread Julian Scheid
Julian Scheid julian...@googlemail.com added the comment: Thank you for the suggestion but in my mind that's not a viable workaround, and not just because of uglyness: I'm using doctest to validate code examples, which are included in the documentation and are meant to be educational. If

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread Julian Scheid
Julian Scheid julian...@googlemail.com added the comment: Hmm, wait. Here's a variation of your suggestion that works OK-ish even as an example: try: ...# ... code that fails ... ... except mypkg.MyException, e: ...print(str(e)) Expected error message. This works because it omits

[issue850728] Semaphore.acquire() timeout parameter

2010-04-15 Thread Andrew Svetlov
Changes by Andrew Svetlov andrew.svet...@gmail.com: -- nosy: +asvetlov ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue850728 ___ ___

[issue5419] urllib.request.open(someURL).read() returns a bytes object so writing it requires binary mode

2010-04-15 Thread Daniel Haertle
Daniel Haertle haer...@uni-bonn.de added the comment: I got struck by the same feature. In addition, currently the docs are wrong in the examples (at http://docs.python.org/dev/py3k/library/urllib.request.html#examples the output of f.read() is a string instead of bytes). There I propose the

[issue8354] siginterrupt with flag=False is reset when signal received

2010-04-15 Thread Ezio Melotti
Changes by Ezio Melotti ezio.melo...@gmail.com: -- keywords: +needs review priority: - normal stage: - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8354 ___

[issue4079] new urllib2.Request 'timeout' attribute needs to have a default

2010-04-15 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Senthil, Facundo, is there a reason this bug shouldn't be fixed, or are we just waiting for someone to come up with a patch? I'm assuming the latter and setting it to languishing, but maybe this will wake somebody up who is interested

[issue5419] urllib.request.open(someURL).read() returns a bytes object so writing it requires binary mode

2010-04-15 Thread Senthil Kumaran
Changes by Senthil Kumaran orsent...@gmail.com: -- assignee: georg.brandl - orsenthil nosy: +orsenthil resolution: - accepted ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5419 ___

[issue5419] urllib.request.open(someURL).read() returns a bytes object so writing it requires binary mode

2010-04-15 Thread Senthil Kumaran
Senthil Kumaran orsent...@gmail.com added the comment: Yeah, there a example in the tutorial that was changed recently along similar lines suggested. (http://docs.python.org/dev/py3k/tutorial/stdlib.html#internet-access) The other examples got to be changed too. --

[issue8406] Make some setup.py paths exclude-able

2010-04-15 Thread Ned Deily
Ned Deily n...@acm.org added the comment: Without testing it, I'd guess the patch wouldn't hurt but it also wouldn't affect the OS X installer build as the installer script builds a local copy of Sleepycat db4 (since none is included in OS X) and supplies it as an additional local

[issue8354] siginterrupt with flag=False is reset when signal received

2010-04-15 Thread Andrew Bennetts
Andrew Bennetts s...@users.sourceforge.net added the comment: Your patches look good to me. (They don't fix platforms without sigaction, but as you say they probably don't have siginterrupt, and even if they do they will still have an unfixable race.) What's the next step? I can't see an

[issue8354] siginterrupt with flag=False is reset when signal received

2010-04-15 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Will the modified test fail on platforms that don't define HAVE_SIGACTION? -- nosy: +r.david.murray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8354

[issue8406] Make some setup.py paths exclude-able

2010-04-15 Thread Ronald Oussoren
Ronald Oussoren ronaldousso...@mac.com added the comment: Ned: the patch does have a (positive) effect when building the OSX installer: the build-installer script creates private builds of a number of libraries, but setup.py can detect other libraries (such as libintl) as well and we don't

[issue8354] siginterrupt with flag=False is reset when signal received

2010-04-15 Thread Charles-Francois Natali
Charles-Francois Natali neolo...@free.fr added the comment: Will the modified test fail on platforms that don't define HAVE_SIGACTION? Well, in theory, if the system has siginterrupt but not sigaction, it will fail. But as said, I don't think it's possible, see man siginterrupt: This

[issue8354] siginterrupt with flag=False is reset when signal received

2010-04-15 Thread Andrew Bennetts
Andrew Bennetts s...@users.sourceforge.net added the comment: Are there any platforms that define HAVE_SIGINTERRUPT but that do not define HAVE_SIGACTION? If there are, then yes I expect they would fail that test. It would be a shame to delay this fix just because it doesn't fix all

[issue8354] siginterrupt with flag=False is reset when signal received

2010-04-15 Thread Andrew Bennetts
Andrew Bennetts s...@users.sourceforge.net added the comment: FWIW, comparing the change history sections of http://www.opengroup.org/onlinepubs/95399/functions/siginterrupt.html and http://www.opengroup.org/onlinepubs/95399/functions/sigaction.html suggests that sigaction predates

[issue8407] expose signalfd(2) and sigprocmask(2) in the signal module

2010-04-15 Thread Andrew Bennetts
Changes by Andrew Bennetts s...@users.sourceforge.net: -- nosy: +spiv ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8407 ___ ___ Python-bugs-list

[issue8407] expose signalfd(2) and sigprocmask(2) in the signal module

2010-04-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: I'm with Martin, better to target 3.2 IMO. Does signalfd really bring something compared to set_wakeup_fd()? The one big difference I can see is that set_wakeup_fd() doesn't transmit the signal number, but this could be fixed if desired (instead

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread Nick Coghlan
Nick Coghlan ncogh...@gmail.com added the comment: The corner case I was talking about was the one where you actually *want* the old, more restrictive behaviour (i.e. you specifically want to receive 'x.y.Exception' and receiving 'a.b.Exception' instead should fail), but still want to ignore

[issue8354] siginterrupt with flag=False is reset when signal received

2010-04-15 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Yes, my question was directed at finding out if there were any platforms on which we'd have to add an additional skip (which would mean refactoring that test into two tests). But if the buildbots are all happy after it is applied we

[issue8354] siginterrupt with flag=False is reset when signal received

2010-04-15 Thread Charles-Francois Natali
Charles-Francois Natali neolo...@free.fr added the comment: Well, I just think that the probability of having siginterrupt without sigaction is far less than having a Unix system without siginterrupt (which the current test_signal assumes). Or just drop the patch for the test, it honestly

[issue8354] siginterrupt with flag=False is reset when signal received

2010-04-15 Thread Jean-Paul Calderone
Jean-Paul Calderone exar...@twistedmatrix.com added the comment: Will the modified test fail on platforms that don't define HAVE_SIGACTION? Only if they also have siginterrupt, which seems unlikely (as neologix explained). The implemented behavior on such platforms is unmodified from

[issue8299] Improve GIL in 2.7

2010-04-15 Thread Kristján Valur Jónsson
Kristján Valur Jónsson krist...@ccpgames.com added the comment: Here is yet another point: if _POSIX_SEMAPHORES is defined, thread_pthread.h is designed to use the (fair) semaphore. If it is not present, or HAVE_BROKEN_POSIX_SEMAPHORES defined, the semaphore is supposed to be emulated using a

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: I think this one is worth making an exception for, since it would mean that a project could have 3.x doctests that also work with 2.7, whereas if we leave it out of 2.7 the doctests have to stay in 2.x format even if the project has (at

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread Lennart Regebro
Lennart Regebro rege...@gmail.com added the comment: It's not possible for 2to3 to reformat exceptions, as the formatting would need to go from TheException to themodule.TheException, and there is no way to figure out the module name... -- ___

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread Nick Coghlan
Nick Coghlan ncogh...@gmail.com added the comment: With a little more thought, I'm actually keen on including it as well (although the docs still need a bit more tweaking). The 2.x/3.x compatibility point is a good one. If Benjamin OKs it, I'll include this in the list of things I want to get

[issue8299] Improve GIL in 2.7

2010-04-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: if _POSIX_SEMAPHORES is defined, thread_pthread.h is designed to use the (fair) semaphore. If it is not present, or HAVE_BROKEN_POSIX_SEMAPHORES defined, the semaphore is supposed to be emulated using a condition variable. Now, I don't have

[issue8409] gettext should honor $LOCPATH environment variable

2010-04-15 Thread Barry A. Warsaw
New submission from Barry A. Warsaw ba...@python.org: LOCPATH is an environment variable recognized by locale(1) http://man.he.net/?topic=localesection=all gettext.find() should probably consult $LOCPATH and use that for localedir if the argument is not given. -- assignee: barry

[issue8409] gettext should honor $LOCPATH environment variable

2010-04-15 Thread Barry A. Warsaw
Changes by Barry A. Warsaw ba...@python.org: -- versions: -Python 2.7, Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8409 ___ ___

[issue8409] gettext should honor $LOCPATH environment variable

2010-04-15 Thread Barry A. Warsaw
Changes by Barry A. Warsaw ba...@python.org: -- versions: +Python 2.7, Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8409 ___ ___

[issue8406] Make some setup.py paths exclude-able

2010-04-15 Thread Skip Montanaro
Skip Montanaro s...@pobox.com added the comment: Ronald To be honest I'd must rather remove /opt/local and /sw entirely Ronald from setup.py and add new configure flags to specify the Ronald location of a number of libraries (e.g. 'configure Ronald --with-sleepycat-db=/opt/local').

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: @Lennart: no, in that direction (2.7 to 3.x) there's less of a problem. You leave the module name off in the doctest, and have 2to3 add the IGNORE_EXCEPTION_DETAIL to the doctest during translation. I was looking at the farther future

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread Lennart Regebro
Lennart Regebro rege...@gmail.com added the comment: Sure, but +IGNORE_EXCEPTION_DETAIL will only work on Python 3.2+, so 2to3 can't solve the issue. It can only help once 3.2 does the actual solving. ;) 3to2 could simply remove the module name from exceptions in the output. You don't need to

[issue8299] Improve GIL in 2.7

2010-04-15 Thread Kristján Valur Jónsson
Kristján Valur Jónsson krist...@ccpgames.com added the comment: Oh dear. I was assuming that the mutex+condition variable were the actual implementation mostly in use on pthreads. This is because of David's GIL open talk at pycon, where we were looking at the source and bickering about the

[issue8299] Improve GIL in 2.7

2010-04-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: However, I just asked a colleague with a os X to compile python 2.7 and _POSIX_SEMAPHORES isn't defined, and so, it is running using the emulation. Why, I wonder? Isn't it defined in unistd.h? Perhaps a bad combination of defines. Has he

[issue2987] RFC2732 support for urlparse (IPv6 addresses)

2010-04-15 Thread Senthil Kumaran
Senthil Kumaran orsent...@gmail.com added the comment: Final patch with inclusion of detecting invalid urls at netloc and hostname level, tests and NEWS entry. -- Added file: http://bugs.python.org/file16931/issue2987-final.patch ___ Python tracker

[issue850728] Semaphore.acquire() timeout parameter

2010-04-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: 2.7 is in (mostly) feature freeze mode, so I'm retargetting this to 3.2. (yes, this issue is very old; sorry) I will try to include it (or a variant thereof; the non-blocking + timeout combination doesn't make much sense, so I plan to forbid it)

[issue8299] Improve GIL in 2.7

2010-04-15 Thread Kristján Valur Jónsson
Kristján Valur Jónsson krist...@ccpgames.com added the comment: Yes, we put #error in both places (defining and undefining USE_SEMAPHORES). The colleague in question is Christian Tismer, he is unlikely to have gotten it wrong. I am also curious why David Beazley kept talking about the binary

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: By that logic, 2to3 can't solve anything. I don't think there's any question that this patch should be applied to 3.2. 3.1 might be an issue as it is a new feature, but maybe we can claim it is a bug fix :) As for 3to2, like I said I

[issue8299] Improve GIL in 2.7

2010-04-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Yes, we put #error in both places (defining and undefining USE_SEMAPHORES). The colleague in question is Christian Tismer, he is unlikely to have gotten it wrong. Ok, so can you or Christian open an issue about it? We should try to fix it.

[issue7384] curses crash on FreeBSD

2010-04-15 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: I'm looking at this again, after installing FreeBSD 8.0/amd64 in a VM. I've reduced Lib/test/test_curses.py to the following 9 lines: import rlcompleter import curses f = open('mytempfile', 'w+b') stdscr = curses.initscr() stdscr.putwin(f)

[issue8299] Improve GIL in 2.7

2010-04-15 Thread Kristján Valur Jónsson
Kristján Valur Jónsson krist...@ccpgames.com added the comment: You do realize, that if we enable the USE_SEMAPHORE, we get the GIL behaviour as seen on windows and with my ROUNDROBIN_GIL implementation, right? Also, at the GIL open space talk on PyCon, David did show us the emulation source

[issue8299] Improve GIL in 2.7

2010-04-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: You do realize, that if we enable the USE_SEMAPHORE, we get the GIL behaviour as seen on windows and with my ROUNDROBIN_GIL implementation, right? I haven't studied this argument, but I don't see how that contradicts anything. The main issue

[issue8299] Improve GIL in 2.7

2010-04-15 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: My understanding is that David noticed the problem originally on MacOS. If the emulation is indeed being used on that platform (and a little googling indicates the MacOS posix semaphore implementation is considered at least slightly

[issue8299] Improve GIL in 2.7

2010-04-15 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Also note that his results were much worse on MacOS than anyone was seeing on Linux, which may support this theory :) -- ___ Python tracker rep...@bugs.python.org

[issue8299] Improve GIL in 2.7

2010-04-15 Thread David Beazley
David Beazley d...@dabeaz.com added the comment: I hope everyone realizes that all of this bike-shedding about emulated semaphores versus real semaphores is mostly a non-issue. For one thing, go look at how a real semaphore is implemented by reading the source code to pthreads or some other

[issue5419] urllib.request.open(someURL).read() returns a bytes object so writing it requires binary mode

2010-04-15 Thread Senthil Kumaran
Senthil Kumaran orsent...@gmail.com added the comment: Fixed in revision 80092 and merged into release31-maint in revision 80093. I am marking this as fixed and closed. If there are any similar issues at other places, we will address them as separate bugs. -- resolution: accepted -

[issue8299] Improve GIL in 2.7

2010-04-15 Thread Kristján Valur Jónsson
Kristján Valur Jónsson krist...@ccpgames.com added the comment: David, I urge you to reconsider: The emulated semaphore is broken because it is unfair. It is clearly a programming error, born out of naivete about how to implement such primitives. Proper semaphores therefore cannot be

[issue8299] Improve GIL in 2.7

2010-04-15 Thread Kristján Valur Jónsson
Kristján Valur Jónsson krist...@ccpgames.com added the comment: Googling a bit gave me this: http://lists.apple.com/archives/darwin-kernel/2005/Dec/msg00022.html It would appear that mac os X was at least lacking full posix semaphore support in 2005. --

[issue8279] python-gdb PyListTests fail

2010-04-15 Thread Dave Malcolm
Dave Malcolm dmalc...@redhat.com added the comment: New version of patch attached All tests continue to pass for me. I believe this will fix the py-list, py-locals, py-print commands and their respective tests on Ubuntu; I expect py-up/py-down to still fail due to missing gdb.Frame.select

[issue4453] MSI installer shows error message if Compile .py files to bytecode option is selected

2010-04-15 Thread Aaron Thomas
Aaron Thomas aaron.tho...@gmail.com added the comment: I can verify this will all versions of Windows 7, and the versions of python 32 and 64 bit. I install this at my work to many machines, and every one of them crashes when trying to 'compile py scripts to bytecode' during install. I have

[issue3823] ssl.wrap_socket() is incompatible with servers that drop privileges, due to keyfile requirement

2010-04-15 Thread Giampaolo Rodola'
Giampaolo Rodola' billiej...@users.sourceforge.net added the comment: Any update about this issue? This should be marked as high priority, imho. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue3823

[issue8354] siginterrupt with flag=False is reset when signal received

2010-04-15 Thread Charles-Francois Natali
Charles-Francois Natali neolo...@free.fr added the comment: * There seems to be no good reason to special case SIGCHLD in signal_handler. The comment about infinite recursion has no obvious interpretation to me. Fortunately, this is irrelevant on platforms with sigaction, because the

[issue2090] __import__ with fromlist=[''] causes double initialization of modules

2010-04-15 Thread George Sakkis
George Sakkis george.sak...@gmail.com added the comment: Just bitten by this (through a 3rd party library that uses this pattern) and I'm wondering why it was closed as invalid. Passing a non-empty fromlist string also imports the tail module but without the side effect of double import, so

[issue8406] Make some setup.py paths exclude-able

2010-04-15 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com: -- nosy: +Arfrever ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8406 ___

[issue6916] Remove deprecated items from asynchat

2010-04-15 Thread Giampaolo Rodola'
Changes by Giampaolo Rodola' billiej...@users.sourceforge.net: -- nosy: +giampaolo.rodola ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6916 ___

[issue8405] Improve test_os._kill (failing on slow machines)

2010-04-15 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: I like this version of the patch better. Is there any reason not to drop the initial sleep(0.5) and loop 10 times instead? Any place we can cut down the sleeps so the test suite runs faster on fast machines is good. As someone else

[issue5091] Segfault in PyObject_Malloc(), address out of bounds

2010-04-15 Thread Charles-Francois Natali
Charles-Francois Natali neolo...@free.fr added the comment: It was a long time ago, but: - I think the interpreter will never be able to catch all memory allocation errors, since because of overcommitting (which Linux does), you can very well get a segmentation fault even if the memory

[issue8410] Fix emulated lock to be 'fair'

2010-04-15 Thread Kristján Valur Jónsson
New submission from Kristján Valur Jónsson krist...@ccpgames.com: On pthreads plaforms, if the posix_sem functions aren't available (when _POSIX_SEMAPHORES isn't defined), the python lock is implemented with a mutex and a condition variable. This appears to be the case on Mac OS X, for

[issue8406] Make some setup.py paths exclude-able

2010-04-15 Thread Ned Deily
Ned Deily n...@acm.org added the comment: Ronald, as far as I can see, the patch as it stands only addresses dbm so more work is needed to address all the other cases, the ones that actually matter. Issue7713 describes a more serious, general problem because a number of other builders /

[issue8410] Fix emulated lock to be 'fair'

2010-04-15 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: On pthreads plaforms, if the posix_sem functions aren't available (when _POSIX_SEMAPHORES isn't defined), the python lock is implemented with a mutex and a condition variable. This appears to be the case on Mac OS X, for example. The

[issue8406] Make some setup.py paths exclude-able

2010-04-15 Thread Ned Deily
Ned Deily n...@acm.org added the comment: Skip, I saw David's chroot remark but I'm having a hard time envisioning how one could use that as a practical matter to build an OS X framework without some *serious* changes to the current configure(s), Makefile(s), and installer script. --

[issue8411] Improve condition variable emulation on NT

2010-04-15 Thread Kristján Valur Jónsson
New submission from Kristján Valur Jónsson krist...@ccpgames.com: As per Antoine's suggestion, here is a patch to improve condition variable emulation on windows. By using the windows Semaphore (which hasn't always been available) all of the problems in emulating condition variables using

[issue8408] need console/pager module

2010-04-15 Thread Benjamin Peterson
Benjamin Peterson benja...@python.org added the comment: Please propose on python-ideas before making a bug. -- nosy: +benjamin.peterson resolution: - rejected status: open - closed ___ Python tracker rep...@bugs.python.org

[issue7490] IGNORE_EXCEPTION_DETAIL should ignore the module name

2010-04-15 Thread Benjamin Peterson
Benjamin Peterson benja...@python.org added the comment: 2010/4/15 Nick Coghlan rep...@bugs.python.org: Nick Coghlan ncogh...@gmail.com added the comment: With a little more thought, I'm actually keen on including it as well (although the docs still need a bit more tweaking). The 2.x/3.x

[issue8406] Make some setup.py paths exclude-able

2010-04-15 Thread Ned Deily
Ned Deily n...@acm.org added the comment: Sorry, Ronald, of course that's what you were suggesting with the proposed configure --with options. +1 on that. I'd just want to ensure that any solution addresses any needs in Issue7713, too. Something like that should. There are probably other

[issue2987] RFC2732 support for urlparse (IPv6 addresses)

2010-04-15 Thread Benjamin Peterson
Benjamin Peterson benja...@python.org added the comment: This is ok with me. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2987 ___ ___

[issue7384] curses crash on FreeBSD

2010-04-15 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: Here's the top of the backtrace. (Thanks asmodai for helping me out with working out how to build a FreeBSD system ncurses with debugging information.) #0 0x000801460714 in cannot_delete (win=0x80116b1d0) at

[issue8409] gettext should honor $LOCPATH environment variable

2010-04-15 Thread Roumen Petrov
Roumen Petrov bugtr...@roumenpetrov.info added the comment: LOCPATH is not used by GNU gettext. /usr/share/locale/XX/... - message translation files (GNU gettext) /usr/lib/locale/xx_XX*/ - locale (GNU libc) -- nosy: +rpetrov ___ Python tracker

[issue8299] Improve GIL in 2.7

2010-04-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Googling a bit gave me this: http://lists.apple.com/archives/darwin-kernel/2005/Dec/msg00022.html It would appear that mac os X was at least lacking full posix semaphore support in 2005. Hmm. OS X really sucks. --

[issue8408] need console/pager module

2010-04-15 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- nosy: +merwok ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8408 ___ ___ Python-bugs-list mailing

[issue2090] __import__ with fromlist=[''] causes double initialization of modules

2010-04-15 Thread Brett Cannon
Brett Cannon br...@python.org added the comment: If you want a justification, think of it as undefined behavior. When you use an empty string in fromlist you are essentially simulating ``from pkg import`` which makes absolutely no sense, so no one has cared enough to try to fix this. It's

[issue2090] __import__ with fromlist=[''] causes double initialization of modules

2010-04-15 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: I concur with Brett. For the most part, we don't care about implementation artifacts and undefined behaviors (as long as it doesn't segfault). -- nosy: +rhettinger ___ Python

[issue7384] curses crash on FreeBSD

2010-04-15 Thread A.M. Kuchling
A.M. Kuchling li...@amk.ca added the comment: Could I get a login on the buildbot to make a fix? I bet the problem is with the stdscr object. PyCurses_InitScr() does 'return (PyObject *)PyCursesWindow_New(stdscr);'. PyCursesWindow_Dealloc() does: if (wo-win != stdscr) delwin(wo-win); I bet

[issue4111] Add Systemtap/DTrace probes

2010-04-15 Thread Garen
Changes by Garen garen.par...@gmail.com: -- nosy: +Garen ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4111 ___ ___ Python-bugs-list mailing list

[issue2090] __import__ with fromlist=[''] causes double initialization of modules

2010-04-15 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Since ``from pkg import`` makes no sense, would it be okay if __import__ with an empty fromlist or slashes raised an error? -- nosy: +merwok ___ Python tracker rep...@bugs.python.org

[issue7384] curses crash on FreeBSD

2010-04-15 Thread A.M. Kuchling
A.M. Kuchling li...@amk.ca added the comment: Here's a possible patch; it at least doesn't seem to break the module on MacOS, though MacOS doesn't crash with the current code either. -- keywords: +patch Added file: http://bugs.python.org/file16935/freebsd-curses.diff

[issue7384] curses crash on FreeBSD

2010-04-15 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: Could I get a login on the buildbot to make a fix? I think David Bolen (db3l) is the maintainer. David? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7384

[issue7384] curses crash on FreeBSD

2010-04-15 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: Here's a possible patch Thanks. I'll give it a try on my FreeBSD VM and report back. BTW, did you mean to include the threading change in that patch? -- ___ Python tracker rep...@bugs.python.org

[issue2090] __import__ with fromlist=

2010-04-15 Thread Brett Cannon
Brett Cannon br...@python.org added the comment: On Thu, Apr 15, 2010 at 14:56, Éric Araujo rep...@bugs.python.org wrote: That's fine with me if someone wrote a patch that did that. -- title: __import__ with fromlist=[''] causes double initialization of modules - __import__ with

[issue7384] curses crash on FreeBSD

2010-04-15 Thread Jeroen Ruigrok van der Werven
Changes by Jeroen Ruigrok van der Werven asmo...@in-nomine.org: -- nosy: +asmodai ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7384 ___ ___

[issue7384] curses crash on FreeBSD

2010-04-15 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: With that patch, I'm still getting the core dump (with the traceback looking pretty much as it did before). When I traced through this with gdb, I didn't see stdscr getting set to 0 at any point. Unless I missed any, the only curses

[issue2090] __import__ with fromlist=

2010-04-15 Thread Brett Cannon
Brett Cannon br...@python.org added the comment: Although now that I think about it, there is a slightly sticky situation of someone using '' or some name with a slash for a key in __dict__. The usage in fromlist would then be reasonable, but the semantics would be somewhat odd as fromlist is

[issue2090] __import__ with fromlist=

2010-04-15 Thread George Sakkis
George Sakkis george.sak...@gmail.com added the comment: When you use an empty string in fromlist you are essentially simulating ``from pkg import`` which makes absolutely no sense, so no one has cared enough to try to fix this. ``from pkg import __bogus__, 123, @$%`` doesn't make sense

[issue2090] __import__ with fromlist=

2010-04-15 Thread George Sakkis
George Sakkis george.sak...@gmail.com added the comment: More fun findings: dots are special-cased too, but only if they don't appear consecutively (!); ~$ cat pkg/__init__.py print __name__ ~$ python -c __import__('pkg', fromlist=['.']) pkg pkg.. ~$ python -c __import__('pkg',

[issue8410] Fix emulated lock to be 'fair'

2010-04-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: I don't understand why you claim your patched version is fair. As far as I can tell, if you have three threads A, B and C all routinely trying to take this lock, your implementation can perfectly well bounce between A and B without ever giving

[issue8394] ctypes.dlopen() doesn't support surrogates

2010-04-15 Thread STINNER Victor
STINNER Victor victor.stin...@haypocalc.com added the comment: amaury Your patch should handle the case when name2 is a bytearray. Ok, fixed. I also tested None: Python does segfault :-) New patch rejects None value. -- Added file:

  1   2   >