datenow -= timedelta(days=datenow.isoweekday() - 5)
print(datenow)
datenow = datenow.replace(hour=16, minute=0, second=0, microsecond=0)
print(datenow)
return datenow
How to create dates using datetime based on day of the week?