Re: Bug in string.find; was: Re: Proposed PEP: New style indexing,was Re: Bug in slice type

2005-08-29 Thread Paul Rubin
"Terry Reedy" <[EMAIL PROTECTED]> writes: > The fact that the -1 return *has* lead to bugs in actual code is the > primary reason Guido has currently decided that find and rfind should go. > A careful review of current usages in the standard library revealed at > least a couple bugs even there.

Re: Writing Multithreaded Client-Server in Python.

2005-08-29 Thread Paul Rubin
"Sidd" <[EMAIL PROTECTED]> writes: >I tried finding and example of multithreaded client-serve program in > python. Can any one please tell me how to write a multithreaded > client-server programn in python such that > 1.It can handle multiple connections > 2.It uses actual threads and not selec

Re: trictionary?

2005-08-29 Thread [EMAIL PROTECTED]
Bengt Richter wrote: > On 28 Aug 2005 18:54:40 -0700, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > > >Steven Bethard wrote: > >> Adam Tomjack wrote: > >> > Steven Bethard wrote: > >> > ... > >> >> Using a two element list to store a pair of counts has a bad code > >> >> smell to me. > >> > ...

Re: Bug in string.find; was: Re: Proposed PEP: New style indexing,was Re: Bug in slice type

2005-08-29 Thread Terry Reedy
"Steve Holden" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Antoon Pardon wrote: >> So what happens if you have a module that is collecting string-index >> pair, colleted from various other parts. In one part you >> want to select the last letter, so you pythonically choose -1 as

Re: global interpreter lock

2005-08-29 Thread Bryan Olson
Mike Meyer wrote: > Bryan Olson <[EMAIL PROTECTED]> writes: >> > Bryan Olson writes: >> > Trivially, an 'if' statement that depends upon input >> >>data is statically predictable. Use of async I/O means makes the >> >>programs execution dependent upon external timing. >>Mike Meyer wrote: >>

Re: aproximate a number

2005-08-29 Thread Grant Edwards
On 2005-08-30, Devan L <[EMAIL PROTECTED]> wrote: > Grant Edwards wrote: >> On 2005-08-30, Devan L <[EMAIL PROTECTED]> wrote: >> > >> > RoundToInt(2.0) will give you 3. >> >> That's what the OP said he wanted. The next bigger integer >> after 2.0 is 3. > > It's not really clear whether he wanted i

Writing Multithreaded Client-Server in Python.

2005-08-29 Thread Sidd
Hi, I tried finding and example of multithreaded client-serve program in python. Can any one please tell me how to write a multithreaded client-server programn in python such that 1.It can handle multiple connections 2.It uses actual threads and not select() or some other function -- http://ma

Re: aproximate a number

2005-08-29 Thread Devan L
Grant Edwards wrote: > On 2005-08-30, Devan L <[EMAIL PROTECTED]> wrote: > > > > RoundToInt(2.0) will give you 3. > > That's what the OP said he wanted. The next bigger integer > after 2.0 is 3. > > -- > Grant Edwards grante Yow! I'd like TRAINED >

Re: [Jython-users] Re: [Jython-dev] Parsing grammar for jython available (compatible with python 2.4)

2005-08-29 Thread could ildg
thanks. pydev is very nice, I like it. But sometimes the code completion will not work.On 8/30/05, Frank Wierzbicki <[EMAIL PROTECTED]> wrote: The code, as well as the files for javacc and asdl (both were changed) are available in the pydev cvs at sourceforge, in theorg.python.pydev.parser module

Re: aproximate a number

2005-08-29 Thread Grant Edwards
On 2005-08-30, Devan L <[EMAIL PROTECTED]> wrote: >>> Hi all. I'd need to aproximate a given float number into the >>> next (int) bigger one. Because of my bad english I try to >>> explain it with some example: >>> >>> 5.7 --> 6 >>> 52.987 --> 53 >>> 3.34 --> 4 >>> 2.1 --> 3 >> >> The standard way

Re: aproximate a number

2005-08-29 Thread Devan L
Thomas Bartkus wrote: > On Sun, 28 Aug 2005 23:11:09 +0200, billiejoex wrote: > > > Hi all. I'd need to aproximate a given float number into the next (int) > > bigger one. Because of my bad english I try to explain it with some example: > > > > 5.7 --> 6 > > 52.987 --> 53 > > 3.34 --> 4 > > 2.1 -->

Re: Using select on a unix command in lieu of signal

2005-08-29 Thread Jp Calderone
On 29 Aug 2005 17:57:34 -0700, rh0dium <[EMAIL PROTECTED]> wrote: >So here's how I solved this.. It's seems crude - but hey it works. >select not needed.. > >def runCmd( self, cmd, timeout=None ): >self.logger.debug("Initializing function %s - %s" % >(sys._getframe().f_code.co_name,cmd

Re: aproximate a number

2005-08-29 Thread Thomas Bartkus
On Sun, 28 Aug 2005 23:11:09 +0200, billiejoex wrote: > Hi all. I'd need to aproximate a given float number into the next (int) > bigger one. Because of my bad english I try to explain it with some example: > > 5.7 --> 6 > 52.987 --> 53 > 3.34 --> 4 > 2.1 --> 3 > The standard way to do this is

Re: File parser

2005-08-29 Thread Rune Strand
It's not clear to me from your posting what possible order the tags may be inn. Assuming you will always END a section before beginning an new, eg. it's always: A some A-section lines. END A B some B-section lines. END B etc. And never: A some A-section lines. B some B-section lines. END B

Re: File parser

2005-08-29 Thread William Park
Angelic Devil <[EMAIL PROTECTED]> wrote: > BAR > END BAR > > FOOBAR > END FOOBAR man csplit -- William Park <[EMAIL PROTECTED]>, Toronto, Canada ThinFlash: Linux thin-client on USB key (flash) drive http://home.eol.ca/~parkw/thinflash.html BashDiff: Super Bash shell h

Re: Jargons of Info Tech industry

2005-08-29 Thread John Bokma
Alan Balmer <[EMAIL PROTECTED]> wrote: > On 29 Aug 2005 21:12:13 GMT, John Bokma <[EMAIL PROTECTED]> wrote: > >>> Now, go away. And please, stay away. >> >>Like I already said, it doesn't work that way. > > Goodbye, John. Filters set. Saidly you didn't get the message. Moreover you think that t

Re: new line

2005-08-29 Thread Peter Hansen
Kuljo wrote: > Kuljo wrote: >>I'm so sorry to bore you with this trivial problem. Allthou: I have string >>having 0x0a as new line, but I should have \n instead. > I have found this in the meantime: nl="\\"+"n" Note: this is unnecessary. You could just do nl='\\n' instead, and you don't nee

Re: Writing portable applications

2005-08-29 Thread Mike Meyer
Ulrich Hobelmann <[EMAIL PROTECTED]> writes: > Mike Meyer wrote: >> I'm still waiting for an answer to that one - where's the Java toolkit >> that handles full-featured GUIs as well as character cell >> interfaces. Without that, you aren't doing the job that the web >> technologies do. > Where is t

Re: OpenSource documentation problems

2005-08-29 Thread Mike Meyer
"Adriaan Renting" <[EMAIL PROTECTED]> writes: > Marked -1 Flamebait, but I'll respond anyway. Yup. > I do agree that a lot of OSS projects seem to lack somewhat in the > documentation department, compared to a lot of commercial software. You know what? My experience is just the opposite. Commerc

Re: Using select on a unix command in lieu of signal

2005-08-29 Thread rh0dium
So here's how I solved this.. It's seems crude - but hey it works. select not needed.. def runCmd( self, cmd, timeout=None ): self.logger.debug("Initializing function %s - %s" % (sys._getframe().f_code.co_name,cmd) ) command = cmd + "\n" child = popen2.Popen3(command)

Re: new line

2005-08-29 Thread Kuljo
Kuljo wrote: > Dear friends > I'm so sorry to bore you with this trivial problem. Allthou: I have string > having 0x0a as new line, but I should have \n instead. > How should I solve it? > I've tried text_new=tex_old.replace(str(0x0a), '\n') > and other things, but none of them worked. > Thank

Re: overload builtin operator

2005-08-29 Thread Bengt Richter
On Sun, 28 Aug 2005 23:27:07 -0400, "Terry Reedy" <[EMAIL PROTECTED]> wrote: >I suspect that PyPy, when further alone, will make it easier to do things >like develop a customized interpreter that has alternate definitions for >builtin operators. So maybe the OP should ask again in a year or two

python-dev Summary for 2005-08-01 through 2005-08-15

2005-08-29 Thread Tony Meyer
[The HTML version of this Summary is available at http://www.python.org/dev/summary/2005-08-01_2005-08-15.html] = Announcements = QOTF: Quote of the Fortnight Some wise words from Donovan Baarda in the PEP 347 di

Re: using common lisp with python.

2005-08-29 Thread Mike Meyer
"[EMAIL PROTECTED]" <[EMAIL PROTECTED]> writes: > Your best bet is probably to look into your LISP environment's FFI > (Foreign Function Interface). Most LISP environments have some way to > call C code directly. Insofar as going back the other way... that I'm > a little more sketchy on. Guile (

Re: global interpreter lock

2005-08-29 Thread Mike Meyer
Bryan Olson <[EMAIL PROTECTED]> writes: > Mike Meyer wrote: > > Bryan Olson writes: > > phil hunt wrote: > >> > What's important is *predictability*, e.g. which instruction will > >> > the computer execute next? > >> > If you only have one thread, you can tell by looking at the code > >> > wh

File parser

2005-08-29 Thread Angelic Devil
I'm building a file parser but I have a problem I'm not sure how to solve. The files this will parse have the potential to be huge (multiple GBs). There are distinct sections of the file that I want to read into separate dictionaries to perform different operations on. Each section has specific

Drag&Drop in wxListCtrl

2005-08-29 Thread [EMAIL PROTECTED]
Hi, I have to create a ListBox in which I have to move items up and down using DnD. How to create drag and drop call backs in wxListCtrl. I can see EVT_LIST_BEGIN_DRAG but I could not find any EVT_LIST_END_DRAG. So, how can I achieve DnD with ListCtrl? Thanks in advance for the suggestions. Reg

a list of Checkbuttons

2005-08-29 Thread William Gill
OK I'm tired, I've got a cold, and my brain isn't working very well. I have a result set ( a tuple of tuples) from a db. Each element has two elements; classification number, and classification heading. i.e. result=((001,'heading one'),(002,'heading two'),...) classification numbers may not

Re: Jargons of Info Tech industry

2005-08-29 Thread Alan Balmer
On 29 Aug 2005 21:12:13 GMT, John Bokma <[EMAIL PROTECTED]> wrote: >> Now, go away. And please, stay away. > >Like I already said, it doesn't work that way. Goodbye, John. Filters set. -- Al Balmer Balmer Consulting [EMAIL PROTECTED] -- http://mail.python.org/mailman/listinfo/python-list

Re: trictionary?

2005-08-29 Thread Bengt Richter
On 28 Aug 2005 18:54:40 -0700, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: >Steven Bethard wrote: >> Adam Tomjack wrote: >> > Steven Bethard wrote: >> > ... >> >> Using a two element list to store a pair of counts has a bad code >> >> smell to me. >> > ... >> > >> > Why is that? >> >> Note that

networking

2005-08-29 Thread amf
I'm seeking learn more about Python, and specifically to talk with people in the greater Boston, MA area. Can anyone suggest the best way to do this? Feel free to contact me offline: [EMAIL PROTECTED] Amf -- http://mail.python.org/mailman/listinfo/python-list

Re: socket.gaierror from httplib

2005-08-29 Thread spamsink42
fantastic. many thanks. regards, eric -- http://mail.python.org/mailman/listinfo/python-list

Re: python and ajax

2005-08-29 Thread Jp Calderone
On Mon, 29 Aug 2005 12:04:46 -0700 (PDT), Steve Young <[EMAIL PROTECTED]> wrote: >Hi, I was wondering if anybody knew of any good >tutorial/example of AJAX/xmlhttprequest in python. >Thanks. > There's a short example of Nevow's LivePage online here: http://divmod.org/svn/Nevow/trunk/examples/live

Re: Basic Server/Client socket pair not working

2005-08-29 Thread Jp Calderone
On Mon, 29 Aug 2005 21:30:51 +0200, Michael Goettsche <[EMAIL PROTECTED]> wrote: >Hi there, > >I'm trying to write a simple server/client example. The client should be able >to send text to the server and the server should distribute the text to all >connected clients. However, it seems that only t

Re: SocketServer and a Java applet listener

2005-08-29 Thread google
Steve Horsley schreef: > [EMAIL PROTECTED] wrote: > > Steve Horsley schreef: > > > > > >>Probably the same problem. If you didn't send a 2 byte length > >>indicator first, then java's readUTF() will have tried to > >>interpret the first 2 bytes that you did actually send as the > >>string length,

Re: Cygwin font problems

2005-08-29 Thread Steve Holden
Robin Becker wrote: > Steve Holden wrote: > >>Is anyone aware of (a fix for) problems I'm having getting PIL 1.1.5 to >>create bitmaps using TrueType and openType fonts? When I create an image >>using the standard PIL fonts everything seems fine, but when I use >>ImageFont.truetype(, ) no text

Re: Bug in string.find; was: Re: Proposed PEP: New style indexing, was Re: Bug in slice type

2005-08-29 Thread Steve Holden
Antoon Pardon wrote: > Op 2005-08-27, Steve Holden schreef <[EMAIL PROTECTED]>: > >>> >>If you want an exception from your code when 'w' isn't in the string you >>should consider using index() rather than find. > > > Sometimes it is convenient to have the exception thrown at a later > time. >

Re: socket.gaierror from httplib

2005-08-29 Thread Steve Holden
[EMAIL PROTECTED] wrote: > this code > > h=httplib.HTTPConnection('euronext.com') > h.request('GET', > 'http://www.euronext.com/home/0,3766,1732,00.html') > > fails with this message > > File "httplib.py", line 532, in connect > socket.SOCK_STREAM): > socket.gaierror: (

Re: python and ajax

2005-08-29 Thread Peter Hansen
Steve Young wrote: > Hi, I was wondering if anybody knew of any good > tutorial/example of AJAX/xmlhttprequest in python. > Thanks. I can't say if it's "good" since I haven't looked at it yet, but it's certainly timely: this was just posted to the c.l.p.announce group: --

Re: Exploring outlook contents

2005-08-29 Thread Peter Hansen
Subir wrote: > I am trying to build an application to explore the contents of an > outlook .pst files. All the reference that I have seen uses the > registry to do so. Does any one know any other way of doing this. Also, > is anyone has any code which does something related to this, please let >

Re: Using select on a unix command in lieu of signal

2005-08-29 Thread rh0dium
Paul Rubin wrote: > "rh0dium" <[EMAIL PROTECTED]> writes: > > Thanks much - Alternatively if anyone else has a better way to do what > > I am trying to get done always looking for better ways. I still want > > this to work though.. > > You don't have to use select, since you can use timeouts with

Re: Jargons of Info Tech industry

2005-08-29 Thread John Bokma
Alan Balmer <[EMAIL PROTECTED]> wrote: > On 29 Aug 2005 18:21:12 GMT, John Bokma <[EMAIL PROTECTED]> wrote: > >>Alan Balmer <[EMAIL PROTECTED]> wrote: >> >>> Why on earth was this cross-posted to comp.lang.c.? Followups set. >> >>Your reply is even more meaningless and more noise compared to the

Re: Python-list Digest, Vol 23, Issue 415

2005-08-29 Thread Christopher DeMarco
On Mon, Aug 29, 2005 at 10:43:46PM +0200, [EMAIL PROTECTED] wrote: > Date: Mon, 29 Aug 2005 16:32:59 -0400 > To: python-list@python.org > From: Steve Holden <[EMAIL PROTECTED]> > Subject: Re: NYC Opening > >THEY ARE LOCATED IN NEW YORK, THIS IS FULL-TIME ONLY, WILL NOT CONSIDER > >ANYONE FROM O

Re: Using select on a unix command in lieu of signal

2005-08-29 Thread Paul Rubin
"rh0dium" <[EMAIL PROTECTED]> writes: > Thanks much - Alternatively if anyone else has a better way to do what > I am trying to get done always looking for better ways. I still want > this to work though.. You don't have to use select, since you can use timeouts with normal socket i/o. So you co

Re: NYC Opening

2005-08-29 Thread Steve Holden
Kevin McGann wrote: > A major Investment Bank is searching for a strong Java or C++ developer that > can build Pipes to Electronic Exchanges and ECNs. This is a new Internal > Hedge Fund Business and they are looking for superb C++ or Java programmers > that can enable them to go live in 1-2 months

Re: suggestion for Python graphing package, please

2005-08-29 Thread Robert Kern
Stewart Midwinter wrote: > I need a graphing library that I can access from within a Tkinter > application running on Windows. http://matplotlib.sourceforge.net -- Robert Kern [EMAIL PROTECTED] "In the fields of hell where the grass grows high Are the graves of dreams allowed to die." -- Ric

Re: new line

2005-08-29 Thread Robert Kern
Kuljo wrote: > Dear friends > I'm so sorry to bore you with this trivial problem. Allthou: I have string > having 0x0a as new line, but I should have \n instead. In [9]: '\x0a' Out[9]: '\n' They're the same thing. -- Robert Kern [EMAIL PROTECTED] "In the fields of hell where the grass grows hi

Using select on a unix command in lieu of signal

2005-08-29 Thread rh0dium
Hi all, Another newbie question. So you can't use signals on threads but you can use select. The reason I want to do this in the first place it I need a timeout. Fundamentally I want to run a command on another machine, but I need a timeout. I have to do this to a LOT of machines ( > 3000 ) an

Re: close failed: [Errno 0] No error goes to stdout

2005-08-29 Thread Steve Holden
Yoav wrote: > I run a Java command line program. The point is, that it's not the > program that output this error message for sure. And I don't expect > popen3() to catch and report errors. I just want to keep my screen > output clean, and I expect popen3() to run the program and not let > anyt

Re: new line

2005-08-29 Thread Claudio Grondi
"Kuljo" <[EMAIL PROTECTED]> schrieb im Newsbeitrag news:[EMAIL PROTECTED] > Dear friends > I'm so sorry to bore you with this trivial problem. Allthou: I have string > having 0x0a as new line, but I should have \n instead. > How should I solve it? > I've tried > >>>text_new=tex_old.replace(str(0x0a

suggestion for Python graphing package, please

2005-08-29 Thread Stewart Midwinter
I need a graphing library that I can access from within a Tkinter application running on Windows. It needs to be able to draw some *simple* 2D plots, and then output them to a file (e.g. .PNG, .JPG) for inclusion in a HTML-formatted e-mail to interested parties. Many of the packages that I've lo

Re: Robust statistics and optimmization from Python

2005-08-29 Thread Tim Churches
[EMAIL PROTECTED] wrote: > Robert Kern wrote: > > > >>If you find suitable >>FORTRAN or C code that implements a particular "robust" algorithm, it >>can probably wrapped for scipy relatively easily. > > > An alternative would be to call R (a free statistical package) from > Python, using somet

Re: python and ajax

2005-08-29 Thread matt
Steve- I recently ported version 1.3 of cpaint to python. Soon after version 2.0 was released and I haven't really looked at it since. The 1.3 stuff was really simple though if you understand cgi, then you just implement a endpoint for your request to call. The javascript side is really the onl

Re: python xml DOM? pulldom? SAX?

2005-08-29 Thread William Park
jog <[EMAIL PROTECTED]> wrote: > Hi, > I want to get text out of some nodes of a huge xml file (1,5 GB). The > architecture of the xml file is something like this > > > bla > > > > blablabla > > > > > > > I want to combine the text out of p

Re: reg email packages work

2005-08-29 Thread Steve Holden
praba kar wrote: > Dear All, > >I am working in web based email system project. > Here I try to build email message > from scratch. I used below code to build email > message > >msg = email.MIMEBase('text','html') >msg['Return-Path'] = user+'@'+domain >msg['Date'] = formatdat

Re: Basic Server/Client socket pair not working

2005-08-29 Thread Nicolas Couture
Michael Goettsche wrote: > Hi there, > > I'm trying to write a simple server/client example. The client should be able > to send text to the server and the server should distribute the text to all > connected clients. However, it seems that only the first entered text is sent > and received. When

Re: NooB Question

2005-08-29 Thread Jeff Schwab
APCass wrote: > How do you execute a .py in Linux with KDE? If I double click on my > program it opens Kwrite, for editing. Try inserting this as the first line of the file: #!/usr/bin/env python -- http://mail.python.org/mailman/listinfo/python-list

Re: global interpreter lock

2005-08-29 Thread Bryan Olson
Mike Meyer wrote: > Bryan Olson writes: > phil hunt wrote: > >> > What's important is *predictability*, e.g. which instruction will >> > the computer execute next? >> > >> > If you only have one thread, you can tell by looking at the code >> > what gets executed next. It's very simple. >>N

Re: python image thumbnail generator?

2005-08-29 Thread Damjan
Chris Dewin wrote: > Hi. I run a website for my band, and the other guys want an image gallery. > > I'm thinking it would be nice and easy, if we could just upload a jpg into > a dir called "gallery/". When the client clicks the "gallery" link, a > cgi script could search the gallery/ dir, and cr

new line

2005-08-29 Thread Kuljo
Dear friends I'm so sorry to bore you with this trivial problem. Allthou: I have string having 0x0a as new line, but I should have \n instead. How should I solve it? I've tried >>>text_new=tex_old.replace(str(0x0a), '\n') and other things, but none of them worked. Thanks in advance -- http://mail

Re: Virtual Slicing

2005-08-29 Thread Bryan Olson
Sybren Stuvel wrote: > Bryan Olson enlightened us with: > >>I recently wrote a module supporting value-shared slicing. > > Maybe I'm dumb, but could you explain this concept? Why would someone > whant this? My original motivation was reduce the amount of copying in some tools that parse nest

Basic Server/Client socket pair not working

2005-08-29 Thread Michael Goettsche
Hi there, I'm trying to write a simple server/client example. The client should be able to send text to the server and the server should distribute the text to all connected clients. However, it seems that only the first entered text is sent and received. When I then get prompted for input agai

Re: Robust statistics and optimmization from Python

2005-08-29 Thread araki
use R. it's pretty highend, and there is an interface for python. -- http://mail.python.org/mailman/listinfo/python-list

Re: python image thumbnail generator?

2005-08-29 Thread Paul Rubin
"Fredrik Lundh" <[EMAIL PROTECTED]> writes: > > You could do it with PIL, or run jpegtran in an external process. > > jpegtran may be easier. > > eh? are you sure you know what jpegtran does? > > JPEGTRAN(1) Whoops, sorry, right, jpegtran is for rotating the images. I meant: use a pipeline li

Re: python and ajax

2005-08-29 Thread Do Re Mi chel La Si Do
Hi ! Here : http://wikipython.flibuste.net/moin.py/AJAX @-salutations Michel Claveau -- http://mail.python.org/mailman/listinfo/python-list

Re: Exploring outlook contents

2005-08-29 Thread Beowulf TrollsHammer
Subir wrote: > Hi, > > I am trying to build an application to explore the contents of an > outlook .pst files. All the reference that I have seen uses the > registry to do so. Does any one know any other way of doing this. Also, > is anyone has any code which does something related to this, plea

python and ajax

2005-08-29 Thread Steve Young
Hi, I was wondering if anybody knew of any good tutorial/example of AJAX/xmlhttprequest in python. Thanks. -Steve Start your day with Yahoo! - make it your home page http://www.yahoo.com/r/hs -- http://mail.python.org/mai

Re: python xml DOM? pulldom? SAX?

2005-08-29 Thread Alan Kennedy
[Alan Kennedy] >>SAX is perfect for the job. See code below. [Fredrik Lundh] > depends on your definition of perfect... Obviously, perfect is the eye of the beholder ;-) [Fredrik Lundh] > using a 20 MB version of jog's sample, and having replaced > the print statements with local variable assi

Re: Cygwin font problems

2005-08-29 Thread Robin Becker
Steve Holden wrote: > Is anyone aware of (a fix for) problems I'm having getting PIL 1.1.5 to > create bitmaps using TrueType and openType fonts? When I create an image > using the standard PIL fonts everything seems fine, but when I use > ImageFont.truetype(, ) no text is drawn. > > setup.py r

Re: python xml DOM? pulldom? SAX?

2005-08-29 Thread Fredrik Lundh
Alan Kennedy wrote: > SAX is perfect for the job. See code below. depends on your definition of perfect... using a 20 MB version of jog's sample, and having replaced the print statements with local variable assignments, I get the following timings: 5 lines of cElementTree code: 7.2 seconds 60+

Re: Jargons of Info Tech industry

2005-08-29 Thread John Bokma
Alan Balmer <[EMAIL PROTECTED]> wrote: > On Fri, 26 Aug 2005 16:47:10 GMT, Chris Head <[EMAIL PROTECTED]> > wrote: > >>This point I agree with. There are some situations - 'net cafes included >>- - where thick e-mail clients don't work. Even so, see below. > > I use Portable Thunderbird, on a US

Re: Jargons of Info Tech industry

2005-08-29 Thread John Bokma
Alan Balmer <[EMAIL PROTECTED]> wrote: > Why on earth was this cross-posted to comp.lang.c.? Followups set. Your reply is even more meaningless and more noise compared to the crosspost. Why? You didn't add anything, you quote an entire message and you just tweaked the follow up to header in a b

Re: using common lisp with python.

2005-08-29 Thread Robert Kern
[EMAIL PROTECTED] wrote: > Your best bet is probably to look into your LISP environment's FFI > (Foreign Function Interface). Most LISP environments have some way to > call C code directly. Insofar as going back the other way... that I'm > a little more sketchy on. Guile (the Scheme compiler fro

Re: using common lisp with python.

2005-08-29 Thread [EMAIL PROTECTED]
Your best bet is probably to look into your LISP environment's FFI (Foreign Function Interface). Most LISP environments have some way to call C code directly. Insofar as going back the other way... that I'm a little more sketchy on. Guile (the Scheme compiler from GNU) is a strong contender, tho

command history behavior in windows and linux

2005-08-29 Thread Leo
Does someone know if there is a setting in the python Unix world to make the command history behave as it does in the Windows intepreter? Specifically, I like the fact that the command history remembers which of a sequence of commands is the one that I last issued. For example, suppose that I typed

Re: Newbie question: Sub-interpreters for CAD program

2005-08-29 Thread David MacQuigg
On 27 Aug 2005 17:00:07 -0700, "sonicSpammersGoToHellSmooth" <[EMAIL PROTECTED]> wrote: >Cool, I went to the UofA for my MS in ECE, 2000. I did my theses under >Chuck Higgins. -- >http://neuromorph.ece.arizona.edu/pubs/ma_schwager_msthesis.pdf > >The tools we had were constantly underwhelming me,

Re: Newbie question: Sub-interpreters for CAD program

2005-08-29 Thread David MacQuigg
On Sat, 27 Aug 2005 16:56:03 -0500, Terry Hancock <[EMAIL PROTECTED]> wrote: >On Saturday 27 August 2005 03:21 am, David MacQuigg wrote: >> There is a similar lack of interest in the academic community. None >> of this is likely to lead to publications in scholarly journals. > >I'm confused by wh

Re: python xml DOM? pulldom? SAX?

2005-08-29 Thread Alan Kennedy
[jog] > I want to get text out of some nodes of a huge xml file (1,5 GB). The > architecture of the xml file is something like this [snip] > I want to combine the text out of page:title and page:revision:text > for every single page element. One by one I want to index these > combined texts

Re: trictionary?

2005-08-29 Thread Randy Bush
> So I'm going to try to pump you for a little more information here. Is > your goal to count, for each week, how many times it's "full" and how > many times it's "not full"? What do you use the counts for? What does > "full" mean? Is it always a 0 or 1? What's the importance of the > outp

Exploring outlook contents

2005-08-29 Thread Subir
Hi, I am trying to build an application to explore the contents of an outlook .pst files. All the reference that I have seen uses the registry to do so. Does any one know any other way of doing this. Also, is anyone has any code which does something related to this, please let me know. -Subir

Re: Jargons of Info Tech industry

2005-08-29 Thread Alan Balmer
On Fri, 26 Aug 2005 16:47:10 GMT, Chris Head <[EMAIL PROTECTED]> wrote: >This point I agree with. There are some situations - 'net cafes included >- - where thick e-mail clients don't work. Even so, see below. I use Portable Thunderbird, on a USB memory stick. All I need is a USB port and an inte

ANN: PyDev 0.9.8 released

2005-08-29 Thread Fabio Zadrozny
Hi All, PyDev - Python IDE (Python Development Enviroment for Eclipse) version 0.9.8 has just been released. Check the homepage (http://pydev.sourceforge.net/) for more details. Details for Release: 0.9.8 Major highlights: --- * Jython integrated. * Jython debugger sup

Re: Bug in string.find; was: Re: Proposed PEP: New style indexing,was Re: Bug in slice type

2005-08-29 Thread Steven Bethard
Antoon Pardon wrote: > I think a properly implented find is better than an index. See the current thread in python-dev[1], which proposes a new method, str.partition(). I believe that Raymond Hettinger has shown that almost all uses of str.find() can be more clearly be represented with his pro

Re: GIL, threads and scheduling - performance cost

2005-08-29 Thread Pierre Barbier de Reuille
[EMAIL PROTECTED] a écrit : > Merci Pierre, > > Yes I agree and plan to move more to C/C++ and releasing the GIL when > entering C/C++. > > I also need to understand my original question re GIL and rescheduling. > I fear that lock/unlock too often is also causing delays due to context > switching

Re: trictionary?

2005-08-29 Thread Randy Bush
> bin = {} > for start, end, AS, full in heard: >week = int((start-startDate)/aWeek) >counters = bin.setdefault(week, [0, 0]) >if full: > counters[0] += 1 >else: > counters[1] += 1 yes! thanks! > Using an idea you used earlier, you coul

Re: python xml DOM? pulldom? SAX?

2005-08-29 Thread Fredrik Lundh
"jog" wrote: > I want to get text out of some nodes of a huge xml file (1,5 GB). The > architecture of the xml file is something like this > I want to combine the text out of page:title and page:revision:text for > every single page element. One by one I want to index these combined > texts (so f

Re: python xml DOM? pulldom? SAX?

2005-08-29 Thread Michael Ekstrand
On 29 Aug 2005 08:17:04 -0700 "jog" <[EMAIL PROTECTED]> wrote: > I want to get text out of some nodes of a huge xml file (1,5 GB). The > architecture of the xml file is something like this > [structure snipped] > I want to combine the text out of page:title and page:revision:text > for every single

Re: Robust statistics and optimmization from Python

2005-08-29 Thread beliavsky
Robert Kern wrote: > If you find suitable > FORTRAN or C code that implements a particular "robust" algorithm, it > can probably wrapped for scipy relatively easily. An alternative would be to call R (a free statistical package) from Python, using something like the R/SPlus - Python Interface a

Re: python xml DOM? pulldom? SAX?

2005-08-29 Thread tooper
Hi, I'd advocate for using SAX, as DOM related methods implies loading the complete XML content in memory whereas SAX grab things on the fly. SAX method should therefore be faster and less memory consuming... By the way, if your goal is to just "combine the text out of page:title and page:revisio

Re: Jargons of Info Tech industry

2005-08-29 Thread Alan Balmer
Why on earth was this cross-posted to comp.lang.c.? Followups set. On Mon, 29 Aug 2005 12:26:11 GMT, [EMAIL PROTECTED] wrote: >In comp.lang.perl.misc Mike Meyer <[EMAIL PROTECTED]> wrote: >> [EMAIL PROTECTED] writes: >>> In comp.lang.perl.misc John Bokma <[EMAIL PROTECTED]> wrote: Chris Head

Re: GIL, threads and scheduling - performance cost

2005-08-29 Thread adsheehan
Merci Pierre, Yes I agree and plan to move more to C/C++ and releasing the GIL when entering C/C++. I also need to understand my original question re GIL and rescheduling. I fear that lock/unlock too often is also causing delays due to context switching. BTW do you have any hints/comments on SWI

Re: GIL, threads and scheduling - performance cost

2005-08-29 Thread Pierre Barbier de Reuille
[EMAIL PROTECTED] a écrit : > Hi all, > > Wondering if a GIL lock/unlock causes a re-schedule/contect swap when > embedding Python in a multi-threaded C/C++ app on Unix ? > > If so, do I have any control or influence on this re-scheduling ? > > The app suffers from serious performance degradatio

Re: trictionary?

2005-08-29 Thread Steven Bethard
Randy Bush wrote: > Steven Bethard wrote: >> It would probably help if you explained what the real problem is >> you're trying to solve. > > actually, that code fragment was meant to do that. it's pretty much > what i needed to do at that point, just the variable names made > simple. Yeah, I gat

Re: using common lisp with python.

2005-08-29 Thread [EMAIL PROTECTED]
basically, what I'm looking to do is use python as a bridge between C and Common Lisp to create a virtual city that contains Artificial life. -- http://mail.python.org/mailman/listinfo/python-list

socket.gaierror from httplib

2005-08-29 Thread spamsink42
this code h=httplib.HTTPConnection('euronext.com') h.request('GET', 'http://www.euronext.com/home/0,3766,1732,00.html') fails with this message File "httplib.py", line 532, in connect socket.SOCK_STREAM): socket.gaierror: (-2, 'Name or service not known') what am i doi

Re: Jargons of Info Tech industry

2005-08-29 Thread T Beck
John Bokma wrote: > "T Beck" <[EMAIL PROTECTED]> wrote: > > > [snip] > > alongside of it. The internet is a free-flowing evolving place... to > > try to protect one little segment like usenet from ever evolving is > > just ensuring it's slow death, IMHO. > > And if so, who cares? As long as peopl

Re: trictionary?

2005-08-29 Thread Steven Bethard
[EMAIL PROTECTED] wrote: > import csv > temp1 = [] > temp2 = [] > reader = csv.reader(file(r"py_monsters.csv")) > for rec in reader: > temp1.append(rec) > for i in temp1[1:]: > temp2.append((i[0],dict(zip(temp1[0][1:],i[1:] > monsters = dict(temp2) I would tend to write this as: i

Python port on Palm Treo?

2005-08-29 Thread Paul Watson
Has anyone done or worked on a port of Python to the Treo? -- http://mail.python.org/mailman/listinfo/python-list

Re: overload builtin operator

2005-08-29 Thread Robert Kern
Iain King wrote: > Robert Kern wrote: >>You have silly users. > > You mean you don't? Damn. Can I have some of yours? No, you may not. Mine! All mine! -- Robert Kern [EMAIL PROTECTED] "In the fields of hell where the grass grows high Are the graves of dreams allowed to die." -- Richard H

Re: trictionary?

2005-08-29 Thread Steven Bethard
Adam Tomjack wrote: > I'd write it like this: > >bin = {} >for start, end, AS, full in heard: > week = int((start-startDate)/aWeek) > counters = bin.setdefault(week, [0, 0]) > if full: > counters[0] += 1 > else: > counters[1] += 1 > >for week,

  1   2   >