-
Notifications
You must be signed in to change notification settings - Fork 421
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error: found unexpected type for label 'xxx' (should be array of config options) #712
Comments
Hello @HorizonNet! |
I'm having the same issue. My config looks like this.
|
@HorizonNet could you please provide us with a link to the public repository where the issue occurs? |
@MaksimZhukov we have this issue with labels in the format of Failed public run Edit: Basic ones that are failing.
Config
|
Thank you @bryannaegele! |
I don't know if it's just some yaml parsing strictness that's changed. That's all I can think of. Updated comment above with error and example. |
@bryannaegele you see the error because the configuration file structure was significantly redesigned and is not compatible with the structure of the previous version. Please read the action documentation to find out how to adapt your configuration files for use with the new action version |
Oh, wow. I didn't see that. That's a significant change. Noted. 👍🏻 |
@MaksimZhukov we are having the same issue as well. Does both action version and its configuration be up to date in the develop/main branch for this to work? This was my attempt to update configuration, but GHA is still failing
|
I've also ran into the same issue, but I'm not sure what is correct. The README refers to lists of globs, however, the examples show only a string and not a list. And then the config on #712 (comment) shows multiple items with |
Hello @mndeveci! I am using your configuration file and it works (workflow run, related PR). Could you please check? Hello @lamdor! Thank you for your comment! We will add more examples to the documentation! |
Let me echo the above question: which action and labeling configuration files are used upon a run, the ones from the base branch or the ones from the head branch? model-checking/kani#2923 (with GitHub action log https://github.com/model-checking/kani/actions/runs/7131018587/job/19418690999) was my attempt to downgrade to v4, but it would still fail with this error message?! Are we perhaps just facing a transient issue in that we need to accept the failure in the PR that upgrades the config file, and all will be well afterwards? |
@tautschnig |
Depending on what your workflows do based on labels, I suggest not permanently using checkout and using what is in the head branch to prevent PRs from causing issues or opening up potential abuse. |
I had the same issue. I created a PR that migrates the config from v4 format to v5 format. I changed the triggering event from In theory, using the After a successful run, removing I looked into the implementation of how |
Hi, all! Thanks for drawing our attention to the issue ❤️ , recently we've merged PR that should clarify the cause of the problem, provide mitigation plan and help to make process of migration clearer. I'm going to close this issue, if you have any additional questions feel free to reach out. |
Upgrades `labeleler.yml` to v5 and fixes the breaking changes. Useful documentation for this PR: * actions/labeler#712 * https://github.com/actions/labeler/tree/main?tab=readme-ov-file#basic-examples
After switching from v4 to v5 labeler, it does not seem to be stable and consistent. Now labeler action randomly fails with:
Strangely if I re-run same failed job, it then passes. And most of the time it passes first time, but sometimes just fails randomly with that error.. workflow looks like this: name: Labeler
on:
- pull_request_target
jobs:
triage:
permissions:
contents: read
pull-requests: write
runs-on: [self-hosted, pool]
steps:
- uses: actions/labeler@v5
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
sync-labels: true Config: ---
documentation:
- changed-files:
- any-glob-to-any-file:
- docs/**/*
- README.rst
ops:
- changed-files:
- any-glob-to-any-file:
- ops/**/*
- .github/**/*
dev:
- changed-files:
- any-glob-to-any-file:
- src/**/* P.S. v4 had no such problems. |
Despite the fact that the labeler v5.0.0 demands a different syntax for the configuration file, it has inconsistent behavior: actions/labeler#712 (comment) So, return to the most recent version that works as expected.
Despite the fact that the labeler v5.0.0 demands a different syntax for the configuration file, it has inconsistent behavior: actions/labeler#712 (comment) So, return to the most recent version that works as expected.
After changing
|
I am still seeing this issue. Here is what I have: File
File
But I see the following error:
Any idea how to fix this? |
Description:
After upgrading to v5.0.0 and changing the labeler configuration file matching to what is outlined in the documentation, I'm receiving the following error as soon as the action starts
Action version:
5.0.0
Platform:
Runner type:
Repro steps:
After upgrading to 5.0.0 changed the labeler configuration to
which to me looks similar to the example from the documentation
The workflow is defined as follows and used to work previously
Expected behavior:
The action should run successfully.
Actual behavior:
The action is failing with the error provided above.
The text was updated successfully, but these errors were encountered: