error handling protocol