mirror of
https://code.forgejo.org/forgejo/runner.git
synced 2025-09-05 18:40:59 +00:00
chore: replace gopkg.in/yaml.v3 with go.yaml.in/yaml/v3 (#888)
- gopkg.in/yaml.v3 is archived and unmaintained - go.yaml.in/yaml/v3 is a compatible fork under the umbrella of https://yaml.org/ Refs https://code.forgejo.org/forgejo/runner/issues/887 <!--start release-notes-assistant--> <!--URL:https://code.forgejo.org/forgejo/runner--> - other - [PR](https://code.forgejo.org/forgejo/runner/pulls/888): <!--number 888 --><!--line 0 --><!--description V0lQOiBjaG9yZTogcmVwbGFjZSBnb3BrZy5pbi95YW1sLnYzIHdpdGggZ28ueWFtbC5pbi95YW1sL3Yz-->WIP: chore: replace gopkg.in/yaml.v3 with go.yaml.in/yaml/v3<!--description--> <!--end release-notes-assistant--> Reviewed-on: https://code.forgejo.org/forgejo/runner/pulls/888 Reviewed-by: Mathieu Fenniak <mfenniak@noreply.code.forgejo.org> Reviewed-by: Michael Kriese <michael.kriese@gmx.de> Co-authored-by: Earl Warren <contact@earl-warren.org> Co-committed-by: Earl Warren <contact@earl-warren.org>
This commit is contained in:
parent
ce6502e7b6
commit
8f5470ad37
22 changed files with 24 additions and 21 deletions
|
@ -6,7 +6,7 @@ import (
|
|||
"strings"
|
||||
|
||||
"code.forgejo.org/forgejo/runner/v9/act/exprparser"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
// ExpressionEvaluator is copied from runner.expressionEvaluator,
|
||||
|
|
|
@ -3,7 +3,7 @@ package jobparser
|
|||
import (
|
||||
"code.forgejo.org/forgejo/runner/v9/act/exprparser"
|
||||
"code.forgejo.org/forgejo/runner/v9/act/model"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
// NewInterpeter returns an interpeter used in the server,
|
||||
|
|
|
@ -6,7 +6,7 @@ import (
|
|||
"sort"
|
||||
"strings"
|
||||
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
|
||||
"code.forgejo.org/forgejo/runner/v9/act/model"
|
||||
)
|
||||
|
|
|
@ -8,7 +8,7 @@ import (
|
|||
|
||||
"github.com/stretchr/testify/require"
|
||||
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
func TestParse(t *testing.T) {
|
||||
|
|
|
@ -5,7 +5,7 @@ import (
|
|||
"fmt"
|
||||
|
||||
"code.forgejo.org/forgejo/runner/v9/act/model"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
// SingleWorkflow is a workflow with single job and single matrix
|
||||
|
|
|
@ -9,7 +9,7 @@ import (
|
|||
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
func TestParseRawOn(t *testing.T) {
|
||||
|
|
|
@ -6,7 +6,7 @@ import (
|
|||
"strings"
|
||||
|
||||
"code.forgejo.org/forgejo/runner/v9/act/schema"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
// ActionRunsUsing is the type of runner for the action
|
||||
|
|
|
@ -16,7 +16,7 @@ import (
|
|||
"code.forgejo.org/forgejo/runner/v9/act/common"
|
||||
"code.forgejo.org/forgejo/runner/v9/act/schema"
|
||||
log "github.com/sirupsen/logrus"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
// Workflow is the structure of the files in .github/workflows
|
||||
|
|
|
@ -17,7 +17,7 @@ import (
|
|||
"code.forgejo.org/forgejo/runner/v9/act/container"
|
||||
"code.forgejo.org/forgejo/runner/v9/act/exprparser"
|
||||
"code.forgejo.org/forgejo/runner/v9/act/model"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
// ExpressionEvaluator is the interface for evaluating expressions
|
||||
|
|
|
@ -6,7 +6,7 @@ import (
|
|||
"code.forgejo.org/forgejo/runner/v9/act/exprparser"
|
||||
"code.forgejo.org/forgejo/runner/v9/act/model"
|
||||
assert "github.com/stretchr/testify/assert"
|
||||
yaml "gopkg.in/yaml.v3"
|
||||
yaml "go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
func createRunContext(t *testing.T) *RunContext {
|
||||
|
|
|
@ -22,7 +22,7 @@ import (
|
|||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/mock"
|
||||
"github.com/stretchr/testify/require"
|
||||
yaml "gopkg.in/yaml.v3"
|
||||
yaml "go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
func TestRunContext_EvalBool(t *testing.T) {
|
||||
|
|
|
@ -16,7 +16,7 @@ import (
|
|||
log "github.com/sirupsen/logrus"
|
||||
assert "github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
|
||||
"code.forgejo.org/forgejo/runner/v9/act/common"
|
||||
"code.forgejo.org/forgejo/runner/v9/act/model"
|
||||
|
|
|
@ -12,7 +12,7 @@ import (
|
|||
"code.forgejo.org/forgejo/runner/v9/act/model"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/mock"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
type stepActionLocalMocks struct {
|
||||
|
|
|
@ -9,7 +9,7 @@ import (
|
|||
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/mock"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
|
||||
"code.forgejo.org/forgejo/runner/v9/act/common"
|
||||
"code.forgejo.org/forgejo/runner/v9/act/common/git"
|
||||
|
|
|
@ -9,7 +9,7 @@ import (
|
|||
log "github.com/sirupsen/logrus"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/mock"
|
||||
yaml "gopkg.in/yaml.v3"
|
||||
yaml "go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
func TestStep_MergeIntoMap(t *testing.T) {
|
||||
|
|
|
@ -12,7 +12,7 @@ import (
|
|||
"strings"
|
||||
|
||||
"github.com/rhysd/actionlint"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
//go:embed workflow_schema.json
|
||||
|
|
|
@ -5,7 +5,7 @@ import (
|
|||
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
func TestAdditionalFunctions(t *testing.T) {
|
||||
|
|
3
go.mod
3
go.mod
|
@ -36,10 +36,10 @@ require (
|
|||
github.com/stretchr/testify v1.10.0
|
||||
github.com/timshannon/bolthold v0.0.0-20240314194003-30aac6950928
|
||||
go.etcd.io/bbolt v1.4.2
|
||||
go.yaml.in/yaml/v3 v3.0.4
|
||||
golang.org/x/term v0.34.0
|
||||
golang.org/x/time v0.12.0
|
||||
google.golang.org/protobuf v1.36.7
|
||||
gopkg.in/yaml.v3 v3.0.1
|
||||
gotest.tools/v3 v3.5.2
|
||||
)
|
||||
|
||||
|
@ -105,4 +105,5 @@ require (
|
|||
golang.org/x/sys v0.35.0 // indirect
|
||||
google.golang.org/genproto/googleapis/api v0.0.0-20231120223509-83a465c0220f // indirect
|
||||
gopkg.in/warnings.v0 v0.1.2 // indirect
|
||||
gopkg.in/yaml.v3 v3.0.1 // indirect
|
||||
)
|
||||
|
|
2
go.sum
2
go.sum
|
@ -226,6 +226,8 @@ go.opentelemetry.io/otel/trace v1.36.0 h1:ahxWNuqZjpdiFAyrIoQ4GIiAIhxAunQR6MUoKr
|
|||
go.opentelemetry.io/otel/trace v1.36.0/go.mod h1:gQ+OnDZzrybY4k4seLzPAWNwVBBVlF2szhehOBB/tGA=
|
||||
go.opentelemetry.io/proto/otlp v1.0.0 h1:T0TX0tmXU8a3CbNXzEKGeU5mIVOdf0oykP+u2lIVU/I=
|
||||
go.opentelemetry.io/proto/otlp v1.0.0/go.mod h1:Sy6pihPLfYHkr3NkUbEhGHFhINUSI/v80hjKIs5JXpM=
|
||||
go.yaml.in/yaml/v3 v3.0.4 h1:tfq32ie2Jv2UxXFdLJdh3jXuOzWiL1fo0bu/FbuKpbc=
|
||||
go.yaml.in/yaml/v3 v3.0.4/go.mod h1:DhzuOOF2ATzADvBadXxruRBLzYTpT36CKvDb3+aBEFg=
|
||||
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
|
||||
golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
|
|
|
@ -14,7 +14,7 @@ import (
|
|||
"connectrpc.com/connect"
|
||||
|
||||
"github.com/stretchr/testify/assert"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
func Test_createRunnerFileCmd(t *testing.T) {
|
||||
|
|
|
@ -11,7 +11,7 @@ import (
|
|||
|
||||
runnerv1 "code.forgejo.org/forgejo/actions-proto/runner/v1"
|
||||
"code.forgejo.org/forgejo/runner/v9/act/model"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
func generateWorkflow(task *runnerv1.Task) (*model.Workflow, string, error) {
|
||||
|
|
|
@ -12,7 +12,7 @@ import (
|
|||
|
||||
"github.com/joho/godotenv"
|
||||
log "github.com/sirupsen/logrus"
|
||||
"gopkg.in/yaml.v3"
|
||||
"go.yaml.in/yaml/v3"
|
||||
)
|
||||
|
||||
// Log represents the configuration for logging.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue