feat: improve readability of error messages from ParseRawOn #1063
No reviewers
Labels
No labels
FreeBSD
Kind/Breaking
Kind/Bug
Kind/Chore
Kind/DependencyUpdate
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
Windows
linux-powerpc64le
linux-riscv64
linux-s390x
run-end-to-end-tests
run-forgejo-tests
run-multi-platform-tests
No milestone
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
forgejo/runner!1063
Loading…
Reference in a new issue
No description provided.
Delete branch "mfenniak/forgejo-runner:parserawon-error-messages"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
With https://codeberg.org/forgejo/forgejo/pulls/9530, the error messages from
ParseRawOnare user-facing and need a pass to improve their meaning.@ -272,4 +267,0 @@res = append(res, &Event{Name: k,acts: map[string][]string{},})These
switchcases aren't covered by any tests, don't match any documented supportedonblock, and don't actually use the valuet.The first case
stringwould represent if someone had this in their workflow...But it's going to act identically to:
The second case
[]stringwould represent...But it's going to act identically to:
This change validates the expected options a little more firmly which may make it a breaking change, but it would highlight any misconfiguration... if someone believed
push: abcwas filtering to the branch abc they would have unexpected behaviour currently.I'm 50/50 on removing them? Maybe it's just not in the scope of this change? I just couldn't test them which is why it felt like they needed to be removed.
I am OK to remove them.
I also have in the back of my mind a "weird behavior" red flag because I ran into unexplained behavior in the past. Until I keep using the exact same pattern for all
on:to avoid discovering bugs.I suspect a lot of people used the same "stick to the happy path" method.
The schema validation could catch
push: abcas being incorrect, but I'm unclear if that fits. The many variations ofon:structure makes it not the most amicable specification for static checking.cascading-pr updated at actions/setup-forgejo#708