how to filter files by creation date

2007-11-05 Thread awel
Hello All, I am trying to to make a script to move all the files that has been created at today's to another folder but my problem is the date format that I receive from the 'os.stat [stat.ST_CTIME]' is different from the one that I receive from the 'datetime.date.today()'. Does someone could he

Re: python at command prompt

2007-11-05 Thread Ton van Vliet
On Tue, 06 Nov 2007 04:20:17 GMT, Tim Roberts <[EMAIL PROTECTED]> wrote: >>There are executables (.exe) that have a 'registering' option builtin, >>and need to be registered to have their capabilities made available >>using the /regserver switch (possibly related to OLE/COM services, but >>I'm not

Re: How to use list as key of dictionary?

2007-11-05 Thread Matimus
On Nov 5, 10:53 pm, Davy <[EMAIL PROTECTED]> wrote: > Hi all, > > We know that list cannot be used as key of dictionary. So, how to work > around it? > > For example, there is random list like l=[1,323,54,67]. > > Any suggestions are welcome! > > Best regards, > Davy Use a tuple instead. >>> d =

Re: How to use list as key of dictionary?

2007-11-05 Thread Boris Borcic
Davy wrote: > Hi all, > > We know that list cannot be used as key of dictionary. Yeah, but do we know why ? > So, how to work > around it? That's a subsidiary question. > > For example, there is random list like l=[1,323,54,67]. Don't use 1owercase L as a variab1e name, p1ease ! > > Any su

How to use list as key of dictionary?

2007-11-05 Thread Davy
Hi all, We know that list cannot be used as key of dictionary. So, how to work around it? For example, there is random list like l=[1,323,54,67]. Any suggestions are welcome! Best regards, Davy -- http://mail.python.org/mailman/listinfo/python-list

Re: Python thinks file is empty

2007-11-05 Thread Tim Roberts
loial <[EMAIL PROTECTED]> wrote: > >I am writing a file in python with writelines > >f = open('/home/john/myfile',"w") >f.writelines("line1\n") >f.writelines("line2\n") >f.close() Are you absolutely sure it looks like that? If you wrote this: f.close (as reformed VB programmers tend to write

Re: How can i find the form name without "nr=0"

2007-11-05 Thread scripteaze
On Nov 5, 6:33 pm, alex23 <[EMAIL PROTECTED]> wrote: > On Nov 6, 8:56 am, scripteaze <[EMAIL PROTECTED]> wrote: > > > Is it possible then to have a form with no name and if so, how can i > > access this form > > Hey scripteaze, > > I'm not sure about mechanize, but you might have more success using

RE: How to Create pyd by C#

2007-11-05 Thread Ryan Ginstrom
> On Behalf Of jane janet > I'm wondering how to create extension fill (.pyd) or anything > that seem like DLL file by C# language. If you are going to be using C#, I would suggest that you create an ordinary assembly, and call it via IronPython. Regards, Ryan Ginstrom -- http://mail.python.or

hi friends

2007-11-05 Thread sindhu_jjcet
to get preapred for the business see bird-flumanual.com log on to http://www.geocities.com/humnoses/ -- http://mail.python.org/mailman/listinfo/python-list

Re: SIP won't compile on OSX 10.3

2007-11-05 Thread D.Hering
On Nov 5, 10:41 pm, Benjamin <[EMAIL PROTECTED]> wrote: > Hi! I'm trying to install SIP on my Mac with the eventual aim of > installing PyQt. The "python configure.py" stage works fine, but when > I type make this is what I see: > cc -c -pipe -Os -w -I. -o main.o main.c > cc -c -pipe -Os -w -I. -o

How to Create pyd by C#

2007-11-05 Thread jane janet
Hello all, I'm wondering how to create extension fill (.pyd) or anything that seem like DLL file by C# language. Please help me. Thank you. _ Boo! Scare away worms, viruses and so much more! Try Windows Live OneCare! http://onecare.

Re: python at command prompt

2007-11-05 Thread Tim Roberts
Ton van Vliet <[EMAIL PROTECTED]> wrote: > >There are executables (.exe) that have a 'registering' option builtin, >and need to be registered to have their capabilities made available >using the /regserver switch (possibly related to OLE/COM services, but >I'm not an expert here ;-) Yes, that's st

SIP won't compile on OSX 10.3

2007-11-05 Thread Benjamin
Hi! I'm trying to install SIP on my Mac with the eventual aim of installing PyQt. The "python configure.py" stage works fine, but when I type make this is what I see: cc -c -pipe -Os -w -I. -o main.o main.c cc -c -pipe -Os -w -I. -o transform.o transform.c cc -c -pipe -Os -w -I. -o gencode.o gencod

supplemental data factory

2007-11-05 Thread sndive
i'm trying to import a module typeinfo that looks like so: import xml.dom import minidom var mapper = { minidom.Element.__class__ : "Element", minidom.Node.__class__ : "Node" }; then i'd write a factory method that's look roughly like this: addBaggage(PyObject *victim) { PyObject *typeinf

Re: >>> CIA Squashes Democracy in Pakistan <<

2007-11-05 Thread Virgil
In article <[EMAIL PROTECTED]>, Ivar Rosquist <[EMAIL PROTECTED]> wrote: > On Mon, 05 Nov 2007 21:43:09 +, zionist.news wrote: What has this to do with mathematics? -- http://mail.python.org/mailman/listinfo/python-list

Re: Python good for data mining?

2007-11-05 Thread D.Hering
On Nov 5, 10:29 am, Maarten <[EMAIL PROTECTED]> wrote: > On Nov 5, 1:51 pm, Jens <[EMAIL PROTECTED]> wrote: > > > > > On 5 Nov., 04:42, "D.Hering" <[EMAIL PROTECTED]> wrote: > > > > On Nov 3, 9:02 pm, Jens <[EMAIL PROTECTED]> wrote: > > > > I then leaned C and then C++. I am now coming home to Pyth

is PyUnicode_Decode a part of public api

2007-11-05 Thread sndive
am i allowed to use PyUnicode_Decode or PyUnicode_DecodeUTF8 in my code or that is not advisable? QString s("foo"); // QString::unicode returns garbage unusable for PyUnicode_FromUnicode PyObject *uo = PyUnicode_Decode(s.utf8(), s.length(), "utf8", 0); -- http://mail.

Re: >>> CIA Squashes Democracy in Pakistan <<

2007-11-05 Thread zionist . news
On Nov 5, 4:55 pm, Ivar Rosquist <[EMAIL PROTECTED]> wrote: > On Mon, 05 Nov 2007 21:43:09 +, zionist.news wrote: > >http://www.youtube.com/watch?v=BdB2r1ss5Wk > > >http://www.jewwatch.com/ <- excellent source for well researched > > news on world events and the big movers of history > >

Re: How can i find the form name without "nr=0"

2007-11-05 Thread alex23
On Nov 6, 8:56 am, scripteaze <[EMAIL PROTECTED]> wrote: > Is it possible then to have a form with no name and if so, how can i > access this form Hey scripteaze, I'm not sure about mechanize, but you might have more success using another one of the author's modules, ClientForm: http://wwwsearch

Re: >>> CIA Squashes Democracy in Pakistan <<

2007-11-05 Thread Ivar Rosquist
On Mon, 05 Nov 2007 21:43:09 +, zionist.news wrote: > http://www.youtube.com/watch?v=BdB2r1ss5Wk > > http://www.jewwatch.com/ <- excellent source for well researched > news on world events and the big movers of history What democracy? Pakistan will be either a military dictators

Re: Library package import question

2007-11-05 Thread Gabriel Genellina
En Mon, 05 Nov 2007 10:34:26 -0300, Frank Aune <[EMAIL PROTECTED]> escribió: > I have a python library package 'Foo', which contains alot of submodules: > > Foo/: > __init__.py > module1.py: > class Bar() > class Hmm() > module2.py > cl

Re: Eclipse3.3 with Pydev 1.3.10 Mylar problem, have Mylyn

2007-11-05 Thread Fabio Zadrozny
In the dialog where you select pydev (in the installation -- it'll appear in the 5th screenshot at http://fabioz.com/pydev/manual_101_install.html), you can expand it and uncheck mylyn... I'll update the install instructions to better specify that... Cheers, Fabio On 11/5/07, crybaby <[EMAIL PR

Re: Thread Profiling

2007-11-05 Thread James Matthews
Try passing the verbose=1 flag when creating the tread! On 11/6/07, Chris Mellon <[EMAIL PROTECTED]> wrote: > > On Nov 5, 2007 1:32 PM, JamesHoward <[EMAIL PROTECTED]> wrote: > > Are there any good thread profilers available that can profile a > > thread as it is running instead of after execution

Re: Library package import question

2007-11-05 Thread Martin Marcher
2007/11/5, Frank Aune <[EMAIL PROTECTED]>: > To prevent namespace pollution, I want to import and use this library in the > following way: > > import Foo > (...) > t = Foo.module2.Bee() from x import y as z that has always worked for me to prevent pollution... -- http://noneisyours.marcher.na

Re: dictionary viewer

2007-11-05 Thread Martin Marcher
2007/11/5, [EMAIL PROTECTED] <[EMAIL PROTECTED]>: > On Nov 5, 3:10 pm, Erika Skoe <[EMAIL PROTECTED]> wrote: > > > > That's funny, I can't see anything. Of course, it's an empty dict! tzz, *shaking head* martin -- http://noneisyours.marcher.name http://feeds.feedburner.com/NoneIsYours -- http:

Re: Thread Profiling

2007-11-05 Thread Chris Mellon
On Nov 5, 2007 1:32 PM, JamesHoward <[EMAIL PROTECTED]> wrote: > Are there any good thread profilers available that can profile a > thread as it is running instead of after execution is completed? > > I would like to find a python class which looks at a currently running > thread and if its memory

Eclipse3.3 with Pydev 1.3.10 Mylar problem, have Mylyn

2007-11-05 Thread crybaby
Right now I am trying to install pydev 1.3.10 on Eclipse 3.3. I am getting an Mylar error org.eclipse.mylar (2.0.0.v20070403-1300) or something needed. Mylyn is mylar, now. How do you disable the mylar dependency, so that Mylyn is used by PyDev? -- http://mail.python.org/mailman/listinfo/python-

Re: dictionary viewer

2007-11-05 Thread [EMAIL PROTECTED]
On Nov 5, 3:10 pm, Erika Skoe <[EMAIL PROTECTED]> wrote: > That's funny, I can't see anything. -- http://mail.python.org/mailman/listinfo/python-list

Re: How can i find the form name without "nr=0"

2007-11-05 Thread scripteaze
b> > Well, i wasnt sure if you could have a form without a form name, i was > > just thinking that it had one but maybe hidden and that i could > > retrieve it > > How hidden? HTML source is ... THE source. there is nothing hidden in there. > Is it possible then to have a form with no name and if

Re: Python launcher not working on Mac after Leopard upgrade?

2007-11-05 Thread André
On Nov 5, 11:57 am, [EMAIL PROTECTED] wrote: > On Nov 3, 7:57 am, André <[EMAIL PROTECTED]> wrote: > > > I just installed Leopard on my Mac. I already was using Python 2.5. > > I can run a Python script from a terminal window by typing "python > > script.py" as one would expect ... but not using t

>>> CIA Squashes Democracy in Pakistan <<

2007-11-05 Thread zionist . news
http://www.youtube.com/watch?v=BdB2r1ss5Wk http://www.jewwatch.com/ <- excellent source for well researched news on world events and the big movers of history -- http://mail.python.org/mailman/listinfo/python-list

dictionary viewer

2007-11-05 Thread Erika Skoe
-- http://mail.python.org/mailman/listinfo/python-list

Re: Python good for data mining?

2007-11-05 Thread Paul Rudin
Maarten <[EMAIL PROTECTED]> writes: > > "Premature optimization is the root of all evil", to quote a famous > person. And he's right, as most people working larger codes will > confirm. > But note that it's "premature optimization...", not "optimization..." :) -- http://mail.python.org/mailman/

Re: Functions as Objects, and persisting values

2007-11-05 Thread Bruno Desthuilliers
Falcolas a écrit : > Please help me understand the mechanics of the following behavior. > > def d(): > > header = 'I am in front of ' > def e(something): > print header + something > return e > > f = d() f('this') > > I am in front of this > de

Re: Descriptors and side effects

2007-11-05 Thread Rich Harkins
Bruno Desthuilliers wrote: > Which is easy to do with properties too. True enough. It's the caching of the return value that's the value add of course. ;) > >> After >> it is applied, then the penalties for function call of the property and >> the computation are wiped out once the second acc

Python-URL! - weekly Python news and links (Nov 5)

2007-11-05 Thread Gabriel Genellina
QOTW: "I've just done my first serious work in Python/IDLE, a small dot pre-processor for software modeling diagrams and I am very enthused. It should be called Pytho; it has the positive qualities of Play-Do and Lego: you get ideas squishing it through your fingers and it snaps together nicely t

Re: Functions as Objects, and persisting values

2007-11-05 Thread Rich Harkins
[snip] > The "thing" you observe here is a called a closure. It consists of the > local variables surrounding e. So as long as you keep a reference to e, > you keep one to the variables of d itself. > > Diez More specifically though it keeps references to the requested variables only: def clo

Re: Python thinks file is empty

2007-11-05 Thread Gabriel Genellina
En Mon, 05 Nov 2007 12:57:15 -0300, Tim Chase <[EMAIL PROTECTED]> escribió: > To confuse matters, it happens to work in your example, because a > string is an iterable that returns each character in that string > as the result, so code like this > >f.writelines('hello\n') > > is effectively

Re: Descriptors and side effects

2007-11-05 Thread Bruno Desthuilliers
Rich Harkins a écrit : > Bruno Desthuilliers wrote: > [snip] > >>I'm sorry, but this looks like a very complicated way to do a simple thing: >> >>class MySimpleClass(object): >> def __init__(self, x): >> self.x = x >> self.y = x ** 2 >> >> > > > Sure, for the absurdly simplified case I

Re: Functions as Objects, and persisting values

2007-11-05 Thread Diez B. Roggisch
Falcolas schrieb: > Please help me understand the mechanics of the following behavior. > def d(): > header = 'I am in front of ' > def e(something): > print header + something > return e > f = d() f('this') > I am in front of this del(d) f(

Pydev 1.3.10 Released

2007-11-05 Thread Fabio Zadrozny
Hi All, Pydev and Pydev Extensions 1.3.10 have been released Details on Pydev Extensions: http://www.fabioz.com/pydev Details on Pydev: http://pydev.sf.net Details on its development: http://pydev.blogspot.com Release Highlights in Pydev Extensions: --

Re: instance as a sequence

2007-11-05 Thread Bruno Desthuilliers
[EMAIL PROTECTED] a écrit : > On Nov 5, 9:40 am, Paul McGuire <[EMAIL PROTECTED]> wrote: > >>On Nov 5, 11:32 am, [EMAIL PROTECTED] wrote: >> >> >>>suppose i want to >>>make foo.childNodes[bar] available as foo[bar] >>>(while still providing access to the printxml/printprettyxml() >>>functions >>>a

Re: IDLE won't color code!

2007-11-05 Thread [EMAIL PROTECTED]
On Nov 5, 9:41 pm, JamesHoward <[EMAIL PROTECTED]> wrote: > On Nov 5, 12:33 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> > wrote: > > > Please help! > > IDLE color codes only the shell, not the open files! How can I solve > > this? > > My first guess is that idle is opening files without the .py > e

Functions as Objects, and persisting values

2007-11-05 Thread Falcolas
Please help me understand the mechanics of the following behavior. >>> def d(): header = 'I am in front of ' def e(something): print header + something return e >>> f = d() >>> f('this') I am in front of this >>> del(d) >>> f('this') I am in front of this

Re: IDLE won't color code!

2007-11-05 Thread JamesHoward
On Nov 5, 12:33 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > Please help! > IDLE color codes only the shell, not the open files! How can I solve > this? My first guess is that idle is opening files without the .py extension. If that isn't it, what operating system are you using? What vers

Re: Python good for data mining?

2007-11-05 Thread Bruno Desthuilliers
Aaron Watters a écrit : > On Nov 4, 4:36 pm, Bruno Desthuilliers > <[EMAIL PROTECTED]> wrote: > >>>How good is the integration with MySQL in Python? >> >>Pretty good - but I wouldn't call MySQL a serious RDBMS. > > > I would disagree with this, for this particular case. > I think it's probably b

IDLE won't color code!

2007-11-05 Thread [EMAIL PROTECTED]
Please help! IDLE color codes only the shell, not the open files! How can I solve this? -- http://mail.python.org/mailman/listinfo/python-list

Thread Profiling

2007-11-05 Thread JamesHoward
Are there any good thread profilers available that can profile a thread as it is running instead of after execution is completed? I would like to find a python class which looks at a currently running thread and if its memory exceeds a certain amount than kill it. Ideally I would like the program

Re: instance as a sequence

2007-11-05 Thread Matimus
On Nov 5, 9:59 am, [EMAIL PROTECTED] wrote: > On Nov 5, 9:40 am, Paul McGuire <[EMAIL PROTECTED]> wrote: > > > On Nov 5, 11:32 am, [EMAIL PROTECTED] wrote: > > > > suppose i want to > > > make foo.childNodes[bar] available as foo[bar] > > > (while still providing access to the printxml/printprettyx

Re: (MAC) CoreGraphics module???

2007-11-05 Thread David Ullrich
Robert Kern wrote: > David C. Ullrich wrote: >> On Sun, 04 Nov 2007 15:56:21 -0600, Robert Kern >> <[EMAIL PROTECTED]> wrote: >> >>> David C. Ullrich wrote: On Fri, 02 Nov 2007 14:09:25 -0500, Robert Kern <[EMAIL PROTECTED]> wrote: > David C. Ullrich wrote: >> [???] > Oka

Re: Python good for data mining?

2007-11-05 Thread Aaron Watters
On Nov 4, 4:36 pm, Bruno Desthuilliers <[EMAIL PROTECTED]> wrote: > > > How good is the integration with MySQL in Python? > > Pretty good - but I wouldn't call MySQL a serious RDBMS. I would disagree with this, for this particular case. I think it's probably better than most other rdbms's for apps

Re: __file__ vs __FILE__

2007-11-05 Thread Matimus
On Nov 5, 1:07 am, sandipm <[EMAIL PROTECTED]> wrote: > interestingly... > I wanted to reuse this code so i wrote function in a file > > def getParentDir(): > import os > return os.path.dirname(os.path.abspath(__file__)) > > and called this function, in another file, its giving me parent >

Re: Python good for data mining?

2007-11-05 Thread Jens
On 5 Nov., 16:29, Maarten <[EMAIL PROTECTED]> wrote: > As for pytables: it is the most elegant programming interface for HDF > on any platform that I've encountered so far. Most other platforms > stay close the HDF5 library C-interface, which is low-level, and quite > complex. PyTables was written

Re: Python good for data mining?

2007-11-05 Thread Robert Kern
Jens wrote: > On 5 Nov., 16:29, Maarten <[EMAIL PROTECTED]> wrote: >> On Nov 5, 1:51 pm, Jens <[EMAIL PROTECTED]> wrote: > >> "Premature optimization is the root of all evil", to quote a famous >> person. And he's right, as most people working larger codes will >> confirm. > > I guess I'll have t

Re: Python good for data mining?

2007-11-05 Thread Jens
On 5 Nov., 16:29, Maarten <[EMAIL PROTECTED]> wrote: > On Nov 5, 1:51 pm, Jens <[EMAIL PROTECTED]> wrote: > "Premature optimization is the root of all evil", to quote a famous > person. And he's right, as most people working larger codes will > confirm. I guess I'll have to agree with that. Still

Re: (MAC) CoreGraphics module???

2007-11-05 Thread Robert Kern
David C. Ullrich wrote: > On Sun, 04 Nov 2007 15:56:21 -0600, Robert Kern > <[EMAIL PROTECTED]> wrote: > >> David C. Ullrich wrote: >>> On Fri, 02 Nov 2007 14:09:25 -0500, Robert Kern >>> <[EMAIL PROTECTED]> wrote: >>> David C. Ullrich wrote: > [???] Okay, which version of OS X do yo

Re: instance as a sequence

2007-11-05 Thread sndive
On Nov 5, 9:40 am, Paul McGuire <[EMAIL PROTECTED]> wrote: > On Nov 5, 11:32 am, [EMAIL PROTECTED] wrote: > > > suppose i want to > > make foo.childNodes[bar] available as foo[bar] > > (while still providing access to the printxml/printprettyxml() > > functions > > and other functionality of dom/mi

Re: instance as a sequence

2007-11-05 Thread Paul McGuire
On Nov 5, 11:32 am, [EMAIL PROTECTED] wrote: > suppose i want to > make foo.childNodes[bar] available as foo[bar] > (while still providing access to the printxml/printprettyxml() > functions > and other functionality of dom/minidom instance). > > What is a good way to accomplish that? define __get

Re: instance as a sequence

2007-11-05 Thread Diez B. Roggisch
[EMAIL PROTECTED] wrote: > suppose i want to > make foo.childNodes[bar] available as foo[bar] > (while still providing access to the printxml/printprettyxml() > functions > and other functionality of dom/minidom instance). > > What is a good way to accomplish that? Using element-tree. That alre

Re: Descriptors and side effects

2007-11-05 Thread Rich Harkins
Bruno Desthuilliers wrote: > Rich Harkins a écrit : >> [EMAIL PROTECTED] wrote: >>> Hello everyone, >>> >>> I'm trying to do seemingly trivial thing with descriptors: have >>> another attribute updated on dot access in object defined using >>> descriptors. >> [snip] >> >>> A setter function should

Re: Descriptors and side effects

2007-11-05 Thread Rich Harkins
Bruno Desthuilliers wrote: [snip] > I'm sorry, but this looks like a very complicated way to do a simple thing: > > class MySimpleClass(object): >def __init__(self, x): > self.x = x > self.y = x ** 2 > > Sure, for the absurdly simplified case I posed as an example. ;) Here's ano

instance as a sequence

2007-11-05 Thread sndive
suppose i want to make foo.childNodes[bar] available as foo[bar] (while still providing access to the printxml/printprettyxml() functions and other functionality of dom/minidom instance). What is a good way to accomplish that? -- http://mail.python.org/mailman/listinfo/python-list

Re: wxPython ListCtrl

2007-11-05 Thread kyosohma
On Nov 5, 11:00 am, [EMAIL PROTECTED] wrote: > Hello, > > How can I Insert image with string in ListCtrl with this example: > > # Import ftputil module - like ftplib > from ftputil import FTPHost > # Create connection > ftp=FTPHost("ftp.someserver.com","user","password") > > # LIST ALL FILES/FOLDER

Re: How can i find the form name without "nr=0"

2007-11-05 Thread Diez B. Roggisch
> > Well, i wasnt sure if you could have a form without a form name, i was > just thinking that it had one but maybe hidden and that i could > retrieve it How hidden? HTML source is ... THE source. there is nothing hidden in there. Diez -- http://mail.python.org/mailman/listinfo/python-list

Re: How can i find the form name without "nr=0"

2007-11-05 Thread scripteaze
On Nov 5, 8:52 am, "Diez B. Roggisch" <[EMAIL PROTECTED]> wrote: > scripteaze wrote: > > Im using mechanize method for retrieving the form so that i may log > > into it. I need to find a way to get the form name. Its not listed > > anywhere in the html source.The reason i need to do this is because

wxPython ListCtrl

2007-11-05 Thread vedrandekovic
Hello, How can I Insert image with string in ListCtrl with this example: # Import ftputil module - like ftplib from ftputil import FTPHost # Create connection ftp=FTPHost("ftp.someserver.com","user","password") # LIST ALL FILES/FOLDERS ON SERVER for item in ftp._dir("/"): # Now check if

Re: Poor python and/or Zope performance on Sparc

2007-11-05 Thread pythoncurious
On Nov 3, 2:35 pm, joa2212 <[EMAIL PROTECTED]> wrote: > Result: Almost even worse. The application is not scaling at all. > Every time you start a request it is hanging around on one cpu and is > devouring it at about 90-100% load. The other 31 CPUs which are shown > in "mpstat" are bored at 0% loa

Re: Low-overhead GUI toolkit for Linux w/o X11?

2007-11-05 Thread Grant Edwards
On 2007-11-05, Chris Mellon <[EMAIL PROTECTED]> wrote: >> Yes, it's "modern" enough to run Linux/X11 -- horsepower-wise >> it's sort of in the PDA class of devices. wxWidgets has been >> tried, but it's pretty sluggish. Hence the search for >> something a little lighter weight. Using Python is p

Re: Descriptors and side effects

2007-11-05 Thread Bruno Desthuilliers
Rich Harkins a écrit : > [EMAIL PROTECTED] wrote: >> Hello everyone, >> >> I'm trying to do seemingly trivial thing with descriptors: have >> another attribute updated on dot access in object defined using >> descriptors. > > [snip] > >> A setter function should have updated self.l just like it u

Re: Adding GNU Readline after installation?

2007-11-05 Thread [EMAIL PROTECTED]
> > I really just want to get my "up arrow" history working... > > Google for "rlwrap". Thanks for the rlwrap tip - much easier than reinstalling Python (for the short term). For anyone interested, I installed it and put this in my .bashrc file: alias python='rlwrap python' Now I have my up-arro

Re: Python launcher not working on Mac after Leopard upgrade?

2007-11-05 Thread kyosohma
On Nov 3, 7:57 am, André <[EMAIL PROTECTED]> wrote: > I just installed Leopard on my Mac. I already was using Python 2.5. > I can run a Python script from a terminal window by typing "python > script.py" as one would expect ... but not using the Python launcher > either directly or indirectly (by

Re: How can i find the form name without "nr=0"

2007-11-05 Thread Diez B. Roggisch
scripteaze wrote: > Im using mechanize method for retrieving the form so that i may log > into it. I need to find a way to get the form name. Its not listed > anywhere in the html source.The reason i need to do this is because im > tryin not to use the for loop below. Someone told me that the form

How can i find the form name without "nr=0"

2007-11-05 Thread scripteaze
Im using mechanize method for retrieving the form so that i may log into it. I need to find a way to get the form name. Its not listed anywhere in the html source.The reason i need to do this is because im tryin not to use the for loop below. Someone told me that the form name should be listed in t

Re: Python thinks file is empty

2007-11-05 Thread Tim Chase
loial wrote: > I am writing a file in python with writelines > > f = open('/home/john/myfile',"w") > f.writelines("line1\n") > f.writelines("line2\n") > f.close() > > But whenever I try to do anything with the file in python it finds no > data. I am trying ftp, copying the file...the resultant f

Re: Python thinks file is empty

2007-11-05 Thread kyosohma
On Nov 5, 9:19 am, loial <[EMAIL PROTECTED]> wrote: > I am writing a file in python with writelines > > f = open('/home/john/myfile',"w") > f.writelines("line1\n") > f.writelines("line2\n") > f.close() > > But whenever I try to do anything with the file in python it finds no > data. I am trying ft

Re: Low-overhead GUI toolkit for Linux w/o X11?

2007-11-05 Thread Chris Mellon
On Nov 3, 2007 6:06 PM, Grant Edwards <[EMAIL PROTECTED]> wrote: > On 2007-11-03, David Bolen <[EMAIL PROTECTED]> wrote: > > Grant Edwards <[EMAIL PROTECTED]> writes: > > > >> I'm looking for GUI toolkits that work with directly with the > >> Linux frambuffer (no X11). It's an embedded device with

Re: Python good for data mining?

2007-11-05 Thread Maarten
On Nov 5, 1:51 pm, Jens <[EMAIL PROTECTED]> wrote: > On 5 Nov., 04:42, "D.Hering" <[EMAIL PROTECTED]> wrote: > > > On Nov 3, 9:02 pm, Jens <[EMAIL PROTECTED]> wrote: > > > I then leaned C and then C++. I am now coming home to Python realizing > > after my self-eduction, that programming in Python i

Re: pyparsing frames and tweens - take 2

2007-11-05 Thread Paul McGuire
Here is a first cut at processing the parsed objects, given a list of Property objects representing the frames at each '#': class Property(object): def __init__(self,**kwargs): self.__dict__.update(kwargs) def copy(self): return Property(**self.__dict__) @staticmethod

Python thinks file is empty

2007-11-05 Thread loial
I am writing a file in python with writelines f = open('/home/john/myfile',"w") f.writelines("line1\n") f.writelines("line2\n") f.close() But whenever I try to do anything with the file in python it finds no data. I am trying ftp, copying the file...the resultant file is always 0 bytes, although

Re: Descriptors and side effects

2007-11-05 Thread Rich Harkins
[EMAIL PROTECTED] wrote: > Hello everyone, > > I'm trying to do seemingly trivial thing with descriptors: have > another attribute updated on dot access in object defined using > descriptors. [snip] > A setter function should have updated self.l just like it updated > self.s: > > def __se

Re: Python good for data mining?

2007-11-05 Thread Aaron Watters
On Nov 3, 9:02 pm, Jens <[EMAIL PROTECTED]> wrote: > How good is the integration with MySQL in Python? I think it's very good. However, I'm not sure how good SQL really is for data mining, depending on what you mean by that. Please have a look at nucular for this kind of thing -- I've advertised

httplib.HTTPSConnection with timeout support (pyton 2.5.1)

2007-11-05 Thread mmomar
Hi, I am using a HTTPS connection to invoke a cgi-script. I want to use a timeout between the sending the request and receiving the response, so what I want to do is when the request is send, the client should wait for a specified time, drop the connection and then do some thing else. I found ou

Re: pyparsing frames and tweens - take 2

2007-11-05 Thread Paul McGuire
Donn - The exception you posted is from using an old version of pyparsing. You can get the latest from SourceForge - if you download the Windows binary install, please get the docs package too. It has a full doc directory (generated with epydoc), plus example scripts for a variety of applications

Re: PyObjC with Xcode 3.0 Leopard

2007-11-05 Thread Kevin Walzer
flyfree wrote: > I got an error during making a python application with xcode 3.0 in OS > X Leopard. > > (KeyError: 'NSUnknownKeyException - [ > valueForUndefinedKey:]: this class is not key value coding-compliant > for the key calculatedMean.') > > The application is a simple example of how to u

Re: Downloading file from cgi application

2007-11-05 Thread sophie_newbie
On Nov 5, 1:50 pm, Jeff McNeil <[EMAIL PROTECTED]> wrote: > You could also just store the files outside of the document root if > you don't want to worry about a database. Then, as Jeff said, just > print the proper Content-Type header and print the file out. > > On Nov 5, 2007, at 8:26 AM, Jeff w

Re: Python good for data mining?

2007-11-05 Thread Jens
On 5 Nov., 04:42, "D.Hering" <[EMAIL PROTECTED]> wrote: > On Nov 3, 9:02 pm, Jens <[EMAIL PROTECTED]> wrote: > > > > > I'm starting a project indatamining, and I'm considering Python and > > Java as possible platforms. > > > I'm conserned by performance. Most benchmarks report that Java is > > abou

Re: Downloading file from cgi application

2007-11-05 Thread Jeff McNeil
You could also just store the files outside of the document root if you don't want to worry about a database. Then, as Jeff said, just print the proper Content-Type header and print the file out. On Nov 5, 2007, at 8:26 AM, Jeff wrote: > Store the file in a database. When an authorized user

Re: how does google search in phrase

2007-11-05 Thread Diez B. Roggisch
[EMAIL PROTECTED] wrote: > hi my friends; > google can searching in phrase but it is imposible. it have a lot of > page in data base and quadrillions sentence it can't search in > fulltxt all of them .it need a super algorithm. ı need the algorithm > now. if you have a idea ,pls share to me use

Library package import question

2007-11-05 Thread Frank Aune
Hello, I have a python library package 'Foo', which contains alot of submodules: Foo/: __init__.py module1.py: class Bar() class Hmm() module2.py class Bee() class Wax() module3.py etc

Re: Downloading file from cgi application

2007-11-05 Thread Diez B. Roggisch
sophie_newbie wrote: > Hi, > > I'm writing a cgi application in Python that generates a PDF file for > the user and then allows them to download that file. Currently I'm > just writing the PDF file to the 'htdocs' directory and giving the > user a link to this file to download it. But the problem

Re: achieving performance using C/C++

2007-11-05 Thread Jeff
http://artfulcode.nfshost.com/files/extending_python_with_pyrex.html -- http://mail.python.org/mailman/listinfo/python-list

Re: achieving performance using C/C++

2007-11-05 Thread Luis M . González
On Nov 5, 8:51 am, Filip Wasilewski <[EMAIL PROTECTED]> wrote: > On Nov 5, 7:40 am, sandipm <[EMAIL PROTECTED]> wrote:> I did fair amount of > programming in python but never used c/c++ as > > mentioned below. > > any good tutorials for using C/C++ to optimize python codebase for > > performance?

Re: Downloading file from cgi application

2007-11-05 Thread Jeff
Store the file in a database. When an authorized user clicks the link, send the proper headers ('Content-Type: application/pdf') and then print the file. -- http://mail.python.org/mailman/listinfo/python-list

Re: how does google search in phrase

2007-11-05 Thread Dustan
On Nov 5, 7:14 am, Jeff <[EMAIL PROTECTED]> wrote: > Here is a detailed explanation: > > http://www.google.com/technology/pigeonrank.html Ha ha... Hilarious. -- http://mail.python.org/mailman/listinfo/python-list

pyparsing frames and tweens - take 2

2007-11-05 Thread Donn Ingle
Paul, > frame = Literal("#") > tween = Word("-") # that is, it is a "word" composed of 1 or more -'s > copy = Literal("=") > blank = Literal("_") > > animation = OneOrMore((frame + Optional( > (tween + FollowedBy(frame)) | > OneOrMore(copy | blank) ) ) ) I found that this form insists on having

Re: python at command prompt

2007-11-05 Thread Ton van Vliet
On Mon, 05 Nov 2007 11:03:36 +1100, "[david]" <[EMAIL PROTECTED]> wrote: >Tim Roberts wrote: >> Ton van Vliet <[EMAIL PROTECTED]> wrote: >>> There's could also be an issue with entering 'python' at the command >>> line, and not 'python.exe'. Once the PATH is setup correctly, try to >>> enter 'pyth

Re: how does google search in phrase

2007-11-05 Thread Jeff
Here is a detailed explanation: http://www.google.com/technology/pigeonrank.html -- http://mail.python.org/mailman/listinfo/python-list

Re: how does google search in phrase

2007-11-05 Thread Dustan
On Nov 4, 6:21 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > hi my friends; > google can searching in phrase but it is imposible. it have a lot of > page in data base and quadrillions sentence it can't search in > fulltxt all of them .it need a super algorithm. ý need the algorithm > now. i

Re: Python good for data mining?

2007-11-05 Thread Greg Lindstrom
> -- Forwarded message -- > From: "D.Hering" <[EMAIL PROTECTED]> > To: python-list@python.org > Date: Sun, 04 Nov 2007 19:42:16 -0800 > Subject: Re: Python good for data mining? > On Nov 3, 9:02 pm, Jens <[EMAIL PROTECTED]> wrote: > > I'm starting a project indatamining, and I'm con

Downloading file from cgi application

2007-11-05 Thread sophie_newbie
Hi, I'm writing a cgi application in Python that generates a PDF file for the user and then allows them to download that file. Currently I'm just writing the PDF file to the 'htdocs' directory and giving the user a link to this file to download it. But the problem is that another user could simply

  1   2   >