feat(aria2): show detailed error message from aria2 (#2296)
This commit is contained in:
@@ -139,6 +139,7 @@ func (a *aria2Client) Info(ctx context.Context, handle *downloader.TaskHandle) (
|
||||
UploadSpeed: uploadSpeed,
|
||||
SavePath: savePath,
|
||||
NumPieces: numPieces,
|
||||
ErrorMessage: status.ErrorMessage,
|
||||
Hash: status.InfoHash,
|
||||
Files: lo.Map(status.Files, func(item rpc.FileInfo, index int) downloader.TaskFile {
|
||||
index, _ = strconv.Atoi(item.Index)
|
||||
|
||||
@@ -44,6 +44,7 @@ type (
|
||||
Files []TaskFile `json:"files,omitempty"`
|
||||
Pieces []byte `json:"pieces,omitempty"` // Hexadecimal representation of the download progress of the peer. The highest bit corresponds to the piece at index 0.
|
||||
NumPieces int `json:"num_pieces,omitempty"`
|
||||
ErrorMessage string `json:"error_message,omitempty"`
|
||||
}
|
||||
|
||||
TaskFile struct {
|
||||
|
||||
Reference in New Issue
Block a user