build(deps): bump all dependencies (#2532)

* build(deps): bump all dependencies

Signed-off-by: Jan-Otto Kröpke <mail@jkroepke.de>

* build(deps): bump all dependencies

Signed-off-by: Jan-Otto Kröpke <mail@jkroepke.de>
Signed-off-by: Jan-Otto Kröpke <joe@cloudeteer.de>

* build(deps): bump all dependencies

Signed-off-by: Jan-Otto Kröpke <mail@jkroepke.de>
Signed-off-by: Jan-Otto Kröpke <joe@cloudeteer.de>

* build(deps): bump all dependencies

Signed-off-by: Jan-Otto Kröpke <mail@jkroepke.de>

---------

Signed-off-by: Jan-Otto Kröpke <mail@jkroepke.de>
Signed-off-by: Jan-Otto Kröpke <joe@cloudeteer.de>
This commit is contained in:
Jan-Otto Kröpke
2024-08-02 23:23:53 +02:00
committed by GitHub
parent 7729fef2fe
commit fa4b69954d
30 changed files with 635 additions and 543 deletions
+6 -5
View File
@@ -3,6 +3,7 @@ package local
import (
"bufio"
"bytes"
"context"
"errors"
"io"
"os"
@@ -11,7 +12,7 @@ import (
"time"
"unicode/utf8"
storagedriver "github.com/docker/distribution/registry/storage/driver"
storagedriver "github.com/distribution/distribution/v3/registry/storage/driver"
zerr "zotregistry.dev/zot/errors"
storageConstants "zotregistry.dev/zot/pkg/storage/constants"
@@ -177,7 +178,7 @@ func (driver *Driver) WriteFile(filepath string, content []byte) (int, error) {
nbytes, err := io.Copy(writer, bytes.NewReader(content))
if err != nil {
_ = writer.Cancel()
_ = writer.Cancel(context.Background())
return -1, driver.formatErr(err)
}
@@ -316,7 +317,7 @@ func (driver *Driver) formatErr(err error) error {
default:
storageError := storagedriver.Error{
DriverName: driver.Name(),
Enclosed: err,
Detail: err,
}
return storageError
@@ -421,7 +422,7 @@ func (fw *fileWriter) Close() error {
return nil
}
func (fw *fileWriter) Cancel() error {
func (fw *fileWriter) Cancel(_ context.Context) error {
if fw.closed {
return zerr.ErrFileAlreadyClosed
}
@@ -432,7 +433,7 @@ func (fw *fileWriter) Cancel() error {
return os.Remove(fw.file.Name())
}
func (fw *fileWriter) Commit() error {
func (fw *fileWriter) Commit(_ context.Context) error {
//nolint: gocritic
if fw.closed {
return zerr.ErrFileAlreadyClosed
+1 -1
View File
@@ -6,7 +6,7 @@ import (
"strings"
"testing"
storagedriver "github.com/docker/distribution/registry/storage/driver"
storagedriver "github.com/distribution/distribution/v3/registry/storage/driver"
. "github.com/smartystreets/goconvey/convey"
storageConstants "zotregistry.dev/zot/pkg/storage/constants"