It works! Thanks so much for your help!
--
http://mail.python.org/mailman/listinfo/python-list
> Unfortunatly I stiill get the same error. :-(
The same "metaclass bases[]" error??
> Here is the code:
> import ftplib
-snip-
> if __name__ == '__main__':
> ftp = ftplib.FTP("ftp.sadpanda.cjb.cc")
> ftp.login("sadpanda","PASSWORDEDITIEDOUT")
> filename = "/FrenchBrochure.pages
Unfortunatly I stiill get the same error. :-(
Here is the code:
import ftplib
class ProgressFile(file):
def read(self, size = None):
from sys import stdout
if size is not None:
buff = file.read(self, size)
if bu
Hello,
> file = "/FrenchBrochure.pages.zip"
> ftp.storbinary("STOR " + file, ProgressFile(file, "rb"), 1024)
You are using file = "/FrenchBrochure.pages.zip" (sorry I did not notice
earlier).
You can not use file as variable name like you have, as it represents a
file object in pyt
I'm really sorry that I keep having problems with this. :-( Now I get:
TypeError: Error when calling the metaclass bases[] str() takes at most
1 arguement (3 given)
and the Traceback is:
file "formattedthing", line 2, in '?'
classProgressFile(file)
With the following code:
import ftplib
class P
That is because you have just taken marduk's program and included your
ftp code... please see what he has done in the if __name__ == '__main__'
part.
He expects the file name as an commandline argument (sys.argv[1]) and
since you just copied his code, you are invoking the script *without*
the
When I execute the folllowing code with all of the address, username,
and passwords filled out I gt an error saying:
"/Library/Frameworks/Python.framework/Versions/2.4/Resources/Python.app/Contents/MacOS/Python"
"/Users/zacim/Documents/FireUpFTP/foramttedthing" ; exit
Traceback (most recent call l
Thanks, I'll give this a try. This will print a period right?
--
http://mail.python.org/mailman/listinfo/python-list
On Sat, 2005-09-17 at 04:42 +, marduk wrote:
>
> ... and I haven't tried this myself, but you should be able to subclass
> the builtin file object and prepare your own read() method. Something
> like
>
> class ProgressFile(file):
>
> def read(self, size = None):
> print '.',
>
On Fri, 2005-09-16 at 19:27 -0700, Nainto wrote:
> Hello, I have posted before about trying to find the status of an FTP
> uplaod but couldn't get anything to work. After some more searching I
> found
> http://groups.google.com/group/comp.lang.python/browse_thread/thread/76be9a994547db4/91917c906cd
Hello, I have posted before about trying to find the status of an FTP
uplaod but couldn't get anything to work. After some more searching I
found
http://groups.google.com/group/comp.lang.python/browse_thread/thread/76be9a994547db4/91917c906cdc04d4?q=ftp+progress&rnum=1#91917c906cdc04d4
but it does
11 matches
Mail list logo