From 55051eb1001ba58d322ca5f6bf5516ed98239b33 Mon Sep 17 00:00:00 2001 From: Congqi Xia Date: Fri, 6 Sep 2024 14:33:39 +0800 Subject: [PATCH] fix: Use unified errors lib to fix lint Signed-off-by: Congqi Xia --- states/etcd/repair/channel_watched.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/states/etcd/repair/channel_watched.go b/states/etcd/repair/channel_watched.go index ffc2fa0..cbe2dad 100644 --- a/states/etcd/repair/channel_watched.go +++ b/states/etcd/repair/channel_watched.go @@ -6,8 +6,7 @@ import ( "sort" "strings" - "github.com/pkg/errors" - + "github.com/cockroachdb/errors" "github.com/milvus-io/birdwatcher/framework" "github.com/milvus-io/birdwatcher/models" "github.com/milvus-io/birdwatcher/states/etcd/common" @@ -27,7 +26,7 @@ func (c *ComponentRepair) RepairChannelWatchedCommand(ctx context.Context, p *Ch (p.ChannelName == "" || channel.Vchan.ChannelName == p.ChannelName) }) if err != nil { - return errors.Wrap(err, "failed to list channel watch info") + return errors.Errorf("failed to list channel watch info, %w", err) } var targets []*models.ChannelWatch