Detect and manage roc errors

Fixes #1