However, to solve the issue, it seems the answer is to check the queried object is not NULL $query->get_queried_object() !== NULL
I had to remove the query_var because it turned the homepage into a 404. A separate issue.
// redirect if there's no job id
function redirect_to_pending($query) {
if($query->get_queried_object() !== NULL && $query->is_page(26)) {
if(!isset($_GET['shazzid'])) {
wp_redirect(get_permalink(1752));
exit;
}
}
}
add_action('parse_query', 'redirect_to_pending');