(self, dt)
dt (str) => datetime
dt (str) => datetime
dt ( str ) = > datetime
def _parse_date(self, dt):
        """dt (str) => datetime"""
        try:
            return datetime.strptime(dt, "%Y-%m")
        except ValueError:
            return datetime.strptime(dt, "%Y-%m-%d")
def _parse_date ( self , dt ) : try : return datetime . strptime ( dt , "%Y-%m" ) except ValueError : return datetime . strptime ( dt , "%Y-%m-%d" )