Make extract listen for errors and pass them to callback