Skip to content

German date with leading zeros not working properly when no year given #902

Open
@SiKreuz

Description

@SiKreuz

Reproduction

I'm using this method to parse a german date without year:

dateparser.parse('13.01.', languages=['de'])

What I get returned is a datetime object with the current date and time, no reference to my given date-string. If I leave out the zero, it's working. If I add a year, it's working. So the following is no problem and parsed properly:

dateparser.parse('13.1.', languages=['de'])
dateparser.parse('13.01.2001', languages=['de'])

Using the format MM/DD is also no problem and working fine for me, but DD.MM is not.

System

  • OS: Arch Linux 5.11.11-arch1-1 and Arch Linux 5.11.4-1-ARCH
  • Version: v1.0.0

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions