Skip to content

Commit

Permalink
clean up code
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanthemanuel committed Feb 7, 2025
1 parent f79cb17 commit 95acc70
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions packages/server/lib/cloud/studio.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ export class StudioManager implements StudioManagerShape {
},
})
} catch (e) {
debug(`Error calling ProtocolManager.sendErrors: %o, original error %o`, e, error)
debug(`Error calling StudioManager.reportError: %o, original error %o`, e, error)
}
}

Expand All @@ -92,8 +92,7 @@ export class StudioManager implements StudioManagerShape {
}

try {
// @ts-expect-error - TS not associating the method & args properly, even though we know it's correct
return this._appStudio[method].apply(this._protocol, args)
return this._appStudio[method].apply(this._appStudio, args)
} catch (error) {
this.status = 'IN_ERROR'
// Call and forget this, we don't want to block the main thread
Expand All @@ -102,7 +101,7 @@ export class StudioManager implements StudioManagerShape {
}

/**
* Abstracts invoking a synchronous method on the AppCaptureProtocol instance, so we can handle
* Abstracts invoking a synchronous method on the AppStudio instance, so we can handle
* errors in a uniform way
*/
private async invokeAsync <K extends AppStudioAsyncMethods> (method: K, { isEssential }: { isEssential: boolean }, ...args: Parameters<AppStudioShape[K]>): Promise<ReturnType<AppStudioShape[K]> | undefined> {
Expand All @@ -112,7 +111,7 @@ export class StudioManager implements StudioManagerShape {

try {
// @ts-expect-error - TS not associating the method & args properly, even though we know it's correct
return await this._appStudio[method].apply(this._protocol, args)
return await this._appStudio[method].apply(this._appStudio, args)
} catch (error) {
this.status = 'IN_ERROR'
// Call and forget this, we don't want to block the main thread
Expand Down

4 comments on commit 95acc70

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 95acc70 Feb 7, 2025

Choose a reason for hiding this comment

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

Circle has built the linux x64 version of the Test Runner.

Learn more about this pre-release build at https://on.cypress.io/advanced-installation#Install-pre-release-version

Run this command to install the pre-release locally:

npm install https://cdn.cypress.io/beta/npm/14.0.3/linux-x64/ryanm/chore/add_internal_studio-95acc70b58ee3c0a4c133aded50c5ff965b8a0d0/cypress.tgz

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 95acc70 Feb 7, 2025

Choose a reason for hiding this comment

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

Circle has built the linux arm64 version of the Test Runner.

Learn more about this pre-release build at https://on.cypress.io/advanced-installation#Install-pre-release-version

Run this command to install the pre-release locally:

npm install https://cdn.cypress.io/beta/npm/14.0.3/linux-arm64/ryanm/chore/add_internal_studio-95acc70b58ee3c0a4c133aded50c5ff965b8a0d0/cypress.tgz

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 95acc70 Feb 7, 2025

Choose a reason for hiding this comment

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

Circle has built the darwin arm64 version of the Test Runner.

Learn more about this pre-release build at https://on.cypress.io/advanced-installation#Install-pre-release-version

Run this command to install the pre-release locally:

npm install https://cdn.cypress.io/beta/npm/14.0.3/darwin-arm64/ryanm/chore/add_internal_studio-95acc70b58ee3c0a4c133aded50c5ff965b8a0d0/cypress.tgz

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 95acc70 Feb 7, 2025

Choose a reason for hiding this comment

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

Circle has built the win32 x64 version of the Test Runner.

Learn more about this pre-release build at https://on.cypress.io/advanced-installation#Install-pre-release-version

Run this command to install the pre-release locally:

npm install https://cdn.cypress.io/beta/npm/14.0.3/win32-x64/ryanm/chore/add_internal_studio-95acc70b58ee3c0a4c133aded50c5ff965b8a0d0/cypress.tgz

Please sign in to comment.