-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
feat: Support Copilot metrics endpoints #3350
Conversation
Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). View this failed invocation of the CLA check for more information. For the most up to date status, view the checks section at the bottom of the pull request. |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #3350 +/- ##
==========================================
- Coverage 97.72% 92.33% -5.39%
==========================================
Files 153 176 +23
Lines 13390 15095 +1705
==========================================
+ Hits 13085 13938 +853
- Misses 215 1064 +849
- Partials 90 93 +3 ☔ View full report in Codecov by Sentry. 🚨 Try these New Features:
|
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.
Thank you, @henriklundstrom !
First, there are a few acronyms that need to be fixed for idiomatic Go naming conventions.
Then, before continuing my review, it seems like there is a lot of duplication in the new set of structs... are there structs (potential candidates are the ones utilizing omitempty
) that could possibly be shared, or is there enough distinction to warrant the current number of structs?
I'm fine if the answer is the latter - I just wanted your opinion to see if you think we could take advantage of simplifying the interface by a bit of sharing (like we do with other structs). But again, if not, no big deal... then no changes necessary.
Co-authored-by: Glenn Lewis <[email protected]>
@gmlewis I've gone through your renaming suggestions and applied them all. I agree there are many structs being introduced and that they're somewhat repetitive, but still not actually modular, and it's not a good read... Unfortunately this is how GitHub has structured the response schema. In this case I don't see that using struct embedding or reusable structs will make it any better. Possibly, I could introduce some:
That would cut down the size of the |
Thank you for double-checking... I appreciate it. Let's run with what you've got. |
@henriklundstrom - to proceed with this PR, it looks like you need to do the following steps:
This should pull #3352 into your PR which has the latest OpenAPI changes needed to support |
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.
Thank you, @henriklundstrom !
LGTM.
Awaiting second LGTM+Approval from any other contributor to this repo before merging.
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.
LGTM :)
@gmlewis I've updated the branch and we have a second approval now 🚀 |
Thank you, @claystation ! |
Introduces structs and functions for calling the newly GA endpoints for Copilot metrics. See this post from GitHub https://github.blog/changelog/2024-10-30-github-copilot-metrics-api-ga-release-now-available/.