yiisoft / actions

https://www.yiiframework.com/
BSD 3-Clause "New" or "Revised" License
16 stars 2 forks source link

CI new pull request always fails? #52

Open nahakyuu opened 1 year ago

nahakyuu commented 1 year ago

https://github.com/yiisoft/yii-debug-api/actions/workflows/rector.yml?query=is%3Afailure

vjik commented 1 year ago

Rector workflow make commit and now fail on pull request from forks.

Can you try change /.github/workflow/rector.yml in your PR to this code:

on:
  pull_request:
    paths-ignore:
      - 'docs/**'
      - 'README.md'
      - 'CHANGELOG.md'
      - '.gitignore'
      - '.gitattributes'
      - 'infection.json.dist'
      - 'psalm.xml'

name: rector

jobs:
  rector:
    uses: yiisoft/actions/.github/workflows/rector.yml@master
    secrets:
      token: ${{ secrets.YIISOFT_GITHUB_TOKEN }}
    with:
      os: >-
        ['ubuntu-latest']
      php: >-
        ['8.0']

?

samdark commented 1 year ago

YIISOFT_GITHUB_TOKEN isn't passed to forks.

samdark commented 1 year ago

I think it's a good idea to fall back to regular GitHub token if YIISOFT_GITHUB_TOKEN isn't available.

vjik commented 1 year ago

But it's should be available in PR to origin repository

samdark commented 1 year ago

No.

image
vjik commented 1 year ago

Fall back already exist...