-
Notifications
You must be signed in to change notification settings - Fork 335
feat: implement ruleset bypass actor #2199
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
base: main
Are you sure you want to change the base?
feat: implement ruleset bypass actor #2199
Conversation
Dry-run check results |
aa4aaa5 to
29a954f
Compare
29a954f to
023b6b5
Compare
| source_type: RulesetSourceType::Repository, | ||
| enforcement: RulesetEnforcement::Active, | ||
| bypass_actors: None, | ||
| bypass_actors: None, // Will be populated when applying the diff |
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.
We can discuss if this needs to be changed. I can think of making ID resolution methods available on the read client.
I'm okay with this comment because the current implementation is read-only
| } | ||
|
|
||
| /// Custom deserializer for actor_id that distinguishes between null and missing | ||
| fn deserialize_actor_id<'de, D>(deserializer: D) -> Result<Option<ActorId>, D::Error> |
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.
I'm not sure if this can be written better. I would love to learn. This is generated code but it works. Here is the video reference.
https://github.com/user-attachments/assets/e5ee56f5-4d83-4312-8cb5-a42c42fd82d4
https://github.com/user-attachments/assets/b16f1d52-746b-4afa-9217-7b2a49720f90
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.
Maybe we can simplify things by only implementing what we need.
For example, we only need to allow github apps and github teams for now I think.
For the crates-io repo we only need github apps for sure.
We don't use deploy keys anywhere if I remember correctly. So we don't need to implement them.
I think we should have a pragmatic approach where we implement stuff only when we find we use it in some repos 👍
Maybe I should have catch this earlier so that you saved time implementing this. If that's the case, sorry! D:
Closes: #2192