pgAgent updates the
pgagent.pga_job row for the job once the scheduled job completes. pgAgent will then only run the job a minimum of 1 minute later. The thread for jobs that are scheduled to run "every minute" looks for new jobs to run once per minute, at the start of each minute. So, if your job completes at 13:01:26, the next time the schedule runs will be 13:02:00, however since the job completed 34 seconds ago, it does not run the job. The next time the scheduler runs, at 13:03:00, it sees the job ran more than one minute ago, and runs the job.
The pgAgent source code for
pgagent.pga_next_schedule notes this:
-- Get the time to find the next run after. It will just be the later of
-- now() + 1m and the start date for the time being, however, we might want to
-- do more complex things using this value in the future.
IF date_trunc(''MINUTE'', jscstart) > date_trunc(''MINUTE'', (now() + ''1 Minute''::interval)) THEN
runafter := date_trunc(''MINUTE'', jscstart);
runafter := date_trunc(''MINUTE'', (now() + ''1 Minute''::interval));