From 315b5b23f86f6007613536277e9e514ae724518e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rados=C5=82aw=20Krzemie=C5=84?= Date: Wed, 31 Jan 2024 17:21:05 +0100 Subject: [PATCH] [eas-cli] [ENG-9957] Don't overwrite distribution for simulator builds (#2073) * [eas-cli] Update dependencies Updated eas-build-job to new version See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Don't overwrite distribution Stops overwriting distribution type for simulator builds, and sets simulator field in metadata instead See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Merge main Merged changes from main branch See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Check for simulator flag Updated build:run command to use simulator flag instead of overwritten distribution type See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Update schema Update graphql schema with simulator fields See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Add flag Add simulator flag to build:list command See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Fix check Fixed check function with correct field name See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Fix tests Fixed failing tests after BuildFragment structure changed See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Add warning Added warning to build:list command that the distribution=simulator is deprecated See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Add description Added description to the new simulator flag See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Add validation Added validation so the simulator flag can only be used with --platofrm=ios See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Change message Updated the warning displayed when using deprecated --distribution=simulator flag value See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Replace string Replaced hardcoded string with variable See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Remove redundant check Removed no longer necessary check for simulator build See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Update schema Updated graphql schema after recent changes See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * [eas-cli] Update schema Updated graphql schema after recent changes See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds * update CHANGELOG.md * [eas-cli] Update schema Updated graphql schema after recent changes See: https://linear.app/expo/issue/ENG-9957/fix-internal-distribution-pages-for-simulator-builds --- CHANGELOG.md | 2 + packages/eas-cli/graphql.schema.json | 206 ++++++++++++++++++ .../src/build/__tests__/cancel-test.ts | 1 + .../src/build/__tests__/delete-test.ts | 1 + packages/eas-cli/src/build/metadata.ts | 7 +- packages/eas-cli/src/build/types.ts | 1 + packages/eas-cli/src/commands/build/list.ts | 17 ++ packages/eas-cli/src/commands/build/run.ts | 9 +- packages/eas-cli/src/graphql/generated.ts | 45 +++- packages/eas-cli/src/graphql/types/Build.ts | 1 + packages/eas-cli/src/run/utils.ts | 4 +- 11 files changed, 274 insertions(+), 20 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 157e248185..eabe389260 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,8 @@ This is the log of notable changes to EAS CLI and related packages. ### 🧹 Chores +- Add simulator flag to metadata. ([#2073](https://github.com/expo/eas-cli/pull/2073) by [@radoslawkrzemien](https://github.com/radoslawkrzemien)) + ## [7.1.2](https://github.com/expo/eas-cli/releases/tag/v7.1.2) - 2024-01-30 ### 🧹 Chores diff --git a/packages/eas-cli/graphql.schema.json b/packages/eas-cli/graphql.schema.json index 3e04fcb88f..11b0315ff4 100644 --- a/packages/eas-cli/graphql.schema.json +++ b/packages/eas-cli/graphql.schema.json @@ -4726,6 +4726,18 @@ "isDeprecated": false, "deprecationReason": null }, + { + "name": "googleServiceAccountKeyForFcmV1", + "description": null, + "args": [], + "type": { + "kind": "OBJECT", + "name": "GoogleServiceAccountKey", + "ofType": null + }, + "isDeprecated": false, + "deprecationReason": null + }, { "name": "googleServiceAccountKeyForSubmissions", "description": null, @@ -4829,6 +4841,18 @@ "isDeprecated": false, "deprecationReason": null }, + { + "name": "googleServiceAccountKeyForFcmV1Id", + "description": null, + "type": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + }, + "defaultValue": null, + "isDeprecated": false, + "deprecationReason": null + }, { "name": "googleServiceAccountKeyForSubmissionsId", "description": null, @@ -4916,6 +4940,71 @@ "isDeprecated": false, "deprecationReason": null }, + { + "name": "createFcmV1Credential", + "description": "Create a GoogleServiceAccountKeyEntity to store credential and\nconnect it with an edge from AndroidAppCredential", + "args": [ + { + "name": "accountId", + "description": null, + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + "defaultValue": null, + "isDeprecated": false, + "deprecationReason": null + }, + { + "name": "androidAppCredentialsId", + "description": null, + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + "defaultValue": null, + "isDeprecated": false, + "deprecationReason": null + }, + { + "name": "credential", + "description": null, + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "String", + "ofType": null + } + }, + "defaultValue": null, + "isDeprecated": false, + "deprecationReason": null + } + ], + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "OBJECT", + "name": "AndroidAppCredentials", + "ofType": null + } + }, + "isDeprecated": false, + "deprecationReason": null + }, { "name": "deleteAndroidAppCredentials", "description": "Delete a set of credentials for an Android app", @@ -4998,6 +5087,55 @@ "isDeprecated": false, "deprecationReason": null }, + { + "name": "setGoogleServiceAccountKeyForFcmV1", + "description": "Set the Google Service Account Key to be used for Firebase Cloud Messaging V1", + "args": [ + { + "name": "googleServiceAccountKeyId", + "description": null, + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + "defaultValue": null, + "isDeprecated": false, + "deprecationReason": null + }, + { + "name": "id", + "description": null, + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "ID", + "ofType": null + } + }, + "defaultValue": null, + "isDeprecated": false, + "deprecationReason": null + } + ], + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "OBJECT", + "name": "AndroidAppCredentials", + "ofType": null + } + }, + "isDeprecated": false, + "deprecationReason": null + }, { "name": "setGoogleServiceAccountKeyForSubmissions", "description": "Set the Google Service Account Key to be used for submitting an Android app", @@ -14573,6 +14711,22 @@ "isDeprecated": false, "deprecationReason": null }, + { + "name": "isForIosSimulator", + "description": null, + "args": [], + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + "isDeprecated": false, + "deprecationReason": null + }, { "name": "isGitWorkingTreeDirty", "description": null, @@ -15872,6 +16026,18 @@ "isDeprecated": false, "deprecationReason": null }, + { + "name": "simulator", + "description": null, + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + }, + "defaultValue": null, + "isDeprecated": false, + "deprecationReason": null + }, { "name": "status", "description": null, @@ -15970,6 +16136,18 @@ "defaultValue": null, "isDeprecated": false, "deprecationReason": null + }, + { + "name": "simulator", + "description": null, + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + }, + "defaultValue": null, + "isDeprecated": false, + "deprecationReason": null } ], "interfaces": null, @@ -16894,6 +17072,18 @@ "isDeprecated": false, "deprecationReason": null }, + { + "name": "simulator", + "description": null, + "type": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + }, + "defaultValue": null, + "isDeprecated": false, + "deprecationReason": null + }, { "name": "trackingContext", "description": null, @@ -17959,6 +18149,22 @@ "isDeprecated": false, "deprecationReason": null }, + { + "name": "isForIosSimulator", + "description": null, + "args": [], + "type": { + "kind": "NON_NULL", + "name": null, + "ofType": { + "kind": "SCALAR", + "name": "Boolean", + "ofType": null + } + }, + "isDeprecated": false, + "deprecationReason": null + }, { "name": "platform", "description": null, diff --git a/packages/eas-cli/src/build/__tests__/cancel-test.ts b/packages/eas-cli/src/build/__tests__/cancel-test.ts index b1cd81fe5f..476e35a44e 100644 --- a/packages/eas-cli/src/build/__tests__/cancel-test.ts +++ b/packages/eas-cli/src/build/__tests__/cancel-test.ts @@ -92,5 +92,6 @@ function createMockBuildFragment({ }, status: BuildStatus.InQueue, resourceClass: BuildResourceClass.AndroidMedium, + isForIosSimulator: false, }; } diff --git a/packages/eas-cli/src/build/__tests__/delete-test.ts b/packages/eas-cli/src/build/__tests__/delete-test.ts index e72fa699e2..9f23e02833 100644 --- a/packages/eas-cli/src/build/__tests__/delete-test.ts +++ b/packages/eas-cli/src/build/__tests__/delete-test.ts @@ -92,5 +92,6 @@ function createMockBuildFragment({ }, status: BuildStatus.InQueue, resourceClass: BuildResourceClass.AndroidMedium, + isForIosSimulator: false, }; } diff --git a/packages/eas-cli/src/build/metadata.ts b/packages/eas-cli/src/build/metadata.ts index 8670395557..4393ce2d1c 100644 --- a/packages/eas-cli/src/build/metadata.ts +++ b/packages/eas-cli/src/build/metadata.ts @@ -8,6 +8,7 @@ import { maybeResolveVersionsAsync as maybeResolveAndroidVersionsAsync } from '. import { BuildContext } from './context'; import { maybeResolveVersionsAsync as maybeResolveIosVersionsAsync } from './ios/version'; import { LocalBuildMode } from './local'; +import { BuildDistributionType } from './types'; import Log from '../log'; import { getUsername, @@ -28,10 +29,7 @@ export async function collectMetadataAsync( ctx: BuildContext ): Promise { const channelOrReleaseChannel = await resolveChannelOrReleaseChannelAsync(ctx); - const distribution = - ('simulator' in ctx.buildProfile && ctx.buildProfile.simulator - ? 'simulator' - : ctx.buildProfile.distribution) ?? 'store'; + const distribution = ctx.buildProfile.distribution ?? BuildDistributionType.STORE; const metadata: Metadata = { trackingContext: ctx.analyticsEventProperties, ...(await maybeResolveVersionsAsync(ctx)), @@ -70,6 +68,7 @@ export async function collectMetadataAsync( requiredPackageManager: ctx.requiredPackageManager ?? undefined, selectedImage: ctx.buildProfile.image, customNodeVersion: ctx.buildProfile.node, + simulator: 'simulator' in ctx.buildProfile && ctx.buildProfile.simulator, }; return sanitizeMetadata(metadata); } diff --git a/packages/eas-cli/src/build/types.ts b/packages/eas-cli/src/build/types.ts index 5f6852c9eb..4af6ccfe64 100644 --- a/packages/eas-cli/src/build/types.ts +++ b/packages/eas-cli/src/build/types.ts @@ -11,5 +11,6 @@ export enum BuildStatus { export enum BuildDistributionType { STORE = 'store', INTERNAL = 'internal', + /** @deprecated Use simulator flag instead */ SIMULATOR = 'simulator', } diff --git a/packages/eas-cli/src/commands/build/list.ts b/packages/eas-cli/src/commands/build/list.ts index 7b1c2a4e11..5a001a0be4 100644 --- a/packages/eas-cli/src/commands/build/list.ts +++ b/packages/eas-cli/src/commands/build/list.ts @@ -10,6 +10,7 @@ import { getPaginatedQueryOptions, } from '../../commandUtils/pagination'; import { AppPlatform, BuildStatus as GraphQLBuildStatus } from '../../graphql/generated'; +import Log from '../../log'; import { RequestedPlatform } from '../../platform'; import { getDisplayNameForProjectIdAsync } from '../../project/projectUtils'; import { buildDistributionTypeToGraphQLDistributionType } from '../../utils/buildDistribution'; @@ -51,6 +52,10 @@ export default class BuildList extends EasCommand { ...EasPaginatedQueryFlags, limit: getLimitFlagWithCustomValues({ defaultTo: 10, limit: BUILDS_LIMIT }), ...EasNonInteractiveAndJsonFlags, + simulator: Flags.boolean({ + description: + 'Filter only iOS simulator builds. Can only be used with --platform flag set to "ios"', + }), }; static override contextDefinition = { @@ -69,6 +74,17 @@ export default class BuildList extends EasCommand { distribution: buildDistribution, 'non-interactive': nonInteractive, } = flags; + if (buildDistribution === BuildDistributionType.SIMULATOR) { + Log.warn( + `Using --distribution flag with "simulator" value is deprecated - use --simulator flag instead` + ); + } + if (flags.simulator && requestedPlatform !== RequestedPlatform.Ios) { + Log.error( + `The --simulator flag is only usable with --platform flag set to "ios", as it is used to filter specifically iOS simulator builds` + ); + process.exit(1); + } const { privateProjectConfig: { projectId }, loggedIn: { graphqlClient }, @@ -100,6 +116,7 @@ export default class BuildList extends EasCommand { appIdentifier: flags.appIdentifier, buildProfile: flags.buildProfile, gitCommitHash: flags.gitCommitHash, + simulator: flags.simulator, }, paginatedQueryOptions, }); diff --git a/packages/eas-cli/src/commands/build/run.ts b/packages/eas-cli/src/commands/build/run.ts index f6b41931a8..a7ec1411b6 100644 --- a/packages/eas-cli/src/commands/build/run.ts +++ b/packages/eas-cli/src/commands/build/run.ts @@ -11,7 +11,7 @@ import { PaginatedQueryOptions, getPaginatedQueryOptions, } from '../../commandUtils/pagination'; -import { AppPlatform, BuildFragment, BuildStatus, DistributionType } from '../../graphql/generated'; +import { AppPlatform, BuildFragment, BuildStatus } from '../../graphql/generated'; import { BuildQuery } from '../../graphql/queries/BuildQuery'; import Log from '../../log'; import { appPlatformDisplayNames } from '../../platform'; @@ -200,8 +200,7 @@ async function maybeGetBuildAsync( projectId: string, paginatedQueryOptions: PaginatedQueryOptions ): Promise { - const distributionType = - flags.selectedPlatform === AppPlatform.Ios ? DistributionType.Simulator : undefined; + const simulator = flags.selectedPlatform === AppPlatform.Ios ? true : undefined; if (flags.runArchiveFlags.id) { const build = await BuildQuery.byIdAsync(graphqlClient, flags.runArchiveFlags.id); @@ -219,9 +218,9 @@ async function maybeGetBuildAsync( } build to run for ${await getDisplayNameForProjectIdAsync(graphqlClient, projectId)} app`, filter: { platform: flags.selectedPlatform, - distribution: distributionType, status: BuildStatus.Finished, buildProfile: flags.profile, + simulator, }, paginatedQueryOptions, selectPromptDisabledFunction: build => !isRunnableOnSimulatorOrEmulator(build), @@ -235,9 +234,9 @@ async function maybeGetBuildAsync( projectId, filter: { platform: flags.selectedPlatform, - distribution: distributionType, status: BuildStatus.Finished, buildProfile: flags.profile, + simulator, }, }); diff --git a/packages/eas-cli/src/graphql/generated.ts b/packages/eas-cli/src/graphql/generated.ts index e7e6e9a6e6..d7ad4e2b20 100644 --- a/packages/eas-cli/src/graphql/generated.ts +++ b/packages/eas-cli/src/graphql/generated.ts @@ -759,6 +759,7 @@ export type AndroidAppCredentials = { androidFcm?: Maybe; app: App; applicationIdentifier?: Maybe; + googleServiceAccountKeyForFcmV1?: Maybe; googleServiceAccountKeyForSubmissions?: Maybe; id: Scalars['ID']['output']; isLegacy: Scalars['Boolean']['output']; @@ -771,6 +772,7 @@ export type AndroidAppCredentialsFilter = { export type AndroidAppCredentialsInput = { fcmId?: InputMaybe; + googleServiceAccountKeyForFcmV1Id?: InputMaybe; googleServiceAccountKeyForSubmissionsId?: InputMaybe; }; @@ -778,10 +780,17 @@ export type AndroidAppCredentialsMutation = { __typename?: 'AndroidAppCredentialsMutation'; /** Create a set of credentials for an Android app */ createAndroidAppCredentials: AndroidAppCredentials; + /** + * Create a GoogleServiceAccountKeyEntity to store credential and + * connect it with an edge from AndroidAppCredential + */ + createFcmV1Credential: AndroidAppCredentials; /** Delete a set of credentials for an Android app */ deleteAndroidAppCredentials: DeleteAndroidAppCredentialsResult; /** Set the FCM push key to be used in an Android app */ setFcm: AndroidAppCredentials; + /** Set the Google Service Account Key to be used for Firebase Cloud Messaging V1 */ + setGoogleServiceAccountKeyForFcmV1: AndroidAppCredentials; /** Set the Google Service Account Key to be used for submitting an Android app */ setGoogleServiceAccountKeyForSubmissions: AndroidAppCredentials; }; @@ -794,6 +803,13 @@ export type AndroidAppCredentialsMutationCreateAndroidAppCredentialsArgs = { }; +export type AndroidAppCredentialsMutationCreateFcmV1CredentialArgs = { + accountId: Scalars['ID']['input']; + androidAppCredentialsId: Scalars['String']['input']; + credential: Scalars['String']['input']; +}; + + export type AndroidAppCredentialsMutationDeleteAndroidAppCredentialsArgs = { id: Scalars['ID']['input']; }; @@ -805,6 +821,12 @@ export type AndroidAppCredentialsMutationSetFcmArgs = { }; +export type AndroidAppCredentialsMutationSetGoogleServiceAccountKeyForFcmV1Args = { + googleServiceAccountKeyId: Scalars['ID']['input']; + id: Scalars['ID']['input']; +}; + + export type AndroidAppCredentialsMutationSetGoogleServiceAccountKeyForSubmissionsArgs = { googleServiceAccountKeyId: Scalars['ID']['input']; id: Scalars['ID']['input']; @@ -2117,6 +2139,7 @@ export type Build = ActivityTimelineProjectActivity & BuildOrBuildJob & { /** @deprecated User type is deprecated */ initiatingUser?: Maybe; iosEnterpriseProvisioning?: Maybe; + isForIosSimulator: Scalars['Boolean']['output']; isGitWorkingTreeDirty?: Maybe; isWaived: Scalars['Boolean']['output']; logFiles: Array; @@ -2282,6 +2305,7 @@ export type BuildFilter = { platform?: InputMaybe; runtimeVersion?: InputMaybe; sdkVersion?: InputMaybe; + simulator?: InputMaybe; status?: InputMaybe; }; @@ -2291,6 +2315,7 @@ export type BuildFilterInput = { distributions?: InputMaybe>; platforms?: InputMaybe>; releaseChannel?: InputMaybe; + simulator?: InputMaybe; }; export enum BuildIosEnterpriseProvisioning { @@ -2408,6 +2433,7 @@ export type BuildMetadataInput = { runtimeVersion?: InputMaybe; sdkVersion?: InputMaybe; selectedImage?: InputMaybe; + simulator?: InputMaybe; trackingContext?: InputMaybe; username?: InputMaybe; workflow?: InputMaybe; @@ -2588,6 +2614,7 @@ export type BuildPublicData = { artifacts: PublicArtifacts; distribution?: Maybe; id: Scalars['ID']['output']; + isForIosSimulator: Scalars['Boolean']['output']; platform: AppPlatform; project: ProjectPublicData; status: BuildStatus; @@ -6492,7 +6519,7 @@ export type CreateAndroidBuildMutationVariables = Exact<{ }>; -export type CreateAndroidBuildMutation = { __typename?: 'RootMutation', build: { __typename?: 'BuildMutation', createAndroidBuild: { __typename?: 'CreateBuildResult', build: { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } }, deprecationInfo?: { __typename?: 'EASBuildDeprecationInfo', type: EasBuildDeprecationInfoType, message: string } | null } } }; +export type CreateAndroidBuildMutation = { __typename?: 'RootMutation', build: { __typename?: 'BuildMutation', createAndroidBuild: { __typename?: 'CreateBuildResult', build: { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, isForIosSimulator: boolean, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } }, deprecationInfo?: { __typename?: 'EASBuildDeprecationInfo', type: EasBuildDeprecationInfoType, message: string } | null } } }; export type CreateIosBuildMutationVariables = Exact<{ appId: Scalars['ID']['input']; @@ -6502,7 +6529,7 @@ export type CreateIosBuildMutationVariables = Exact<{ }>; -export type CreateIosBuildMutation = { __typename?: 'RootMutation', build: { __typename?: 'BuildMutation', createIosBuild: { __typename?: 'CreateBuildResult', build: { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } }, deprecationInfo?: { __typename?: 'EASBuildDeprecationInfo', type: EasBuildDeprecationInfoType, message: string } | null } } }; +export type CreateIosBuildMutation = { __typename?: 'RootMutation', build: { __typename?: 'BuildMutation', createIosBuild: { __typename?: 'CreateBuildResult', build: { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, isForIosSimulator: boolean, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } }, deprecationInfo?: { __typename?: 'EASBuildDeprecationInfo', type: EasBuildDeprecationInfoType, message: string } | null } } }; export type UpdateBuildMetadataMutationVariables = Exact<{ buildId: Scalars['ID']['input']; @@ -6510,7 +6537,7 @@ export type UpdateBuildMetadataMutationVariables = Exact<{ }>; -export type UpdateBuildMetadataMutation = { __typename?: 'RootMutation', build: { __typename?: 'BuildMutation', updateBuildMetadata: { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } } } }; +export type UpdateBuildMetadataMutation = { __typename?: 'RootMutation', build: { __typename?: 'BuildMutation', updateBuildMetadata: { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, isForIosSimulator: boolean, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } } } }; export type RetryIosBuildMutationVariables = Exact<{ buildId: Scalars['ID']['input']; @@ -6518,7 +6545,7 @@ export type RetryIosBuildMutationVariables = Exact<{ }>; -export type RetryIosBuildMutation = { __typename?: 'RootMutation', build: { __typename?: 'BuildMutation', retryIosBuild: { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } } } }; +export type RetryIosBuildMutation = { __typename?: 'RootMutation', build: { __typename?: 'BuildMutation', retryIosBuild: { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, isForIosSimulator: boolean, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } } } }; export type CreateEnvironmentSecretForAccountMutationVariables = Exact<{ input: CreateEnvironmentSecretInput; @@ -6686,14 +6713,14 @@ export type BuildsByIdQueryVariables = Exact<{ }>; -export type BuildsByIdQuery = { __typename?: 'RootQuery', builds: { __typename?: 'BuildQuery', byId: { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } } } }; +export type BuildsByIdQuery = { __typename?: 'RootQuery', builds: { __typename?: 'BuildQuery', byId: { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, isForIosSimulator: boolean, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } } } }; export type BuildsWithSubmissionsByIdQueryVariables = Exact<{ buildId: Scalars['ID']['input']; }>; -export type BuildsWithSubmissionsByIdQuery = { __typename?: 'RootQuery', builds: { __typename?: 'BuildQuery', byId: { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, submissions: Array<{ __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null, rollout?: number | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null }>, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } } } }; +export type BuildsWithSubmissionsByIdQuery = { __typename?: 'RootQuery', builds: { __typename?: 'BuildQuery', byId: { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, isForIosSimulator: boolean, submissions: Array<{ __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null, rollout?: number | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null }>, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } } } }; export type ViewBuildsOnAppQueryVariables = Exact<{ appId: Scalars['String']['input']; @@ -6703,7 +6730,7 @@ export type ViewBuildsOnAppQueryVariables = Exact<{ }>; -export type ViewBuildsOnAppQuery = { __typename?: 'RootQuery', app: { __typename?: 'AppQuery', byId: { __typename?: 'App', id: string, builds: Array<{ __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } }> } } }; +export type ViewBuildsOnAppQuery = { __typename?: 'RootQuery', app: { __typename?: 'AppQuery', byId: { __typename?: 'App', id: string, builds: Array<{ __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, isForIosSimulator: boolean, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } }> } } }; export type ViewUpdateChannelOnAppQueryVariables = Exact<{ appId: Scalars['String']['input']; @@ -6845,9 +6872,9 @@ export type AccountFragment = { __typename?: 'Account', id: string, name: string export type AppFragment = { __typename?: 'App', id: string, fullName: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string, ownerUserActor?: { __typename?: 'SSOUser', id: string, username: string } | { __typename?: 'User', id: string, username: string } | null, users: Array<{ __typename?: 'UserPermission', role: Role, actor: { __typename?: 'Robot', id: string } | { __typename?: 'SSOUser', id: string } | { __typename?: 'User', id: string } }> } }; -export type BuildFragment = { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } }; +export type BuildFragment = { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, isForIosSimulator: boolean, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } }; -export type BuildWithSubmissionsFragment = { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, submissions: Array<{ __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null, rollout?: number | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null }>, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } }; +export type BuildWithSubmissionsFragment = { __typename?: 'Build', id: string, status: BuildStatus, platform: AppPlatform, channel?: string | null, releaseChannel?: string | null, distribution?: DistributionType | null, iosEnterpriseProvisioning?: BuildIosEnterpriseProvisioning | null, buildProfile?: string | null, sdkVersion?: string | null, appVersion?: string | null, appBuildVersion?: string | null, runtimeVersion?: string | null, gitCommitHash?: string | null, gitCommitMessage?: string | null, initialQueuePosition?: number | null, queuePosition?: number | null, estimatedWaitTimeLeftSeconds?: number | null, priority: BuildPriority, createdAt: any, updatedAt: any, message?: string | null, completedAt?: any | null, resourceClass: BuildResourceClass, expirationDate?: any | null, isForIosSimulator: boolean, submissions: Array<{ __typename?: 'Submission', id: string, status: SubmissionStatus, platform: AppPlatform, logsUrl?: string | null, app: { __typename?: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } }, androidConfig?: { __typename?: 'AndroidSubmissionConfig', applicationIdentifier?: string | null, track: SubmissionAndroidTrack, releaseStatus?: SubmissionAndroidReleaseStatus | null, rollout?: number | null } | null, iosConfig?: { __typename?: 'IosSubmissionConfig', ascAppIdentifier: string, appleIdUsername?: string | null } | null, error?: { __typename?: 'SubmissionError', errorCode?: string | null, message?: string | null } | null }>, error?: { __typename?: 'BuildError', errorCode: string, message: string, docsUrl?: string | null } | null, artifacts?: { __typename?: 'BuildArtifacts', buildUrl?: string | null, xcodeBuildLogsUrl?: string | null, applicationArchiveUrl?: string | null, buildArtifactsUrl?: string | null } | null, initiatingActor?: { __typename: 'Robot', id: string, displayName: string } | { __typename: 'SSOUser', id: string, displayName: string } | { __typename: 'User', id: string, displayName: string } | null, project: { __typename: 'App', id: string, name: string, slug: string, ownerAccount: { __typename?: 'Account', id: string, name: string } } | { __typename: 'Snack', id: string, name: string, slug: string } }; export type EnvironmentSecretFragment = { __typename?: 'EnvironmentSecret', id: string, name: string, type: EnvironmentSecretType, createdAt: any }; diff --git a/packages/eas-cli/src/graphql/types/Build.ts b/packages/eas-cli/src/graphql/types/Build.ts index 4f71747d7d..1ee60b010b 100644 --- a/packages/eas-cli/src/graphql/types/Build.ts +++ b/packages/eas-cli/src/graphql/types/Build.ts @@ -57,6 +57,7 @@ export const BuildFragmentNode = gql` completedAt resourceClass expirationDate + isForIosSimulator } `; diff --git a/packages/eas-cli/src/run/utils.ts b/packages/eas-cli/src/run/utils.ts index a3c5e9cc5d..c420dc16ca 100644 --- a/packages/eas-cli/src/run/utils.ts +++ b/packages/eas-cli/src/run/utils.ts @@ -1,4 +1,4 @@ -import { AppPlatform, BuildFragment, BuildStatus, DistributionType } from '../graphql/generated'; +import { AppPlatform, BuildFragment, BuildStatus } from '../graphql/generated'; function isAab(build: BuildFragment): boolean { return build.artifacts?.applicationArchiveUrl?.endsWith('.aab') ?? false; @@ -12,7 +12,7 @@ export function isRunnableOnSimulatorOrEmulator(build: BuildFragment): boolean { return ( build.status === BuildStatus.Finished && !!build.artifacts?.applicationArchiveUrl && - ((build.platform === AppPlatform.Ios && build.distribution === DistributionType.Simulator) || + ((build.platform === AppPlatform.Ios && build.isForIosSimulator) || (build.platform === AppPlatform.Android && !isAab(build))) && !didArtifactsExpire(build) );