Skip to content

Add support for different FTP LIST locales (Windows CE exclusive?) #438

Closed
@atollk

Description

@atollk

We are using pyfilesystem2 to access a German locale FTP server on an MS Windows CE operating system. I cannot pinpoint whether it is the locale, the OS, or a different factor altogether, but the FTP LIST command, which is apparently used almost everywhere in the library, yields its data in a different format than Windows NT. Thus, FTPFS.read_dir fails to parse any items and always returns an empty dict and most operations fail.

To be precise, the LIST output only differs slightly in that it uses 24 hour days rather than 12 hour AM/PM days.

WinNT:
11-02-18 02:12PM <DIR> images
11-02-18 03:33PM 9276 logo.gif

WinCE:
11-02-18 14:12 <DIR> images
11-02-18 15:33 9276 logo.gif

We would like to see support for that format added, either as an extension to the "WindowsNT" parsing, or as a new kind of response parsing. If this is an acceptable change, we'd create the suitable PR for it. It would be great if this fix would make it into 2.4.12, as we'd have to keep using a custom fix in our code until 2.4.13 otherwise.

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions