Replies: 2 comments 1 reply
-
@jfmatth thanks to digging into the cause of this. I wasn't aware uwsgi's cron doesn't handle ranges. I wonder if we need to update the docs to mention this @rcarmo? |
Beta Was this translation helpful? Give feedback.
1 reply
-
Filed as #331. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Noticed that my cron line isn't being picked up correctly by Piku, and not being the crontab guru, hoping to find out if i'm right?
current
git push output from piku
Seems to only be picking up the cron.1 | [uwsgi-cron] command "1-5 ./bin/cron_job.sh" registered as cron task schedule?
Looking at the regex defined in piku.py
Thoughts?
I'm trying to have the job run from 6am to 1pm every minute M-F, if my crontab is wrong, let me know too.
shelling into the app, i see the uwsgi line is
Updates
After troubleshooting a lot, don't know why the jobs aren't running like they should
issue 1 - UTC counts, so I changed the job to run on UTC time, not local, so changed to run UTC, for just one hour and it works.
issue 2 - doesn't seem to like ranges?
This doesn't work for whatever reason, although UWSGI see's it OK according to the file and the docs
Really need ranges to work, but not sure what I'm doing wrong :(
Updates 2
OK, digging into the UWSGI C code, looks like they only support INT's on hours, so my guess is they are expecting a single number, uggh.
I'll assume that's the case, and create multiple cron jobs and see how that goes, uggh
Final solution
Just in case anyone else run's into this...
Kudo's to the Piku team for sending my cron string over to UWSGI, but unfortunately, UWSGI doesn't provide full crontab regex, which is fine. I ended up using Python's APSCHEDULER.
APscheduler is an amazing library, and even has a 3rd party add-on for Django. With a little work in apscheduler, I used their
from_crontab
trigger type:This worked like I needed it to.
I
Beta Was this translation helpful? Give feedback.
All reactions