[PR #2123] [MERGED] WorkflowDispatchConfig supports multiple yaml node kinds #2280

Closed
opened 2026-03-01 21:54:46 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/nektos/act/pull/2123
Author: @pangliang
Created: 12/12/2023
Status: Merged
Merged: 1/20/2024
Merged by: @mergify[bot]

Base: masterHead: WorkflowDispatchConfig_enhancement


📝 Commits (4)

  • 1072faa WorkflowDispatchConfig supports ScalarNode and SequenceNode yaml node kinds
  • 10ee45a Avoid using log.Fatal
  • d139d03 package slices is not in golang 1.20
  • f97f497 Merge branch 'master' into WorkflowDispatchConfig_enhancement

📊 Changes

2 files changed (+135 additions, -13 deletions)

View changed files

📝 pkg/model/workflow.go (+31 -13)
📝 pkg/model/workflow_test.go (+104 -0)

📄 Description

I was working on PR https://github.com/go-gitea/gitea/pull/28163 . and found that the workflow.WorkflowDispatchConfig() method cannot be parsed correctly when the yaml node is not a mapping type

on: workflow_dispatch

on: [push, workflow_dispatch]

on:
    - push
    - workflow_dispatch

on:
    push:
    pull_request:
    workflow_dispatch:
        inputs:
            logLevel:
                description: 'Log level'
                required: true
                default: 'warning'
                type: choice
                options:
                - info
                - warning
                - debug

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/nektos/act/pull/2123 **Author:** [@pangliang](https://github.com/pangliang) **Created:** 12/12/2023 **Status:** ✅ Merged **Merged:** 1/20/2024 **Merged by:** [@mergify[bot]](https://github.com/apps/mergify) **Base:** `master` ← **Head:** `WorkflowDispatchConfig_enhancement` --- ### 📝 Commits (4) - [`1072faa`](https://github.com/nektos/act/commit/1072faabc5d1ebcfdaed803e3a62a4ac14335600) WorkflowDispatchConfig supports ScalarNode and SequenceNode yaml node kinds - [`10ee45a`](https://github.com/nektos/act/commit/10ee45aaa1d13b725fe44dc2a28d83b3e9dc890a) Avoid using log.Fatal - [`d139d03`](https://github.com/nektos/act/commit/d139d0326e0f98c992bc46e2a419da165d42435d) package slices is not in golang 1.20 - [`f97f497`](https://github.com/nektos/act/commit/f97f4976391cdd37a7bf25cd3a9262c246b8d848) Merge branch 'master' into WorkflowDispatchConfig_enhancement ### 📊 Changes **2 files changed** (+135 additions, -13 deletions) <details> <summary>View changed files</summary> 📝 `pkg/model/workflow.go` (+31 -13) 📝 `pkg/model/workflow_test.go` (+104 -0) </details> ### 📄 Description I was working on PR https://github.com/go-gitea/gitea/pull/28163 . and found that the `workflow.WorkflowDispatchConfig()` method cannot be parsed correctly when the yaml node is not a mapping type ``` on: workflow_dispatch on: [push, workflow_dispatch] on: - push - workflow_dispatch on: push: pull_request: workflow_dispatch: inputs: logLevel: description: 'Log level' required: true default: 'warning' type: choice options: - info - warning - debug ``` --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-01 21:54:46 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/act#2280
No description provided.