monthly-check: improve username validation workflow#19151
monthly-check: improve username validation workflow#19151waldyrious wants to merge 5 commits intomainfrom
Conversation
c17ad30 to
9f056fc
Compare
| id: last-issue # Step ID to reference later | ||
| with: | ||
| state: open | ||
| state: all |
There was a problem hiding this comment.
There's no need to only update an existing issue if it is open; so I changed this to search for closed ones too, and modified the last step in the workflow to reopen the closed issue if needed.
.github/workflows/monthly-check.yml
Outdated
| --no-progress | ||
| --max-concurrency 25 | ||
| usernames.txt | ||
| --output lychee_report.txt |
There was a problem hiding this comment.
I explicitly defined the output filename here, rather than let the action use the default one, since it's referenced further down in the workflow, and this way it is a bit clearer where it comes from.
Refactor the monthly username validation workflow for improved clarity and maintainability. Also update lychee.md to the link to the CLI documentation page in the docs site.
9f056fc to
330d7c2
Compare
|
(I wanted to also rename the file from |
|
Btw, the current workflow doesn't seem to be working correctly: the last run did fail to load some of the userpages (though for reasons other than them actually being invalid), but skipped the issue update steps, for reasons that are not clear to me. Screenshot of the job log/output for future reference, since they will eventually be deleted:
|
sbrl
left a comment
There was a problem hiding this comment.
Looks cool, and definitely improves maintainability here! Just thought I'd drop some comments while I'm thinking about it haha
Could you test if this PR fixed the issue? |
| - name: Extract GitHub usernames for validation | ||
| run: | | ||
| { | ||
| grep -oP '@[\w-]+' .github/CODEOWNERS |
There was a problem hiding this comment.
| grep -oP '@[\w-]+' .github/CODEOWNERS | |
| grep -oP '@[\w-]+' .github/CODEOWNERS |
There was a problem hiding this comment.
I did it that way to make it more obvious that both patterns are looking for the same thing, with the only difference being the ** prefix in the second one. Do you think it makes it more confusing than helpful?
There was a problem hiding this comment.
I actually meant to remove the extra whitespace between the command and the regex. Besides that, I am not a big fan of using grep -P since -P isn't usable on MacOS.
Sure. How can I do that test? Maybe temporarily changing the triggering conditions of the workflow so it executes in this PR? |
We do have |
|
Thanks! That seems to have done the trick: https://github.com/tldr-pages/tldr/actions/runs/19003751429/job/54274077842 I think I might change the action to add a comment to the issue instead of modifying the existing opening comment, to make the historical progression easier to follow. |
sbrl
left a comment
There was a problem hiding this comment.
Cool!
(take my time suggestion or leave it, it's p minor)
I see we still have the issue about running into a 403 for 10 valid users. Are you able to fix that as well? |
|
conflicts seem to have arisen with the main branch also, /cc @waldyrious? |
|
(I haven't abandoned this, but it will take me a few more days to have the time to implement the changes I mentioned above.) |
Shall we mark it as draft until you have time? |
|
Thanks for changing this to a draft, @sebastiaanspeck. Indeed I ended up becoming busier than I expected in the past couple weeks. I'll get back to this as soon as I can spare the bandwidth to pick up the work. |
|
@waldyrious any update on this? |
|
Not yet, I'm afraid. I've got a lot going on and will likely have to attend to other topics before returning to this one. |
Cherry-picked some changes from #19151


Refactor the monthly username validation workflow for improved clarity and maintainability.
Also update lychee.md to the link to the CLI documentation page in the docs site.