- Notifications
You must be signed in to change notification settings - Fork899
Add missing enum constraints#278
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
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.
Pull Request Overview
This PR adds missing enum constraints for various string properties to ensure only the allowed values are accepted.
- Enforced enum constraints for pull request state, sort options, merge methods, and review event types in pkg/github/pullrequests.go.
- Added enum constraints for code scanning alert states and severity levels in pkg/github/code_scanning.go.
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
File | Description |
---|---|
pkg/github/pullrequests.go | Added enum constraints for pull request query and review parameters. |
pkg/github/code_scanning.go | Added enum constraints for code scanning alerts parameters. |
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
2928235
toa92e445
Comparef810b65
to5a7d13c
CompareUh oh!
There was an error while loading.Please reload this page.
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.
Added one minor suggestion (the word category doesn't add much I think) but it's a nit, and this looks great. Thanks for all your work on finding all these!
4457d0a
intomainUh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
This pr adds some missing enum constraints for string props with enum like categories.
It also removes those listed enums from the descriptions, as the llm already receives the list of possible candidates by the the enum constraint.
This will save tokens as noted by@SamMorrowDrums
In regard to#228
Example testing with Copilot(Model Claude 3.7 Sonnet):