[ftputil] Problem using FTPHost.makedirs()

Roger Demetrescu roger.demetrescu at gmail.com
Tue Nov 4 02:51:02 CET 2014

Hi Stefan, how are you doing?

I've find an issue with ftputil 3.2 (well, it happens with 2.8 and 3.0
too) when trying to use host.makedirs() withing a FTP server that
doesnt show any directories/files under de root ('/')

My customer gave me this directory to work:


When I try to create this directory:   ./ddd/eee/
FTPHost.makedirs() try do create those directories:


Of course, /aaa already exists, and the ftputil does this check to see
if it should reraise the exception:

    if not self.path.isdir(next_directory):

The problem is: I am able to do a host.chdir('/aaa/bbb/ccc')
but if I do a host.chdir('/') and try to list de files and
directories, it returns an empty list.

Using FileZilla to connect to this FTP server gave me the same result.
I am able to see all files and directories under /aaa/bbb/ccc but I
see nothing under the root:  /

FTP is a Microsoft FTP Service (don't know any more details).

So, any suggestion on how to make ftputil stop trying to create theses


and only try to create:


since my current directory is already /aaa/bbb/ccc ?

Thanks in advance!


More information about the ftputil mailing list