Skip to content

Commit b085314

Browse files
refactor: reorder initialize since breaks in C9 (#4413)
The order of the intialize methods caused issues in C9 due to the order of execution. <!--- REMINDER: - Read CONTRIBUTING.md first. - Add test coverage for your changes. - Update the changelog using `npm run newChange`. - Link to related issues/commits. - Testing: how did you test your changes? - Screenshots --> ## License By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. Signed-off-by: nkomonen <[email protected]>
1 parent 3255576 commit b085314

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

packages/toolkit/src/extensionShared.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,10 @@ export async function activateShared(
5858
): Promise<ExtContext> {
5959
localize = nls.loadMessageBundle()
6060

61+
// some "initialize" functions
62+
await initializeComputeRegion()
63+
initialize(context)
64+
6165
registerCommandErrorHandler((info, error) => {
6266
const defaultMessage = localize('AWS.generic.message.error', 'Failed to run command: {0}', info.id)
6367
void logAndShowError(error, info.id, defaultMessage)
@@ -95,10 +99,6 @@ export async function activateShared(
9599
globals.sdkClientBuilder = new DefaultAWSClientBuilder(globals.awsContext)
96100
globals.loginManager = new LoginManager(globals.awsContext, new CredentialsStore())
97101

98-
// some "initialize" functions
99-
await initializeComputeRegion()
100-
initialize(context)
101-
102102
// order matters here
103103
globals.manifestPaths.endpoints = context.asAbsolutePath(join('resources', 'endpoints.json'))
104104
globals.manifestPaths.lambdaSampleRequests = context.asAbsolutePath(

0 commit comments

Comments
 (0)