Improve exception handling and logging for model upload processing.