From 44d9d4f45371ee64df88baa5767aab11f00552dc Mon Sep 17 00:00:00 2001 From: Earl Warren Date: Thu, 3 Jul 2025 16:55:53 +0000 Subject: [PATCH] chore: upgrade to code.forgejo.org/forgejo/actions-proto (#655) In replacement of code.gitea.io/actions-proto-go - https://gitea.com/gitea/actions-proto-def and https://gitea.com/gitea/actions-proto-go were merged into https://code.forgejo.org/forgejo/actions-proto to facilitate maintenance - the generated go code is different because the package name is different - https://code.forgejo.org/forgejo/actions-proto/commit/f4285dfc2855e3ef26f49d74a5c596e015d40607 shows they compare exactly identical before the name change - https://code.forgejo.org/forgejo/actions-proto/commit/a3c95cb82fbcb972432d04a51423710c43ed27ec is the generated code right after the name change - the cascading pull request further shows the protocol is compatible by running [end-to-end actions tests](https://code.forgejo.org/forgejo/end-to-end/src/branch/main/actions) that rely on it, using a runner binary built from [this pull request](https://code.forgejo.org/forgejo/end-to-end/actions/runs/3329/jobs/2#jobstep-4-640) `0296d988d65e66b8d8a7951d0d7d7f8c6cf78b44` matches `v0.0.1+576-g0296d98` - `time="2025-07-03T12:53:50Z" level=info msg="runner: runner, with version: v0.0.1+576-g0296d98, with labels: [docker], declared successfully" func="[func6]" file="[daemon.go:108]"` A similar pull request will be sent to Forgejo once this one is merged (less risky environment) Reviewed-on: https://code.forgejo.org/forgejo/runner/pulls/655 Reviewed-by: Michael Kriese Co-authored-by: Earl Warren Co-committed-by: Earl Warren --- go.mod | 2 +- go.sum | 4 ++-- internal/app/cmd/create-runner-file.go | 2 +- internal/app/cmd/create-runner-file_test.go | 2 +- internal/app/cmd/register.go | 4 ++-- internal/app/job/job.go | 2 +- internal/app/job/job_test.go | 6 +++--- internal/app/poll/poller.go | 2 +- internal/app/poll/poller_test.go | 6 +++--- internal/app/run/runner.go | 2 +- internal/app/run/workflow.go | 2 +- internal/app/run/workflow_test.go | 2 +- internal/pkg/client/client.go | 4 ++-- internal/pkg/client/http.go | 4 ++-- internal/pkg/client/mocks/Client.go | 4 ++-- internal/pkg/report/reporter.go | 2 +- internal/pkg/report/reporter_test.go | 2 +- 17 files changed, 26 insertions(+), 26 deletions(-) diff --git a/go.mod b/go.mod index 7618e50c..cd1b0bd6 100644 --- a/go.mod +++ b/go.mod @@ -5,7 +5,7 @@ go 1.23.0 toolchain go1.23.10 require ( - code.gitea.io/actions-proto-go v0.4.1 + code.forgejo.org/forgejo/actions-proto v0.5.1 code.gitea.io/gitea-vet v0.2.3 connectrpc.com/connect v1.18.1 github.com/avast/retry-go/v4 v4.6.1 diff --git a/go.sum b/go.sum index 4c38fd7e..ac8cc261 100644 --- a/go.sum +++ b/go.sum @@ -1,7 +1,7 @@ code.forgejo.org/forgejo/act v1.28.0 h1:96njNC7C1YNyjWq5OWvLZMF/nw0PMthzIA8Nwbnn7jo= code.forgejo.org/forgejo/act v1.28.0/go.mod h1:dFuiwAmD5vyrzecysHB2kL/GM3wRpoVPl+WdbCTC8Bs= -code.gitea.io/actions-proto-go v0.4.1 h1:l0EYhjsgpUe/1VABo2eK7zcoNX2W44WOnb0MSLrKfls= -code.gitea.io/actions-proto-go v0.4.1/go.mod h1:mn7Wkqz6JbnTOHQpot3yDeHx+O5C9EGhMEE+htvHBas= +code.forgejo.org/forgejo/actions-proto v0.5.1 h1:GCJHR/Y/Apk7Yl7CH9qOsKrdf/k0tRVFeVhz1EIZvb4= +code.forgejo.org/forgejo/actions-proto v0.5.1/go.mod h1:nu8N1HQLsu3c4T/PpYWbqwNBxsZnEOVxqV0mQWtIQvE= code.gitea.io/gitea-vet v0.2.3 h1:gdFmm6WOTM65rE8FUBTRzeQZYzXePKSSB1+r574hWwI= code.gitea.io/gitea-vet v0.2.3/go.mod h1:zcNbT/aJEmivCAhfmkHOlT645KNOf9W2KnkLgFjGGfE= connectrpc.com/connect v1.18.1 h1:PAg7CjSAGvscaf6YZKUefjoih5Z/qYkyaTrBW8xvYPw= diff --git a/internal/app/cmd/create-runner-file.go b/internal/app/cmd/create-runner-file.go index a972624f..09cf00f0 100644 --- a/internal/app/cmd/create-runner-file.go +++ b/internal/app/cmd/create-runner-file.go @@ -8,7 +8,7 @@ import ( "fmt" "os" - pingv1 "code.gitea.io/actions-proto-go/ping/v1" + pingv1 "code.forgejo.org/forgejo/actions-proto/ping/v1" "connectrpc.com/connect" gouuid "github.com/google/uuid" log "github.com/sirupsen/logrus" diff --git a/internal/app/cmd/create-runner-file_test.go b/internal/app/cmd/create-runner-file_test.go index 4f3acb83..1d84faf4 100644 --- a/internal/app/cmd/create-runner-file_test.go +++ b/internal/app/cmd/create-runner-file_test.go @@ -8,7 +8,7 @@ import ( "os" "testing" - runnerv1 "code.gitea.io/actions-proto-go/runner/v1" + runnerv1 "code.forgejo.org/forgejo/actions-proto/runner/v1" "connectrpc.com/connect" "gitea.com/gitea/act_runner/internal/pkg/client" "gitea.com/gitea/act_runner/internal/pkg/config" diff --git a/internal/app/cmd/register.go b/internal/app/cmd/register.go index d3624828..43633a40 100644 --- a/internal/app/cmd/register.go +++ b/internal/app/cmd/register.go @@ -13,8 +13,8 @@ import ( "strings" "time" - pingv1 "code.gitea.io/actions-proto-go/ping/v1" - runnerv1 "code.gitea.io/actions-proto-go/runner/v1" + pingv1 "code.forgejo.org/forgejo/actions-proto/ping/v1" + runnerv1 "code.forgejo.org/forgejo/actions-proto/runner/v1" "connectrpc.com/connect" "github.com/mattn/go-isatty" log "github.com/sirupsen/logrus" diff --git a/internal/app/job/job.go b/internal/app/job/job.go index dfa184a0..ec0ad92e 100644 --- a/internal/app/job/job.go +++ b/internal/app/job/job.go @@ -12,7 +12,7 @@ import ( "connectrpc.com/connect" log "github.com/sirupsen/logrus" - runnerv1 "code.gitea.io/actions-proto-go/runner/v1" + runnerv1 "code.forgejo.org/forgejo/actions-proto/runner/v1" "gitea.com/gitea/act_runner/internal/app/run" "gitea.com/gitea/act_runner/internal/pkg/client" "gitea.com/gitea/act_runner/internal/pkg/config" diff --git a/internal/app/job/job_test.go b/internal/app/job/job_test.go index 086c69f8..19b05d29 100644 --- a/internal/app/job/job_test.go +++ b/internal/app/job/job_test.go @@ -8,9 +8,9 @@ import ( "connectrpc.com/connect" - "code.gitea.io/actions-proto-go/ping/v1/pingv1connect" - runnerv1 "code.gitea.io/actions-proto-go/runner/v1" - "code.gitea.io/actions-proto-go/runner/v1/runnerv1connect" + "code.forgejo.org/forgejo/actions-proto/ping/v1/pingv1connect" + runnerv1 "code.forgejo.org/forgejo/actions-proto/runner/v1" + "code.forgejo.org/forgejo/actions-proto/runner/v1/runnerv1connect" "gitea.com/gitea/act_runner/internal/pkg/config" log "github.com/sirupsen/logrus" diff --git a/internal/app/poll/poller.go b/internal/app/poll/poller.go index cc89fa50..6fd3e027 100644 --- a/internal/app/poll/poller.go +++ b/internal/app/poll/poller.go @@ -10,7 +10,7 @@ import ( "sync" "sync/atomic" - runnerv1 "code.gitea.io/actions-proto-go/runner/v1" + runnerv1 "code.forgejo.org/forgejo/actions-proto/runner/v1" "connectrpc.com/connect" log "github.com/sirupsen/logrus" "golang.org/x/time/rate" diff --git a/internal/app/poll/poller_test.go b/internal/app/poll/poller_test.go index 04b1a841..2df133d3 100644 --- a/internal/app/poll/poller_test.go +++ b/internal/app/poll/poller_test.go @@ -11,9 +11,9 @@ import ( "connectrpc.com/connect" - "code.gitea.io/actions-proto-go/ping/v1/pingv1connect" - runnerv1 "code.gitea.io/actions-proto-go/runner/v1" - "code.gitea.io/actions-proto-go/runner/v1/runnerv1connect" + "code.forgejo.org/forgejo/actions-proto/ping/v1/pingv1connect" + runnerv1 "code.forgejo.org/forgejo/actions-proto/runner/v1" + "code.forgejo.org/forgejo/actions-proto/runner/v1/runnerv1connect" "gitea.com/gitea/act_runner/internal/pkg/config" log "github.com/sirupsen/logrus" diff --git a/internal/app/run/runner.go b/internal/app/run/runner.go index 4c6d6556..4f121514 100644 --- a/internal/app/run/runner.go +++ b/internal/app/run/runner.go @@ -15,7 +15,7 @@ import ( "sync" "time" - runnerv1 "code.gitea.io/actions-proto-go/runner/v1" + runnerv1 "code.forgejo.org/forgejo/actions-proto/runner/v1" "connectrpc.com/connect" "github.com/docker/docker/api/types/container" "github.com/nektos/act/pkg/artifactcache" diff --git a/internal/app/run/workflow.go b/internal/app/run/workflow.go index a6fbb71c..f742c20e 100644 --- a/internal/app/run/workflow.go +++ b/internal/app/run/workflow.go @@ -9,7 +9,7 @@ import ( "sort" "strings" - runnerv1 "code.gitea.io/actions-proto-go/runner/v1" + runnerv1 "code.forgejo.org/forgejo/actions-proto/runner/v1" "github.com/nektos/act/pkg/model" "gopkg.in/yaml.v3" ) diff --git a/internal/app/run/workflow_test.go b/internal/app/run/workflow_test.go index 4ab31b14..6f57c7d2 100644 --- a/internal/app/run/workflow_test.go +++ b/internal/app/run/workflow_test.go @@ -6,7 +6,7 @@ package run import ( "testing" - runnerv1 "code.gitea.io/actions-proto-go/runner/v1" + runnerv1 "code.forgejo.org/forgejo/actions-proto/runner/v1" "github.com/nektos/act/pkg/model" "github.com/stretchr/testify/require" "gotest.tools/v3/assert" diff --git a/internal/pkg/client/client.go b/internal/pkg/client/client.go index 57f91add..0fb1620a 100644 --- a/internal/pkg/client/client.go +++ b/internal/pkg/client/client.go @@ -4,8 +4,8 @@ package client import ( - "code.gitea.io/actions-proto-go/ping/v1/pingv1connect" - "code.gitea.io/actions-proto-go/runner/v1/runnerv1connect" + "code.forgejo.org/forgejo/actions-proto/ping/v1/pingv1connect" + "code.forgejo.org/forgejo/actions-proto/runner/v1/runnerv1connect" ) // A Client manages communication with the runner. diff --git a/internal/pkg/client/http.go b/internal/pkg/client/http.go index 193e3298..8e0eb2a1 100644 --- a/internal/pkg/client/http.go +++ b/internal/pkg/client/http.go @@ -9,8 +9,8 @@ import ( "net/http" "strings" - "code.gitea.io/actions-proto-go/ping/v1/pingv1connect" - "code.gitea.io/actions-proto-go/runner/v1/runnerv1connect" + "code.forgejo.org/forgejo/actions-proto/ping/v1/pingv1connect" + "code.forgejo.org/forgejo/actions-proto/runner/v1/runnerv1connect" "connectrpc.com/connect" ) diff --git a/internal/pkg/client/mocks/Client.go b/internal/pkg/client/mocks/Client.go index a8bfdb19..cfd58072 100644 --- a/internal/pkg/client/mocks/Client.go +++ b/internal/pkg/client/mocks/Client.go @@ -9,9 +9,9 @@ import ( mock "github.com/stretchr/testify/mock" - pingv1 "code.gitea.io/actions-proto-go/ping/v1" + pingv1 "code.forgejo.org/forgejo/actions-proto/ping/v1" - runnerv1 "code.gitea.io/actions-proto-go/runner/v1" + runnerv1 "code.forgejo.org/forgejo/actions-proto/runner/v1" ) // Client is an autogenerated mock type for the Client type diff --git a/internal/pkg/report/reporter.go b/internal/pkg/report/reporter.go index cee50623..1cbe19b4 100644 --- a/internal/pkg/report/reporter.go +++ b/internal/pkg/report/reporter.go @@ -11,7 +11,7 @@ import ( "sync" "time" - runnerv1 "code.gitea.io/actions-proto-go/runner/v1" + runnerv1 "code.forgejo.org/forgejo/actions-proto/runner/v1" "connectrpc.com/connect" retry "github.com/avast/retry-go/v4" log "github.com/sirupsen/logrus" diff --git a/internal/pkg/report/reporter_test.go b/internal/pkg/report/reporter_test.go index 524e9724..0b9379b2 100644 --- a/internal/pkg/report/reporter_test.go +++ b/internal/pkg/report/reporter_test.go @@ -9,7 +9,7 @@ import ( "testing" "time" - runnerv1 "code.gitea.io/actions-proto-go/runner/v1" + runnerv1 "code.forgejo.org/forgejo/actions-proto/runner/v1" connect_go "connectrpc.com/connect" log "github.com/sirupsen/logrus" "github.com/stretchr/testify/assert"