eas-cli 16.15.0 → 16.16.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/README.md +137 -84
  2. package/build/commandUtils/workflow/fetchLogs.d.ts +2 -0
  3. package/build/commandUtils/workflow/fetchLogs.js +16 -0
  4. package/build/commandUtils/workflow/stateMachine.d.ts +44 -0
  5. package/build/commandUtils/workflow/stateMachine.js +212 -0
  6. package/build/commandUtils/workflow/types.d.ts +39 -0
  7. package/build/commandUtils/workflow/types.js +13 -0
  8. package/build/commandUtils/workflow/utils.d.ts +12 -0
  9. package/build/commandUtils/workflow/utils.js +116 -0
  10. package/build/commands/workflow/cancel.js +3 -6
  11. package/build/commands/workflow/logs.d.ts +18 -0
  12. package/build/commands/workflow/logs.js +94 -0
  13. package/build/commands/workflow/run.d.ts +105 -0
  14. package/build/commands/workflow/run.js +280 -0
  15. package/build/commands/workflow/runs.js +4 -3
  16. package/build/commands/workflow/view.d.ts +17 -0
  17. package/build/commands/workflow/view.js +95 -0
  18. package/build/credentials/ios/appstore/bundleIdCapabilities.d.ts +4 -17
  19. package/build/credentials/ios/appstore/bundleIdCapabilities.js +45 -625
  20. package/build/credentials/ios/appstore/capabilityIdentifiers.js +33 -34
  21. package/build/credentials/ios/appstore/capabilityList.d.ts +33 -0
  22. package/build/credentials/ios/appstore/capabilityList.js +646 -0
  23. package/build/graphql/generated.d.ts +236 -19
  24. package/build/graphql/queries/WorkflowJobQuery.d.ts +7 -0
  25. package/build/graphql/queries/WorkflowJobQuery.js +29 -0
  26. package/build/graphql/queries/WorkflowRunQuery.js +13 -13
  27. package/build/graphql/types/WorkflowJob.d.ts +1 -0
  28. package/build/graphql/types/WorkflowJob.js +32 -0
  29. package/build/graphql/types/WorkflowRun.js +18 -0
  30. package/build/worker/assets.d.ts +0 -3
  31. package/build/worker/assets.js +3 -3
  32. package/build/worker/upload.js +4 -8
  33. package/build/worker/utils/multipart.d.ts +5 -4
  34. package/build/worker/utils/multipart.js +44 -9
  35. package/oclif.manifest.json +85 -1
  36. package/package.json +2 -2
  37. package/build/commandUtils/workflows.d.ts +0 -20
  38. package/build/commandUtils/workflows.js +0 -21
@@ -168,6 +168,7 @@ export type Account = {
168
168
  googleServiceAccountKeys: Array<GoogleServiceAccountKey>;
169
169
  /** Android credentials for account */
170
170
  googleServiceAccountKeysPaginated: AccountGoogleServiceAccountKeysConnection;
171
+ /** @deprecated No longer needed */
171
172
  hasBuilds: Scalars['Boolean']['output'];
172
173
  id: Scalars['ID']['output'];
173
174
  isCurrent: Scalars['Boolean']['output'];
@@ -506,6 +507,7 @@ export declare enum AccountAppsSortByField {
506
507
  Name = "NAME"
507
508
  }
508
509
  export type AccountDataInput = {
510
+ displayName?: InputMaybe<Scalars['String']['input']>;
509
511
  name: Scalars['String']['input'];
510
512
  };
511
513
  export type AccountGoogleServiceAccountKeysConnection = {
@@ -2842,12 +2844,6 @@ export type BuildPublicDataQueryByIdArgs = {
2842
2844
  };
2843
2845
  export type BuildQuery = {
2844
2846
  __typename?: 'BuildQuery';
2845
- /**
2846
- * Get all builds.
2847
- * By default, they are sorted from latest to oldest.
2848
- * Available only for admin users.
2849
- */
2850
- all: Array<Build>;
2851
2847
  /**
2852
2848
  * Get all builds for a specific app.
2853
2849
  * They are sorted from latest to oldest.
@@ -2857,12 +2853,6 @@ export type BuildQuery = {
2857
2853
  /** Look up EAS Build by build ID */
2858
2854
  byId: Build;
2859
2855
  };
2860
- export type BuildQueryAllArgs = {
2861
- limit?: InputMaybe<Scalars['Int']['input']>;
2862
- offset?: InputMaybe<Scalars['Int']['input']>;
2863
- order?: InputMaybe<Order>;
2864
- statuses?: InputMaybe<Array<BuildStatus>>;
2865
- };
2866
2856
  export type BuildQueryAllForAppArgs = {
2867
2857
  appId: Scalars['String']['input'];
2868
2858
  limit?: InputMaybe<Scalars['Int']['input']>;
@@ -2944,6 +2934,16 @@ export type ChannelQuery = {
2944
2934
  export type ChannelQueryByIdArgs = {
2945
2935
  channelId: Scalars['ID']['input'];
2946
2936
  };
2937
+ export type ChannelRuntimeEdge = {
2938
+ __typename?: 'ChannelRuntimeEdge';
2939
+ cursor: Scalars['String']['output'];
2940
+ node: RuntimeWithLastActivity;
2941
+ };
2942
+ export type ChannelRuntimesConnection = {
2943
+ __typename?: 'ChannelRuntimesConnection';
2944
+ edges: Array<ChannelRuntimeEdge>;
2945
+ pageInfo: PageInfo;
2946
+ };
2947
2947
  export type Charge = {
2948
2948
  __typename?: 'Charge';
2949
2949
  amount: Scalars['Int']['output'];
@@ -5457,6 +5457,11 @@ export type RuntimeQuery = {
5457
5457
  export type RuntimeQueryByIdArgs = {
5458
5458
  runtimeId: Scalars['ID']['input'];
5459
5459
  };
5460
+ export type RuntimeWithLastActivity = {
5461
+ __typename?: 'RuntimeWithLastActivity';
5462
+ lastActivityPostgresSerialized: Scalars['String']['output'];
5463
+ runtime: Runtime;
5464
+ };
5460
5465
  /** Represents the connection over the runtime edge of an App */
5461
5466
  export type RuntimesConnection = {
5462
5467
  __typename?: 'RuntimesConnection';
@@ -5474,7 +5479,10 @@ export type SsoUser = Actor & UserActor & {
5474
5479
  appCount: Scalars['Int']['output'];
5475
5480
  /** @deprecated No longer supported */
5476
5481
  appetizeCode?: Maybe<Scalars['String']['output']>;
5477
- /** Apps this user has published. If this user is the viewer, this field returns the apps the user has access to. */
5482
+ /**
5483
+ * Apps this user has published. If this user is the viewer, this field returns the apps the user has access to.
5484
+ * @deprecated Use Account.appsPaginated instead
5485
+ */
5478
5486
  apps: Array<App>;
5479
5487
  bestContactEmail?: Maybe<Scalars['String']['output']>;
5480
5488
  created: Scalars['DateTime']['output'];
@@ -6066,10 +6074,17 @@ export type UpdateChannel = {
6066
6074
  createdAt: Scalars['DateTime']['output'];
6067
6075
  id: Scalars['ID']['output'];
6068
6076
  isPaused: Scalars['Boolean']['output'];
6077
+ latestRuntimes: ChannelRuntimesConnection;
6069
6078
  name: Scalars['String']['output'];
6070
6079
  updateBranches: Array<UpdateBranch>;
6071
6080
  updatedAt: Scalars['DateTime']['output'];
6072
6081
  };
6082
+ export type UpdateChannelLatestRuntimesArgs = {
6083
+ after?: InputMaybe<Scalars['String']['input']>;
6084
+ before?: InputMaybe<Scalars['String']['input']>;
6085
+ first?: InputMaybe<Scalars['Int']['input']>;
6086
+ last?: InputMaybe<Scalars['Int']['input']>;
6087
+ };
6073
6088
  export type UpdateChannelUpdateBranchesArgs = {
6074
6089
  limit: Scalars['Int']['input'];
6075
6090
  offset: Scalars['Int']['input'];
@@ -6311,7 +6326,10 @@ export type User = Actor & UserActor & {
6311
6326
  appCount: Scalars['Int']['output'];
6312
6327
  /** @deprecated No longer supported */
6313
6328
  appetizeCode?: Maybe<Scalars['String']['output']>;
6314
- /** Apps this user has published */
6329
+ /**
6330
+ * Apps this user has published
6331
+ * @deprecated Use Account.appsPaginated instead
6332
+ */
6315
6333
  apps: Array<App>;
6316
6334
  bestContactEmail?: Maybe<Scalars['String']['output']>;
6317
6335
  created: Scalars['DateTime']['output'];
@@ -6409,7 +6427,10 @@ export type UserActor = {
6409
6427
  appCount: Scalars['Int']['output'];
6410
6428
  /** @deprecated No longer supported */
6411
6429
  appetizeCode?: Maybe<Scalars['String']['output']>;
6412
- /** Apps this user has published */
6430
+ /**
6431
+ * Apps this user has published
6432
+ * @deprecated Use Account.appsPaginated instead
6433
+ */
6413
6434
  apps: Array<App>;
6414
6435
  bestContactEmail?: Maybe<Scalars['String']['output']>;
6415
6436
  created: Scalars['DateTime']['output'];
@@ -6704,6 +6725,8 @@ export type UserInvitationMutation = {
6704
6725
  deleteUserInvitationByToken: RescindUserInvitationResult;
6705
6726
  /** Re-send UserInivitation by ID */
6706
6727
  resendUserInvitation: UserInvitation;
6728
+ /** Update UserInvitation permissions by ID */
6729
+ updateUserInvitationPermissions: UserInvitation;
6707
6730
  };
6708
6731
  export type UserInvitationMutationAcceptUserInvitationAsViewerArgs = {
6709
6732
  id: Scalars['ID']['input'];
@@ -6725,6 +6748,10 @@ export type UserInvitationMutationDeleteUserInvitationByTokenArgs = {
6725
6748
  export type UserInvitationMutationResendUserInvitationArgs = {
6726
6749
  id: Scalars['ID']['input'];
6727
6750
  };
6751
+ export type UserInvitationMutationUpdateUserInvitationPermissionsArgs = {
6752
+ invitationID: Scalars['ID']['input'];
6753
+ permissions: Array<InputMaybe<Permission>>;
6754
+ };
6728
6755
  /** Publicly visible data for a UserInvitation. */
6729
6756
  export type UserInvitationPublicData = {
6730
6757
  __typename?: 'UserInvitationPublicData';
@@ -7018,14 +7045,14 @@ export type WorkerDeploymentCrashesHashEdge = {
7018
7045
  __typename?: 'WorkerDeploymentCrashesHashEdge';
7019
7046
  crashHash: Scalars['ID']['output'];
7020
7047
  node: WorkerDeploymentCrashesAggregationNode;
7021
- sample: WorkerDeploymentCrashNode;
7048
+ sample?: Maybe<WorkerDeploymentCrashNode>;
7022
7049
  timeseries: Array<WorkerDeploymentCrashesTimeseriesEdge>;
7023
7050
  };
7024
7051
  export type WorkerDeploymentCrashesNameEdge = {
7025
7052
  __typename?: 'WorkerDeploymentCrashesNameEdge';
7026
7053
  name: Scalars['String']['output'];
7027
7054
  node: WorkerDeploymentCrashesAggregationNode;
7028
- sample: WorkerDeploymentCrashNode;
7055
+ sample?: Maybe<WorkerDeploymentCrashNode>;
7029
7056
  timeseries: Array<WorkerDeploymentCrashesTimeseriesEdge>;
7030
7057
  };
7031
7058
  export type WorkerDeploymentCrashesTimeseriesEdge = {
@@ -7505,6 +7532,7 @@ export type WorkflowRunGitBranchFilterInput = {
7505
7532
  searchTerm?: InputMaybe<Scalars['String']['input']>;
7506
7533
  };
7507
7534
  export type WorkflowRunInput = {
7535
+ inputs?: InputMaybe<Scalars['JSONObject']['input']>;
7508
7536
  projectSource: WorkflowProjectSourceInput;
7509
7537
  };
7510
7538
  export type WorkflowRunMutation = {
@@ -12556,8 +12584,30 @@ export type AppByIdWorkflowRunsFilteredByStatusQuery = {
12556
12584
  status: WorkflowRunStatus;
12557
12585
  gitCommitMessage?: string | null;
12558
12586
  gitCommitHash?: string | null;
12587
+ requestedGitRef?: string | null;
12588
+ triggeringLabelName?: string | null;
12589
+ triggerEventType: WorkflowRunTriggerEventType;
12590
+ triggeringSchedule?: string | null;
12559
12591
  createdAt: any;
12560
12592
  updatedAt: any;
12593
+ actor?: {
12594
+ __typename: 'Robot';
12595
+ firstName?: string | null;
12596
+ id: string;
12597
+ } | {
12598
+ __typename: 'SSOUser';
12599
+ username: string;
12600
+ id: string;
12601
+ } | {
12602
+ __typename: 'User';
12603
+ username: string;
12604
+ id: string;
12605
+ } | null;
12606
+ errors: Array<{
12607
+ __typename?: 'WorkflowRunError';
12608
+ title?: string | null;
12609
+ message: string;
12610
+ }>;
12561
12611
  workflow: {
12562
12612
  __typename?: 'Workflow';
12563
12613
  id: string;
@@ -14442,6 +14492,45 @@ export type WebhookByIdQuery = {
14442
14492
  };
14443
14493
  };
14444
14494
  };
14495
+ export type WorkflowJobByIdQueryVariables = Exact<{
14496
+ workflowJobId: Scalars['ID']['input'];
14497
+ }>;
14498
+ export type WorkflowJobByIdQuery = {
14499
+ __typename?: 'RootQuery';
14500
+ workflowJobs: {
14501
+ __typename?: 'WorkflowJobQuery';
14502
+ byId: {
14503
+ __typename?: 'WorkflowJob';
14504
+ id: string;
14505
+ key: string;
14506
+ name: string;
14507
+ status: WorkflowJobStatus;
14508
+ type: WorkflowJobType;
14509
+ outputs: any;
14510
+ createdAt: any;
14511
+ updatedAt: any;
14512
+ workflowRun: {
14513
+ __typename?: 'WorkflowRun';
14514
+ id: string;
14515
+ };
14516
+ turtleJobRun?: {
14517
+ __typename?: 'JobRun';
14518
+ id: string;
14519
+ logFileUrls: Array<string>;
14520
+ errors: Array<{
14521
+ __typename?: 'JobRunError';
14522
+ errorCode: string;
14523
+ message: string;
14524
+ }>;
14525
+ } | null;
14526
+ errors: Array<{
14527
+ __typename?: 'WorkflowJobError';
14528
+ title: string;
14529
+ message: string;
14530
+ }>;
14531
+ };
14532
+ };
14533
+ };
14445
14534
  export type WorkflowRunByIdQueryVariables = Exact<{
14446
14535
  workflowRunId: Scalars['ID']['input'];
14447
14536
  }>;
@@ -14466,24 +14555,78 @@ export type WorkflowRunByIdWithJobsQuery = {
14466
14555
  byId: {
14467
14556
  __typename?: 'WorkflowRun';
14468
14557
  id: string;
14469
- name: string;
14470
14558
  status: WorkflowRunStatus;
14559
+ gitCommitMessage?: string | null;
14560
+ gitCommitHash?: string | null;
14561
+ requestedGitRef?: string | null;
14562
+ triggeringLabelName?: string | null;
14563
+ triggerEventType: WorkflowRunTriggerEventType;
14564
+ triggeringSchedule?: string | null;
14471
14565
  createdAt: any;
14566
+ updatedAt: any;
14472
14567
  workflow: {
14473
14568
  __typename?: 'Workflow';
14474
14569
  id: string;
14475
14570
  name?: string | null;
14476
14571
  fileName: string;
14572
+ app: {
14573
+ __typename?: 'App';
14574
+ id: string;
14575
+ name: string;
14576
+ ownerAccount: {
14577
+ __typename?: 'Account';
14578
+ id: string;
14579
+ name: string;
14580
+ };
14581
+ };
14477
14582
  };
14478
14583
  jobs: Array<{
14479
14584
  __typename?: 'WorkflowJob';
14480
14585
  id: string;
14481
14586
  key: string;
14482
14587
  name: string;
14483
- type: WorkflowJobType;
14484
14588
  status: WorkflowJobStatus;
14589
+ type: WorkflowJobType;
14485
14590
  outputs: any;
14486
14591
  createdAt: any;
14592
+ updatedAt: any;
14593
+ workflowRun: {
14594
+ __typename?: 'WorkflowRun';
14595
+ id: string;
14596
+ };
14597
+ turtleJobRun?: {
14598
+ __typename?: 'JobRun';
14599
+ id: string;
14600
+ logFileUrls: Array<string>;
14601
+ errors: Array<{
14602
+ __typename?: 'JobRunError';
14603
+ errorCode: string;
14604
+ message: string;
14605
+ }>;
14606
+ } | null;
14607
+ errors: Array<{
14608
+ __typename?: 'WorkflowJobError';
14609
+ title: string;
14610
+ message: string;
14611
+ }>;
14612
+ }>;
14613
+ actor?: {
14614
+ __typename: 'Robot';
14615
+ firstName?: string | null;
14616
+ id: string;
14617
+ } | {
14618
+ __typename: 'SSOUser';
14619
+ username: string;
14620
+ id: string;
14621
+ } | {
14622
+ __typename: 'User';
14623
+ username: string;
14624
+ id: string;
14625
+ } | null;
14626
+ errors: Array<{
14627
+ __typename?: 'WorkflowRunError';
14628
+ title?: string | null;
14629
+ message: string;
14487
14630
  }>;
14488
14631
  };
14489
14632
  };
@@ -14511,8 +14654,30 @@ export type WorkflowRunsForAppIdFileNameAndStatusQuery = {
14511
14654
  status: WorkflowRunStatus;
14512
14655
  gitCommitMessage?: string | null;
14513
14656
  gitCommitHash?: string | null;
14657
+ requestedGitRef?: string | null;
14658
+ triggeringLabelName?: string | null;
14659
+ triggerEventType: WorkflowRunTriggerEventType;
14660
+ triggeringSchedule?: string | null;
14514
14661
  createdAt: any;
14515
14662
  updatedAt: any;
14663
+ actor?: {
14664
+ __typename: 'Robot';
14665
+ firstName?: string | null;
14666
+ id: string;
14667
+ } | {
14668
+ __typename: 'SSOUser';
14669
+ username: string;
14670
+ id: string;
14671
+ } | {
14672
+ __typename: 'User';
14673
+ username: string;
14674
+ id: string;
14675
+ } | null;
14676
+ errors: Array<{
14677
+ __typename?: 'WorkflowRunError';
14678
+ title?: string | null;
14679
+ message: string;
14680
+ }>;
14516
14681
  workflow: {
14517
14682
  __typename?: 'Workflow';
14518
14683
  id: string;
@@ -15159,14 +15324,66 @@ export type WorkflowFragment = {
15159
15324
  createdAt: any;
15160
15325
  updatedAt: any;
15161
15326
  };
15327
+ export type WorkflowJobFragment = {
15328
+ __typename?: 'WorkflowJob';
15329
+ id: string;
15330
+ key: string;
15331
+ name: string;
15332
+ status: WorkflowJobStatus;
15333
+ type: WorkflowJobType;
15334
+ outputs: any;
15335
+ createdAt: any;
15336
+ updatedAt: any;
15337
+ workflowRun: {
15338
+ __typename?: 'WorkflowRun';
15339
+ id: string;
15340
+ };
15341
+ turtleJobRun?: {
15342
+ __typename?: 'JobRun';
15343
+ id: string;
15344
+ logFileUrls: Array<string>;
15345
+ errors: Array<{
15346
+ __typename?: 'JobRunError';
15347
+ errorCode: string;
15348
+ message: string;
15349
+ }>;
15350
+ } | null;
15351
+ errors: Array<{
15352
+ __typename?: 'WorkflowJobError';
15353
+ title: string;
15354
+ message: string;
15355
+ }>;
15356
+ };
15162
15357
  export type WorkflowRunFragment = {
15163
15358
  __typename?: 'WorkflowRun';
15164
15359
  id: string;
15165
15360
  status: WorkflowRunStatus;
15166
15361
  gitCommitMessage?: string | null;
15167
15362
  gitCommitHash?: string | null;
15363
+ requestedGitRef?: string | null;
15364
+ triggeringLabelName?: string | null;
15365
+ triggerEventType: WorkflowRunTriggerEventType;
15366
+ triggeringSchedule?: string | null;
15168
15367
  createdAt: any;
15169
15368
  updatedAt: any;
15369
+ actor?: {
15370
+ __typename: 'Robot';
15371
+ firstName?: string | null;
15372
+ id: string;
15373
+ } | {
15374
+ __typename: 'SSOUser';
15375
+ username: string;
15376
+ id: string;
15377
+ } | {
15378
+ __typename: 'User';
15379
+ username: string;
15380
+ id: string;
15381
+ } | null;
15382
+ errors: Array<{
15383
+ __typename?: 'WorkflowRunError';
15384
+ title?: string | null;
15385
+ message: string;
15386
+ }>;
15170
15387
  workflow: {
15171
15388
  __typename?: 'Workflow';
15172
15389
  id: string;
@@ -0,0 +1,7 @@
1
+ import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
2
+ import { WorkflowJobByIdQuery } from '../generated';
3
+ export declare const WorkflowJobQuery: {
4
+ byIdAsync(graphqlClient: ExpoGraphqlClient, workflowJobId: string, { useCache }?: {
5
+ useCache?: boolean | undefined;
6
+ }): Promise<WorkflowJobByIdQuery['workflowJobs']['byId']>;
7
+ };
@@ -0,0 +1,29 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.WorkflowJobQuery = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const graphql_1 = require("graphql");
6
+ const graphql_tag_1 = tslib_1.__importDefault(require("graphql-tag"));
7
+ const client_1 = require("../client");
8
+ const WorkflowJob_1 = require("../types/WorkflowJob");
9
+ exports.WorkflowJobQuery = {
10
+ async byIdAsync(graphqlClient, workflowJobId, { useCache = true } = {}) {
11
+ const data = await (0, client_1.withErrorHandlingAsync)(graphqlClient
12
+ .query((0, graphql_tag_1.default) `
13
+ query WorkflowJobById($workflowJobId: ID!) {
14
+ workflowJobs {
15
+ byId(workflowJobId: $workflowJobId) {
16
+ id
17
+ ...WorkflowJobFragment
18
+ }
19
+ }
20
+ }
21
+ ${(0, graphql_1.print)(WorkflowJob_1.WorkflowJobFragmentNode)}
22
+ `, { workflowJobId }, {
23
+ requestPolicy: useCache ? 'cache-first' : 'network-only',
24
+ additionalTypenames: ['WorkflowJob'],
25
+ })
26
+ .toPromise());
27
+ return data.workflowJobs.byId;
28
+ },
29
+ };
@@ -6,6 +6,7 @@ const assert_1 = tslib_1.__importDefault(require("assert"));
6
6
  const graphql_1 = require("graphql");
7
7
  const graphql_tag_1 = tslib_1.__importDefault(require("graphql-tag"));
8
8
  const client_1 = require("../client");
9
+ const WorkflowJob_1 = require("../types/WorkflowJob");
9
10
  const WorkflowRun_1 = require("../types/WorkflowRun");
10
11
  exports.WorkflowRunQuery = {
11
12
  async byIdAsync(graphqlClient, workflowRunId, { useCache = true } = {}) {
@@ -33,28 +34,27 @@ exports.WorkflowRunQuery = {
33
34
  workflowRuns {
34
35
  byId(workflowRunId: $workflowRunId) {
35
36
  id
36
- name
37
- status
38
- createdAt
39
-
40
37
  workflow {
41
38
  id
42
- name
43
- fileName
39
+ app {
40
+ id
41
+ name
42
+ ownerAccount {
43
+ id
44
+ name
45
+ }
46
+ }
44
47
  }
45
-
46
48
  jobs {
47
49
  id
48
- key
49
- name
50
- type
51
- status
52
- outputs
53
- createdAt
50
+ ...WorkflowJobFragment
54
51
  }
52
+ ...WorkflowRunFragment
55
53
  }
56
54
  }
57
55
  }
56
+ ${(0, graphql_1.print)(WorkflowRun_1.WorkflowRunFragmentNode)}
57
+ ${(0, graphql_1.print)(WorkflowJob_1.WorkflowJobFragmentNode)}
58
58
  `, { workflowRunId }, {
59
59
  requestPolicy: useCache ? 'cache-first' : 'network-only',
60
60
  additionalTypenames: ['WorkflowRun'],
@@ -0,0 +1 @@
1
+ export declare const WorkflowJobFragmentNode: import("graphql").DocumentNode;
@@ -0,0 +1,32 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.WorkflowJobFragmentNode = void 0;
4
+ const tslib_1 = require("tslib");
5
+ const graphql_tag_1 = tslib_1.__importDefault(require("graphql-tag"));
6
+ exports.WorkflowJobFragmentNode = (0, graphql_tag_1.default) `
7
+ fragment WorkflowJobFragment on WorkflowJob {
8
+ id
9
+ key
10
+ name
11
+ status
12
+ workflowRun {
13
+ id
14
+ }
15
+ type
16
+ turtleJobRun {
17
+ id
18
+ logFileUrls
19
+ errors {
20
+ errorCode
21
+ message
22
+ }
23
+ }
24
+ outputs
25
+ errors {
26
+ title
27
+ message
28
+ }
29
+ createdAt
30
+ updatedAt
31
+ }
32
+ `;
@@ -9,8 +9,26 @@ exports.WorkflowRunFragmentNode = (0, graphql_tag_1.default) `
9
9
  status
10
10
  gitCommitMessage
11
11
  gitCommitHash
12
+ requestedGitRef
13
+ actor {
14
+ id
15
+ __typename
16
+ ... on UserActor {
17
+ username
18
+ }
19
+ ... on Robot {
20
+ firstName
21
+ }
22
+ }
23
+ triggeringLabelName
24
+ triggerEventType
25
+ triggeringSchedule
12
26
  createdAt
13
27
  updatedAt
28
+ errors {
29
+ title
30
+ message
31
+ }
14
32
  workflow {
15
33
  id
16
34
  name
@@ -1,11 +1,8 @@
1
1
  /// <reference types="node" />
2
- /// <reference types="node" />
3
2
  import { GzipOptions } from 'minizlib';
4
- import { HashOptions } from 'node:crypto';
5
3
  import { ExpoGraphqlClient } from '../commandUtils/context/contextUtils/createGraphqlClient';
6
4
  import { EnvironmentVariableEnvironment } from '../graphql/generated';
7
5
  interface AssetMapOptions {
8
- hashOptions?: HashOptions;
9
6
  maxFileSize: number;
10
7
  }
11
8
  export interface AssetFileEntry {
@@ -35,8 +35,8 @@ async function createTempWritePathAsync() {
35
35
  return node_path_1.default.resolve(tmpdir, `tmp-${basename}-${process.pid}-${random}`);
36
36
  }
37
37
  /** Computes a SHA512 hash for a file */
38
- async function computeSha512HashAsync(filePath, options) {
39
- const hash = (0, node_crypto_1.createHash)('sha512', { encoding: 'hex', ...options });
38
+ async function computeSha512HashAsync(filePath) {
39
+ const hash = (0, node_crypto_1.createHash)('sha512', { encoding: 'hex' });
40
40
  await (0, promises_1.pipeline)(node_fs_1.default.createReadStream(filePath), hash);
41
41
  return `${hash.read()}`;
42
42
  }
@@ -89,7 +89,7 @@ async function collectAssetsAsync(assetPath, options) {
89
89
  if (file.size > options.maxFileSize) {
90
90
  throw new Error(`Upload of "${file.normalizedPath}" aborted: File size is greater than the upload limit (>500MB)`);
91
91
  }
92
- const sha512$ = computeSha512HashAsync(file.path, options?.hashOptions);
92
+ const sha512$ = computeSha512HashAsync(file.path);
93
93
  const contentType$ = determineMimeTypeAsync(file.path);
94
94
  assets.push({
95
95
  normalizedPath: file.normalizedPath,
@@ -52,7 +52,7 @@ async function uploadAsync(init, payload, onProgressUpdate) {
52
52
  }
53
53
  method = 'POST';
54
54
  url.pathname = `/asset/${asset.sha512}`;
55
- body = node_fs_1.default.createReadStream(asset.path);
55
+ body = node_stream_1.Readable.from((0, multipart_1.createReadStreamAsync)(asset), { objectMode: false });
56
56
  }
57
57
  else if ('filePath' in payload) {
58
58
  const { filePath } = payload;
@@ -65,13 +65,9 @@ async function uploadAsync(init, payload, onProgressUpdate) {
65
65
  headers.set('content-type', multipart_1.multipartContentType);
66
66
  method = 'PATCH';
67
67
  url.pathname = '/asset/batch';
68
- const iterator = (0, multipart_1.createMultipartBodyFromFilesAsync)(multipart.map(asset => ({
69
- name: asset.sha512,
70
- filePath: asset.path,
71
- contentType: asset.type,
72
- contentLength: asset.size,
73
- })), onProgressUpdate);
74
- body = node_stream_1.Readable.from(iterator);
68
+ body = node_stream_1.Readable.from((0, multipart_1.createMultipartBodyFromFilesAsync)(multipart, onProgressUpdate), {
69
+ objectMode: false,
70
+ });
75
71
  }
76
72
  let response;
77
73
  try {
@@ -1,8 +1,9 @@
1
+ export declare function createReadStreamAsync(fileEntry: MultipartFileEntry): AsyncGenerator<Uint8Array>;
1
2
  export interface MultipartFileEntry {
2
- name: string;
3
- filePath: string;
4
- contentType: string | null;
5
- contentLength: number | null;
3
+ sha512: string;
4
+ path: string;
5
+ type: string | null;
6
+ size: number;
6
7
  }
7
8
  export declare const multipartContentType = "multipart/form-data; boundary=----formdata-eas-cli";
8
9
  type OnProgressUpdateCallback = (progress: number) => void;