add header + sleep on error + trap position