Re: sum for sequences?

2010-03-24 Thread TomF
On 2010-03-24 14:07:24 -0700, Steven D'Aprano said: On Wed, 24 Mar 2010 15:29:07 +, kj wrote: Is there a sequence-oriented equivalent to the sum built-in? E.g.: seq_sum(((1, 2), (5, 6))) --> (1, 2) + (5, 6) --> (1, 2, 5, 6) ? Yes, sum. help(sum) is your friend. You might not want t

Re: Is there any library for indexing binary data?

2010-03-24 Thread 甜瓜
Well, Database is not proper because 1. the table is very big (~10^9 rows) 2. we should support very fast *simple* query that is to get value corresponding to single key (~10^7 queries / second). Currently, I have implemented a specific algorithm to deal with my problem. However, I want to employ

Re: Advice Criticism on Python App

2010-03-24 Thread Steven D'Aprano
On Wed, 24 Mar 2010 21:14:23 -0700, Tim Roberts wrote: > Jimbo wrote: >> >>class stock: >>code = "" >>purchasePrice= 0 >>purchaseQuantity = 0 >>price= [] # list of recent prices >>recentBid= [] # list of recent bids for stock >>recent

Re: Is there any library for indexing binary data?

2010-03-24 Thread Gabriel Genellina
En Thu, 25 Mar 2010 00:28:58 -0300, 甜瓜 escribió: Recently, I am finding a good library for build index on binary data. Xapian & Lucene for python binding focus on text digestion rather than binary data. Could anyone give me some recommendation? Is there any library for indexing binary data no

Re: Advice Criticism on Python App

2010-03-24 Thread Tim Roberts
Jimbo wrote: > >class stock: >code = "" >purchasePrice= 0 >purchaseQuantity = 0 >price= [] # list of recent prices >recentBid= [] # list of recent bids for stock >recentOffer = [] # list of recent offers for stock >stockVol

Re: MySQLdb compiled -- Import issue

2010-03-24 Thread Sean DiZazzo
> You are right. I was trying to import the module sitting on the source > folder :"-). Thanks for your quick response and let me try further. Sweet! I remember it because it confused the hell out of me on at least one past occasion. :) -- http://mail.python.org/mailman/listinfo/python-list

Re: Super() function

2010-03-24 Thread Gabriel Genellina
En Thu, 25 Mar 2010 00:17:52 -0300, Alan Harris-Reid escribió: Using Python 3.1, I sometimes use the super() function to call the equivalent method from a parent class, for example def mymethod(self): super().mymethod() some more code... Is there any way of writing the code so tha

Re: Super() function

2010-03-24 Thread alex23
Alan Harris-Reid wrote: > Is there any way of writing the code so that the super() call is generic > and automatically recognises the name of the current method (ie. > something like super().thismethod()) or do I always have to repeat the > method name after super()? To the best of my knowledge,

Re: device identification

2010-03-24 Thread Tim Roberts
Omer Ihsan wrote: > >VID and PID is fair enough. now what i want is that i have a threaded >code that threads two functions to run at the same time. i want each >function to run seperate devices. the problem is if it doesnt identify >the attached devices it might run the code on a single device wh

Re: Super() function

2010-03-24 Thread 岳帅杰
Hi: On 25 March 2010 11:17, Alan Harris-Reid wrote: > Hi, > > Using Python 3.1, I sometimes use the super() function to call the > equivalent method from a parent class, for example > > def mymethod(self): > super().mymethod() > some more code... > > Is there any way of writing the code so t

Re: MySQLdb compiled -- Import issue

2010-03-24 Thread Kurian Thayil
On Wed, 2010-03-24 at 20:15 -0700, Sean DiZazzo wrote: > On Mar 24, 7:59 pm, Kurian Thayil wrote: > > Hi All, > > > > I am just a month old with Python and trying to learn CGI with Python. I > > was trying to install MySQLdb module in my new CentOS 5.3 box with > > Python 2.4.3 default install.

Is there any library for indexing binary data?

2010-03-24 Thread 甜瓜
Howdy, Recently, I am finding a good library for build index on binary data. Xapian & Lucene for python binding focus on text digestion rather than binary data. Could anyone give me some recommendation? Is there any library for indexing binary data no matter whether it is written in python? In my

Super() function

2010-03-24 Thread Alan Harris-Reid
Hi, Using Python 3.1, I sometimes use the super() function to call the equivalent method from a parent class, for example def mymethod(self): super().mymethod() some more code... Is there any way of writing the code so that the super() call is generic and automatically recognises the n

Re: MySQLdb compiled -- Import issue

2010-03-24 Thread Sean DiZazzo
On Mar 24, 7:59 pm, Kurian Thayil wrote: > Hi All, > > I am just a month old with Python and trying to learn CGI with Python. I > was trying to install MySQLdb module in my new CentOS 5.3 box with > Python 2.4.3 default install. I downloaded the tar-ball of MySQLdb > module (MySQL-python-1.2.3c1).

MySQLdb compiled -- Import issue

2010-03-24 Thread Kurian Thayil
Hi All, I am just a month old with Python and trying to learn CGI with Python. I was trying to install MySQLdb module in my new CentOS 5.3 box with Python 2.4.3 default install. I downloaded the tar-ball of MySQLdb module (MySQL-python-1.2.3c1). Did build as normal user and install as root. MySQL

threads (specifically timers) and releasing resources

2010-03-24 Thread Alex Hall
Okay, I have my program and it has three different modes (there will be more than that). Each mode will have a timer attached to it. If the mode remains active and the timer runs out, a function specific to that mode is called. If that mode is switched away from, however, the timer is canceled and

cxfreeze on ubuntu 9.10

2010-03-24 Thread Waspinator
Hi, I'm trying to compile a python script on Ubuntu 9.10. It uses the gtk toolkit. I tried to run GUI2EXE for a cxfreeze gui, but even after installing wxPython in synaptic it still complains about not having it. I also tried to use cxfreeze by itself but the file it produces does not run. I tri

Re: timers not canceling!

2010-03-24 Thread Steve Holden
Steve Holden wrote: > Alex Hall wrote: [...] > "thread already started" implies that the thread is running, but you > actually get the same message if you try to start any terminated thread > (including a canceled one), so "threads cannot be restarted" might be a > better message. > Or, better sti

Re: the Python Foundation

2010-03-24 Thread Paul Rubin
"Steve Holden, Chairman, PSF" writes: > We have also registered the trademark "Python" for use in reference to > computer programming languages, thereby ensuring that we can take action > should some ill-advised individual or organization decide to produce > another language with "Python" in its n

Re: sum for sequences?

2010-03-24 Thread Paul Rubin
kj writes: > Is there a sequence-oriented equivalent to the sum built-in? E.g.: > seq_sum(((1, 2), (5, 6))) --> (1, 2) + (5, 6) --> (1, 2, 5, 6) use itertools.chain for this. A few people have mentioned that sum will also work, but I think for that purpose it could have O(n**2) complexity. --

Re: Programmatically discovering encoding types supported by codecs module

2010-03-24 Thread Gabriel Genellina
En Wed, 24 Mar 2010 14:58:47 -0300, escribió: After looking at how things are done in codecs.c and encodings/__init__.py I think you should enumerate all modules in the encodings package that define a getregentry function. Aliases come from encodings.aliases.aliases. Thanks for looking

Re: RELEASED Python 2.6.5

2010-03-24 Thread Martin v. Loewis
> Is anyone else having trouble with the 2.6.5 Windows x86 installer? Not me. Run msiexec /i py...msi /l*v py.log and inspect py.log for errors (post it to bugs.python.org if you can't determine the cause of the problems). Are you using SUBST by any chance? Regards, Martin -- http://mail.pyth

Re: timers not canceling!

2010-03-24 Thread Steven D'Aprano
On Wed, 24 Mar 2010 17:12:45 -0400, Alex Hall wrote: > Hi all, > I am having trouble with a timer I am trying to use. It is the same > timer, but I need to cancel it when a certain event happens, then start > it again when a second event happens. The below is from a shell session, > not a file, bu

Re: timers not canceling!

2010-03-24 Thread Steve Holden
Alex Hall wrote: > Hi all, > I am having trouble with a timer I am trying to use. It is the same > timer, but I need to cancel it when a certain event happens, then > start it again when a second event happens. The below is from a shell > session, not a file, but it shows my problem: I call cancel

Re: the Python Foundation

2010-03-24 Thread Steve Holden, Chairman, PSF
Mark Tarver wrote: >>From the website > > The Python Software Foundation (PSF) is a 501(c)(3) non-profit > corporation that > holds the intellectual property rights behind the Python programming > language. We manage the open source licensing for Python version 2.1 > and later and own and protect

timers not canceling!

2010-03-24 Thread Alex Hall
Hi all, I am having trouble with a timer I am trying to use. It is the same timer, but I need to cancel it when a certain event happens, then start it again when a second event happens. The below is from a shell session, not a file, but it shows my problem: I call cancel on a timer, then call start

Re: sum for sequences?

2010-03-24 Thread Steven D'Aprano
On Wed, 24 Mar 2010 15:29:07 +, kj wrote: > Is there a sequence-oriented equivalent to the sum built-in? E.g.: > > seq_sum(((1, 2), (5, 6))) --> (1, 2) + (5, 6) --> (1, 2, 5, 6) > > ? Yes, sum. help(sum) is your friend. >>> a = range(2) >>> b = range(3) >>> c = range(4) >>> sum((a, b,

Re: the Python Foundation

2010-03-24 Thread Robert Kern
On 2010-03-24 15:50 PM, Mark Tarver wrote: From the website The Python Software Foundation (PSF) is a 501(c)(3) non-profit corporation that holds the intellectual property rights behind the Python programming language. We manage the open source licensing for Python version 2.1 and later and own

the Python Foundation

2010-03-24 Thread Mark Tarver
>From the website The Python Software Foundation (PSF) is a 501(c)(3) non-profit corporation that holds the intellectual property rights behind the Python programming language. We manage the open source licensing for Python version 2.1 and later and own and protect the trademarks associated with P

Is there a way to detect an environment's "default" encoding type (Windows)?

2010-03-24 Thread python
Is there a way to detect an environment's "default" encoding type under Windows? I'm not sure if code page and encoding mean the same thing here. For example: When I use Word on my US based version of Windows and decide to save a file as text, I am prompted with an encoding dialog that defaults to

help sending text to windows edit control

2010-03-24 Thread Richard Leahy
I am trying to write text into a windows edit control using python. it seems to write to every control i try except the edit box not sure if this is a security measure or not. here is my code any help please. import os,sys,subprocess,time from subprocess import * from os import * from cty

Re: Unicode blues in Python3

2010-03-24 Thread John Nagle
nn wrote: To be more informative I am both writing text and binary data together. That is I am embedding text from another source into stream that uses non-ascii characters as "control" characters. In Python2 I was processing it mostly as text containing a few "funny" characters. OK. Then

Re: Advice needed on parallel processing in python

2010-03-24 Thread Shashwat Anand
have you checked hadoop ? On Wed, Mar 24, 2010 at 11:43 PM, Jon Clements wrote: > On 24 Mar, 15:27, Glazner wrote: > > Hi! > > > > I need to replace an app that does number crunching over a local > > network. > > it have about 50 computers as slaves > > each computer needs to run COM that will d

Re: Advice needed on parallel processing in python

2010-03-24 Thread Jon Clements
On 24 Mar, 15:27, Glazner wrote: > Hi! > > I need to replace an app that does number crunching over a local > network. > it have about 50 computers as slaves > each computer needs to run COM that will do the "job" > right now the system uses MFC threads and DCOM to distribute the load. > > as i sa

Re: Programmatically discovering encoding types supported by codecs module

2010-03-24 Thread python
Gabriel, > After looking at how things are done in codecs.c and encodings/__init__.py I > think you should enumerate all modules in the encodings package that define a > getregentry function. Aliases come from encodings.aliases.aliases. Thanks for looking into this for me. Benjamin Kaplan made

Re: Programmatically discovering encoding types supported by codecs module

2010-03-24 Thread python
Benjamin, > According to my brief messing around with the REPL, encodings.aliases.aliases > is a good place to start. I don't know of any way to get the Language column, > but at the very least that will give you most of the supported encodings and > any aliases they have. Thank you - that's e

how to do asynchronous http requests with epoll and python 3.1

2010-03-24 Thread _wolf
i asked this question before on http://stackoverflow.com/questions/2489780/how-to-do-asynchronous-http-requests-with-epoll-and-python-3-1 but without a definitive answer as yet. can someone help me out? i want to do several simple http GET and POST requests in the same process using Python 3.1 wi

Re: Is it possible to use re2 from Python?

2010-03-24 Thread _wolf
yes we can! http://github.com/facebook/pyre2 as pointed out by http://stackoverflow.com/users/219162/daniel-stutzbach now gotta go and try it out. -- http://mail.python.org/mailman/listinfo/python-list

Re: Programmatically discovering encoding types supported by codecs module

2010-03-24 Thread Gabriel Genellina
En Wed, 24 Mar 2010 13:17:16 -0300, escribió: Is there a way to programmatically discover the encoding types supported by the codecs module? For example, the following link shows a table with Codec, Aliases, and Language columns. http://docs.python.org/library/codecs.html#standard-encodings I

Re: Unicode blues in Python3

2010-03-24 Thread nn
Antoine Pitrou wrote: > Le Tue, 23 Mar 2010 10:33:33 -0700, nn a écrit : > > > I know that unicode is the way to go in Python 3.1, but it is getting in > > my way right now in my Unix scripts. How do I write a chr(253) to a > > file? > > > > #nntst2.py > > import sys,codecs > > mychar=chr(253) >

Re: Unicode blues in Python3

2010-03-24 Thread Michael Torrie
Steven D'Aprano wrote: > I think your question is malformed. You need to work out what behaviour > you actually want, before you can ask for help on how to get it. It may or may not be malformed, but I understand the question. So let eme translate for you. How can he write arbitrary bytes ( 0x0

Re: Programmatically discovering encoding types supported by codecs module

2010-03-24 Thread Benjamin Kaplan
On Wed, Mar 24, 2010 at 12:17 PM, wrote: > Is there a way to programmatically discover the encoding types supported by > the codecs module? > > For example, the following link shows a table with Codec, Aliases, and > Language columns. > http://docs.python.org/library/codecs.html#standard-encoding

Re: spams

2010-03-24 Thread Shashwat Anand
seems good :) On Wed, Mar 24, 2010 at 9:12 PM, D'Arcy J.M. Cain wrote: > On Wed, 24 Mar 2010 20:47:12 +0530 > Shashwat Anand wrote: > > Lately this list have been spammed a lot. Any workarounds by moderators? > > Not as long as it is gatewayed to Usenet. You can kill most of the > spam by bloc

Re: C-API: Extract information from function object

2010-03-24 Thread Gabriel Genellina
En Wed, 24 Mar 2010 12:09:27 -0300, moerchendiser2k3 escribió: I have a reference to a function and would like to know how to extract information from a function object. Information I am looking for: line and file where this function is from. PyObject_Call can do this to when I call a funct

Re: What's the matter with docs.python.org?

2010-03-24 Thread kj
In Philip Semanchuk writes: >On Mar 24, 2010, at 12:05 PM, kj wrote: >> In the last couple of weeks, docs.python.org has been down repeatedly >> (like right now). Has anyone else noticed this? >http://downforeveryoneorjustme.com/docs.python.org Very handy. Thanks! ~K -- http://mail.py

Re: What's the matter with docs.python.org?

2010-03-24 Thread Steve Holden
kj wrote: > > > In the last couple of weeks, docs.python.org has been down repeatedly > (like right now). Has anyone else noticed this? http://downforeveryoneorjustme.com/docs.python.org regards Steve -- Steve Holden +1 571 484 6266 +1 800 494 3119 See PyCon Talks from Atlanta 20

Re: sum for sequences?

2010-03-24 Thread Duncan Booth
kj wrote: > Is there a sequence-oriented equivalent to the sum built-in? E.g.: > > seq_sum(((1, 2), (5, 6))) --> (1, 2) + (5, 6) --> (1, 2, 5, 6) > > ? > Apart from the suggestions for Google for general list flattening, for this specific example you could just use the 'sum' built-in: >>>

Re: What's the matter with docs.python.org?

2010-03-24 Thread Philip Semanchuk
On Mar 24, 2010, at 12:05 PM, kj wrote: In the last couple of weeks, docs.python.org has been down repeatedly (like right now). Has anyone else noticed this? http://downforeveryoneorjustme.com/docs.python.org Works for me... HTH Philip -- http://mail.python.org/mailman/listinfo/python-li

Re: What's the matter with docs.python.org?

2010-03-24 Thread python
KJ, > In the last couple of weeks, docs.python.org has been down repeatedly > (like right now). Has anyone else noticed this? I've been surfing docs.python.org all morning and haven't had any problems. I'm connecting from Bethlehem, PA (USA). Malcolm -- http://mail.python.org/mailman/listinfo

Programmatically discovering encoding types supported by codecs module

2010-03-24 Thread python
Is there a way to programmatically discover the encoding types supported by the codecs module? For example, the following link shows a table with Codec, Aliases, and Language columns. http://docs.python.org/library/codecs.html#standard-encodings I'm looking for a way to programmatically generate

What's the matter with docs.python.org?

2010-03-24 Thread kj
In the last couple of weeks, docs.python.org has been down repeatedly (like right now). Has anyone else noticed this? ~K -- http://mail.python.org/mailman/listinfo/python-list

coding contest

2010-03-24 Thread insomnia iit roookee
IIT ROORKEE COGNIZANCE presents INSOMNIA :THE MIDNIGHT PROGRAMMING CONTEST... www.insomnia.cognizance.org.in Starts on : 27th March, 9:00 PM Cash prizes worth Rs.30,000 on stake for this round. (PS: Problems of previous rounds are available for practice.) -- http://mail.python.org/mailman/li

Re: sum for sequences?

2010-03-24 Thread Neil Cerutti
On 2010-03-24, kj wrote: > > > Is there a sequence-oriented equivalent to the sum built-in? E.g.: > > seq_sum(((1, 2), (5, 6))) --> (1, 2) + (5, 6) --> (1, 2, 5, 6) > > ? > > (By "sequence" I'm referring primarily to lists and tuples, and > excluding strings, since for these there is ''.join())

Re: sum for sequences?

2010-03-24 Thread Steve Holden
kj wrote: > > Is there a sequence-oriented equivalent to the sum built-in? E.g.: > > seq_sum(((1, 2), (5, 6))) --> (1, 2) + (5, 6) --> (1, 2, 5, 6) > > ? > > (By "sequence" I'm referring primarily to lists and tuples, and > excluding strings, since for these there is ''.join()). > Do you me

Re: spams

2010-03-24 Thread D'Arcy J.M. Cain
On Wed, 24 Mar 2010 20:47:12 +0530 Shashwat Anand wrote: > Lately this list have been spammed a lot. Any workarounds by moderators? Not as long as it is gatewayed to Usenet. You can kill most of the spam by blocking anything from gmail.com with a Newsgroups line. Unfortunately you will also bloc

Re: sum for sequences?

2010-03-24 Thread Glazner
On Mar 24, 5:29 pm, kj wrote: > Is there a sequence-oriented equivalent to the sum built-in?  E.g.: > >   seq_sum(((1, 2), (5, 6))) --> (1, 2) + (5, 6) --> (1, 2, 5, 6) > > ? > > (By "sequence" I'm referring primarily to lists and tuples, and > excluding strings, since for these there is ''.join()

sum for sequences?

2010-03-24 Thread kj
Is there a sequence-oriented equivalent to the sum built-in? E.g.: seq_sum(((1, 2), (5, 6))) --> (1, 2) + (5, 6) --> (1, 2, 5, 6) ? (By "sequence" I'm referring primarily to lists and tuples, and excluding strings, since for these there is ''.join()). TIA! ~K -- http://mail.python.org/ma

Advice needed on parallel processing in python

2010-03-24 Thread Glazner
Hi! I need to replace an app that does number crunching over a local network. it have about 50 computers as slaves each computer needs to run COM that will do the "job" right now the system uses MFC threads and DCOM to distribute the load. as i said, Now i'm trying to replace this system with pyt

spams

2010-03-24 Thread Shashwat Anand
Lately this list have been spammed a lot. Any workarounds by moderators? ~l0nwlf -- http://mail.python.org/mailman/listinfo/python-list

C-API: Extract information from function object

2010-03-24 Thread moerchendiser2k3
Hi, I have a reference to a function and would like to know how to extract information from a function object. Information I am looking for: line and file where this function is from. PyObject_Call can do this to when I call a function object and something failed so these information are written

Sniffing encoding type by looking at file BOM header

2010-03-24 Thread python
I assume there's no standard library function that wraps codecs.open() to sniff a file's BOM header and open the file with the appropriate encoding? My reading of the docs leads me to believe that there are 5 types of possible BOM headers with multiple names (synoymns?) for the same BOM encoding

crypto: verify external pkcs7 signature

2010-03-24 Thread Thomas Guettler
Hi, some black box system gives me secKey.pkcs7 signature and a data file. The signature should be correct, but it fails. On newer system I get this: M2Crypto.SMIME.PKCS7_Error: digest failure on older systems (openssl-0.9.8h-28.10.1) I get PKCS7 routines:PKCS7_verify:signature failure:pk7_smi

Re: Unicode blues in Python3

2010-03-24 Thread Antoine Pitrou
Le Tue, 23 Mar 2010 10:33:33 -0700, nn a écrit : > I know that unicode is the way to go in Python 3.1, but it is getting in > my way right now in my Unix scripts. How do I write a chr(253) to a > file? > > #nntst2.py > import sys,codecs > mychar=chr(253) > print(sys.stdout.encoding) > print(mycha

Re: Unicode blues in Python3

2010-03-24 Thread nn
Steven D'Aprano wrote: > On Tue, 23 Mar 2010 11:46:33 -0700, nn wrote: > > > Actually what I want is to write a particular byte to standard output, > > and I want this to work regardless of where that output gets sent to. > > What do you mean "work"? > > Do you mean "display a particular glyph" o

Re: Unicode blues in Python3

2010-03-24 Thread nn
Martin v. Loewis wrote: > nn wrote: > > > > Stefan Behnel wrote: > >> nn, 23.03.2010 19:46: > >>> Actually what I want is to write a particular byte to standard output, > >>> and I want this to work regardless of where that output gets sent to. > >>> I am aware that I could do > >>> open('nnout',

ANN: eGenix mxODBC Zope Database Adapter 2.0.0

2010-03-24 Thread eGenix Team: M.-A. Lemburg
ANNOUNCEMENT mxODBC Zope Database Adapter Version 2.0.0 for Zope and the Plone CMS Available for Zope 2.12 and later on Windows,

Re: exiting threaded program?

2010-03-24 Thread Tim Golden
On 24/03/2010 11:04, Alex Hall wrote: A daemon... Good idea, and that makes more sense for what the thread does anyway; it is just a timer, updating a variable by contacting a server every hour. By the way, just what is the difference between user32.PostQuitMessage (0) and sys.exit()? The forme

Re: exiting threaded program?

2010-03-24 Thread Alex Hall
A daemon... Good idea, and that makes more sense for what the thread does anyway; it is just a timer, updating a variable by contacting a server every hour. By the way, just what is the difference between user32.PostQuitMessage (0) and sys.exit()? On 3/24/10, Tim Golden wrote: > On 24/03/2010 10

Re: exiting threaded program?

2010-03-24 Thread Alf P. Steinbach
* Alex Hall: Hi all, I have a program with a timer in it, therefore I have multiple threads. Is the "therefore..." an inference or independendent information? If it is an inference then it may not be correct. For example, timers in a GUI program need not involve additional threads. My meth

Re: logging: local functions ==> loss of lineno

2010-03-24 Thread Vinay Sajip
On Mar 24, 9:34 am, Peter Otten <__pete...@web.de> wrote: > > You mean you'd have to monkey-patchlogging._findCaller() instead of > overridinglogging.Logger.findCaller()? > > I don't see a big advantage in that. > Only that you just have to replace a function, and not have to subclass Logger + ove

Re: exiting threaded program?

2010-03-24 Thread Tim Golden
On 24/03/2010 10:43, Alex Hall wrote: Hi all, I have a program with a timer in it, therefore I have multiple threads. My method of exiting by using "user32.PostQuitMessage (0)" no longer seems to be doing the job since I added the timer. What else do I have to do to close my program? I say it is

Re: using message loop for hotkey capturing

2010-03-24 Thread Alex Hall
Thanks, it seems to be working for now... Hopefully that trend continues! On 3/24/10, Tim Golden wrote: > On 23/03/2010 17:01, Alex Hall wrote: >> Hi all, but mainly Tim Golden: >> Tim, I am using your wonderful message loop for keyboard input, the >> one on your site that you pointed me to a few

exiting threaded program?

2010-03-24 Thread Alex Hall
Hi all, I have a program with a timer in it, therefore I have multiple threads. My method of exiting by using "user32.PostQuitMessage (0)" no longer seems to be doing the job since I added the timer. What else do I have to do to close my program? I say it is not closing because, before, I would be

Re: logging: local functions ==> loss of lineno

2010-03-24 Thread Jean-Michel Pichavant
Peter Otten wrote: Vinay Sajip wrote: Sorry I'm a little late to this discussion. I could add a _findCaller function to the module (not part of the public API, but replaceable by someone who really needs to) which does the heavy lifting, and Logger.findCaller just calls it. Then those who ne

Re: Where can i reference the "regular expressions"

2010-03-24 Thread Andre Engels
On Wed, Mar 24, 2010 at 10:34 AM, John Smithury wrote: > ==source > the > is > name > ==source end= > > First, get the word only(discard the "" and ""), it can use > regular expression, right? > > the > is > name > Second, get a charactor in each word an

Re: using message loop for hotkey capturing

2010-03-24 Thread Tim Golden
On 23/03/2010 17:01, Alex Hall wrote: Hi all, but mainly Tim Golden: Tim, I am using your wonderful message loop for keyboard input, the one on your site that you pointed me to a few months ago. It has been working perfectly as long as I had only one dictionary of keys mapping to one dictionary o

Re: logging: local functions ==> loss of lineno

2010-03-24 Thread Peter Otten
Vinay Sajip wrote: > Sorry I'm a little late to this discussion. I could add a _findCaller > function to the module (not part of the public API, but replaceable by > someone who really needs to) which does the heavy lifting, and > Logger.findCaller just calls it. Then those who need to can impleme

Re: Where can i reference the "regular expressions"

2010-03-24 Thread Andre Engels
On Wed, Mar 24, 2010 at 10:07 AM, John Smithury wrote: > Dear pythoners, > > I'm a new member to studay the python, i wan't to studay the "regular > expressions" handle like below: > > ==source > the > is > name > ==source end= > > > after convert, the r

Where can i reference the "regular expressions"

2010-03-24 Thread John Smithury
Dear pythoners, I'm a new member to studay the python, i wan't to studay the "regular expressions" handle like below: ==source the is name ==source end= after convert, the result like below: -result {'t

Re: Castrated traceback in sys.exc_info()

2010-03-24 Thread Gabriel Genellina
En Tue, 23 Mar 2010 19:43:40 -0300, Vinay Sajip escribió: On Mar 23, 8:49 pm, Pascal Chambon wrote: Should I open an issue for this evolution of exceptiuon handling, or should we content ourselves of this "hacking" of frame stck ? Possibly worth raising an issue (not logging-related), but

Re: Python is cool!!

2010-03-24 Thread Stef Mientki
On 23-03-2010 17:55, Jose Manuel wrote: I have been learning Python, and it is amazing I am using the tutorial that comes with the official distribution. At the end my goal is to develop applied mathematic in engineering applications to be published on the Web, specially on app. oriented to

Re: Python is cool!!

2010-03-24 Thread Parker
On Mar 23, 4:55 pm, Jose Manuel wrote: > I have been learning Python, and it is amazing I am using the > tutorial that comes with the official distribution. > > At the end my goal is to develop applied mathematic in engineering > applications to be published on the Web, specially on app. orie