update
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
"""Safe operational notices; model failures are not missing business information."""
|
||||
|
||||
|
||||
def review_failure(exc):
|
||||
if getattr(exc, 'reason', None) == 'model_account_unavailable':
|
||||
return {
|
||||
'code': 'model_account_unavailable',
|
||||
'message': '模型服务账户暂不可用,请联系管理员检查账户余额及服务状态,恢复后重新分析。',
|
||||
}
|
||||
return {
|
||||
'code': 'analysis_incomplete',
|
||||
'message': '本次分析未完成,请稍后重新分析;无需因此修改目标或任务描述。',
|
||||
}
|
||||
Reference in New Issue
Block a user