diff --git a/server/forge/gitlab/gitlab.go b/server/forge/gitlab/gitlab.go index 0e85be2e9a..89faa2e5a1 100644 --- a/server/forge/gitlab/gitlab.go +++ b/server/forge/gitlab/gitlab.go @@ -33,7 +33,6 @@ import ( "github.com/woodpecker-ci/woodpecker/server" "github.com/woodpecker-ci/woodpecker/server/forge" "github.com/woodpecker-ci/woodpecker/server/forge/common" - "github.com/woodpecker-ci/woodpecker/server/forge/types" forge_types "github.com/woodpecker-ci/woodpecker/server/forge/types" "github.com/woodpecker-ci/woodpecker/server/model" "github.com/woodpecker-ci/woodpecker/server/store" @@ -620,7 +619,7 @@ func (g *GitLab) Hook(ctx context.Context, req *http.Request) (*model.Repo, *mod case *gitlab.TagEvent: return convertTagHook(event) default: - return nil, nil, &types.ErrIgnoreEvent{Event: string(eventType)} + return nil, nil, &forge_types.ErrIgnoreEvent{Event: string(eventType)} } } diff --git a/server/grpc/rpc.go b/server/grpc/rpc.go index de6c8352d4..41ac02cf35 100644 --- a/server/grpc/rpc.go +++ b/server/grpc/rpc.go @@ -28,7 +28,6 @@ import ( "github.com/prometheus/client_golang/prometheus" "github.com/rs/zerolog/log" - "google.golang.org/grpc/metadata" grpcMetadata "google.golang.org/grpc/metadata" "github.com/woodpecker-ci/woodpecker/pipeline/rpc" @@ -428,7 +427,7 @@ func (s *RPC) notify(c context.Context, repo *model.Repo, pipeline *model.Pipeli } func (s *RPC) getAgentFromContext(ctx context.Context) (*model.Agent, error) { - md, ok := metadata.FromIncomingContext(ctx) + md, ok := grpcMetadata.FromIncomingContext(ctx) if !ok { return nil, errors.New("metadata is not provided") }