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

[BREAKING CHANGES]: int to long Ids for PreReceiveHook, Deployment Environments, Repository, Org Team, Repo Invitations, Public Key, Project Cards, Organization Invitation, Migrations, GpgKey, Deployment, Authorizations, Accounts / Profiles, Codespace / Workspaces #2941

Merged
merged 6 commits into from
Jun 26, 2024

Conversation

nickfloyd
Copy link
Contributor

Relates to #2893

We have uncovered a series of issues around the IDs used across our API surface (Issues, Pull Requests, deployments, etc.. are all effected).

The GitHub database schemas were changed to accommodate for the growing IDs - migrating many of them from int to bigint - this SDK was lagging behind in those changes so when API calls began to return data that was too large for the types defined in our SDKs - their apps, integration, and automation began to break.


Before the change?

  • Overflow issues would happen when calling an API that returned a long (e.g. a release ID) but the class had this defined as an int - this would cause the SDK to throw an overflow exception.

After the change?

  • We have updated the int types to be long across the SDKs - this will allow for the larger IDs to be returned without causing an overflow exception.

Pull request checklist

  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been reviewed and added / updated if needed (for bug fixes / features)

Does this introduce a breaking change?

Please see our docs on breaking changes to help!

  • Yes
  • No

@nickfloyd nickfloyd added Type: Breaking change Used to note any change that requires a major version bump Type: Bug Something isn't working as documented labels Jun 24, 2024
Copy link
Member

@kfcampbell kfcampbell left a comment

Choose a reason for hiding this comment

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

Awesome job! This is super helpful for our users.

@nickfloyd nickfloyd marked this pull request as draft June 25, 2024 14:55
@nickfloyd nickfloyd changed the title [FIX]: int to long Ids for Releases, Collaborators, and Contributors [FIX]: int to long Ids for PreReceiveHook, Deployment Environments, Repository, Org Team, Repo Invitations, Public Key, Project Cards, Organization Invitation, Migrations, GpgKey, Deployment, Authorizations, Accounts / Profiles, Codespace / Workspaces Jun 25, 2024
@nickfloyd nickfloyd changed the title [FIX]: int to long Ids for PreReceiveHook, Deployment Environments, Repository, Org Team, Repo Invitations, Public Key, Project Cards, Organization Invitation, Migrations, GpgKey, Deployment, Authorizations, Accounts / Profiles, Codespace / Workspaces [BREAKING CHANGES]: int to long Ids for PreReceiveHook, Deployment Environments, Repository, Org Team, Repo Invitations, Public Key, Project Cards, Organization Invitation, Migrations, GpgKey, Deployment, Authorizations, Accounts / Profiles, Codespace / Workspaces Jun 25, 2024
@nickfloyd nickfloyd marked this pull request as ready for review June 25, 2024 19:47
@nickfloyd nickfloyd merged commit 6565a07 into main Jun 26, 2024
5 checks passed
@nickfloyd nickfloyd deleted the fix-int-to-long branch June 26, 2024 15:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Breaking change Used to note any change that requires a major version bump Type: Bug Something isn't working as documented
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants