I have tried the Python croniter's get_prev() method to get the last scheduled time based on a cron string and current time.
When I tried it in windows machine it returned the value in 24 hour format. But when I tried the same code via AWS glue (possibly Linux) , it returned scheduled time in 12 hour format without AM/PM notation.
Is there any way to force the croniter to return time in 24 hour format always.
currentTime=datetime.now()
print(currentTime)
cron = croniter(cron_str, currentTime)
lastCronScheduleTime=cron.get_prev(datetime)
print(lastCronScheduleTime)