Process with ftplib

Gabriel Genellina gagsl-py2 at
Fri Dec 26 15:40:05 CET 2008

En Fri, 26 Dec 2008 11:07:30 -0200, nemo <nemokingdom at> 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:

Gabriel Genellina

More information about the Python-list mailing list