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
.github: Add label generation tool and update labels #1389
base: staging
Are you sure you want to change the base?
Conversation
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.
Hey @arvganesh
This initial version looks really good, left you some comments.
Can you squash you commits and leave only two:
.github/scripts: Add label generation tool
.github/labels: Update labels to track latest staging
You will also need to add commit message bodies for each to describe the changes. (in order for the checkpatch
check to pass)
In a separate PR, if you want, we can also add a workflow that runs on pushes (or weekly) and checks if labels changed and updates them automatically. |
b886451
to
e49aceb
Compare
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.
Hi @arvganesh! Thanks for this contribution. We use an external tool called governctl
to do the heavy lifting in terms of interacting with GitHub's API, performing operations specifically on the Unikraft core repository as well as organization-wide repositories and teams.
In order to prevent too many tools, scripts or programs dotted all over the place, I suggest looking at how label synchronization can be accomplished with this tool under a new subcommand governctl labels sync
.
One thing to note is that these label config files are in fact meant to work in the opposite direction: their static declaration should dictate GitHub's state of labels (aka "Infrastructure as Code"). This means that labels should be updated from the repo and not the other way around.
I think this particular issue can be kept nearly as-is sans the introduction of the python script, changes to descriptions and changing the hex color values.
For direct changes to the labels, please:
- Ensure all color attributes are quoted, lowercase and include a pound (
#
) symbol i.e.:"#1d76db"
is better vs.1D76DB
. This prevents the diff from needless changes; - Only change the description if it is a better representation of what the label is intended;
- Remove
libx/posix-unisocket
;
Thanks!
Using the code generation tool in .github/scripts, update labels in .github/labels to match the latest staging. Signed-off-by: Arvind Ganesh <arvind.cganesh@gmail.com>
Hi @nderjung. Thanks for getting back to me! Had a few follow-up questions: Re: Re: The changes in this PR, there were many label files that were "created" (i.e labels were on GitHub but not in |
Yes.
The new libraries we can keep. There are also changes which need to be reverted:
Thanks! |
Prerequisite checklist
checkpatch.uk
on your commit series before opening this PR;Base target
Additional configuration
Added
update_labels.py
, a tool to automatically update the files in.github/labels
with configuration of latest labels from Github.It only has one external dependency, ruamel-yaml, which is a more powerful derivative of PyYAML for interacting with YAML files.
Description of changes
Update labels in
.github/labels
to match the current state of the repo.To aid with this process in the future, I also wrote a tool (
update_labels.py
) to automate the majority of this process. It queries this endpoint in the GithubAPI, grabs the relevant data, and updates the YAML files in.github/labels
.GitHub-Fixes: #1283