Skip to content

Allow GitHub Actions workflow to run on pull requests from forked repos#279

Merged
jsvine merged 2 commits into
stablefrom
fix/fork-repo-workflow-run
Sep 30, 2020
Merged

Allow GitHub Actions workflow to run on pull requests from forked repos#279
jsvine merged 2 commits into
stablefrom
fix/fork-repo-workflow-run

Conversation

@samkit-jain

Copy link
Copy Markdown
Collaborator

I noticed in #278 that the checks were stuck at "Waiting for status to be reported". This was happening because in our workflow file we had set it to run on all push commits and apparently, that is not enough for the workflow to run on forked repos. This PR attempts to solve that by adding a pull_request_target event trigger so that the workflow is run on PRs raised from forked repos. More information can be found here and here.

@samkit-jain
samkit-jain requested a review from jsvine September 29, 2020 07:53
@samkit-jain

Copy link
Copy Markdown
Collaborator Author

The check is failing because of the newer black version. There are 2 options:

  • Pin the black version so that the checks pass and since merging in stable, no conflicts when merging stable onto develop
  • Reformat per the latest black version and change the base to develop

@jsvine

jsvine commented Sep 30, 2020

Copy link
Copy Markdown
Owner

Thanks for this PR, @samkit-jain and for raising the question about black. I think we should pin black to a specific version. I've pushed a quick-fix to stable doing so, and will merge this PR.

@codecov

codecov Bot commented Sep 30, 2020

Copy link
Copy Markdown

Codecov Report

Merging #279 into stable will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           stable     #279   +/-   ##
=======================================
  Coverage   97.41%   97.41%           
=======================================
  Files          10       10           
  Lines        1160     1160           
=======================================
  Hits         1130     1130           
  Misses         30       30           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6b8a590...ec9a0bf. Read the comment docs.

@jsvine
jsvine merged commit c95f4fd into stable Sep 30, 2020
@samkit-jain
samkit-jain deleted the fix/fork-repo-workflow-run branch September 30, 2020 09:45
samkit-jain added a commit that referenced this pull request Oct 1, 2020
In #279 `pull_request_target` was added which is now replaced with just `pull_request`
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

Successfully merging this pull request may close these issues.

2 participants