Re: RELEASED Python 3.1 alpha 1

2009-03-07 Thread Christian Heimes
bearophileh...@lycos.com wrote: Are the computed gotos used in the future pre-compiled Windows binary (of V.3.1) too? No, the MS Visual C compiler doesn't supported labels as values [1]. The feature is only supported by some compilers like GCC. Christian [1]

Re: Ban Xah Lee

2009-03-07 Thread D Herring
apologies for the cross posting Xah Lee wrote: This page is a short collection of online communities that banned me, in a way that i don't consider just. It illustrates the political nature among the tech geeking males. If anybody on this list visits Boston, contact me to claim your free

Re: RELEASED Python 3.1 alpha 1

2009-03-07 Thread bearophileHUGS
Benjamin Peterson: It provides a good incentive for people to upgrade. :) Sometimes at work you are forced you to use Python 2.x, so incentives aren't much relevant. Christian Heimes: No, the MS Visual C compiler doesn't supported labels as values [1]. The feature is only supported by some

Re: Candidate for a new itertool

2009-03-07 Thread bearophileHUGS
Raymond Hettinger, maybe it can be useful to add an optional argument flag to tell such split_on to keep the separators or not? This is the xsplit I usually use: def xsplit(seq, key=bool, keepkeys=True): xsplit(seq, key=bool, keepkeys=True): given an iterable seq and a predicate key,

Re: Python3 on the Web

2009-03-07 Thread Paul Rubin
Tim Roberts t...@probo.com writes: At that level of load, CGI is perfectly workable, and it's certainly the easiest of the choices for development and exploration. One problem of CGI even at very low loads is that it's harder to handle the case where two hits arrive at the same time and want to

Re: Ban Xah Lee

2009-03-07 Thread Tim Greer
Xah Lee wrote: Of interest: Unintesting stuff snipped. Perhaps it's the irrelevant, off topic posts you continue to make to groups that have nothing to do with your self gratifying rants? We get it, you think you're smarter than anyone else and that's the reason for you posting and arguing

Re: Ban Xah Lee

2009-03-07 Thread Tim Roberts
Xah Lee xah...@gmail.com wrote: Summary: I was posting relevant but controversial opinions in a rude manner to “comp.lang.*” newsgroups. And that one (completely accurate) sentence is really the core of virtually all of your troubles, isn't it? Usually, as people mature, they learn by

Re: Chandler, Python, speed

2009-03-07 Thread alex23
On Mar 8, 8:05 am, Ville M. Vainio vivai...@gmail.com wrote: I remember reading somewhere that the cause of slowness is/was architectural - perhaps it was that chandler was persisting too much stuff to disk, or something. In any case, this might help you google for more detail. My

Re: Ban Xah Lee

2009-03-07 Thread Dirk Bruere at NeoPax
Dirk Bruere at NeoPax wrote: Xah Lee wrote: Of interest: • Why Can't You Be Normal? http://xahlee.org/Netiquette_dir/why_cant_you_be_normal.html • Ban Xah Lee http://xahlee.org/Netiquette_dir/ban_Xah_Lee.html I consider this post relevant because i've been perennially gossiped about in

Re: Ban Xah Lee

2009-03-07 Thread Grant Edwards
On 2009-03-08, Tim Roberts t...@probo.com wrote: Xah Lee xah...@gmail.com wrote: Summary: I was posting relevant but controversial opinions in a rude manner to “comp.lang.*” newsgroups. And that one (completely accurate) sentence is really the core of virtually all of your troubles, isn't it?

Re: RichCompare and RichCompareBool

2009-03-07 Thread Steven D'Aprano
Aaron Brady wrote: Hi.  Just bringing it up again.  I feel the docs should mention it at least, and there should possibly be a separate function. Post a bug report or feature request on the tracker, or nothing will happen. If you include a patch, odds of it being approved are greatly

Re: Themed TK (tk Tile) at last?!

2009-03-07 Thread r
Hip, Hip, Hooray! -- http://mail.python.org/mailman/listinfo/python-list

Re: Is there a better way of doing this?

2009-03-07 Thread Steven D'Aprano
Gabriel Genellina wrote: Imagine you're working with someone side by side. You write a note in a piece of paper, put it into an envelope, and hand it to your co-worker. He opens the envelope, throws it away, takes the note and files it inside a folder right at the end. And you do this over

Re: ANN: Dao, the official 1.0 version is released

2009-03-07 Thread Ben Finney
Daniel Fetchinson fetchin...@googlemail.com writes: Why this hostility? The guy has worked on an interesting piece of software and tries to promote it to people who are most probably interested in programming languages. What's wrong with that? Because there's no particular reason for it

Which Lisp to Learn?

2009-03-07 Thread Xah Lee
For those of you imperative programers who kept on hearing about lisp and is tempted to learn, then, of interest: • What Is Your Favorite Lisp http://xahlee.org/UnixResource_dir/writ/whats_your_fav_lisp.html plain text version follows. - What Is Your

Re: speeding up reading files (possibly with cython)

2009-03-07 Thread Steven D'Aprano
per wrote: hi all, i have a program that essentially loops through a textfile file thats about 800 MB in size containing tab separated data... my program parses this file and stores its fields in a dictionary of lists. for line in file: split_values = line.strip().split('\t') # do

Re: Help cleaning up some code

2009-03-07 Thread odeits
On Mar 7, 1:07 pm, Scott David Daniels scott.dani...@acm.org wrote: odeits wrote: I am looking to clean up this code... any help is much appreciated. Note: It works just fine, I just think it could be done cleaner. The result is a stack of dictionaries. the query returns up to STACK_SIZE

Re: Is there a better way of doing this?

2009-03-07 Thread Tim Wintle
On Sun, 2009-03-08 at 15:49 +1100, Steven D'Aprano wrote: If the environmental costs of recycling something are worse than the environmental costs of throwing it away and making a new one, then recycling that object is actually harmful. But I digress. Unless you live in a country that imports

Re: Help cleaning up some code

2009-03-07 Thread odeits
On Mar 7, 10:58 pm, odeits ode...@gmail.com wrote: On Mar 7, 1:07 pm, Scott David Daniels scott.dani...@acm.org wrote: odeits wrote: I am looking to clean up this code... any help is much appreciated. Note: It works just fine, I just think it could be done cleaner. The result is a

How to define a db file for sqlite?

2009-03-07 Thread Muddy Coder
Hi Folks, I just downloaded and installed pysqlite, and I can import sqlite3 smoothly. Then, I need to connect sqlite by syntax: conn = sqlite3.connect('adirectory/db') I wish the data will be stored into directory --- adirectory, with a file named in db. But I got kicked out with an error

Re: Parsing unicode (devanagari) text with xml.dom.minidom

2009-03-07 Thread Stefan Behnel
rpar...@gmail.com wrote: I am trying to process an xml file that contains unicode characters (see http://vyakarnam.wordpress.com/). Wordpress allows exporting the entire content of the website into an xml file. Using xml.dom.minidom, I wrote a few lines of python code to parse out the xml

Re: RichCompare and RichCompareBool

2009-03-07 Thread Aaron Brady
On Mar 7, 10:39 pm, Steven D'Aprano st...@pearwood.info wrote: Aaron Brady wrote: Hi.  Just bringing it up again.  I feel the docs should mention it at least, and there should possibly be a separate function. Post a bug report or feature request on the tracker, or nothing will happen. If

[issue5425] 2to3 wrong for types.StringTypes

2009-03-07 Thread Hagen Fürstenau
Hagen Fürstenau hfuerste...@gmx.net added the comment: I can see the merit of not including bytes in StringTypes, but then the translation of StringType should be changed accordingly. How about changing the present StringType - bytes StringTypes - str into StringType - str StringTypes -

[issue5435] test_httpservers on Debian Testing

2009-03-07 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- components: +Library (Lib), Tests -None type: compile error - behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5435 ___

[issue5434] datetime.MonthDelta

2009-03-07 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- nosy: +lemburg, tim_one ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5434 ___ ___ Python-bugs-list

[issue3992] removed custom log from distutils

2009-03-07 Thread Akira Kitada
Akira Kitada akit...@gmail.com added the comment: I updated the patch. Mine only changes log.py. -- nosy: +akitada Added file: http://bugs.python.org/file13260/remove-custom-log-revised.diff ___ Python tracker rep...@bugs.python.org

[issue5436] test_distutils fails with official Mac OS X Installer Disk Image (3.0.1)

2009-03-07 Thread Martina Oefelein
New submission from Martina Oefelein mart...@oefelein.de: Majestix:~ martina$ python3.0 -m test.regrtest test_distutils Could not find '/Library/Frameworks/Python.framework/Versions/3.0/lib/python3.0/test' in sys.path to remove it test_distutils test test_distutils failed -- Traceback (most

[issue5436] test_distutils fails with official Mac OS X Installer Disk Image (3.0.1)

2009-03-07 Thread Tarek Ziadé
Tarek Ziadé ziade.ta...@gmail.com added the comment: That's because get_config_vars reads the src_dir located in your Makefile (in config/Makefile): srcdir=.../Users/ronald/Projects/python/bld/r301 VPATH=/Users/ronald/Projects/python/bld/r301 Moreover, the test is totally broken

[issue5435] test_httpservers on Debian Testing

2009-03-07 Thread Michael Zamot
Michael Zamot mich...@zamotcr.net added the comment: I tried too yesterday with the svn version, and i get the same error. Is there a solution or im doing something wrong? ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5435

[issue5435] test_httpservers on Debian Testing

2009-03-07 Thread Hirokazu Yamamoto
Hirokazu Yamamoto ocean-c...@m2.ccsnet.ne.jp added the comment: Probably this is short code to reproduce permission denied. import os, pwd nobody = pwd.getpwnam('nobody')[2] os.setuid(nobody) open(dummy.txt, w).write(foo) # permission denied Still I cannot understand what's going on. Is debian

[issue5435] test_httpservers on Debian Testing

2009-03-07 Thread Michael Zamot
Michael Zamot mich...@zamotcr.net added the comment: I dont know, it weird, because im running the test as root. I tried in a Stable Lenny, and nothing too ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5435

[issue5435] test_httpservers on Debian Testing

2009-03-07 Thread Michael Zamot
Michael Zamot mich...@zamotcr.net added the comment: I re-download again (maybe its the four time jaja) the python 3.0.1 from the svn and now, it pass all the tests. Thanks to all! ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5435

[issue5425] 2to3 wrong for types.StringTypes

2009-03-07 Thread Daniel Diniz
Daniel Diniz aja...@gmail.com added the comment: I think Hagen's initial analysis makes more sense: the translation is currently guessing that the user meant the more restrict (text) alternative. IMHO it doesn't make much sense to have this: strings = (types.StringType, types.UnicodeType)

[issue5415] uuid module generates incorrect values for uuid3 (and possibly uuid5)

2009-03-07 Thread DSM
DSM dsm...@users.sourceforge.net added the comment: Hmm. I quickly wrote my own implementation and I agree with the uuid module and disagree with the RFC value. Further searching suggests that this may be an error in the RFC. See http://www.rfc-editor.org/errata_search.php?rfc=4122 ; see

[issue3700] test_bigmem broken

2009-03-07 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Committed to py3k, let's see if the buildbots like it... -- stage: patch review - committed/rejected status: open - pending ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue3700

[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2009-03-07 Thread Antoine Pitrou
New submission from Antoine Pitrou pit...@free.fr: The PyExc_MemoryErrorInst object is persistent and its members never get cleared. This means any local variable which gets caught in the traceback isn't deallocated until the next MemoryError (!). Sample script demonstrates this. (this doesn't

[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2009-03-07 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: The following patch fixes the case when the exception is discarded in Python, but not when e.g. PyErr_Clear() is used from C code. -- keywords: +patch Added file: http://bugs.python.org/file13262/issue5437.patch

[issue5438] test_bigmem.test_from_2G_generator uses more memory than expected

2009-03-07 Thread Antoine Pitrou
New submission from Antoine Pitrou pit...@free.fr: It seems test_from_2G_generator doesn't respect its announced memory consumption. I launched test_bigmem with -M 12G on a 16GB machine, and the interpreter process got killed by the OOM killer (Out Of Memory) while running this test case.

[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2009-03-07 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: A proper fix would probably be to maintain a bunch of preallocated instances in a freelist rather than relying on an explicit singleton. It would enforce proper dereferencing and garbage collection semantics.

[issue5251] contextlib.nested inconsistent with, well, nested with statements due exceptions raised in __enter__

2009-03-07 Thread Nick Coghlan
Nick Coghlan ncogh...@gmail.com added the comment: PEP 377 (http://www.python.org/dev/peps/pep-0377/) has now been submitted. ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5251 ___

[issue1818] Add named tuple reader to CSV module

2009-03-07 Thread Jervis Whitley
Jervis Whitley jervi...@gmail.com added the comment: Added a patch against py3k branch. in csv.rst removed reference to reader.next() as a public method. Added file: http://bugs.python.org/file13263/ntreader4_py3_1.diff ___ Python tracker

[issue1818] Add named tuple reader to CSV module

2009-03-07 Thread Skip Montanaro
Skip Montanaro s...@pobox.com added the comment: Jervis in csv.rst removed reference to reader.next() as a public method. Because? I've not seen any discussion in this issue or in any other forums (most certainly not on the c...@python.org mailing list) which would suggest that csv.reader's

[issue5440] string.strip behaves strangly

2009-03-07 Thread Dongwook Jang
New submission from Dongwook Jang jang.dongw...@gmail.com: Python 2.4.2 (#1, Mar 4 2008, 22:56:43) [GCC 3.4.5] on linux2 Type help, copyright, credits or license for more information. temp = a/b/c temp.strip(a) '/b/c' temp.strip(a/) 'b/c' temp.strip(a/b) 'c' temp.strip(a/b/) 'c' So, in

[issue5251] contextlib.nested inconsistent with, well, nested with statements due exceptions raised in __enter__

2009-03-07 Thread Nick Coghlan
Nick Coghlan ncogh...@gmail.com added the comment: Attached simple benchmark script to check for any slowdowns introduced by the planned with statement changes. Added file: http://bugs.python.org/file13264/pep377_bench.py ___ Python tracker

[issue5441] Convenience API for timeit.main

2009-03-07 Thread Nick Coghlan
New submission from Nick Coghlan ncogh...@gmail.com: For quick and dirty benchmarking, timeit.main() is one of the handiest tools out there, but calling it from Python code is a little tedious since you need to construct a fake list of command line arguments in order to call it. What would be

<    1   2