Merge "Throw the right exception flavor." into nyc-dev