Im attempting to perform an if statement at a certain time but can't get it to execute when it is that time. I am running the program when it reaches that time and nothing happens.
import os
import datetime
now = datetime.datetime.now()
if now.hour == 20 and now.minute == 46:
print ("REBOOTING")
os.system("shutdown -t 0 -r -f")