diff --git a/changelogs/unreleased/9808-Lyndon-Li b/changelogs/unreleased/9808-Lyndon-Li new file mode 100644 index 000000000..d3564ab2d --- /dev/null +++ b/changelogs/unreleased/9808-Lyndon-Li @@ -0,0 +1 @@ +Add Kopia repo snapshot operations for block data mover \ No newline at end of file diff --git a/pkg/repository/udmrepo/kopialib/lib_repo.go b/pkg/repository/udmrepo/kopialib/lib_repo.go index 2cc29e0de..7298347b7 100644 --- a/pkg/repository/udmrepo/kopialib/lib_repo.go +++ b/pkg/repository/udmrepo/kopialib/lib_repo.go @@ -498,7 +498,7 @@ func (kr *kopiaRepository) GetSnapshot(ctx context.Context, id udmrepo.ID) (udmr } if snap.RootEntry == nil { - return udmrepo.Snapshot{}, errors.Wrap(err, "invalid snapshot root entry") + return udmrepo.Snapshot{}, errors.New("invalid snapshot root entry") } return udmrepo.Snapshot{ diff --git a/pkg/repository/udmrepo/kopialib/lib_repo_test.go b/pkg/repository/udmrepo/kopialib/lib_repo_test.go index 750d2b9eb..1770ef83e 100644 --- a/pkg/repository/udmrepo/kopialib/lib_repo_test.go +++ b/pkg/repository/udmrepo/kopialib/lib_repo_test.go @@ -1565,12 +1565,12 @@ func TestListSnapshot(t *testing.T) { StartTime: fs.UTCTimestampFromTime(expectedTime), EndTime: fs.UTCTimestampFromTime(expectedTime.Add(time.Minute)), RootEntry: &snapshot.DirEntry{ - ObjectID: rawObjID, - FileSize: 100, - ModTime: fs.UTCTimestampFromTime(expectedTime), + ObjectID: rawObjID, + FileSize: 100, + ModTime: fs.UTCTimestampFromTime(expectedTime), Permissions: 0o644, - UserID: 1000, - GroupID: 1000, + UserID: 1000, + GroupID: 1000, }, Tags: map[string]string{"tag1": "val1"}, } @@ -1664,4 +1664,3 @@ func TestListSnapshot(t *testing.T) { }) } } -