--changed doesn't grab any files in CI #4896
Unanswered
Andrew-Chen-Wang
asked this question in
Q&A
Replies: 1 comment 4 replies
-
You're telling git, via Biome, to resolve the changed files from the This is expected. To solve your issue, you need to tell git, via Biome, to fetch the changed files from the ref of the PR (I am assuming that's what you're setting up, because it isn't stated in the question. Let me know if the intent is different). To do so, there's a |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
This is my GitHub Action
Here are some local tests
Resulting in this for a PR with 3 commits:
When I run locally in a PR branch:
Running without
--changed
Curiously, running just
check
:So what's going?
I think
--changed
requires the main branch to actually be set up. So we could modify the action to look like this:I wrote a fetch depth of 2 thinking that the 2 commits I have on a PR would compare with the main branch, but, unfortunately, no files were collected.
So there are two bugs in my opinion:
--changed
.--changed
is missing some files. At first I thought "oh maybe it skipped collecting new files", but that doesn't make sense since that's technically a change.Would love to get some thoughts above:)
For now, I've resolved to not using
--changed
. When doing type checking in mypy in python land, not checking all files at the same time made us sometimes miss changes, so I worry a linter would have a similar issue due to the sheer nature of git.Actually this is interesting: I just merged my PR and got this output in both the PR and main branch output
But locally, I got
Beta Was this translation helpful? Give feedback.
All reactions