Election results uses code in refresh_data.py. Candidates use process_candidates.py. Bring the two processes into alignment, probably closer to the candidate process, since that has been edited more recently.
In other words, run_matching_process is defined in two places with different code. It should only exist once.