job poll callback: process only the relevant line

This change ensures that only the relevant line is processed. E.g. If we
use a login shell to call cylc on a remote job host, we can end up with
garbage in the output.