ci: Run workflows only if changes involves them#3680
Conversation
|
@FBruzzesi If you wanna move this out of draft I'll review it. It seems ready to me, but I don't wanna prioritize it over others that you've marked as ready 🙂 |
|
@dangotbanned my only concern is about the repo ruleset for merging. Since some jobs do not run, they don't show up as succeeded, therefore merging is not available. I will try to take a look at the github docs this week |
|
Ah I see, yeah I think changing those rules is above my pay grade sadly 😅 |
|
@dangotbanned according to https://docs.github.com/en/actions/how-tos/write-workflows/choose-when-workflows-run/control-jobs-with-conditions
I think that if you/someone approves it, then it should act as any other PR |
dangotbanned
left a comment
There was a problem hiding this comment.
Thanks @FBruzzesi!
I stole the self-ref idea from (https://github.com/pola-rs/polars/blob/7b05d67937a6b715a813b65a20ee8fa8a01d4950/.github/workflows/test-python.yml)
| paths: | ||
| - "**.py" |
There was a problem hiding this comment.
| paths: | |
| - "**.py" | |
| paths: | |
| - "**.py" | |
| - .github/workflows/check_tpch_queries.yml |
| paths: | ||
| - src/** |
There was a problem hiding this comment.
| paths: | |
| - src/** | |
| paths: | |
| - src/** | |
| - .github/workflows/downstream_tests.yml |
| on: | ||
| pull_request: | ||
| paths: | ||
| - "**.py" |
There was a problem hiding this comment.
| - "**.py" | |
| - "**.py" | |
| - .github/workflows/extremes.yml |
| - src/** | ||
| - tests/** |
There was a problem hiding this comment.
| - src/** | |
| - tests/** | |
| - src/** | |
| - tests/** | |
| - .github/workflows/pytest-fireducks.yml |
Also we might be able to refine more with changes to pandas/dependencies, perhaps?
| - src/narwhals/_expression_parsing.py | ||
| - src/narwhals/_ibis/** | ||
| - src/narwhals/_sql/** | ||
| - tests/** |
There was a problem hiding this comment.
| - tests/** | |
| - tests/** | |
| - .github/workflows/pytest-ibis.yml |
Note
I keep forgetting to mention, but do we still need this job?
| paths: | ||
| - src/narwhals/_expression_parsing.py | ||
| - src/narwhals/_pandas_like/** | ||
| - tests/** |
There was a problem hiding this comment.
| - tests/** | |
| - tests/** | |
| - .github/workflows/pytest-modin.yml |
| on: | ||
| pull_request: | ||
| paths: | ||
| - "**.py" |
There was a problem hiding this comment.
| - "**.py" | |
| - "**.py" | |
| - .github/workflows/random_ci_pytest.yml |
| on: | ||
| pull_request: | ||
| paths: | ||
| - "**.py" |
There was a problem hiding this comment.
| - "**.py" | |
| - "**.py" | |
| - .github/workflows/pytest.yml |
| on: | ||
| pull_request: | ||
| paths: | ||
| - "**.py" |
There was a problem hiding this comment.
Finally one that is more interesting!
It is pretty common for typing issues to arise on version bumps, when we've done nothing internally
| - "**.py" | |
| - "**.py" | |
| - .github/workflows/typing.yml | |
| - pyproject.toml | |
| - uv.lock |

Description
Followup on #3609 (comment)
Trying to follow the same polars philosophy:
Difference between
src/**and**.pycase is to distinguish between:What type of PR is this? (check all applicable)