fix grad status calculations, #847