Re: OT: Entitlements [was Re: Python usage numbers]

2012-02-15 Thread John O'Hagan
On Tue, 14 Feb 2012 17:26:36 -0800 (PST) Rick Johnson rantingrickjohn...@gmail.com wrote: On Feb 14, 6:44 pm, Chris Angelico ros...@gmail.com wrote: But WE are the fittest! Because we are INTELLIGENT! And the whales say: But WE are the fittest! Because we are BIG! And the rabbits say: But

Re: Python vs. C++11

2012-02-15 Thread Henrik Faber
On 15.02.2012 08:18, Tim Roberts wrote: sturlamolden sturlamol...@yahoo.no wrote: There are bigsimilarities between Python and the new C++ standard. Now we can actually use our experience as Python programmers to write fantastic C++ :-) This is more true than you might think. For quite a

Re: OT: Entitlements [was Re: Python usage numbers]

2012-02-15 Thread Duncan Booth
Rick Johnson rantingrickjohn...@gmail.com wrote: On Feb 14, 5:31 am, Duncan Booth duncan.bo...@invalid.invalid wrote: Rick Johnson rantingrickjohn...@gmail.com wrote: BS! With free healthcare, those who would have allowed their immune system fight off the flu, now take off from work, visit

Re: OT: Entitlements [was Re: Python usage numbers]

2012-02-15 Thread Arnaud Delobelle
On 15 February 2012 09:47, Duncan Booth duncan.booth@invalid.invalid wrote: Rick Johnson rantingrickjohn...@gmail.com wrote: [...] Perhaps it's a bit presumptuous of me but... It's tempting to react to his inflammatory posts, but after all Rick is a troll and experience shows that trolls are

Re: Python usage numbers

2012-02-15 Thread Anssi Saari
Matej Cepl mc...@redhat.com writes: Slightly less flameish answer to the question “What should I do, really?” is a tough one: all these suggested answers are bad because they don’t deal with the fact, that your input data are obviously broken. The rest is just pure GIGO … Well, sure, but it

Re: OT: Entitlements [was Re: Python usage numbers]

2012-02-15 Thread Duncan Booth
Arnaud Delobelle arno...@gmail.com wrote: On 15 February 2012 09:47, Duncan Booth duncan.booth@invalid.invalid wrote: Rick Johnson rantingrickjohn...@gmail.com wrote: [...] Perhaps it's a bit presumptuous of me but... It's tempting to react to his inflammatory posts, but after all Rick

Kill files [was Re: OT: Entitlements [was Re: Python usage numbers]]

2012-02-15 Thread Steven D'Aprano
On Wed, 15 Feb 2012 10:04:34 +, Duncan Booth wrote: Actually, I thought it was a bit weird that I saw ChrisA's comment but not the message he was commenting on until I went and looked for it. I read this group on a couple of machines and it looks like Rick's killfile entry had expired on

atexit.register in case of errors

2012-02-15 Thread Andrea Crotti
I have the following very simplified situation from atexit import register def goodbye(): print(saying goodbye) def main(): while True: var = raw_input(read something) if __name__ == '__main__': register(goodbye) main() But in my case the goodbye function is

Re: atexit.register in case of errors

2012-02-15 Thread Mel Wilson
Andrea Crotti wrote: I have the following very simplified situation from atexit import register def goodbye(): print(saying goodbye) def main(): while True: var = raw_input(read something) if __name__ == '__main__': register(goodbye) main()

Re: re module: Nothing to repeat, but no sre_constants.error: nothing to repeat ?

2012-02-15 Thread Devin Jeanpierre
On Tue, Feb 14, 2012 at 9:08 PM, MRAB pyt...@mrabarnett.plus.com wrote: There is one place in the re engine where it tries to avoid getting stuck in an infinite loop because of a zero-width match, but the fix inadvertently causes another bug. It's described in issue #1647489. Just read the

Re: atexit.register in case of errors

2012-02-15 Thread Devin Jeanpierre
On Wed, Feb 15, 2012 at 8:33 AM, Mel Wilson mwil...@the-wire.com wrote: The usual way to do what you're asking is if __name__ == '__main__':    main()    goodbye() and write main so that it returns after it's done all the things it's supposed to do.  If you've sprinkled `sys.exit()` all

[ANN]: Python module to distribute computations for parallel execution

2012-02-15 Thread Giridhar Pemmasani
Hello, I would like to announce dispy (http://dispy.sourceforge.net), a python framework for distributing computations for parallel execution to processors/cores on single node to many nodes over the network. The computations can be python functions or programs. If there are any dependencies,

Re: atexit.register in case of errors

2012-02-15 Thread Andrea Crotti
On 02/15/2012 01:52 PM, Devin Jeanpierre wrote: On Wed, Feb 15, 2012 at 8:33 AM, Mel Wilsonmwil...@the-wire.com wrote: The usual way to do what you're asking is if __name__ == '__main__': main() goodbye() and write main so that it returns after it's done all the things it's supposed

Re: Automatic Type Conversion to String

2012-02-15 Thread Bruce Eckel
Could it be that you missed the fact that strings are immutable? That means that you can't change the content of the object once it is initialized. In particular, it means that you e.g. have to override __new__ instead of __init__, because the content is already fixed when the latter is

Re: OT: Entitlements [was Re: Python usage numbers]

2012-02-15 Thread Rick Johnson
On Feb 15, 2:56 am, John O'Hagan resea...@johnohagan.com wrote: You have just demonstrated that you are the worst kind of racist. Not only have you blamed the victim on a truly monstrous scale, you have assigned blame not to individuals, but to entire races. Your tabloid sensationalism is

Re: OT: Entitlements [was Re: Python usage numbers]

2012-02-15 Thread Mark Lawrence
On 15/02/2012 15:04, Rick Johnson wrote: On Feb 15, 2:56 am, John O'Haganresea...@johnohagan.com wrote: John, I have grown weary of educating you. Go back to your day job writing op-eds for the National Inquirer and News of the World; they love this vile sensationalist crap! Goodnight John

Re: atexit.register in case of errors

2012-02-15 Thread Thomas Rachel
Am 15.02.2012 14:52 schrieb Devin Jeanpierre: On Wed, Feb 15, 2012 at 8:33 AM, Mel Wilsonmwil...@the-wire.com wrote: The usual way to do what you're asking is if __name__ == '__main__': main() goodbye() and write main so that it returns after it's done all the things it's supposed to

Re: atexit.register in case of errors

2012-02-15 Thread Andrea Crotti
On 02/15/2012 03:18 PM, Thomas Rachel wrote: Wouldn't if __name__ == '__main__': try: main() finally: goodbye() be even better? Or doesn't it work well together with SystemExit? Thomas Well in that case goodbye is always called, even if I have some other nasty

Interactive keyword help

2012-02-15 Thread Mark Lawrence
I didn't realise that this was available until today. It doesn't appear to be prominent in the official docs or have I missed something? Certainly I'd have thought a couple of sentences here http://www.python.org/about/help/ would be justified, what do y'all think? -- Cheers. Mark Lawrence.

Re: OT: Entitlements [was Re: Python usage numbers]

2012-02-15 Thread Rick Johnson
On Feb 15, 9:18 am, Mark Lawrence breamore...@yahoo.co.uk wrote: As you didn't answer my question from some days back I'll ask it agin. Please explain why previously healthy people get struck down with Common Fatigue Syndrome amongst other things. Why do you seek my counsel regarding medical

Re: OT: Entitlements [was Re: Python usage numbers]

2012-02-15 Thread Mark Lawrence
On 15/02/2012 16:27, Rick Johnson wrote: On Feb 15, 9:18 am, Mark Lawrencebreamore...@yahoo.co.uk wrote: As you didn't answer my question from some days back I'll ask it agin. Please explain why previously healthy people get struck down with Common Fatigue Syndrome amongst other things. Why

Re: Interactive keyword help

2012-02-15 Thread Andrew Berg
On 2/15/2012 10:04 AM, Mark Lawrence wrote: I didn't realise that this was available until today. It doesn't appear to be prominent in the official docs or have I missed something? Certainly I'd have thought a couple of sentences here http://www.python.org/about/help/ would be justified,

Re: Interactive keyword help

2012-02-15 Thread Arnaud Delobelle
On 15 February 2012 17:23, Andrew Berg bahamutzero8...@gmail.com wrote: On 2/15/2012 10:04 AM, Mark Lawrence wrote: I didn't realise that this was available until today.  It doesn't appear to be prominent in the official docs or have I missed something? Certainly I'd have thought a couple of

Re: Interactive keyword help

2012-02-15 Thread Mark Lawrence
On 15/02/2012 17:27, Arnaud Delobelle wrote: On 15 February 2012 17:23, Andrew Bergbahamutzero8...@gmail.com wrote: On 2/15/2012 10:04 AM, Mark Lawrence wrote: I didn't realise that this was available until today. It doesn't appear to be prominent in the official docs or have I missed

Re: Automatic Type Conversion to String

2012-02-15 Thread Ned Deily
In article dc097623-f377-4c7d-a065-13b58bf1c...@n12g2000yqb.googlegroups.com, Bruce Eckel lists.ec...@gmail.com wrote: Also, I discovered that the attempt to create a Path class goes back to 2006, where it created a lot of discussion and was finally shelved:

Complexity question on Python 3 lists

2012-02-15 Thread Franck Ditter
What is the cost of calling primes(n) below ? I'm mainly interested in knowing if the call to append is O(1), even amortized. Do lists in Python 3 behave like ArrayList in Java (if the capacity is full, then the array grows by more than 1 element) ? def sdiv(n) : # n = 2 returns the

Re: how to tell a method is classmethod or static method or instance method

2012-02-15 Thread Nathan Rice
And I'll take this opportunity to plug my dualmethod descriptor: http://code.activestate.com/recipes/577030-dualmethod-descriptor/ I use an analogous pattern in SQL Alchemy all the time (it's called hybridmethod/hybridproperty there). +1 to dualmethod, that pattern is great when you want a

Re: Complexity question on Python 3 lists

2012-02-15 Thread Chris Rebert
On Wed, Feb 15, 2012 at 10:20 AM, Franck Ditter fra...@ditter.org wrote: What is the cost of calling primes(n) below ? I'm mainly interested in knowing if the call to append is O(1), even amortized. Do lists in Python 3 behave like ArrayList in Java (if the capacity is full, then the array

Re: TEST AN EXECUTABLE PYTHON SCRIPT SPEED UNDER A PYTHON SHELL

2012-02-15 Thread Miki Tebeka
It depends on the overall runtime of the script vs start time of the vm. But yes in most benchmarks the script start time will bias against scripted languages. On a site note: ALL CAPS is considered shouting, please don't use that in news groups. --

Re: atexit.register in case of errors

2012-02-15 Thread Miki Tebeka
Another option is to use a global error flag and set it in sys.excepthook (see http://docs.python.org/library/sys.html#sys.excepthook). goodbye will check the error flag and skip execution if error flag is set. -- http://mail.python.org/mailman/listinfo/python-list

Re: Complexity question on Python 3 lists

2012-02-15 Thread Dave Angel
On 02/15/2012 01:20 PM, Franck Ditter wrote: What is the cost of calling primes(n) below ? I'm mainly interested in knowing if the call to append is O(1), even amortized. Do lists in Python 3 behave like ArrayList in Java (if the capacity is full, then the array grows by more than 1 element) ?

Re: Complexity question on Python 3 lists

2012-02-15 Thread Ian Kelly
On Wed, Feb 15, 2012 at 11:20 AM, Franck Ditter fra...@ditter.org wrote: What is the cost of calling primes(n) below ? I'm mainly interested in knowing if the call to append is O(1), even amortized. Yes, it's amortized O(1). See: http://wiki.python.org/moin/TimeComplexity From a relatively

Re: TEST AN EXECUTABLE PYTHON SCRIPT SPEED UNDER A PYTHON SHELL

2012-02-15 Thread Dave Angel
On 02/15/2012 01:36 PM, Miki Tebeka wrote: It depends on the overall runtime of the script vs start time of the vm. But yes in most benchmarks the script start time will bias against scripted languages. On a site note: ALL CAPS is considered shouting, please don't use that in news groups.

Re: Complexity question on Python 3 lists

2012-02-15 Thread Stefan Behnel
Ian Kelly, 15.02.2012 19:43: On Wed, Feb 15, 2012 at 11:20 AM, Franck Ditter wrote: Do lists in Python 3 behave like ArrayList in Java (if the capacity is full, then the array grows by more than 1 element) ? I believe the behavior in CPython is that if the array is full, the capacity is

Re: Complexity question on Python 3 lists

2012-02-15 Thread Chris Rebert
On Wed, Feb 15, 2012 at 10:43 AM, Ian Kelly ian.g.ke...@gmail.com wrote: On Wed, Feb 15, 2012 at 11:20 AM, Franck Ditter fra...@ditter.org wrote: snip Do lists in Python 3 behave like ArrayList in Java (if the capacity is full, then the array grows by more than 1 element) ? I believe the

Python to Combine Multiple Excel Worksheets into One Worksheet

2012-02-15 Thread SMac2347
Hello, I have one single Excel file with many separate worksheets, and for work I need to combine all these separate worksheets into one single worksheet (I am not worried about formatting, as the format is the same in each sheet, nor am I worried about Excel's row limit). Essentially, I am

Re: Kill files [was Re: OT: Entitlements [was Re: Python usage numbers]]

2012-02-15 Thread Ethan Furman
Steven D'Aprano wrote: On Wed, 15 Feb 2012 10:04:34 +, Duncan Booth wrote: Actually, I thought it was a bit weird that I saw ChrisA's comment but not the message he was commenting on until I went and looked for it. I read this group on a couple of machines and it looks like Rick's killfile

writing to a file from within nested loops

2012-02-15 Thread Rituparna Sengupta
Hi, I'm working on this code and I keep getting an error. It might be some very basic thing but I was wondering if someone could help. Its a loop within a loop. The part outside the innermost loop gets printed fine, but the part within the innermost loop doesn't get printed. I get an error:

Re: writing to a file from within nested loops

2012-02-15 Thread Ian Kelly
On Wed, Feb 15, 2012 at 1:12 PM, Rituparna Sengupta rsengu...@wisc.edu wrote: Hi, I'm working on this code and I keep getting an error. It might be some very basic thing but I was wondering if someone could help. Its a loop within a loop. The part outside the innermost loop gets printed

Re: writing to a file from within nested loops

2012-02-15 Thread Chris Rebert
On Wed, Feb 15, 2012 at 12:12 PM, Rituparna Sengupta rsengu...@wisc.edu wrote: Hi, I'm working on this code and I keep getting an error. It might be some very basic thing but I was wondering if someone could help. Its a loop within a loop. The part outside the innermost loop gets printed

Re: writing to a file from within nested loops

2012-02-15 Thread Dave Angel
On 02/15/2012 03:12 PM, Rituparna Sengupta wrote: Hi, I'm working on this code and I keep getting an error. It might be some very basic thing but I was wondering if someone could help. Its a loop within a loop. The part outside the innermost loop gets printed fine, but the part within the

Re: writing to a file from within nested loops

2012-02-15 Thread Mark Lawrence
On 15/02/2012 20:12, Rituparna Sengupta wrote: Hi, I'm working on this code and I keep getting an error. It might be some very basic thing but I was wondering if someone could help. Its a loop within a loop. The part outside the innermost loop gets printed fine, but the part within the

[semi OT]: Smartphones and Python?

2012-02-15 Thread Martin Schöön
First of all: I don't have any first hand experience of smartphones but now that my trusted old GSM phone is getting old I decided I am in for an up-grade. It struck me it might be nice to get something for which I could write Python programs. A very quick internet search indicated that this

Numerical Linear Algebra in arbitrary precision

2012-02-15 Thread Ken
Brand new Python user and a bit overwhelmed with the variety of packages available. Any recommendation for performing numerical linear algebra (specifically least squares and generalized least squares using QR or SVD) in arbitrary precision? I've been looking at mpmath but can't seem to find

Re: Looking for PyPi 2.0...

2012-02-15 Thread John Nagle
On 2/8/2012 9:47 AM, Chris Rebert wrote: On Wed, Feb 8, 2012 at 8:54 AM, Nathan Rice nathan.alexander.r...@gmail.com wrote: As a user: * Finding the right module in PyPi is a pain because there is limited, low quality semantic information, and there is no code indexing. CPAN does it

Re: Script randomly exits for seemingly no reason with strange traceback

2012-02-15 Thread John Nagle
On 2/4/2012 12:43 PM, Chris Angelico wrote: On Sun, Feb 5, 2012 at 3:32 AM, Andrew Bergbahamutzero8...@gmail.com wrote: On 2/3/2012 9:15 PM, Chris Angelico wrote: Do you call on potentially-buggy external modules? It imports one module that does little more than define a few simple

Re: Looking for PyPi 2.0...

2012-02-15 Thread Donald Stufft
On Wednesday, February 15, 2012 at 4:24 PM, John Nagle wrote: On 2/8/2012 9:47 AM, Chris Rebert wrote: On Wed, Feb 8, 2012 at 8:54 AM, Nathan Rice nathan.alexander.r...@gmail.com (mailto:nathan.alexander.r...@gmail.com) wrote: As a user: * Finding the right module in PyPi is a pain

Re: atexit.register in case of errors

2012-02-15 Thread Terry Reedy
On 2/15/2012 8:12 AM, Andrea Crotti wrote: I have the following very simplified situation from atexit import register def goodbye(): print(saying goodbye) def main(): while True: var = raw_input(read something) if __name__ == '__main__': register(goodbye) main() But in my case

Re: Complexity question on Python 3 lists

2012-02-15 Thread Terry Reedy
On 2/15/2012 2:11 PM, Chris Rebert wrote: It's slightly more complex: http://hg.python.org/cpython/file/096b31e0f8ea/Objects/listobject.c The growth pattern is: 0, 4, 8, 16, 25, 35, 46, 58, 72, 88, … -- list_resize() This has apparently changed from time to time. -- Terry Jan Reedy --

Re: Script randomly exits for seemingly no reason with strange traceback

2012-02-15 Thread Andrew Berg
On 2/15/2012 3:28 PM, John Nagle wrote: Are you doing a conditional import, one that takes place after load time? If you do an import within a function or class, it is executed when the code around it executes. If you import a file with a syntax error during execution, you could get the

Is this the right list?

2012-02-15 Thread Alan McKay
Hey folks, I looked all through the list of mailing lists on the mail.python.orgserver and this seems to be the only one that might apply to me other than maybe the German list which did not seem to have any specific python issue associated with it other than that you should write German on it.

Re: Looking for PyPi 2.0...

2012-02-15 Thread Nathan Rice
Hopefully soon crate.io will be useful for finding modules ;) I have plans for it to try and, encourage people to host their code and encourage following packaging standards. I'm currently focused mostly on the backend stability (e.g. getting it stable) but emphasizing things that are

Re: Is this the right list?

2012-02-15 Thread Terry Reedy
On 2/15/2012 4:51 PM, Alan McKay wrote: I am having a problem moving an application from RHEL 5.7 to Ubuntu 11.11, and the problem is around .py program. It is a web based program, and seems to use a strange combination of mod_python and python CGI as best I can tell. Would this be the right

Re: Is this the right list?

2012-02-15 Thread Mark Lawrence
On 15/02/2012 21:51, Alan McKay wrote: Hey folks, I looked all through the list of mailing lists on the mail.python.orgserver and this seems to be the only one that might apply to me other than maybe the German list which did not seem to have any specific python issue associated with it other

Stand-Alone Python Executable Skeletons

2012-02-15 Thread Calvin Spealman
I've recently been looking into different options to package python code into stand-alone executables, with tools like Py2EXE and PyInstaller, but I'm left feeling a little lost. Documentation seems sparse on all of them, the setups a little unusual to me. It feels like they could be a lot

Re: Complexity question on Python 3 lists

2012-02-15 Thread Ian Kelly
On Wed, Feb 15, 2012 at 1:28 PM, Dennis Lee Bieber wlfr...@ix.netcom.com wrote: On Wed, 15 Feb 2012 11:11:27 -0800, Chris Rebert c...@rebertia.com wrote: The growth pattern is: 0, 4, 8, 16, 25, 35, 46, 58, 72, 88, …    -- list_resize()        Rather perverse, is it not? The first set is

Re: Stand-Alone Python Executable Skeletons

2012-02-15 Thread Chris Rebert
On Wed, Feb 15, 2012 at 2:43 PM, Calvin Spealman ironfro...@gmail.com wrote: I've recently been looking into different options to package python code into stand-alone executables, with tools like Py2EXE and PyInstaller, but I'm left feeling a little lost. Documentation seems sparse on all of

Re: [semi OT]: Smartphones and Python?

2012-02-15 Thread MRAB
On 15/02/2012 20:58, Martin Schöön wrote: First of all: I don't have any first hand experience of smartphones but now that my trusted old GSM phone is getting old I decided I am in for an up-grade. It struck me it might be nice to get something for which I could write Python programs. A very

Wanted: Criticism of code for a Python module, plus a Mac tester

2012-02-15 Thread HoneyMonster
I am quite new to Python (running Python 2.7 on Linux). I have written a very small and simple dealing module for the game of Bridge. For those unfamiliar with the game, the idea is to deal each of 4 players a hand of 13 cards from a pack of 52, and to display it thus (use a fixed pitch font):

Re: [semi OT]: Smartphones and Python?

2012-02-15 Thread Paul Rubin
Martin Schöön martin.sch...@gmail.com writes: A very quick internet search indicated that this should be no big deal if I go for an Android-based phone. What about the alternatives? It works pretty well with Maemo, though phones with that are not so easy to find. My ex-officemate wrote some

Re: TEST AN EXECUTABLE PYTHON SCRIPT SPEED UNDER A PYTHON SHELL

2012-02-15 Thread Chris Angelico
On Thu, Feb 16, 2012 at 5:48 AM, Dave Angel d...@davea.name wrote: When you reply to a known bot, please include some indication of the fact, so we know your message can be ignored as well. Sometimes I wonder about 8. Is there a real person there, as well as the bot? A lot of his/its posts

Re: Interactive keyword help

2012-02-15 Thread Steven D'Aprano
On Wed, 15 Feb 2012 11:23:20 -0600, Andrew Berg wrote: help() is a built-in function, not a keyword. http://docs.python.org/library/functions.html#help http://docs.python.org/py3k/library/functions.html#help Technically, it's not actually built-in, it is added to the built-ins by site.py.

Re: Wanted: Criticism of code for a Python module, plus a Mac tester

2012-02-15 Thread Ian Kelly
On Wed, Feb 15, 2012 at 4:33 PM, HoneyMonster someone@someplace.invalid wrote: Secondly, as a more general point I would welcome comments on code quality, adherence to standards and so forth. The code is at: Looks pretty nice overall. To reduce repetition, I would have constructed the

format a measurement result and its error in scientific way

2012-02-15 Thread Daniel Fetchinson
Hi folks, often times in science one expresses a value (say 1.03789291) and its error (say 0.00089) in a short way by parentheses like so: 1.0379(9) One can vary things a bit, but let's take the simplest case when we only keep 1 digit of the error (and round it of course) and round the value

Re: Complexity question on Python 3 lists

2012-02-15 Thread Steven D'Aprano
On Wed, 15 Feb 2012 19:20:21 +0100, Franck Ditter wrote: What is the cost of calling primes(n) below ? I'm mainly interested in knowing if the call to append is O(1) Your primes() function appears to be a variation on trial division, which is asymptotically O(n*sqrt(n)/(log n)**2). Regardless

Re: Wanted: Criticism of code for a Python module, plus a Mac tester

2012-02-15 Thread Tim Chase
On 02/15/12 17:33, HoneyMonster wrote: Firstly, is there anyone here who uses Python on a Mac and would be prepared to test it? I have tested it on Linux and Windows, but don't have access to a Mac. It works from my quick test of it on my Mac. The class Player(): and the .format() calls

Re: Wanted: Criticism of code for a Python module, plus a Mac tester

2012-02-15 Thread HoneyMonster
On Wed, 15 Feb 2012 17:07:48 -0700, Ian Kelly wrote: On Wed, Feb 15, 2012 at 4:33 PM, HoneyMonster someone@someplace.invalid wrote: Secondly, as a more general point I would welcome comments on code quality, adherence to standards and so forth. The code is at: Looks pretty nice overall.

Re: format a measurement result and its error in scientific way

2012-02-15 Thread Ian Kelly
On Wed, Feb 15, 2012 at 5:18 PM, Daniel Fetchinson fetchin...@googlemail.com wrote: Hi folks, often times in science one expresses a value (say 1.03789291) and its error (say 0.00089) in a short way by parentheses like so: 1.0379(9) One can vary things a bit, but let's take the simplest case

Re: [semi OT]: Smartphones and Python?

2012-02-15 Thread geremy condra
On Wed, Feb 15, 2012 at 12:58 PM, Martin Schöön martin.sch...@gmail.com wrote: First of all: I don't have any first hand experience of smartphones but now that my trusted old GSM phone is getting old I decided I am in for an up-grade. It struck me it might be nice to get something for which I

Re: [semi OT]: Smartphones and Python?

2012-02-15 Thread 88888 Dihedral
在 2012年2月16日星期四UTC+8上午10时19分15秒,geremy condra写道: On Wed, Feb 15, 2012 at 12:58 PM, Martin Schöön martin.sch...@gmail.com wrote: First of all: I don't have any first hand experience of smartphones but now that my trusted old GSM phone is getting old I decided I am in for an up-grade. It

Re: [semi OT]: Smartphones and Python?

2012-02-15 Thread Michael Torrie
On 02/15/2012 07:38 PM, 8 Dihedral wrote: In the 4 G space of SW AP in Adndroid phones, check Jython. But I think a better data compression modules is more helpful. Jython, though a very cool and useful implementation, relies on the Java virtual machine to run. It does not yet run on

Web browser Python programming in NCLab

2012-02-15 Thread Pavel Solin
Hello, the NCLab development team would like to invite everybody to try out Python programming in the web browser at www.nclab.com. Using NCLab is free for personal, non-commercial purposes. If you'd like to give us feedback how we are doing, please use the mailing list

Re: Wanted: Criticism of code for a Python module, plus a Mac tester

2012-02-15 Thread Ian Kelly
On Wed, Feb 15, 2012 at 6:11 PM, HoneyMonster someone@someplace.invalid wrote: As to your first suggestion though, I am having some difficulty. Note that the vulnerability rotates; i.e. CONDITIONS[4] is not the same as CONDITIONS[0]. Is there a better way of doing it than a simple

Re: XSLT to Python script conversion?

2012-02-15 Thread Tim Arnold
On 2/13/2012 6:20 AM, Matej Cepl wrote: Hi, I am getting more and more discouraged from using XSLT for a transformation from one XML scheme to another one. Does anybody could share any experience with porting moderately complicated XSLT stylesheet

[issue14019] Unify tests for str.format and string.Formatter

2012-02-15 Thread Nick Coghlan
New submission from Nick Coghlan ncogh...@gmail.com: A couple of issues have arisen where features were added to str.format without similarly being added to string.Formatter. This is only possible because the test cases for the two are currently almost entirely separate. A common set of

[issue13579] string.Formatter doesn't understand the !a conversion specifier

2012-02-15 Thread Nick Coghlan
Nick Coghlan ncogh...@gmail.com added the comment: Agreed that this is a bug in string.Formatter rather than a new feature. There's already a separate bug for the autonumbering problem: http://bugs.python.org/issue13598 And I created a new issue about unifying some of the tests:

[issue10112] Use -Wl, --dynamic-list=x.list, not -Xlinker -export-dynamic

2012-02-15 Thread Jan Kratochvil
Jan Kratochvil jan.kratoch...@redhat.com added the comment: What more can be done to get it fixed? I do not mind Python but GDB linking is broken due to it. And while I can workaround it in GDB I am not used for workarounding one Free package in another Free package. Free software has the

[issue13703] Hash collision security issue

2012-02-15 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: Frankly, other short strings may give away even more, because you can put several into the same dict. Please don't make such claims without some reasonable security analysis: how *exactly* would you derive the hash seed when you have the

[issue14001] CVE-2012-0845 Python v2.7.2 / v3.2.2 (SimpleXMLRPCServer): DoS (excessive CPU usage) by processing malformed XMLRPC / HTTP POST request

2012-02-15 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: As a security issue, it applies to 2.6 and 3.1 as well. -- versions: +Python 2.6, Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14001

[issue13598] string.Formatter doesn't support empty curly braces {}

2012-02-15 Thread Nick Coghlan
Nick Coghlan ncogh...@gmail.com added the comment: One potential problem with the simple approach to fixing this is that up until now, string.Formatter has been thread safe. Because all the formatting state was held in local variables and passed around as method arguments, there was no state

[issue13987] Handling of broken markup in HTMLParser on 2.7

2012-02-15 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 11a31eb5da93 by Ezio Melotti in branch '2.7': #13987: HTMLParser is now able to handle EOFs in the middle of a construct. http://hg.python.org/cpython/rev/11a31eb5da93 -- nosy: +python-dev

[issue13987] Handling of broken markup in HTMLParser on 2.7

2012-02-15 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 3d7904e3f4b9 by Ezio Melotti in branch '2.7': #13987: HTMLParser is now able to handle malformed start tags. http://hg.python.org/cpython/rev/3d7904e3f4b9 -- ___ Python

[issue14019] Unify tests for str.format and string.Formatter

2012-02-15 Thread Eric V. Smith
Changes by Eric V. Smith e...@trueblade.com: -- nosy: +eric.smith ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14019 ___ ___ Python-bugs-list

[issue13987] Handling of broken markup in HTMLParser on 2.7

2012-02-15 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: This should be fixed now. The first two chunks of the attached patch have been committed in the two changesets linked in the previous messages. The third chunk about the end tag has been fixed as part of #13933. The error previously

[issue14020] Improve HTMLParser doc

2012-02-15 Thread Ezio Melotti
New submission from Ezio Melotti ezio.melo...@gmail.com: Attached patch reworks a bit the HTMLParser doc: - moved the basic example on the top and showed the output; - added a more complete parser with other examples; - fixed some factual errors; - added additional information for some

[issue7644] bug in nntplib.body() method with possible fix

2012-02-15 Thread Hynek Schlawack
Hynek Schlawack h...@ox.cx added the comment: I have also added a test for NTTP.head(), enjoy. -- keywords: +patch Added file: http://bugs.python.org/file24524/nntp-file-test.diff ___ Python tracker rep...@bugs.python.org

[issue14015] surrogateescape largely missing from documentation

2012-02-15 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- versions: -Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14015 ___ ___ Python-bugs-list

[issue14004] Distutils filelist selects too many files on Windows

2012-02-15 Thread Jason R. Coombs
Jason R. Coombs jar...@jaraco.com added the comment: It's not that I forgot to set DISTUTILS_DEBUG, I simply did not set it. If the bug were still present, I would have seen a line indicating that .hg/last-message.txt was being copied. For completeness, here's the output with the DEBUG

[issue14004] Distutils filelist selects too many files on Windows

2012-02-15 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: So it looks like that even if the exclusion of .hg removes .hg/last-message.txt, it should not have been added in the first place, as the command was include and not recursive-include. At first glance, Nadeem’s proposed fix is not right: paths

[issue12297] Clarifications to atexit.register and unregister doc

2012-02-15 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Thanks. I’ve also realized that the doc does not mention that any callable can be used; I don’t know if we should say it explicitly (I think I did a change like that recently in another file), or if we expect people to just know it from

[issue14020] Improve HTMLParser doc

2012-02-15 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Didn’t review in detail but the plan LGTM. In a subsequent commit, you could update the markup to use nested class/method directives. -- ___ Python tracker rep...@bugs.python.org

[issue12297] Clarifications to atexit.register and unregister doc

2012-02-15 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 55fc092dad72 by Éric Araujo in branch '3.2': Improve doc for atexit.register and unregister (#12297) http://hg.python.org/cpython/rev/55fc092dad72 New changeset f7163afecb97 by Éric Araujo in branch 'default': Merge

[issue1326113] Letting build_ext --libraries take more than one lib

2012-02-15 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 53df93a9c002 by Éric Araujo in branch '3.2': Fix parsing of build_ext --libraries option (#1326113) http://hg.python.org/cpython/rev/53df93a9c002 New changeset f7163afecb97 by Éric Araujo in branch 'default': Merge

[issue1326113] Letting build_ext --libraries take more than one lib

2012-02-15 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 96f5718bf005 by Éric Araujo in branch '2.7': Fix parsing of build_ext --libraries option (#1326113) http://hg.python.org/cpython/rev/96f5718bf005 -- ___ Python tracker

[issue12297] Clarifications to atexit.register and unregister doc

2012-02-15 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset a99632426af5 by Éric Araujo in branch '2.7': Improve doc for atexit.register (#12297) http://hg.python.org/cpython/rev/a99632426af5 -- ___ Python tracker

[issue1326113] Letting build_ext --libraries take more than one lib

2012-02-15 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 4ba43318e56b by Éric Araujo in branch 'default': Fix parsing of packaging’s build_ext --libraries option (#1326113) http://hg.python.org/cpython/rev/4ba43318e56b -- ___

[issue1326113] Letting build_ext --libraries take more than one lib

2012-02-15 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 60dd0041c9bc by Éric Araujo in branch 'default': Fix parsing of build_ext --libraries option (#1326113) http://hg.python.org/distutils2/rev/60dd0041c9bc New changeset 158697fd8fa1 by Éric Araujo in branch 'python3':

[issue1326113] Letting build_ext --libraries take more than one lib

2012-02-15 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Here you are! Thanks for the testing. -- resolution: - fixed stage: test needed - committed/rejected status: open - closed versions: +Python 3.3 -Python 3.1 ___ Python tracker rep...@bugs.python.org

[issue12297] Clarifications to atexit.register and unregister doc

2012-02-15 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Closing as fixed, but if you have any feedback on my function vs. callable question, please share. -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python

[issue14021] Write pkg_info with local encoding(GBK) will be a problem.

2012-02-15 Thread 勇刚 罗
New submission from 勇刚 罗 luoyongg...@gmail.com: D:\CI\bld\vcs\pygit2python setup.py install Find C:\Python32\python.exe Using C:\Python32\python.exe running install running bdist_egg running egg_info writing pygit2.egg-info\PKG-INFO Traceback (most recent call last): File setup.py, line 106,

  1   2   >