Skip to content

fix: ValidationError: "// REF" must be of type object #27

@jjangga0214

Description

@jjangga0214

Hi!

I wonder what this error means.

스크린샷 2024-02-05 오후 9 21 32

Background:

I wanted safe-publish label to be automatically unlabeled when it's labeled.
(Scenario: Human labels PR, and some workflows are run, and then the label is to be removed.)

.github/workflows/main.yaml:

name: main

on:
  pull_request_target:
    types: [labeled] # <-- The workflow is triggered when it's labeled.

jobs:
  main:
    permissions:
      contents: write 
      issues: write
      pull-requests: write 

    runs-on: ubuntu-latest

    steps:

      # - name: do something..... (Omitted for brevity)

      - name: unlabel # <-- I want to remove the label from the PR
        if: contains(github.event.pull_request.labels.*.name, 'safe-publish')
        uses: dessant/label-actions@v4
        with:
          github-token: ${{ secrets.GITHUB_TOKEN }}

.github/label-actions.yml:

'safe-publish':
  prs:
    unlabel:
      - 'safe-publish'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions