Merge "Fail gracefully if we get a bad API whitelist." into pi-dev