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

feat: add support for refreshing sandboxes #1031

Merged
merged 2 commits into from
Feb 27, 2024
Merged

feat: add support for refreshing sandboxes #1031

merged 2 commits into from
Feb 27, 2024

Conversation

shetzel
Copy link
Contributor

@shetzel shetzel commented Feb 22, 2024

What does this PR do?

  • Allows refreshing sandboxes.
  • Handles updating auth files of refreshed sandboxes.
  • Fixes a bug where authenticating after successful sandbox status polling did not update the auth file to be a sandbox, and would therefore not be properly identified as a sandbox by org list.

What issues does this PR fix or reference?

@W-15042183@

NOTE: plugin-org tests will fail due to changes in the SandboxRequestCacheEntry type. Added action.

this.logger.debug(refreshResult, 'Return from calling tooling.update');

if (!refreshResult.success) {
throw messages.createError('sandboxInfoRefreshFailed', [JSON.stringify(refreshResult)]);
Copy link
Contributor

Choose a reason for hiding this comment

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

is refreshResult guaranteed to be JSON? Just wondering if we get something unexpected back from the server (like HTML) then it would be an ugly message for the user.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good question. As long as this uses the jsforce version that catches unexpected HTML responses to SOAP requests it should throw a much better error.

@shetzel shetzel merged commit ffe344a into main Feb 27, 2024
67 of 69 checks passed
@shetzel shetzel deleted the sh/refresh-sandbox branch February 27, 2024 20:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants