Zulip Chat Archive
Stream: mathlib4
Topic: Cleaning up old GitHub actions logs
Bryan Gin-ge Chen (Jun 19 2025 at 17:36):
I often use the actions tab of the mathlib4 repo and have found it cumbersome to scroll through a bunch of outdated / no-longer-used workflows in the sidebar to get to what I want. One way to remove a workflow from the sidebar is to delete all the workflow runs corresponding to that workflow using e.g. scripts from this GitHub community discussion. (Are there other ways?)
Would anyone be opposed if I deleted a bunch of these runs to make the actions tab easier to navigate? Note that detailed logs expire after 90 days anyways, so I don't think there's much valuable information left in old runs.
Damiano Testa (Jun 19 2025 at 18:11):
Besides debugging, I think that the only part of the CI logs that may have some "historical" relevance is the one recording the size of the oleans. The idea of that step was to use it as a measure for detecting potential slow-downs due to inefficient code. However, I think that no one ended up looking at that CI step and the automation that was supposed to use it, did not get developed (i.e., I did not do it!).
Damiano Testa (Jun 19 2025 at 18:11):
So, overall, I am in favour of cleansing the logs, maybe we can start by removing the log that are 60 days old, to see how the scripts work?
Bryan Gin-ge Chen (Jun 20 2025 at 00:48):
Looks like the following may do the trick:
gh run list --workflow='<name of workflow>' --created='<2025-04-19' --json databaseId | jq '.[].databaseId' | xargs -I{} gh run delete {}
We can get a list of workflow names with gh workflow list -a --json name.
Damiano Testa (Jun 20 2025 at 08:53):
I just ran your last command. Should we start clearing move-decls (label) (that, btw, was last used a year ago, so well before the 90 days period).
Bryan Gin-ge Chen (Oct 28 2025 at 17:04):
Since I happened to be reminded of this today, I will start cleaning up logs for inactive workflows that were only used for testing to make our list of workflows easier to navigate.
Damiano Testa (Oct 28 2025 at 17:06):
Thank you very much! I had forgotten about this discussion!
Damiano Testa (Oct 28 2025 at 17:07):
I am in favour of a robust clean up: if we end up removing a few too many workflow runs, I would not be too fussed.
Last updated: Dec 20 2025 at 21:32 UTC