amitree / delayed_job_recurring

Extends delayed_job to support recurring jobs
MIT License
84 stars 33 forks source link

Unable to set a job to run more than twice in a day #28

Closed laphlaw closed 5 years ago

laphlaw commented 5 years ago

Using this code: MyJob.schedule(run_every: 1.day, run_at: ['11:30am', '12:07pm' '11:55pm'])

It appears that only the first two times are scheduled to run, and the last time is ignored. See below:

irb(main):002:0> puts Delayed::Job.first.handler --- !ruby/object:MyJob schedule_options: :run_at:

afn commented 5 years ago

You seem to be missing a comma. Try:

MyJob.schedule(run_every: 1.day, run_at: ['11:30am', '12:07pm', '11:55pm'])
laphlaw commented 5 years ago

Oh wow, my bad. Thanks!