Skip to content

"No scope" warning for pull request closed events #129

@SatheeshJM

Description

@SatheeshJM

I get the warning No scopes with read permission were found on the request. if I setup my workflow for triggering on pull request: close.
If I change the trigger to push, it works.

Is the problem that the head_branch of the Pull Request can't read/write to the master's cache?

An example config

on:
  pull_request:
    types: 
      - closed
    branches: 
      - master

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@v2
      with:
        ref: master
        fetch-depth: 1
    - name: Cache node modules
      id: cache_node_modules
      uses: actions/cache@v1
      with: 
        path: node_modules
        key: ${{ runner.os }}-node-${{ hashFiles('package.json') }}

for the above config the cache is never used.. I get the below warning
image

If I tweak the workflow to trigger on branch push, all is well

on:
  push:
    branches: 
      - master

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@v2
      with:
        ref: master
        fetch-depth: 1
    - name: Cache node modules
      id: cache_node_modules
      uses: actions/cache@v1
      with: 
        path: node_modules
        key: ${{ runner.os }}-node-${{ hashFiles('package.json') }}

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationenhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions