Skip to content
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

Action will be failed if run by PR #26

Closed
greenhat616 opened this issue Jul 22, 2020 · 1 comment
Closed

Action will be failed if run by PR #26

greenhat616 opened this issue Jul 22, 2020 · 1 comment

Comments

@greenhat616
Copy link

greenhat616 commented Jul 22, 2020

Summary

i. create a PR to a repo that configured revive action
ii. it will be failed as unexpected

attachment

the log is as below:

Run docker://morphy/revive-action:v1
/usr/bin/docker run --name morphyreviveactionv1_7788ea --label 87c201 --workdir /github/workspace --rm -e GITHUB_TOKEN -e INPUT_CONFIG -e INPUT_PATH -e HOME -e GITHUB_JOB -e GITHUB_REF -e GITHUB_SHA -e GITHUB_REPOSITORY -e GITHUB_REPOSITORY_OWNER -e GITHUB_RUN_ID -e GITHUB_RUN_NUMBER -e GITHUB_ACTOR -e GITHUB_WORKFLOW -e GITHUB_HEAD_REF -e GITHUB_BASE_REF -e GITHUB_EVENT_NAME -e GITHUB_SERVER_URL -e GITHUB_API_URL -e GITHUB_GRAPHQL_URL -e GITHUB_WORKSPACE -e GITHUB_ACTION -e GITHUB_EVENT_PATH -e RUNNER_OS -e RUNNER_TOOL_CACHE -e RUNNER_TEMP -e RUNNER_WORKSPACE -e ACTIONS_RUNTIME_URL -e ACTIONS_RUNTIME_TOKEN -e ACTIONS_CACHE_URL -e GITHUB_ACTIONS=true -e CI=true -v "/var/run/docker.sock":"/var/run/docker.sock" -v "/home/runner/work/_temp/_github_home":"/github/home" -v "/home/runner/work/_temp/_github_workflow":"/github/workflow" -v "/home/runner/work/ncm-helper/ncm-helper":"/github/workspace" morphy/revive-action:v1
Error while creating check-run: POST https://api.github.com/repos/greenhat616/ncm-helper/check-runs: 403 Resource not accessible by integration []

the workflow file:

on:
  push:
    branches: [ master ]
  pull_request:
    branches: [ master ]

name: Go
jobs:
  test:
    name: Test
    strategy:
      matrix:
        go-version: [1.14.x]
        platform: [ubuntu-latest]
    runs-on: ${{ matrix.platform }}
    steps:
    - name: Set up Go 1.x
      uses: actions/setup-go@v2
      with:
        go-version: ${{ matrix.go-version }}
      id: go

    - name: Check out code into the Go module directory
      uses: actions/checkout@v2
    - name: Cache Go module
      uses: actions/cache@v2
      with:
        path: ~/go/pkg/mod
        key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
        restore-keys: |
          ${{ runner.os }}-go-
    - name: Get dependences
      run: make dep
    - name: Check code issues by vet
      run: make vet
    - name: Test
      run: make test
    - name: Test Coverage
      run: make test-coverage
    - name: Post coverage data to Codecov
      uses: codecov/codecov-action@v1
      with:
        token: ${{ secrets.CODECOV_TOKEN }}
        file: ./coverage.txt
    - name: Clean Make
      run: make clean

  lint:
    name: Lint
    strategy:
      matrix:
        go-version: [1.14.x]
        platform: [ubuntu-latest]
    runs-on: ${{ matrix.platform }}
    steps:
      - name: Check out code into the Go module directory
        uses: actions/checkout@v2
      - name: Lint Go code with revive
        uses: docker://morphy/revive-action:v1
        with:
          config: ./revive.toml
          path: ./...
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

  build:
    name: Build
    strategy:
      matrix:
        go-version: [1.14.x]
        platform: [ubuntu-latest]
    runs-on: ${{ matrix.platform }}
    steps:
      - name: Set up Go 1.x
        uses: actions/setup-go@v2
        with:
          go-version: ${{ matrix.go-version }}
        id: go
      - name: Check out code into the Go module directory
        uses: actions/checkout@v2
      - name: Cache Go module
        uses: actions/cache@v2
        with:
          path: ~/go/pkg/mod
          key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
          restore-keys: |
            ${{ runner.os }}-go-
      - name: Build
        run: make build
@morphy2k
Copy link
Owner

Fixed with v2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants