changed the title [-]bedevere could add docs label for prs, that touch Doc/tools/.nitignore[/-][+]Add docs label for PRs that touch Doc/tools/.nitignore[/+]on Jan 19, 2024
I guess - so. Or every pr that has some *.rst file could skip news.
That wouldn't be correct — there are lots of PRs that introduce new features and add docs for the new feature as part of the same PR. Most of those PRs need news entries.
Ok, so the goal is to add the docs label only to PRs that are "docs-only", i.e. they only change documentation and possibly files related to the documentation (like .nitignore). If a PR adds a new feature and edits the docs to document it, it's not "docs-only" and shouldn't get the docs label.
(Maybe this should be spelled out clearly in a comment/docstring, including the expected behavior for other labels, since the intention is currently not too clear IMHO).
Activity
hugovk commented on Jan 19, 2024
Good idea!
I found it a bit annoying the label is added for PRs touching rst files in Docs/, but not those touching rst plus .nitignore.
skirpichev commented on Jan 19, 2024
PR: #617
ezio-melotti commented on Jan 20, 2024
Why does this happen? Isn't bedevere already adding the docs label whenever at least an .rst file has been changed, regardless of the other files?
skirpichev commented on Jan 20, 2024
Looking in the sources, it doesn't add any labels (pr_labels == []) if there is some file, which doesn't match known patterns:
bedevere/bedevere/prtype.py
Lines 42 to 51 in b5bcd24
Another case: #605
ezio-melotti commented on Jan 20, 2024
So the problem is the return (prematurely?) terminating the loop? Is that intentional?
skirpichev commented on Jan 20, 2024
I guess - so. Or every pr that has some *.rst file could skip news.
AlexWaygood commented on Jan 20, 2024
That wouldn't be correct — there are lots of PRs that introduce new features and add docs for the new feature as part of the same PR. Most of those PRs need news entries.
skirpichev commented on Jan 20, 2024
(On another hand, most PRs, that touch only test files - probably could skip news;) That's another story, however.)
ezio-melotti commented on Jan 20, 2024
Ok, so the goal is to add the docs label only to PRs that are "docs-only", i.e. they only change documentation and possibly files related to the documentation (like .nitignore). If a PR adds a new feature and edits the docs to document it, it's not "docs-only" and shouldn't get the docs label.
(Maybe this should be spelled out clearly in a comment/docstring, including the expected behavior for other labels, since the intention is currently not too clear IMHO).