Process with ftplib

nemo nemokingdom at gmail.com
Fri Dec 26 20:29:37 EST 2008


On Dec 26, 10:40 pm, "Gabriel Genellina" <gagsl-... at yahoo.com.ar>
wrote:
> En Fri, 26 Dec 2008 11:07:30 -0200, nemo <nemoking... at gmail.com> escribió:
>
> > There seems something wrong when I use multiprocessing.Process with
> > ftplib, [...]
> > It works well but when I using the Process module, something seems
> > wrong:
> > ftp = qftp(host, port, user, password)
> > p = multiprocessing.Process(target = ftp.connect)
> > p.join()
> > ftp.ftp.pwd()                   #after join, i think a connection has
> > made, but it throws an exception
> > This give me a 'NoneType object has no attribute sendall' exception. I
> > wondered why?
>
> After p.join(), the second process has finished. The global variable ftp  
> isn't shared between them - so it does not reflect the changes made in the  
> other process.
>
> An introductory article to multiprocessing:http://www.doughellmann.com/articles/CompletelyDifferent-2007-10-mult...
>
> --
> Gabriel Genellina

thanks.

--
nemo



More information about the Python-list mailing list