feat: refactor pg commands to leverage sdk - #3728
Merged
michaelmalave merged 8 commits intoMay 28, 2026
Merged
michaelmalave merged 8 commits into
michaelmalave merged 8 commits into
Conversation
… database APIs (instead of legacy typed this.heroku calls), removing obsolete PG upgrade types and updating unit tests to match the new request/response behavior
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 17:00 — with
GitHub Actions
Error
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 17:00 — with
GitHub Actions
Failure
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 17:00 — with
GitHub Actions
Error
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 17:00 — with
GitHub Actions
Failure
… client once and pass it through helper methods instead of re-creating it in each call
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 19:00 — with
GitHub Actions
Error
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 19:00 — with
GitHub Actions
Failure
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 19:00 — with
GitHub Actions
Failure
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 19:00 — with
GitHub Actions
Error
tlowrimore-heroku
approved these changes
May 27, 2026
tlowrimore-heroku
left a comment
Contributor
There was a problem hiding this comment.
LGTM!
Comments:
- I see you're having to do a lot of double assertions (i.e.
x as unknown as Y), in this PR. I think You, Eric, and I should discuss how best to avoid this. I think the crux of the issue is that SDK returns types defined by@heroku/types, but we're still opting to use the types defined in the CLI. - I also see several updates to
nock. There was a discussion a couple of weeks ago--I think you may have been OOO--where there was a strong consensus to mock the SDK, rather than mocking the HTTP request/responses. We should probably revisit this conversation to see if everyone still feels this is the best approach.
… commands to use them, reducing duplicated SDK request/error handling logic across command implementations
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 20:55 — with
GitHub Actions
Error
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 20:55 — with
GitHub Actions
Failure
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 20:55 — with
GitHub Actions
Error
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 20:55 — with
GitHub Actions
Failure
… ordering, and set a default test HEROKU_API_KEY so SDK token initialization does not fail during mocked test runs
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 21:29 — with
GitHub Actions
Failure
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 21:29 — with
GitHub Actions
Error
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 21:29 — with
GitHub Actions
Error
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 21:29 — with
GitHub Actions
Failure
…d SDK mocking helper and align expectations with SDK-based response shapes and call patterns.
…ry entries, and update .gitignore to reflect cleanup of these now-obsolete migration tooling files.
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 22:19 — with
GitHub Actions
Failure
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 22:19 — with
GitHub Actions
Error
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 22:19 — with
GitHub Actions
Error
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 22:19 — with
GitHub Actions
Failure
…dictionary entries, and update .gitignore to reflect cleanup of these now-obsolete migration tooling files." This reverts commit a93d08e.
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 22:26 — with
GitHub Actions
Error
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 22:26 — with
GitHub Actions
Failure
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 22:26 — with
GitHub Actions
Failure
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 22:26 — with
GitHub Actions
Error
…g shared runUpgrade/prepareUpgrade/dryRunUpgrade helpers and refactor the corresponding upgrade commands to use them instead of repeating inline SDK method casting
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 22:54 — with
GitHub Actions
Failure
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 22:54 — with
GitHub Actions
Error
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 22:54 — with
GitHub Actions
Error
michaelmalave
had a problem deploying
to
AcceptanceTests
May 27, 2026 22:54 — with
GitHub Actions
Failure
tlowrimore-heroku
approved these changes
May 27, 2026
tlowrimore-heroku
left a comment
Contributor
There was a problem hiding this comment.
Nice! I like the sdk-adapter approach!
michaelmalave
merged commit May 28, 2026
a2dad85
into
feat/heroku-sdk-integration
4 of 17 checks passed
This branch had an error being deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This branch migrates core CLI command surfaces to
@heroku/sdkand adds tooling to accelerate further command migrations, with broad updates across addons, pipelines, maintenance, Postgres, logs, and supporting libraries. Scope includes command implementations, shared helpers, and corresponding unit test updates to align with SDK request/response behavior.@heroku/sdkinto the CLI and command runtime pathsType of Change
Verification
npm ci npm run lint npm testAdditional Context
Related Issue
W-22265695