shep uses a defer to always signal worker even on error exit