0

Is it only me? I cant figure out, how to run job for example every minute on friday with Schedule module

import schedule
import time

def job(x):
    print("{} Amigo".format(x))

schedule.every(1).minutes.friday.do(job,'Hello')

while True:
    schedule.run_pending()
    time.sleep(1)

This code doesnt throw any error nor expected result. It just do nothing. Am I the only one who needs this kind of scheduling? Because I didnt see any example on this, nothing is in the documentation or in git repository as an example.

Could you please advice me, how to do this time logic with this library?

Thanks in advnce

Martin
  • 3,333
  • 2
  • 18
  • 39
  • `schedule` is not a module in the standard library. Are you using any external packages? We cannot guess you code dependancies, nor do we know every package that exists out there... – Ralf Sep 28 '18 at 18:21
  • yes, check this https://stackoverflow.com/questions/373335/how-do-i-get-a-cron-like-scheduler-in-python – Martin Sep 28 '18 at 18:22

0 Answers0