Re: Access class from staticmethod

2010-04-30 Thread Thomas Allen
Ah ha, @classmethod. On Apr 30, 3:47 pm, Thomas Allen wrote: > Is that possible? > > class A(object): >   @staticmethod >   def set_b(x): >     # A.b = x, without knowing A is "A" >     pass > > Thomas -- http://mail.python.org/mailman/listinfo/python-list

Access class from staticmethod

2010-04-30 Thread Thomas Allen
Is that possible? class A(object): @staticmethod def set_b(x): # A.b = x, without knowing A is "A" pass Thomas -- http://mail.python.org/mailman/listinfo/python-list

SimpleXMLRPCServer daemon

2010-01-29 Thread Thomas Allen
e if it were deleted reliably. Thomas Allen -- http://mail.python.org/mailman/listinfo/python-list

Re: Python simple web development

2009-06-26 Thread Thomas Allen
On Jun 25, 3:29 am, Private Private wrote: > Hi, > > I am looking for a python library which will allow me to do a simple > web development. I need to use > some forms (but nice looking :-) ), creating images based on input > from those forms, etc. I have read a bit about Django and TurboGears > b

Re: FTP libs for Python?

2009-02-20 Thread Thomas Allen
On Feb 20, 9:45 am, coldpizza wrote: > Why don't you just use Curl? It does a dozen of protocols including > SFTP. And if the command line version is not enough for you then there > are Python bindings for Curl. I'm actually hoping to eventually package these tools using py2exe for some co-worker

FTP libs for Python?

2009-02-20 Thread Thomas Allen
I'm interested in writing a script to ease deployment of minor changes on some websites here, and it would involve some SFTP transfers. Do you know of good alternatives to ftplib, which is relatively low- level? Thomas -- http://mail.python.org/mailman/listinfo/python-list

Re: "Maximum recursion depth exceeded"...why?

2009-02-19 Thread Thomas Allen
On Feb 18, 10:15 pm, rdmur...@bitdance.com wrote: > Thomas Allen wrote: > > On Feb 18, 4:51 am, alex23 wrote: > > > On Feb 18, 7:34 pm, rdmur...@bitdance.com wrote: > > > > > Yeah, but wget -r -k will do that bit of it, too. > > > > Wow, nice,

Re: "Maximum recursion depth exceeded"...why?

2009-02-18 Thread Thomas Allen
On Feb 18, 4:51 am, alex23 wrote: > On Feb 18, 7:34 pm, rdmur...@bitdance.com wrote: > > > Yeah, but wget -r -k will do that bit of it, too. > > Wow, nice, I don't know why I never noticed that. Cheers! Hm...doesn't do that over here. I thought it may have been because of absolute links (not to s

Re: "Maximum recursion depth exceeded"...why?

2009-02-17 Thread Thomas Allen
On Feb 17, 9:08 pm, Christian Heimes wrote: > Thomas Allen wrote: > > If you'd read the messages in this thread you'd understand why I'm not > > using os.walk(): I'm not using it because I need my code to be aware > > of the current recursion dept

Re: "Maximum recursion depth exceeded"...why?

2009-02-17 Thread Thomas Allen
On Feb 17, 7:05 pm, Christian Heimes wrote: > Thomas Allen wrote: > > I'm referring to the same code, but with a print: > > > for file in os.listdir(dir): > >     if os.path.isdir(file): > >         print "D", file > > > in place of th

Re: "Maximum recursion depth exceeded"...why?

2009-02-17 Thread Thomas Allen
On Feb 17, 6:05 pm, Peter Otten <__pete...@web.de> wrote: > Thomas Allen wrote: > > On Feb 17, 5:31 pm, Peter Otten <__pete...@web.de> wrote: > >> Thomas Allen wrote: > >> > I must not be understanding something. This is a simple recursive > >>

Re: "Maximum recursion depth exceeded"...why?

2009-02-17 Thread Thomas Allen
On Feb 17, 5:31 pm, Peter Otten <__pete...@web.de> wrote: > Thomas Allen wrote: > > I must not be understanding something. This is a simple recursive > > function that prints all HTML files in argv[1] as its scans the > > directory's contents. Why do I get a

Re: "Maximum recursion depth exceeded"...why?

2009-02-17 Thread Thomas Allen
On Feb 17, 4:46 pm, Thomas Allen wrote: > I must not be understanding something. This is a simple recursive > function that prints all HTML files in argv[1] as its scans the > directory's contents. Why do I get a RuntimeError for recursion depth > exceeded? > > #!/usr/bin/e

"Maximum recursion depth exceeded"...why?

2009-02-17 Thread Thomas Allen
I must not be understanding something. This is a simple recursive function that prints all HTML files in argv[1] as its scans the directory's contents. Why do I get a RuntimeError for recursion depth exceeded? #!/usr/bin/env python import os, sys def main(): absToRel(sys.argv[1], sys.argv[2]