mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2026-06-10 11:20:02 -04:00
chore: add more diagnostic output to dbfs Stat error (#11525)
Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/11525 Reviewed-by: Michael Kriese <michael.kriese@gmx.de> Co-authored-by: Mathieu Fenniak <mathieu@fenniak.net> Co-committed-by: Mathieu Fenniak <mathieu@fenniak.net>
This commit is contained in:
parent
b8dac67364
commit
7fdb31c8ef
1 changed files with 1 additions and 1 deletions
|
|
@ -61,7 +61,7 @@ func WriteLogs(ctx context.Context, filename string, offset int64, rows []*runne
|
|||
|
||||
stat, err := f.Stat()
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("dbfs Stat %q: %w", name, err)
|
||||
return nil, fmt.Errorf("WriteLogs(name=%q, offset=%d, len(rows)=%d): dbfs Stat: %w", name, offset, len(rows), err)
|
||||
}
|
||||
if stat.Size() < offset {
|
||||
// If the size is less than offset, refuse to write, or it could result in content holes.
|
||||
|
|
|
|||
Loading…
Reference in a new issue