better error resilience