ftplib.FTP.nlst() behaviour on empty dirs

Discussion in 'Python' started by Mikael, Jul 14, 2004.

  1. Mikael

    Mikael Guest

    Hello,

    I am using the ftplib.FTP.nlst() method to list the files in
    a directory on a FTP server. But when the directoty is empty,
    python raises an error:

    ftplib.error_perm: 550 No files found.

    I find this behaviour very strange. Why not simply return an empty
    list?

    What do I do?

    /M
    Mikael, Jul 14, 2004
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Stephen Horne
    Replies:
    2
    Views:
    368
    Stephen Horne
    Feb 22, 2004
  2. Nico Grubert
    Replies:
    0
    Views:
    611
    Nico Grubert
    Nov 24, 2005
  3. Nico Grubert
    Replies:
    0
    Views:
    427
    Nico Grubert
    Nov 25, 2005
  4. loial
    Replies:
    1
    Views:
    1,754
    Giampaolo Rodola'
    Dec 7, 2007
  5. D. Buck
    Replies:
    2
    Views:
    447
    D. Buck
    Jun 29, 2004
Loading...

Share This Page