def QA_util_datetime_to_strdate ( dt ) : strdate = "%04d-%02d-%02d" % ( dt . year , dt . month , dt . day ) return strdate
python best way to stringify a date
: param dt : pythone datetime . datetime : return : 1999 - 02 - 01 string type
def QA_util_datetime_to_strdate(dt):
    """
    :param dt:  pythone datetime.datetime
    :return:  1999-02-01 string type
    """
    strdate = "%04d-%02d-%02d" % (dt.year, dt.month, dt.day)
    return strdate