add readme and better error reporting