Merge "Catch generic exception to avoid crash." into nyc-dev