-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
CI: Automatic PR labelling is back #10201
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
Conversation
This reverts commit ce1af97.
There was some duplication here as `**` would capture `*` etc
Here's a script for your convenience showing each glob and the files it matches. Just CTRL+F for "no matches" from pathlib import Path
import yaml
CODEBASE = Path(".")
CONFIG_PATH = CODEBASE / ".github/labeler.yml"
CONFIG = yaml.safe_load(CONFIG_PATH.read_text())
del CONFIG["needs triage"]
def main():
for topic, label_obj in CONFIG.items():
globs = label_obj[0]["changed-files"][0]["any-glob-to-any-file"]
print(f"## {topic}")
for glob in globs:
print(f"- glob: {glob}")
matches = list(CODEBASE.glob(glob))
for m in matches:
print(f" - {m}")
if len(matches) == 0:
print(" - no matches")
print("\n")
if __name__ == "__main__":
main() output
|
pinging @TomNicholas since you submitted the prior issues/PRs on this topic. Feel free to review if you have a moment :) |
this looks good! I would recommend we slim down the categories a bit — easy to add more if we need, harder to prune I think the standard could be "would someone reasonable want to subscribe to one of the labels", for example I would like to immediately look at any issues with Rolling... |
lgtm — any feedback from anyone before merging? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great - I've missed this bot - thanks @VeckoTheGecko !
* Revert "Remove PR labeler bot (pydata#8525)" This reverts commit ce1af97. * Remove redundant globs There was some duplication here as `**` would capture `*` etc * Update actions/labeler to v5 * Label all PRs as "needs triage" * Try my best to update config to match current structure * patch needs triage regex * run pre-commit * Update labeler.yml to match current project structure * pr feedback
* main: (76 commits) Update how-to-add-new-backend.rst (#10240) Support extension array indexes (#9671) Switch documentation to pydata-sphinx-theme (#8708) Bump codecov/codecov-action from 5.4.0 to 5.4.2 in the actions group (#10239) Fix mypy, min-versions CI, xfail Zarr tests (#10255) Remove `test_dask_layers_and_dependencies` (#10242) Fix: Docs generation create temporary files that are not cleaned up. (#10238) opendap / dap4 support for pydap backend (#10182) Add RangeIndex (#10076) Fix mypy (#10232) Fix doctests (#10230) Fix broken Sphinx Roles (#10225) `DatasetView.map` fix `keep_attrs` (#10219) Add datatree repr asv (#10214) CI: Automatic PR labelling is back (#10201) Fixes dimension order in `xarray.Dataset.to_stacked_array` (#10205) Fix references to core classes in docs (#10207) Update pre-commit hooks (#10208) add `scipy-stubs` as extra `[types]` dependency (#10202) Fix sparse dask repr test (#10200) ...
Automatic PR labelling was added in #6912, then removed in [#8524, #8525] due to an archived dependency.
This PR fixes #8524. It:
needs triage
.github/labeler.yml
changed-files: any-glob-to-any-file:
to each glob.Please validate the
labeler.yml
config is correct and matches current project structure, or modify as you otherwise see fit.See open PR on my fork (VeckoTheGecko#3) for an example.
(ps, can someone update the body of GH10198 to point to point to GH9524 not GH8524? Kinda funny that a typo led to this PR 😂)