[issue6071] no longer possible to hash arrays

2009-09-21 Thread Jan Hosang
Jan Hosang added the comment: I tried to implement the new buffer API, but as soon as I add bf_getbuffer/bf_releasebuffer to PyBufferProcs writing an array to a file breaks: f.write(a) TypeError: must be contiguous buffer, not array.array I searched through the file functions, but couldn'

[issue6864] IDLE 2.6.1 locks up on Mac OS 10.6

2009-09-21 Thread Ned Deily
Ned Deily added the comment: I also can verify that the problem is not reproducible using a current trunk (2.7) and the 10.6 Apple Tk 8.5.7. Further testing of this issue with both Apple Tk 8.4.x and ActiveState Tk 8.4.19 on 10.4, 10.5, and 10.6 has been hang-free. It looks like there were

[issue5120] Disabling test_ttk_guionly on mac

2009-09-21 Thread Ned Deily
Ned Deily added the comment: I noticed this while investigating Issue6834. Is this still an open issue for OS X? Could it explain the symptoms in 6834? -- nosy: +ned.deily, ronaldoussoren ___ Python tracker _

[issue5120] Disabling test_ttk_guionly on mac

2009-09-21 Thread Ned Deily
Ned Deily added the comment: Sorry, that should be Issue6864. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue1766304] improve xrange.__contains__

2009-09-21 Thread Mark Dickinson
Mark Dickinson added the comment: Robert, The patch looks good: thank you. Please use C89-style comments (/* ... */). I'd like to see a few more tests covering the various combinations of start less-than/equal-to/greater-than stop, step positive/negative, tested value within/without/at endpo

[issue1766304] improve xrange.__contains__

2009-09-21 Thread Mark Dickinson
Mark Dickinson added the comment: Also, it would be good to add a test or two for non-integers, e.g. to make explicit that the following behaviour hasn't changed: >>> class C: ... def __int__(self): return 3 ... def __index__(self): return 5 ... def __eq__(self, other): return oth

[issue3366] Add gamma function, error functions and other C99 math.h functions to math module

2009-09-21 Thread Mark Dickinson
Mark Dickinson added the comment: New patch for gamma , with some tweaks: - return exact values for integral arguments: gamma(1) through gamma(23) - apply a cheap correction to improve accuracy of exp and pow computations - use a different form of the reflection formula: gamma(x) =

[issue6956] Test creation in unittest.TestProgram should be done in one place

2009-09-21 Thread Michael Foord
New submission from Michael Foord : Requested by Fernando Perez on the Testing in Python mailing list. Test creation in TestProgram is done in both parseArgs and createTests. It would be better if it was only done in createTests so that controlling test creation only required the overloading of

[issue6957] Extension modules fail to build on OS X 10.6 using python.org 2.x/3.x

2009-09-21 Thread Ned Deily
New submission from Ned Deily : Potential 2.6.3 release blocker On OS X 10.6 (Snow Leopard), if you attempt to install a package with a extension module using a Python from a python.org OS X installer (say, 2.6.x or 3.1.x), the c compilation steps will likely fail in one of two ways: 1. Rece

[issue6952] deprecated conversion from string constant to char *

2009-09-21 Thread Trundle
Trundle added the comment: See also issue #1699259. -- nosy: +Trundle ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubsc

[issue6957] Extension modules fail to build on OS X 10.6 using python.org 2.x/3.x

2009-09-21 Thread Ned Deily
Changes by Ned Deily : -- nosy: +barry ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/ma

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread Thomas Heller
New submission from Thomas Heller : I want the Python executable to have command line flags which allow simple configuration of the logging module. Use cases are to run applications/scripts (which use libraries that use logging calls) with different logging output without having to edit (ugly) l

[issue6952] deprecated conversion from string constant to char *

2009-09-21 Thread Sebastian Ramacher
Changes by Sebastian Ramacher : -- nosy: +sebastinas ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail

[issue5764] 2.6.2 Python Manuals CHM file seems broken

2009-09-21 Thread Ding Xuan
Ding Xuan added the comment: thanks very much for your kindly notification :) On Mon, Sep 21, 2009 at 3:44 AM, Georg Brandl wrote: > > Georg Brandl added the comment: > > 2.6.3 will be out soon with a valid chm again. > > -- > resolution: -> later > status: open -> closed > > ___

[issue1766304] improve xrange.__contains__

2009-09-21 Thread Benjamin Peterson
Benjamin Peterson added the comment: As a small style note, I would prefer if the patch assigned in conditionals less and split them out to the line before. I see that rangeobject.c has a mixed style with regards to this, so the clearer one should win! :) -- nosy: +benjamin.peterson __

[issue6958] Add Python command line flags to configure logging

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

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread R. David Murray
Changes by R. David Murray : -- nosy: +vsajip priority: -> normal versions: +Python 2.7, Python 3.2 ___ Python tracker ___ ___ Python-

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread Doug Hellmann
Changes by Doug Hellmann : -- nosy: +doughellmann ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.py

[issue3366] Add gamma function, error functions and other C99 math.h functions to math module

2009-09-21 Thread Daniel Stutzbach
Daniel Stutzbach added the comment: I'll test your patch on Windows. Are you working against the trunk or the py3k branch? -- ___ Python tracker ___

[issue3366] Add gamma function, error functions and other C99 math.h functions to math module

2009-09-21 Thread Mark Dickinson
Mark Dickinson added the comment: Thanks! The patch is against the trunk. (It doesn't quite apply cleanly to py3k, but the changes needed to make it do so should be minimal.) Hmm. Rereading my previous comment, I seem to have a blindness for negative signs: gamma(x) = -pi/sinpi(x)/x/ga

[issue6954] DISTUTILS_DEBUG causes stack trace, really simple fix

2009-09-21 Thread Tarek Ziadé
Tarek Ziadé added the comment: Mmm, the problem is deeper for the second stack trace: distutils.fancy_getopt.longopt_xlate was changed from a translation mapping into a lambda in py3, that's why you have it. I'm fixing back this problem too. -- versions: +Python 3.2

[issue6952] deprecated conversion from string constant to char *

2009-09-21 Thread Barry Alan Scott
Barry Alan Scott added the comment: I'd guess that this change can first be made against 2.7 and 3.2 so that API's do not change. Where do I find the source code to generate the patch against for 2.7 and 3.2? -- ___ Python tracker

[issue6954] DISTUTILS_DEBUG causes stack trace, really simple fix

2009-09-21 Thread Tarek Ziadé
Changes by Tarek Ziadé : -- versions: +Python 2.7 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.py

[issue3366] Add gamma function, error functions and other C99 math.h functions to math module

2009-09-21 Thread Daniel Stutzbach
Daniel Stutzbach added the comment: I'm only setup to test the official Windows build setup under PCbuild. I'm not testing the legacy build setups under PC/VC6, PC/VS7.1, or PC/VS8.0. The patch against the trunk failed for PC/VC6/pythoncore.dsp. I don't need that to build, though. Your patch

[issue6952] deprecated conversion from string constant to char *

2009-09-21 Thread R. David Murray
R. David Murray added the comment: Take a look at http://www.python.org/dev, specifically the 'How to Get Started' article (which points you to the developer's FAQ, which explains how to do an anonymous checkout of the source). -- nosy: +r.david.murray _

[issue6954] DISTUTILS_DEBUG causes stack trace, really simple fix

2009-09-21 Thread Tarek Ziadé
Tarek Ziadé added the comment: Everything is covered now, and the mentioned bug is fixed in trunk (r74994), py3k (r74999) and release31 (75000). Thanks ! -- status: open -> closed ___ Python tracker _

[issue6952] deprecated conversion from string constant to char *

2009-09-21 Thread R. David Murray
R. David Murray added the comment: I'm setting the targets to 2.7/3.2 per the discussion in issue #1699259. Perhaps the question of whether or not it is "really" an API change could be revisited, but if so that would probably have to go through python-dev. -- priority: -> normal versi

[issue1699259] replacing char* with const char* in sysmodule.c/.h

2009-09-21 Thread R. David Murray
R. David Murray added the comment: See also issue 6952, which seems to be a broader request of the same nature. Moving the 3.1 target to 3.2, since 3.1 is out. -- nosy: +r.david.murray versions: +Python 3.2 -Python 3.1 ___ Python tracker

[issue3366] Add gamma function, error functions and other C99 math.h functions to math module

2009-09-21 Thread Mark Dickinson
Mark Dickinson added the comment: Many thanks, Daniel. > The patch against the trunk failed for PC/VC6/pythoncore.dsp. I don't > need that to build, though. I've no idea why that would happen. A line-ending issue, perhaps? If it doesn't stop me committing the change, then perhaps it's not

[issue3451] Asymptotically faster divmod and str(long)

2009-09-21 Thread steve21
Changes by steve21 : -- nosy: +steve21 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/ma

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread Vinay Sajip
Vinay Sajip added the comment: I get the idea. The Python part of the patch demonstrates what you're getting at, though it can't be used as is - for example the getattr(logging, a, a) could lead to problems. However a more intelligent parser (which looked for specific keywords recognised by basi

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread Thomas Heller
Thomas Heller added the comment: > I get the idea. The Python part of the patch demonstrates what you're > getting at, though it can't be used as is - for example the > getattr(logging, a, a) could lead to problems. However a more > intelligent parser (which looked for specific keywords recognis

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread Antoine Pitrou
Antoine Pitrou added the comment: If you want to add flags to the main executable, it deserves a discussion on python-dev IMO. It could be obtained through an environment variable, e.g. PYLOGGING_CONFIG; which has the nice side-effect of working for executable scripts too. -- nosy: +pit

[issue3366] Add gamma function, error functions and other C99 math.h functions to math module

2009-09-21 Thread Mark Dickinson
Mark Dickinson added the comment: gamma5.patch. very minor changes from the last patch: - add (int) cast suggested by Daniel Stutzbach - Misc/NEWS entry - ..versionadded in docs - minor corrections to some comments -- Added file: http://bugs.python.org/file14943/gamma5.patch

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread Eric Smith
Eric Smith added the comment: The C code looks basically okay to me. I'd probably use strdup() instead of the malloc/strlen/strcpy calls. And as Thomas said, the cleanup needs a little bit of work. -- ___ Python tracker

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread R. David Murray
R. David Murray added the comment: Also possibly relevant was the recent python-dev discussion about replicating (some of) the command line argument parsing in python so that it can be used by things other than the 'python' command: http://mail.python.org/pipermail/python-dev/2009-August/091484

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-09-21 Thread egreen
egreen added the comment: The problem is that the fileio struct in Modules/_io/fileio.c defines the 2-bit seekable field as int. >From the C99 standard, §6.7.2: for bit-fields, it is implementation-defined whether the specifier int designates the same type as signed int or the same type as unsi

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread Georg Brandl
Georg Brandl added the comment: Also, don't forget to update the "python -h" help text. -- nosy: +georg.brandl ___ Python tracker ___

[issue6959] OS X 10.6 / Snow Leopard

2009-09-21 Thread cscscs
Changes by cscscs : -- nosy: cscscs severity: normal status: open title: OS X 10.6 / Snow Leopard type: compile error ___ Python tracker ___ __

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread Michael Foord
Michael Foord added the comment: Why does this need to be built into the interpreter? The script / app should have logging config support. -- nosy: +michael.foord ___ Python tracker

[issue6959] OS X 10.6 / Snow Leopard: building 2.6 maintenance release fails for some modules (architecture issue)

2009-09-21 Thread Ned Deily
Ned Deily added the comment: By default on 10.6, gcc builds in 64-bit mode. Nav is one of the deprecated "classic" Macintosh platform modules and has been removed in Python 3. It and many other of the deprecated Mac modules use Carbon interfaces that are only available in 32-bit on OS X. If

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread Thomas Heller
Thomas Heller added the comment: > Why does this need to be built into the interpreter? The script / app > should have logging config support. It does not need to, but it would be nice. I think the '-l' flag should be similar to the -W flag. Or consider for example using unittest.main() as scri

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread Vinay Sajip
Vinay Sajip added the comment: If we do include interpreter support, there should be an option to invoke a configuration file, too: -l config=path Mutually exclusive with all the other options. So, you can either use it to invoke basicConfig or to invoke an arbitrary configuration in a file.

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread Doug Hellmann
Doug Hellmann added the comment: I think I'm with Michael on this one. I'd rather add logging configuration to any stdlib modules that support being run directly and want to support logging. -- ___ Python tracker

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread R. David Murray
R. David Murray added the comment: I don't think this is about logging in stdlib modules that are run directly. I think this is about a library that contains logging calls (eg: multiprocessing), and is used in j-random-application, and while prototyping/debugging the application you want to acce

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread Jean-Paul Calderone
Jean-Paul Calderone added the comment: How about putting this into the logging module instead? Instead of "python ", making it "python -m logging ___ ___ Python-bugs-list mail

[issue6348] solaris/aix: Py_Initialize: can't initialize sys standard streams

2009-09-21 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- resolution: -> duplicate status: open -> closed superseder: -> os.popen causes illegal seek on AIX in Python 3.1rc ___ Python tracker ___

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-09-21 Thread Sridhar Ratnakumar
Changes by Sridhar Ratnakumar : -- nosy: +srid ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pytho

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-09-21 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- resolution: -> accepted ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://m

[issue6958] Add Python command line flags to configure logging

2009-09-21 Thread Doug Hellmann
Doug Hellmann added the comment: How do these "global" settings (either via the interpreter or a wrapper in the logging module) change what an app might do on its own? IOW, if my app is already written to configure logging, and someone invokes it with these other settings, which settings are us

[issue6960] test_telnetlib gives spurious output

2009-09-21 Thread Antoine Pitrou
New submission from Antoine Pitrou : I just got the following traceback: Exception in thread Thread-538: Traceback (most recent call last): File "/home/antoine/py3k/__svn__/Lib/threading.py", line 509, in _bootstrap_inner self.run() File "/home/antoine/py3k/__svn__/Lib/threading.py", lin

[issue6961] test_distutils failure

2009-09-21 Thread Antoine Pitrou
New submission from Antoine Pitrou : I get the following (deterministic) failure on the py3k branch: test_distutils 0 blocks find: `/home/antoine/tmp/tmpX6PtRb/foo/build/bdist.linux-x86_64/rpm/BUILDROOT/foo-0.1-1.x86_64/usr/lib/debug': Aucun fichier ou dossier de ce type 0 blocks find: `/home/an

[issue6236] os.popen causes illegal seek on AIX in Python 3.1rc

2009-09-21 Thread Antoine Pitrou
Antoine Pitrou added the comment: Thanks for the patch! Committed in r75007, r75008, r75009, r75010. If there's any problem, please reopen. -- resolution: accepted -> fixed status: open -> closed versions: +Python 2.6, Python 2.7, Python 3.2 ___ Pyth

[issue6961] test_distutils failure

2009-09-21 Thread Antoine Pitrou
Antoine Pitrou added the comment: It also fails on release31-maint, but not on trunk. -- versions: +Python 3.1 ___ Python tracker ___

[issue6962] traceback.format_exception_only does not return SyntaxError carot correctly

2009-09-21 Thread thewtex
New submission from thewtex : On Python 2.6.2, and possibly other versions, in the traceback module, format_exception_only does not behave correctly when printout out a SyntaxError. An extra newline is inserted before the carot. E.g. 38 exceptionType, exceptionValue, exceptionTracebac

[issue1766304] improve xrange.__contains__

2009-09-21 Thread Robert Lehmann
Robert Lehmann added the comment: Thanks for your feedback. I added a few tests and changed the bits you criticized. -- Added file: http://bugs.python.org/file14945/range.patch ___ Python tracker ___

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

2009-09-21 Thread Brett Cannon
Brett Cannon added the comment: Is this open or closed? Wondering as I just updated my checkout and I am now segfaulting at the command-line whenever I import something under readline 6.0 which was working fine. >>> import tokenize Program received signal EXC_BAD_ACCESS, Could not access me

[issue6823] time.strftime does unnecessary range check

2009-09-21 Thread Brett Cannon
Brett Cannon added the comment: time.strftime() now normalizes tm_isdst. 2.7: r75011 3.2: r75012 This could probably be backported to 2.6/3.1, but since this is purely a convenience thing and it is a (very) minor change in semantics I am not going to bother. Thanks, Robert, for the initial

[issue6845] Restart support in binary upload for ftplib

2009-09-21 Thread Alejandro Santos
Changes by Alejandro Santos : -- nosy: +alejolp ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue6845] Restart support in binary upload for ftplib

2009-09-21 Thread Facundo Batista
Facundo Batista added the comment: I like this. I'd love to see a test of this, though. Pablo, do you think you could came up with a test? Thanks! -- ___ Python tracker ___

[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2009-09-21 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- versions: -Python 3.1 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://

[issue6963] Add worker process lifetime to multiprocessing.Pool - patch included

2009-09-21 Thread Charles Cazabon
New submission from Charles Cazabon : Worker processes with multiprocessing.Pool live for the duration of the Pool. If the tasks they run happen to leak memory (from a C extension module, or from creating cycles of unreachable objects, etc) or open files or other resources, there's no easy way t

[issue6963] Add worker process lifetime to multiprocessing.Pool - patch included

2009-09-21 Thread Charles Cazabon
Changes by Charles Cazabon : Removed file: http://bugs.python.org/file14946/worker-lifetime-python2.6.2.patch ___ Python tracker ___ ___ Python

[issue6963] Add worker process lifetime to multiprocessing.Pool - patch included

2009-09-21 Thread Charles Cazabon
Changes by Charles Cazabon : Added file: http://bugs.python.org/file14947/worker-lifetime-python2.6.2.patch ___ Python tracker ___ ___ Python-b

[issue6963] Add worker process lifetime to multiprocessing.Pool - patch included

2009-09-21 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- assignee: -> jnoller nosy: +jnoller ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubsc

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

2009-09-21 Thread Ronald Oussoren
Ronald Oussoren added the comment: This should have been closed, although readline shouldn't crash either. Brett: What version of OSX do you use? Readline works fine for me on OSX 10.6 without GNU readline. BTW. The crashlog indicates you are no longer using GNU readline, but use system read

[issue6957] Extension modules fail to build on OS X 10.6 using python.org 2.x/3.x

2009-09-21 Thread Ronald Oussoren
Ronald Oussoren added the comment: It should be possible to tweak distutils to do the right thing for upcoming releases, distutils already contains some special code to allow building extensions for a univeral build on 10.3.9 (where the compiler doesn't support universal builds at all) and we