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

Annotations appear on the wrong file #120

Open
CBID2 opened this issue Mar 5, 2024 · 1 comment
Open

Annotations appear on the wrong file #120

CBID2 opened this issue Mar 5, 2024 · 1 comment

Comments

@CBID2
Copy link

CBID2 commented Mar 5, 2024

Hi there! :) I’m currently testing Vale’s GitHub action before putting in this pull request. Now, in my test repo, the pushed file’s errors appear in the test logs: https://github.com/CBID2/github-actions-test-for-vale/actions/runs/8135829059/job/22231056287#step:3:194
screenshot of errors in test log

However, the annotations only on appear on the present file:
screenshot of annotations on untracked file

https://github.com/CBID2/github-actions-test-for-vale/pull/17/files

How can I make the annotations appear on the file being pushed?

@CollierCZ
Copy link
Contributor

You're running this workflow on pull_request_target events. That means it's running in the context of the branch you're trying to merge into (not the pull request itself). That means it has no idea about any files you're adding in the pull request.

I'd recommend setting up the workflow to run on pull requests against main using the GitHub token method.

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