mirror of
https://github.com/YspCoder/clawgo.git
synced 2026-05-06 16:57:29 +08:00
feat: harden jsonl runtime reliability
This commit is contained in:
@@ -101,6 +101,19 @@ type ProviderExecutionError struct {
|
||||
Source string `json:"source,omitempty"`
|
||||
}
|
||||
|
||||
func (e *ProviderExecutionError) Error() string {
|
||||
if e == nil {
|
||||
return ""
|
||||
}
|
||||
if e.Message != "" {
|
||||
return e.Message
|
||||
}
|
||||
if e.Code != "" {
|
||||
return e.Code
|
||||
}
|
||||
return "provider execution error"
|
||||
}
|
||||
|
||||
type ProviderExecutionResult struct {
|
||||
Body []byte `json:"-"`
|
||||
StatusCode int `json:"status_code,omitempty"`
|
||||
|
||||
Reference in New Issue
Block a user