I\'m trying to get the datestamp on the file in mm/dd/yyyy format
time.ctime(os.path.getmtime(file))
gives me detailed time stamp Fri Jun
Fri Jun
You want to use time.strftime() to format the timestamp; convert it to a time tuple first using either time.gmtime() or time.localtime():
time.strftime('%m/%d/%Y', time.gmtime(os.path.getmtime(file)))