Skip to content
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

Change total_minutes_used and included_minutes from int to float64 #2643

Merged
merged 3 commits into from Jan 25, 2023

Conversation

loispostula
Copy link
Contributor

Fixes #2642

GitHub Actions returns total_minutes_used and included_minutes as floating point value.
The Implementation should accept this floating point value as float64.

Example

curl -H "Authorization: Bearer <TOKEN>" \
-H "Accept: application/vnd.github.v3+json"  \
https://api.github.com/orgs/{org}/settings/billing/actions
{
  "total_minutes_used": 1234.0,
  "total_paid_minutes_used": 3959.0,
  "included_minutes": 3000.0,
  "minutes_used_breakdown": {
    "UBUNTU": 1234,
    "MACOS": 1234,
    "WINDOWS": 0
  }
}

@gmlewis gmlewis added the Breaking API Change PR will require a bump to the major version num in next release. Look here to see the change(s). label Jan 25, 2023
@gmlewis gmlewis changed the title [fix] Github now returns float for total_minutes_used and included_minutes Change total_minutes_used and included_minutes from int to float64 Jan 25, 2023
@codecov
Copy link

codecov bot commented Jan 25, 2023

Codecov Report

Merging #2643 (d7947b8) into master (2561c07) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master    #2643   +/-   ##
=======================================
  Coverage   98.05%   98.05%           
=======================================
  Files         130      130           
  Lines       11242    11242           
=======================================
  Hits        11023    11023           
  Misses        150      150           
  Partials       69       69           
Impacted Files Coverage Δ
github/billing.go 100.00% <ø> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Copy link
Collaborator

@gmlewis gmlewis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you, @loispostula !
LGTM.

Awaiting second LGTM+Approval from any other contributor to this repo.

@gmlewis gmlewis added the NeedsReview PR is awaiting a review before merging. label Jan 25, 2023
Copy link
Contributor

@valbeat valbeat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@gmlewis gmlewis removed the NeedsReview PR is awaiting a review before merging. label Jan 25, 2023
@gmlewis
Copy link
Collaborator

gmlewis commented Jan 25, 2023

Thank you, @valbeat !
Merging.

@gmlewis gmlewis merged commit 36c47d1 into google:master Jan 25, 2023
@loispostula
Copy link
Contributor Author

@gmlewis np, any info regarding the next release date?

@gmlewis
Copy link
Collaborator

gmlewis commented Jan 25, 2023

@gmlewis np, any info regarding the next release date?

The last release was 2 weeks ago, and we have a potentially broad-reaching breaking API change coming up shortly: #2645
and I would prefer to make as few major releases as possible, so if you can be patient for another week or two, we can come out with version 50.0.0 including these two breaking API changes.

Are you OK with that, @loispostula ?

@loispostula
Copy link
Contributor Author

I'll continue using my fork while waiting ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Breaking API Change PR will require a bump to the major version num in next release. Look here to see the change(s).
Projects
None yet
Development

Successfully merging this pull request may close these issues.

GitHub Actions Billing returns total_minutes_used and included_minutes as float64
3 participants