eas-cli 2.3.0 → 2.4.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 (346) hide show
  1. package/README.md +47 -47
  2. package/build/ApiV2Error.d.ts +15 -0
  3. package/build/ApiV2Error.js +14 -0
  4. package/build/api.d.ts +10 -16
  5. package/build/api.js +52 -59
  6. package/build/branch/queries.d.ts +3 -2
  7. package/build/branch/queries.js +7 -7
  8. package/build/build/android/build.js +3 -3
  9. package/build/build/android/syncProjectConfiguration.d.ts +2 -1
  10. package/build/build/android/syncProjectConfiguration.js +2 -2
  11. package/build/build/android/version.d.ts +2 -1
  12. package/build/build/android/version.js +4 -4
  13. package/build/build/build.d.ts +2 -1
  14. package/build/build/build.js +5 -5
  15. package/build/build/context.d.ts +2 -0
  16. package/build/build/createContext.d.ts +3 -1
  17. package/build/build/createContext.js +4 -2
  18. package/build/build/ios/build.js +3 -3
  19. package/build/build/ios/syncProjectConfiguration.d.ts +2 -1
  20. package/build/build/ios/syncProjectConfiguration.js +2 -2
  21. package/build/build/ios/version.d.ts +2 -1
  22. package/build/build/ios/version.js +4 -4
  23. package/build/build/queries.d.ts +2 -1
  24. package/build/build/queries.js +3 -3
  25. package/build/build/runBuildAndSubmit.d.ts +2 -1
  26. package/build/build/runBuildAndSubmit.js +9 -6
  27. package/build/channel/queries.d.ts +4 -3
  28. package/build/channel/queries.js +13 -13
  29. package/build/commandUtils/EasCommand.d.ts +24 -3
  30. package/build/commandUtils/EasCommand.js +36 -6
  31. package/build/commandUtils/context/ContextField.d.ts +2 -0
  32. package/build/commandUtils/context/DynamicProjectConfigContextField.d.ts +1 -1
  33. package/build/commandUtils/context/DynamicProjectConfigContextField.js +2 -2
  34. package/build/commandUtils/context/LoggedInContextField.d.ts +12 -0
  35. package/build/commandUtils/context/LoggedInContextField.js +15 -0
  36. package/build/commandUtils/context/MaybeLoggedInContextField.d.ts +12 -0
  37. package/build/commandUtils/context/MaybeLoggedInContextField.js +17 -0
  38. package/build/commandUtils/context/OptionalProjectConfigContextField.d.ts +1 -1
  39. package/build/commandUtils/context/OptionalProjectConfigContextField.js +2 -2
  40. package/build/commandUtils/context/ProjectConfigContextField.d.ts +1 -1
  41. package/build/commandUtils/context/ProjectConfigContextField.js +2 -2
  42. package/build/commandUtils/context/SessionManagementContextField.d.ts +5 -0
  43. package/build/commandUtils/context/SessionManagementContextField.js +10 -0
  44. package/build/commandUtils/context/contextUtils/createGraphqlClient.d.ts +11 -0
  45. package/build/commandUtils/context/contextUtils/createGraphqlClient.js +43 -0
  46. package/build/commandUtils/context/contextUtils/getProjectIdAsync.d.ts +2 -1
  47. package/build/commandUtils/context/contextUtils/getProjectIdAsync.js +11 -7
  48. package/build/commands/account/login.d.ts +3 -0
  49. package/build/commands/account/login.js +7 -2
  50. package/build/commands/account/logout.d.ts +3 -0
  51. package/build/commands/account/logout.js +7 -2
  52. package/build/commands/account/view.d.ts +3 -0
  53. package/build/commands/account/view.js +8 -3
  54. package/build/commands/branch/create.d.ts +3 -1
  55. package/build/commands/branch/create.js +6 -5
  56. package/build/commands/branch/delete.d.ts +1 -0
  57. package/build/commands/branch/delete.js +10 -9
  58. package/build/commands/branch/list.d.ts +1 -0
  59. package/build/commands/branch/list.js +3 -2
  60. package/build/commands/branch/rename.d.ts +1 -0
  61. package/build/commands/branch/rename.js +6 -5
  62. package/build/commands/branch/view.d.ts +1 -0
  63. package/build/commands/branch/view.js +4 -3
  64. package/build/commands/build/cancel.d.ts +3 -1
  65. package/build/commands/build/cancel.js +14 -13
  66. package/build/commands/build/configure.d.ts +1 -0
  67. package/build/commands/build/configure.js +4 -3
  68. package/build/commands/build/index.d.ts +1 -1
  69. package/build/commands/build/index.js +3 -3
  70. package/build/commands/build/inspect.d.ts +1 -1
  71. package/build/commands/build/inspect.js +2 -2
  72. package/build/commands/build/list.d.ts +1 -0
  73. package/build/commands/build/list.js +4 -3
  74. package/build/commands/build/version/set.d.ts +1 -1
  75. package/build/commands/build/version/set.js +4 -4
  76. package/build/commands/build/version/sync.d.ts +1 -1
  77. package/build/commands/build/version/sync.js +2 -2
  78. package/build/commands/build/view.d.ts +1 -0
  79. package/build/commands/build/view.js +5 -4
  80. package/build/commands/channel/create.d.ts +3 -1
  81. package/build/commands/channel/create.js +8 -7
  82. package/build/commands/channel/delete.d.ts +1 -0
  83. package/build/commands/channel/delete.js +7 -6
  84. package/build/commands/channel/edit.d.ts +3 -1
  85. package/build/commands/channel/edit.js +12 -8
  86. package/build/commands/channel/list.d.ts +1 -0
  87. package/build/commands/channel/list.js +3 -2
  88. package/build/commands/channel/rollout.d.ts +1 -0
  89. package/build/commands/channel/rollout.js +15 -14
  90. package/build/commands/channel/view.d.ts +1 -0
  91. package/build/commands/channel/view.js +4 -3
  92. package/build/commands/credentials.d.ts +1 -1
  93. package/build/commands/credentials.js +2 -2
  94. package/build/commands/device/create.d.ts +1 -1
  95. package/build/commands/device/create.js +2 -1
  96. package/build/commands/device/delete.d.ts +3 -1
  97. package/build/commands/device/delete.js +9 -8
  98. package/build/commands/device/list.d.ts +1 -0
  99. package/build/commands/device/list.js +5 -4
  100. package/build/commands/device/view.d.ts +1 -0
  101. package/build/commands/device/view.js +4 -3
  102. package/build/commands/metadata/pull.d.ts +1 -1
  103. package/build/commands/metadata/pull.js +2 -1
  104. package/build/commands/metadata/push.d.ts +1 -1
  105. package/build/commands/metadata/push.js +2 -1
  106. package/build/commands/open.d.ts +1 -0
  107. package/build/commands/open.js +3 -2
  108. package/build/commands/project/info.d.ts +1 -0
  109. package/build/commands/project/info.js +5 -4
  110. package/build/commands/project/init.d.ts +1 -1
  111. package/build/commands/project/init.js +5 -5
  112. package/build/commands/secret/create.d.ts +1 -0
  113. package/build/commands/secret/create.js +10 -9
  114. package/build/commands/secret/delete.d.ts +1 -0
  115. package/build/commands/secret/delete.js +4 -3
  116. package/build/commands/secret/list.d.ts +1 -0
  117. package/build/commands/secret/list.js +3 -2
  118. package/build/commands/submit.d.ts +1 -1
  119. package/build/commands/submit.js +4 -3
  120. package/build/commands/update/configure.d.ts +1 -0
  121. package/build/commands/update/configure.js +4 -3
  122. package/build/commands/update/delete.d.ts +3 -0
  123. package/build/commands/update/delete.js +9 -3
  124. package/build/commands/update/index.d.ts +3 -1
  125. package/build/commands/update/index.js +23 -17
  126. package/build/commands/update/list.d.ts +1 -0
  127. package/build/commands/update/list.js +6 -5
  128. package/build/commands/update/view.d.ts +3 -0
  129. package/build/commands/update/view.js +7 -1
  130. package/build/commands/webhook/create.d.ts +1 -0
  131. package/build/commands/webhook/create.js +3 -2
  132. package/build/commands/webhook/delete.d.ts +1 -0
  133. package/build/commands/webhook/delete.js +7 -6
  134. package/build/commands/webhook/list.d.ts +1 -0
  135. package/build/commands/webhook/list.js +4 -3
  136. package/build/commands/webhook/update.d.ts +3 -0
  137. package/build/commands/webhook/update.js +8 -2
  138. package/build/commands/webhook/view.d.ts +3 -0
  139. package/build/commands/webhook/view.js +7 -1
  140. package/build/credentials/android/actions/AssignFcm.js +2 -2
  141. package/build/credentials/android/actions/AssignGoogleServiceAccountKey.js +2 -2
  142. package/build/credentials/android/actions/BuildCredentialsUtils.js +12 -12
  143. package/build/credentials/android/actions/CreateFcm.js +1 -1
  144. package/build/credentials/android/actions/CreateGoogleServiceAccountKey.js +1 -1
  145. package/build/credentials/android/actions/CreateKeystore.js +4 -4
  146. package/build/credentials/android/actions/RemoveFcm.js +2 -2
  147. package/build/credentials/android/actions/RemoveGoogleServiceAccountKey.js +2 -2
  148. package/build/credentials/android/actions/RemoveKeystore.js +1 -1
  149. package/build/credentials/android/actions/SetUpBuildCredentials.js +3 -3
  150. package/build/credentials/android/actions/SetUpBuildCredentialsFromCredentialsJson.js +3 -3
  151. package/build/credentials/android/actions/SetUpGoogleServiceAccountKey.js +3 -3
  152. package/build/credentials/android/actions/UseExistingGoogleServiceAccountKey.js +1 -1
  153. package/build/credentials/android/api/GraphqlClient.d.ts +19 -18
  154. package/build/credentials/android/api/GraphqlClient.js +45 -45
  155. package/build/credentials/android/api/graphql/mutations/AndroidAppBuildCredentialsMutation.d.ts +3 -2
  156. package/build/credentials/android/api/graphql/mutations/AndroidAppBuildCredentialsMutation.js +4 -4
  157. package/build/credentials/android/api/graphql/mutations/AndroidAppCredentialsMutation.d.ts +4 -3
  158. package/build/credentials/android/api/graphql/mutations/AndroidAppCredentialsMutation.js +6 -6
  159. package/build/credentials/android/api/graphql/mutations/AndroidFcmMutation.d.ts +3 -2
  160. package/build/credentials/android/api/graphql/mutations/AndroidFcmMutation.js +4 -4
  161. package/build/credentials/android/api/graphql/mutations/AndroidKeystoreMutation.d.ts +3 -2
  162. package/build/credentials/android/api/graphql/mutations/AndroidKeystoreMutation.js +4 -4
  163. package/build/credentials/android/api/graphql/mutations/GoogleServiceAccountKeyMutation.d.ts +3 -2
  164. package/build/credentials/android/api/graphql/mutations/GoogleServiceAccountKeyMutation.js +4 -4
  165. package/build/credentials/android/api/graphql/queries/AndroidAppCredentialsQuery.d.ts +2 -1
  166. package/build/credentials/android/api/graphql/queries/AndroidAppCredentialsQuery.js +2 -2
  167. package/build/credentials/android/api/graphql/queries/GoogleServiceAccountKeyQuery.d.ts +2 -1
  168. package/build/credentials/android/api/graphql/queries/GoogleServiceAccountKeyQuery.js +2 -2
  169. package/build/credentials/android/utils/keystore.d.ts +2 -1
  170. package/build/credentials/android/utils/keystore.js +6 -6
  171. package/build/credentials/context.d.ts +3 -0
  172. package/build/credentials/context.js +1 -0
  173. package/build/credentials/credentialsJson/update.js +1 -1
  174. package/build/credentials/ios/actions/AppleTeamUtils.js +1 -1
  175. package/build/credentials/ios/actions/AscApiKeyUtils.js +1 -1
  176. package/build/credentials/ios/actions/AssignAscApiKey.js +2 -2
  177. package/build/credentials/ios/actions/AssignPushKey.js +2 -2
  178. package/build/credentials/ios/actions/BuildCredentialsUtils.js +5 -5
  179. package/build/credentials/ios/actions/ConfigureProvisioningProfile.js +1 -1
  180. package/build/credentials/ios/actions/CreateAscApiKey.js +1 -1
  181. package/build/credentials/ios/actions/CreateDistributionCertificate.js +1 -1
  182. package/build/credentials/ios/actions/CreateProvisioningProfile.js +2 -2
  183. package/build/credentials/ios/actions/CreatePushKey.js +1 -1
  184. package/build/credentials/ios/actions/DistributionCertificateUtils.js +2 -2
  185. package/build/credentials/ios/actions/PushKeyUtils.js +1 -1
  186. package/build/credentials/ios/actions/RemoveAscApiKey.js +1 -1
  187. package/build/credentials/ios/actions/RemoveDistributionCertificate.js +1 -1
  188. package/build/credentials/ios/actions/RemoveProvisioningProfile.js +1 -1
  189. package/build/credentials/ios/actions/RemovePushKey.js +1 -1
  190. package/build/credentials/ios/actions/SetUpAdhocProvisioningProfile.js +8 -8
  191. package/build/credentials/ios/actions/SetUpAscApiKey.js +2 -2
  192. package/build/credentials/ios/actions/SetUpDistributionCertificate.js +2 -2
  193. package/build/credentials/ios/actions/SetUpProvisioningProfile.js +1 -1
  194. package/build/credentials/ios/actions/SetUpPushKey.js +4 -4
  195. package/build/credentials/ios/actions/SetUpTargetBuildCredentialsFromCredentialsJson.js +5 -5
  196. package/build/credentials/ios/api/GraphqlClient.d.ts +25 -24
  197. package/build/credentials/ios/api/GraphqlClient.js +73 -73
  198. package/build/credentials/ios/api/graphql/mutations/AppStoreConnectApiKeyMutation.d.ts +3 -2
  199. package/build/credentials/ios/api/graphql/mutations/AppStoreConnectApiKeyMutation.js +4 -4
  200. package/build/credentials/ios/api/graphql/mutations/AppleAppIdentifierMutation.d.ts +2 -1
  201. package/build/credentials/ios/api/graphql/mutations/AppleAppIdentifierMutation.js +2 -2
  202. package/build/credentials/ios/api/graphql/mutations/AppleDeviceMutation.d.ts +3 -2
  203. package/build/credentials/ios/api/graphql/mutations/AppleDeviceMutation.js +4 -4
  204. package/build/credentials/ios/api/graphql/mutations/AppleDeviceRegistrationRequestMutation.d.ts +2 -1
  205. package/build/credentials/ios/api/graphql/mutations/AppleDeviceRegistrationRequestMutation.js +2 -2
  206. package/build/credentials/ios/api/graphql/mutations/AppleDistributionCertificateMutation.d.ts +3 -2
  207. package/build/credentials/ios/api/graphql/mutations/AppleDistributionCertificateMutation.js +4 -4
  208. package/build/credentials/ios/api/graphql/mutations/AppleProvisioningProfileMutation.d.ts +4 -3
  209. package/build/credentials/ios/api/graphql/mutations/AppleProvisioningProfileMutation.js +6 -6
  210. package/build/credentials/ios/api/graphql/mutations/ApplePushKeyMutation.d.ts +3 -2
  211. package/build/credentials/ios/api/graphql/mutations/ApplePushKeyMutation.js +4 -4
  212. package/build/credentials/ios/api/graphql/mutations/AppleTeamMutation.d.ts +2 -1
  213. package/build/credentials/ios/api/graphql/mutations/AppleTeamMutation.js +2 -2
  214. package/build/credentials/ios/api/graphql/mutations/IosAppBuildCredentialsMutation.d.ts +4 -3
  215. package/build/credentials/ios/api/graphql/mutations/IosAppBuildCredentialsMutation.js +6 -6
  216. package/build/credentials/ios/api/graphql/mutations/IosAppCredentialsMutation.d.ts +4 -3
  217. package/build/credentials/ios/api/graphql/mutations/IosAppCredentialsMutation.js +6 -6
  218. package/build/credentials/ios/api/graphql/queries/AppStoreConnectApiKeyQuery.d.ts +2 -1
  219. package/build/credentials/ios/api/graphql/queries/AppStoreConnectApiKeyQuery.js +2 -2
  220. package/build/credentials/ios/api/graphql/queries/AppleAppIdentifierQuery.d.ts +2 -1
  221. package/build/credentials/ios/api/graphql/queries/AppleAppIdentifierQuery.js +2 -2
  222. package/build/credentials/ios/api/graphql/queries/AppleDeviceQuery.d.ts +4 -3
  223. package/build/credentials/ios/api/graphql/queries/AppleDeviceQuery.js +6 -6
  224. package/build/credentials/ios/api/graphql/queries/AppleDistributionCertificateQuery.d.ts +3 -2
  225. package/build/credentials/ios/api/graphql/queries/AppleDistributionCertificateQuery.js +4 -4
  226. package/build/credentials/ios/api/graphql/queries/AppleProvisioningProfileQuery.d.ts +2 -1
  227. package/build/credentials/ios/api/graphql/queries/AppleProvisioningProfileQuery.js +2 -2
  228. package/build/credentials/ios/api/graphql/queries/ApplePushKeyQuery.d.ts +2 -1
  229. package/build/credentials/ios/api/graphql/queries/ApplePushKeyQuery.js +2 -2
  230. package/build/credentials/ios/api/graphql/queries/AppleTeamQuery.d.ts +3 -2
  231. package/build/credentials/ios/api/graphql/queries/AppleTeamQuery.js +4 -4
  232. package/build/credentials/ios/api/graphql/queries/IosAppBuildCredentialsQuery.d.ts +2 -1
  233. package/build/credentials/ios/api/graphql/queries/IosAppBuildCredentialsQuery.js +2 -2
  234. package/build/credentials/ios/api/graphql/queries/IosAppCredentialsQuery.d.ts +3 -2
  235. package/build/credentials/ios/api/graphql/queries/IosAppCredentialsQuery.js +4 -4
  236. package/build/credentials/manager/HelperActions.d.ts +2 -0
  237. package/build/credentials/manager/ManageAndroid.js +4 -3
  238. package/build/credentials/manager/ManageIos.js +4 -3
  239. package/build/credentials/manager/SelectAndroidBuildCredentials.js +2 -2
  240. package/build/credentials/manager/SelectPlatform.d.ts +3 -1
  241. package/build/credentials/manager/SelectPlatform.js +2 -1
  242. package/build/devices/actions/create/action.d.ts +3 -1
  243. package/build/devices/actions/create/action.js +5 -4
  244. package/build/devices/actions/create/developerPortalMethod.d.ts +2 -1
  245. package/build/devices/actions/create/developerPortalMethod.js +9 -9
  246. package/build/devices/actions/create/inputMethod.d.ts +2 -1
  247. package/build/devices/actions/create/inputMethod.js +4 -4
  248. package/build/devices/actions/create/registrationUrlMethod.d.ts +2 -1
  249. package/build/devices/actions/create/registrationUrlMethod.js +4 -4
  250. package/build/devices/context.d.ts +4 -1
  251. package/build/devices/context.js +2 -1
  252. package/build/devices/manager.d.ts +3 -1
  253. package/build/devices/manager.js +9 -8
  254. package/build/devices/queries.d.ts +4 -3
  255. package/build/devices/queries.js +7 -7
  256. package/build/graphql/client.d.ts +1 -8
  257. package/build/graphql/client.js +1 -39
  258. package/build/graphql/mutations/AppMutation.d.ts +2 -1
  259. package/build/graphql/mutations/AppMutation.js +2 -2
  260. package/build/graphql/mutations/AppVersionMutation.d.ts +2 -1
  261. package/build/graphql/mutations/AppVersionMutation.js +2 -2
  262. package/build/graphql/mutations/BuildMutation.d.ts +3 -2
  263. package/build/graphql/mutations/BuildMutation.js +4 -4
  264. package/build/graphql/mutations/EnvironmentSecretMutation.d.ts +4 -3
  265. package/build/graphql/mutations/EnvironmentSecretMutation.js +6 -6
  266. package/build/graphql/mutations/KeystoreGenerationUrlMutation.d.ts +2 -1
  267. package/build/graphql/mutations/KeystoreGenerationUrlMutation.js +2 -2
  268. package/build/graphql/mutations/PublishMutation.d.ts +4 -3
  269. package/build/graphql/mutations/PublishMutation.js +6 -6
  270. package/build/graphql/mutations/SubmissionMutation.d.ts +3 -2
  271. package/build/graphql/mutations/SubmissionMutation.js +4 -4
  272. package/build/graphql/mutations/UploadSessionMutation.d.ts +2 -1
  273. package/build/graphql/mutations/UploadSessionMutation.js +2 -2
  274. package/build/graphql/mutations/WebhookMutation.d.ts +4 -3
  275. package/build/graphql/mutations/WebhookMutation.js +6 -6
  276. package/build/graphql/queries/AppQuery.d.ts +3 -2
  277. package/build/graphql/queries/AppQuery.js +4 -4
  278. package/build/graphql/queries/AppVersionQuery.d.ts +2 -1
  279. package/build/graphql/queries/AppVersionQuery.js +2 -2
  280. package/build/graphql/queries/BranchQuery.d.ts +4 -3
  281. package/build/graphql/queries/BranchQuery.js +6 -6
  282. package/build/graphql/queries/BuildQuery.d.ts +4 -3
  283. package/build/graphql/queries/BuildQuery.js +6 -6
  284. package/build/graphql/queries/ChannelQuery.d.ts +3 -2
  285. package/build/graphql/queries/ChannelQuery.js +4 -4
  286. package/build/graphql/queries/EnvironmentSecretsQuery.d.ts +3 -2
  287. package/build/graphql/queries/EnvironmentSecretsQuery.js +4 -4
  288. package/build/graphql/queries/PublishQuery.d.ts +3 -2
  289. package/build/graphql/queries/PublishQuery.js +4 -4
  290. package/build/graphql/queries/StatuspageServiceQuery.d.ts +2 -1
  291. package/build/graphql/queries/StatuspageServiceQuery.js +2 -2
  292. package/build/graphql/queries/SubmissionQuery.d.ts +3 -2
  293. package/build/graphql/queries/SubmissionQuery.js +4 -4
  294. package/build/graphql/queries/UpdateQuery.d.ts +4 -3
  295. package/build/graphql/queries/UpdateQuery.js +6 -6
  296. package/build/graphql/queries/UserQuery.d.ts +2 -1
  297. package/build/graphql/queries/UserQuery.js +2 -2
  298. package/build/graphql/queries/WebhookQuery.d.ts +3 -2
  299. package/build/graphql/queries/WebhookQuery.js +4 -4
  300. package/build/project/fetchOrCreateProjectIDForWriteToConfigWithConfirmationAsync.d.ts +3 -2
  301. package/build/project/fetchOrCreateProjectIDForWriteToConfigWithConfirmationAsync.js +5 -5
  302. package/build/project/projectUtils.d.ts +3 -2
  303. package/build/project/projectUtils.js +4 -4
  304. package/build/project/publish.d.ts +3 -2
  305. package/build/project/publish.js +7 -7
  306. package/build/submit/ArchiveSource.d.ts +2 -1
  307. package/build/submit/ArchiveSource.js +30 -30
  308. package/build/submit/android/AndroidSubmitter.js +2 -2
  309. package/build/submit/context.d.ts +3 -0
  310. package/build/submit/context.js +3 -2
  311. package/build/submit/ios/IosSubmitter.js +2 -2
  312. package/build/submit/submit.d.ts +2 -1
  313. package/build/submit/submit.js +2 -2
  314. package/build/submit/utils/builds.d.ts +2 -1
  315. package/build/submit/utils/builds.js +2 -2
  316. package/build/submit/utils/errors.js +20 -4
  317. package/build/submit/utils/files.d.ts +2 -1
  318. package/build/submit/utils/files.js +2 -2
  319. package/build/submit/utils/wait.d.ts +2 -1
  320. package/build/submit/utils/wait.js +2 -2
  321. package/build/update/android/UpdatesModule.d.ts +2 -1
  322. package/build/update/android/UpdatesModule.js +2 -2
  323. package/build/update/ios/UpdatesModule.d.ts +2 -1
  324. package/build/update/ios/UpdatesModule.js +2 -2
  325. package/build/update/queries.d.ts +4 -3
  326. package/build/update/queries.js +22 -12
  327. package/build/uploads.d.ts +2 -1
  328. package/build/uploads.js +2 -2
  329. package/build/user/SessionManager.d.ts +70 -0
  330. package/build/user/SessionManager.js +258 -0
  331. package/build/user/User.d.ts +0 -9
  332. package/build/user/User.js +1 -60
  333. package/build/user/fetchSessionSecretAndUser.d.ts +9 -0
  334. package/build/user/fetchSessionSecretAndUser.js +43 -0
  335. package/build/utils/statuspageService.d.ts +2 -1
  336. package/build/utils/statuspageService.js +4 -4
  337. package/oclif.manifest.json +1 -1
  338. package/package.json +2 -2
  339. package/build/commandUtils/context/ActorContextField.d.ts +0 -5
  340. package/build/commandUtils/context/ActorContextField.js +0 -11
  341. package/build/commandUtils/context/contextUtils/ensureLoggedInAsync.d.ts +0 -21
  342. package/build/commandUtils/context/contextUtils/ensureLoggedInAsync.js +0 -75
  343. package/build/user/otp.d.ts +0 -29
  344. package/build/user/otp.js +0 -119
  345. package/build/user/sessionStorage.d.ts +0 -11
  346. package/build/user/sessionStorage.js +0 -36
@@ -24,34 +24,34 @@ var ArchiveSourceType;
24
24
  ArchiveSourceType[ArchiveSourceType["buildList"] = 4] = "buildList";
25
25
  ArchiveSourceType[ArchiveSourceType["prompt"] = 5] = "prompt";
26
26
  })(ArchiveSourceType = exports.ArchiveSourceType || (exports.ArchiveSourceType = {}));
27
- async function getArchiveAsync(source) {
27
+ async function getArchiveAsync(graphqlClient, source) {
28
28
  switch (source.sourceType) {
29
29
  case ArchiveSourceType.prompt: {
30
- return await handlePromptSourceAsync(source);
30
+ return await handlePromptSourceAsync(graphqlClient, source);
31
31
  }
32
32
  case ArchiveSourceType.url: {
33
- return await handleUrlSourceAsync(source);
33
+ return await handleUrlSourceAsync(graphqlClient, source);
34
34
  }
35
35
  case ArchiveSourceType.latest: {
36
- return await handleLatestSourceAsync(source);
36
+ return await handleLatestSourceAsync(graphqlClient, source);
37
37
  }
38
38
  case ArchiveSourceType.path: {
39
- return await handlePathSourceAsync(source);
39
+ return await handlePathSourceAsync(graphqlClient, source);
40
40
  }
41
41
  case ArchiveSourceType.buildId: {
42
- return await handleBuildIdSourceAsync(source);
42
+ return await handleBuildIdSourceAsync(graphqlClient, source);
43
43
  }
44
44
  case ArchiveSourceType.buildList: {
45
- return await handleBuildListSourceAsync(source);
45
+ return await handleBuildListSourceAsync(graphqlClient, source);
46
46
  }
47
47
  }
48
48
  }
49
49
  exports.getArchiveAsync = getArchiveAsync;
50
- async function handleUrlSourceAsync(source) {
50
+ async function handleUrlSourceAsync(graphqlClient, source) {
51
51
  const { url } = source;
52
52
  if (!validateUrl(url)) {
53
53
  log_1.default.error(chalk_1.default.bold(`The URL you provided is invalid: ${url}`));
54
- return getArchiveAsync({
54
+ return getArchiveAsync(graphqlClient, {
55
55
  ...source,
56
56
  sourceType: ArchiveSourceType.prompt,
57
57
  });
@@ -59,7 +59,7 @@ async function handleUrlSourceAsync(source) {
59
59
  const maybeBuildId = isBuildDetailsPage(url);
60
60
  if (maybeBuildId) {
61
61
  if (await askIfUseBuildIdFromUrlAsync(source, maybeBuildId)) {
62
- return getArchiveAsync({
62
+ return getArchiveAsync(graphqlClient, {
63
63
  ...source,
64
64
  sourceType: ArchiveSourceType.buildId,
65
65
  id: maybeBuildId,
@@ -71,12 +71,12 @@ async function handleUrlSourceAsync(source) {
71
71
  source,
72
72
  };
73
73
  }
74
- async function handleLatestSourceAsync(source) {
74
+ async function handleLatestSourceAsync(graphqlClient, source) {
75
75
  try {
76
- const [latestBuild] = await (0, builds_1.getRecentBuildsForSubmissionAsync)((0, AppPlatform_1.toAppPlatform)(source.platform), source.projectId);
76
+ const [latestBuild] = await (0, builds_1.getRecentBuildsForSubmissionAsync)(graphqlClient, (0, AppPlatform_1.toAppPlatform)(source.platform), source.projectId);
77
77
  if (!latestBuild) {
78
78
  log_1.default.error(chalk_1.default.bold("Couldn't find any builds for this project on EAS servers. It looks like you haven't run 'eas build' yet."));
79
- return getArchiveAsync({
79
+ return getArchiveAsync(graphqlClient, {
80
80
  ...source,
81
81
  sourceType: ArchiveSourceType.prompt,
82
82
  });
@@ -91,29 +91,29 @@ async function handleLatestSourceAsync(source) {
91
91
  throw err;
92
92
  }
93
93
  }
94
- async function handlePathSourceAsync(source) {
94
+ async function handlePathSourceAsync(graphqlClient, source) {
95
95
  if (!(await (0, files_1.isExistingFileAsync)(source.path))) {
96
96
  log_1.default.error(chalk_1.default.bold(`${source.path} doesn't exist`));
97
- return getArchiveAsync({
97
+ return getArchiveAsync(graphqlClient, {
98
98
  ...source,
99
99
  sourceType: ArchiveSourceType.prompt,
100
100
  });
101
101
  }
102
102
  log_1.default.log('Uploading your app archive to the Expo Submission Service');
103
- const uploadUrl = await (0, files_1.uploadAppArchiveAsync)(source.path);
103
+ const uploadUrl = await (0, files_1.uploadAppArchiveAsync)(graphqlClient, source.path);
104
104
  return {
105
105
  url: uploadUrl,
106
106
  source,
107
107
  };
108
108
  }
109
- async function handleBuildIdSourceAsync(source) {
109
+ async function handleBuildIdSourceAsync(graphqlClient, source) {
110
110
  try {
111
- const build = await BuildQuery_1.BuildQuery.byIdAsync(source.id);
111
+ const build = await BuildQuery_1.BuildQuery.byIdAsync(graphqlClient, source.id);
112
112
  if (build.platform !== (0, AppPlatform_1.toAppPlatform)(source.platform)) {
113
113
  const expectedPlatformName = platform_1.appPlatformDisplayNames[(0, AppPlatform_1.toAppPlatform)(source.platform)];
114
114
  const receivedPlatformName = platform_1.appPlatformDisplayNames[build.platform];
115
115
  log_1.default.error(chalk_1.default.bold(`Build platform doesn't match! Expected ${expectedPlatformName} build but got ${receivedPlatformName}.`));
116
- return getArchiveAsync({
116
+ return getArchiveAsync(graphqlClient, {
117
117
  ...source,
118
118
  sourceType: ArchiveSourceType.prompt,
119
119
  });
@@ -128,24 +128,24 @@ async function handleBuildIdSourceAsync(source) {
128
128
  log_1.default.warn('Are you sure that the given ID corresponds to a build from EAS Build?');
129
129
  log_1.default.warn(`Build IDs from the classic build service (expo build:[android|ios]) are not supported. ${(0, log_1.learnMore)('https://docs.expo.dev/submit/classic-builds/')}`);
130
130
  log_1.default.debug('Original error:', err);
131
- return getArchiveAsync({
131
+ return getArchiveAsync(graphqlClient, {
132
132
  ...source,
133
133
  sourceType: ArchiveSourceType.prompt,
134
134
  });
135
135
  }
136
136
  }
137
- async function handleBuildListSourceAsync(source) {
137
+ async function handleBuildListSourceAsync(graphqlClient, source) {
138
138
  try {
139
139
  const appPlatform = (0, AppPlatform_1.toAppPlatform)(source.platform);
140
140
  const expiryDate = new Date(); // artifacts expire after 30 days
141
141
  expiryDate.setDate(expiryDate.getDate() - 30);
142
- const recentBuilds = await (0, builds_1.getRecentBuildsForSubmissionAsync)(appPlatform, source.projectId, {
142
+ const recentBuilds = await (0, builds_1.getRecentBuildsForSubmissionAsync)(graphqlClient, appPlatform, source.projectId, {
143
143
  limit: exports.BUILD_LIST_ITEM_COUNT,
144
144
  });
145
145
  if (recentBuilds.length < 1) {
146
146
  log_1.default.error(chalk_1.default.bold(`Couldn't find any ${platform_1.appPlatformDisplayNames[appPlatform]} builds for this project on EAS servers. ` +
147
147
  "It looks like you haven't run 'eas build' yet."));
148
- return getArchiveAsync({
148
+ return getArchiveAsync(graphqlClient, {
149
149
  ...source,
150
150
  sourceType: ArchiveSourceType.prompt,
151
151
  });
@@ -153,7 +153,7 @@ async function handleBuildListSourceAsync(source) {
153
153
  if (recentBuilds.every(it => new Date(it.updatedAt) < expiryDate)) {
154
154
  log_1.default.error(chalk_1.default.bold('It looks like all of your build artifacts have expired. ' +
155
155
  'EAS keeps your build artifacts only for 30 days.'));
156
- return getArchiveAsync({
156
+ return getArchiveAsync(graphqlClient, {
157
157
  ...source,
158
158
  sourceType: ArchiveSourceType.prompt,
159
159
  });
@@ -171,7 +171,7 @@ async function handleBuildListSourceAsync(source) {
171
171
  warn: 'This artifact has expired',
172
172
  });
173
173
  if (selectedBuild == null) {
174
- return getArchiveAsync({
174
+ return getArchiveAsync(graphqlClient, {
175
175
  ...source,
176
176
  sourceType: ArchiveSourceType.prompt,
177
177
  });
@@ -211,7 +211,7 @@ function formatBuildChoice(build, expiryDate) {
211
211
  disabled: buildDate < expiryDate,
212
212
  };
213
213
  }
214
- async function handlePromptSourceAsync(source) {
214
+ async function handlePromptSourceAsync(graphqlClient, source) {
215
215
  const { sourceType: sourceTypeRaw } = await (0, prompts_1.promptAsync)({
216
216
  name: 'sourceType',
217
217
  type: 'select',
@@ -236,7 +236,7 @@ async function handlePromptSourceAsync(source) {
236
236
  switch (sourceType) {
237
237
  case ArchiveSourceType.url: {
238
238
  const url = await askForArchiveUrlAsync(source.platform);
239
- return getArchiveAsync({
239
+ return getArchiveAsync(graphqlClient, {
240
240
  ...source,
241
241
  sourceType: ArchiveSourceType.url,
242
242
  url,
@@ -244,21 +244,21 @@ async function handlePromptSourceAsync(source) {
244
244
  }
245
245
  case ArchiveSourceType.path: {
246
246
  const path = await askForArchivePathAsync(source.platform);
247
- return getArchiveAsync({
247
+ return getArchiveAsync(graphqlClient, {
248
248
  ...source,
249
249
  sourceType: ArchiveSourceType.path,
250
250
  path,
251
251
  });
252
252
  }
253
253
  case ArchiveSourceType.buildList: {
254
- return getArchiveAsync({
254
+ return getArchiveAsync(graphqlClient, {
255
255
  ...source,
256
256
  sourceType: ArchiveSourceType.buildList,
257
257
  });
258
258
  }
259
259
  case ArchiveSourceType.buildId: {
260
260
  const id = await askForBuildIdAsync();
261
- return getArchiveAsync({
261
+ return getArchiveAsync(graphqlClient, {
262
262
  ...source,
263
263
  sourceType: ArchiveSourceType.buildId,
264
264
  id,
@@ -13,7 +13,7 @@ class AndroidSubmitter extends BaseSubmitter_1.default {
13
13
  constructor(ctx, options) {
14
14
  const sourceOptionsResolver = {
15
15
  // eslint-disable-next-line async-protect/async-suffix
16
- archive: async () => await (0, ArchiveSource_1.getArchiveAsync)(this.options.archiveSource),
16
+ archive: async () => await (0, ArchiveSource_1.getArchiveAsync)(ctx.graphqlClient, this.options.archiveSource),
17
17
  // eslint-disable-next-line async-protect/async-suffix
18
18
  serviceAccountKeyResult: async () => {
19
19
  return await (0, ServiceAccountSource_1.getServiceAccountKeyResultAsync)(this.ctx, this.options.serviceAccountSource);
@@ -44,7 +44,7 @@ class AndroidSubmitter extends BaseSubmitter_1.default {
44
44
  };
45
45
  }
46
46
  async createPlatformSubmissionAsync({ projectId, submissionConfig, buildId, }) {
47
- return await SubmissionMutation_1.SubmissionMutation.createAndroidSubmissionAsync({
47
+ return await SubmissionMutation_1.SubmissionMutation.createAndroidSubmissionAsync(this.ctx.graphqlClient, {
48
48
  appId: projectId,
49
49
  config: submissionConfig,
50
50
  submittedBuildId: buildId,
@@ -2,6 +2,7 @@ import { ExpoConfig } from '@expo/config';
2
2
  import { Platform } from '@expo/eas-build-job';
3
3
  import { SubmitProfile } from '@expo/eas-json';
4
4
  import { TrackingContext } from '../analytics/common';
5
+ import { ExpoGraphqlClient } from '../commandUtils/context/contextUtils/createGraphqlClient';
5
6
  import { CredentialsContext } from '../credentials/context';
6
7
  import { Actor } from '../user/User';
7
8
  export interface SubmissionContext<T extends Platform> {
@@ -17,6 +18,7 @@ export interface SubmissionContext<T extends Platform> {
17
18
  projectId: string;
18
19
  projectName: string;
19
20
  user: Actor;
21
+ graphqlClient: ExpoGraphqlClient;
20
22
  applicationIdentifierOverride?: string;
21
23
  }
22
24
  export interface SubmitArchiveFlags {
@@ -35,6 +37,7 @@ export declare function createSubmissionContextAsync<T extends Platform>(params:
35
37
  projectDir: string;
36
38
  applicationIdentifier?: string;
37
39
  actor: Actor;
40
+ graphqlClient: ExpoGraphqlClient;
38
41
  exp: ExpoConfig;
39
42
  projectId: string;
40
43
  }): Promise<SubmissionContext<T>>;
@@ -6,16 +6,17 @@ const events_1 = require("../analytics/events");
6
6
  const context_1 = require("../credentials/context");
7
7
  const projectUtils_1 = require("../project/projectUtils");
8
8
  async function createSubmissionContextAsync(params) {
9
- const { applicationIdentifier, projectDir, nonInteractive, actor, exp, projectId } = params;
9
+ const { applicationIdentifier, projectDir, nonInteractive, actor, exp, projectId, graphqlClient, } = params;
10
10
  const { env, ...rest } = params;
11
11
  const projectName = exp.slug;
12
- const account = await (0, projectUtils_1.getOwnerAccountForProjectIdAsync)(projectId);
12
+ const account = await (0, projectUtils_1.getOwnerAccountForProjectIdAsync)(graphqlClient, projectId);
13
13
  const accountId = account.id;
14
14
  let credentialsCtx = params.credentialsCtx;
15
15
  if (!credentialsCtx) {
16
16
  credentialsCtx = new context_1.CredentialsContext({
17
17
  projectDir,
18
18
  user: actor,
19
+ graphqlClient,
19
20
  projectInfo: { exp, projectId },
20
21
  nonInteractive,
21
22
  });
@@ -15,7 +15,7 @@ class IosSubmitter extends BaseSubmitter_1.default {
15
15
  constructor(ctx, options) {
16
16
  const sourceOptionsResolver = {
17
17
  // eslint-disable-next-line async-protect/async-suffix
18
- archive: async () => await (0, ArchiveSource_1.getArchiveAsync)(this.options.archiveSource),
18
+ archive: async () => await (0, ArchiveSource_1.getArchiveAsync)(ctx.graphqlClient, this.options.archiveSource),
19
19
  // eslint-disable-next-line async-protect/async-suffix
20
20
  credentials: async () => {
21
21
  const maybeAppSpecificPassword = this.options.appSpecificPasswordSource
@@ -59,7 +59,7 @@ class IosSubmitter extends BaseSubmitter_1.default {
59
59
  };
60
60
  }
61
61
  async createPlatformSubmissionAsync({ projectId, submissionConfig, buildId, }) {
62
- return await SubmissionMutation_1.SubmissionMutation.createIosSubmissionAsync({
62
+ return await SubmissionMutation_1.SubmissionMutation.createIosSubmissionAsync(this.ctx.graphqlClient, {
63
63
  appId: projectId,
64
64
  config: submissionConfig,
65
65
  submittedBuildId: buildId,
@@ -1,8 +1,9 @@
1
1
  import { Platform } from '@expo/eas-build-job';
2
+ import { ExpoGraphqlClient } from '../commandUtils/context/contextUtils/createGraphqlClient';
2
3
  import { SubmissionFragment } from '../graphql/generated';
3
4
  import { SubmissionContext } from './context';
4
5
  export declare function submitAsync<T extends Platform>(ctx: SubmissionContext<T>): Promise<SubmissionFragment>;
5
- export declare function waitToCompleteAsync(submissions: SubmissionFragment[], { verbose }?: {
6
+ export declare function waitToCompleteAsync(graphqlClient: ExpoGraphqlClient, submissions: SubmissionFragment[], { verbose }?: {
6
7
  verbose?: boolean;
7
8
  }): Promise<SubmissionFragment[]>;
8
9
  export declare function exitWithNonZeroCodeIfSomeSubmissionsDidntFinish(submissions: SubmissionFragment[]): void;
@@ -27,9 +27,9 @@ async function submitAsync(ctx) {
27
27
  });
28
28
  }
29
29
  exports.submitAsync = submitAsync;
30
- async function waitToCompleteAsync(submissions, { verbose = false } = {}) {
30
+ async function waitToCompleteAsync(graphqlClient, submissions, { verbose = false } = {}) {
31
31
  log_1.default.newLine();
32
- const completedSubmissions = await (0, wait_1.waitForSubmissionsEndAsync)(submissions);
32
+ const completedSubmissions = await (0, wait_1.waitForSubmissionsEndAsync)(graphqlClient, submissions);
33
33
  const moreSubmissions = completedSubmissions.length > 1;
34
34
  if (moreSubmissions) {
35
35
  log_1.default.newLine();
@@ -1,4 +1,5 @@
1
+ import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
1
2
  import { AppPlatform, BuildFragment } from '../../graphql/generated';
2
- export declare function getRecentBuildsForSubmissionAsync(platform: AppPlatform, appId: string, { limit }?: {
3
+ export declare function getRecentBuildsForSubmissionAsync(graphqlClient: ExpoGraphqlClient, platform: AppPlatform, appId: string, { limit }?: {
3
4
  limit?: number;
4
5
  }): Promise<BuildFragment[]>;
@@ -3,8 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getRecentBuildsForSubmissionAsync = void 0;
4
4
  const generated_1 = require("../../graphql/generated");
5
5
  const BuildQuery_1 = require("../../graphql/queries/BuildQuery");
6
- async function getRecentBuildsForSubmissionAsync(platform, appId, { limit = 1 } = {}) {
7
- return await BuildQuery_1.BuildQuery.viewBuildsOnAppAsync({
6
+ async function getRecentBuildsForSubmissionAsync(graphqlClient, platform, appId, { limit = 1 } = {}) {
7
+ return await BuildQuery_1.BuildQuery.viewBuildsOnAppAsync(graphqlClient, {
8
8
  appId,
9
9
  limit,
10
10
  offset: 0,
@@ -14,9 +14,13 @@ var SubmissionErrorCode;
14
14
  SubmissionErrorCode["ANDROID_FIRST_UPLOAD_ERROR"] = "SUBMISSION_SERVICE_ANDROID_FIRST_UPLOAD_ERROR";
15
15
  SubmissionErrorCode["ANDROID_OLD_VERSION_CODE_ERROR"] = "SUBMISSION_SERVICE_ANDROID_OLD_VERSION_CODE_ERROR";
16
16
  SubmissionErrorCode["ANDROID_MISSING_PRIVACY_POLICY"] = "SUBMISSION_SERVICE_ANDROID_MISSING_PRIVACY_POLICY";
17
- SubmissionErrorCode["IOS_OLD_VERSION_CODE_ERROR"] = "SUBMISSION_SERVICE_IOS_OLD_VERSION_CODE_ERROR";
17
+ SubmissionErrorCode["IOS_OLD_APP_VERSION"] = "SUBMISSION_SERVICE_IOS_OLD_APP_VERSION";
18
+ SubmissionErrorCode["IOS_OLD_BUILD_NUMBER"] = "SUBMISSION_SERVICE_IOS_OLD_BUILD_NUMBER";
19
+ SubmissionErrorCode["IOS_INVALID_APP_VERSION_NUMBER"] = "SUBMISSION_SERVICE_IOS_INVALID_APP_VERSION_NUMBER";
20
+ SubmissionErrorCode["IOS_INVALID_BUILD_NUMBER"] = "SUBMISSION_SERVICE_IOS_INVALID_BUILD_NUMBER";
18
21
  SubmissionErrorCode["IOS_UNKNOWN_ERROR"] = "SUBMISSION_SERVICE_IOS_UNKNOWN_ERROR";
19
22
  SubmissionErrorCode["IOS_MISSING_APP_ICON"] = "SUBMISSION_SERVICE_IOS_MISSING_APP_ICON";
23
+ SubmissionErrorCode["IOS_TRANSPARENT_APP_ICON"] = "SUBMISSION_SERVICE_IOS_TRANSPARENT_APP_ICON";
20
24
  SubmissionErrorCode["IOS_INVALID_SIGNATURE"] = "SUBMISSION_SERVICE_IOS_INVALID_SIGNATURE";
21
25
  SubmissionErrorCode["IOS_INCORRECT_CREDENTIALS"] = "SUBMISSION_SERVICE_IOS_INVALID_CREDENTIALS";
22
26
  SubmissionErrorCode["IOS_IPAD_INVALID_ORIENTATION"] = "SUBMISSION_SERVICE_IOS_IPAD_INVALID_ORIENTATION";
@@ -39,14 +43,26 @@ const SubmissionErrorMessages = {
39
43
  `${(0, log_1.learnMore)('https://expo.fyi/bumping-android-version-code')}.`,
40
44
  [SubmissionErrorCode.ANDROID_MISSING_PRIVACY_POLICY]: 'The app has permissions that require a privacy policy set for the app.\n' +
41
45
  `${(0, log_1.learnMore)('https://expo.fyi/missing-privacy-policy')}.`,
42
- [SubmissionErrorCode.IOS_OLD_VERSION_CODE_ERROR]: "You've already submitted this version of the app.\n" +
43
- 'Versions are identified by Build Numbers (expo.ios.buildNumber in app.json).\n' +
44
- "If you're submitting an Expo project built with EAS Build, increment the build number in app.json and build the project again.\n" +
46
+ [SubmissionErrorCode.IOS_OLD_APP_VERSION]: "You've already submitted this version of the app.\n" +
47
+ 'Versions are identified by CFBundleShortVersionString from Info.plist (expo.version in app.json).\n' +
48
+ "If you're submitting an Expo project built with EAS Build, increment the version (expo.version) in app.json and build the project again.",
49
+ [SubmissionErrorCode.IOS_OLD_BUILD_NUMBER]: "You've already submitted this build of the app.\n" +
50
+ 'Builds are identified by CFBundleVersion from Info.plist (expo.ios.buildNumber in app.json).\n' +
51
+ "If you're submitting an Expo project built with EAS Build, increment the build number (expo.ios.buildNumber) in app.json and build the project again.\n" +
45
52
  `${(0, log_1.learnMore)('https://expo.fyi/bumping-ios-build-number')}.`,
53
+ [SubmissionErrorCode.IOS_INVALID_APP_VERSION_NUMBER]: 'Invalid app version number.\n' +
54
+ 'Versions are identified by CFBundleShortVersionString from Info.plist (expo.version in app.json).\n' +
55
+ "If you're submitting an Expo project built with EAS Build, fix the version (expo.version) in app.json and build the project again.\n" +
56
+ `${(0, log_1.learnMore)('https://developer.apple.com/documentation/bundleresources/information_property_list/cfbundleshortversionstring')}.`,
57
+ [SubmissionErrorCode.IOS_INVALID_BUILD_NUMBER]: 'Invalid build number.\n' +
58
+ 'Builds are identified by CFBundleVersion from Info.plist (expo.ios.buildNumber in app.json).\n' +
59
+ "If you're submitting an Expo project built with EAS Build, fix the build number (expo.ios.buildNumber) in app.json and build the project again.\n" +
60
+ `${(0, log_1.learnMore)('https://developer.apple.com/documentation/bundleresources/information_property_list/cfbundleversion')}.`,
46
61
  [SubmissionErrorCode.IOS_UNKNOWN_ERROR]: "We couldn't figure out what went wrong. See logs to learn more.",
47
62
  [SubmissionErrorCode.IOS_MISSING_APP_ICON]: 'Your iOS app icon is missing or is an invalid format. The icon must be a 1024x1024 PNG image with no transparency.\n' +
48
63
  'Check your icon image and icon configuration in app.json.\n' +
49
64
  `${(0, log_1.learnMore)('https://docs.expo.dev/guides/app-icons/')}`,
65
+ [SubmissionErrorCode.IOS_TRANSPARENT_APP_ICON]: `Invalid App Store Icon. The App Store Icon can't be transparent nor contain an alpha channel.`,
50
66
  [SubmissionErrorCode.IOS_INVALID_SIGNATURE]: 'Your app signature seems to be invalid.\n' +
51
67
  "Check your iOS Distribution Certificate and your app's Provisioning Profile.\n" +
52
68
  `${(0, log_1.learnMore)('https://docs.expo.dev/distribution/app-signing')}`,
@@ -1,2 +1,3 @@
1
+ import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
1
2
  export declare function isExistingFileAsync(filePath: string): Promise<boolean>;
2
- export declare function uploadAppArchiveAsync(path: string): Promise<string>;
3
+ export declare function uploadAppArchiveAsync(graphqlClient: ExpoGraphqlClient, path: string): Promise<string>;
@@ -16,9 +16,9 @@ async function isExistingFileAsync(filePath) {
16
16
  }
17
17
  }
18
18
  exports.isExistingFileAsync = isExistingFileAsync;
19
- async function uploadAppArchiveAsync(path) {
19
+ async function uploadAppArchiveAsync(graphqlClient, path) {
20
20
  const fileSize = (await fs_extra_1.default.stat(path)).size;
21
- const { url } = await (0, uploads_1.uploadFileAtPathToS3Async)(generated_1.UploadSessionType.EasSubmitAppArchive, path, (0, progress_1.createProgressTracker)({
21
+ const { url } = await (0, uploads_1.uploadFileAtPathToS3Async)(graphqlClient, generated_1.UploadSessionType.EasSubmitAppArchive, path, (0, progress_1.createProgressTracker)({
22
22
  total: fileSize,
23
23
  message: 'Uploading to EAS Submit',
24
24
  completedMessage: 'Uploaded to EAS Submit',
@@ -1,2 +1,3 @@
1
+ import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
1
2
  import { SubmissionFragment } from '../../graphql/generated';
2
- export declare function waitForSubmissionsEndAsync(initialSubmissions: SubmissionFragment[]): Promise<SubmissionFragment[]>;
3
+ export declare function waitForSubmissionsEndAsync(graphqlClient: ExpoGraphqlClient, initialSubmissions: SubmissionFragment[]): Promise<SubmissionFragment[]>;
@@ -13,13 +13,13 @@ const APP_STORE_NAMES = {
13
13
  [generated_1.AppPlatform.Ios]: 'Apple App Store Connect',
14
14
  };
15
15
  const CHECK_INTERVAL_MS = 5000;
16
- async function waitForSubmissionsEndAsync(initialSubmissions) {
16
+ async function waitForSubmissionsEndAsync(graphqlClient, initialSubmissions) {
17
17
  log_1.default.log(`Waiting for submission${initialSubmissions.length > 1 ? 's' : ''} to complete. You can press Ctrl+C to exit.`);
18
18
  const spinner = (0, ora_1.ora)(`Submitting`).start();
19
19
  while (true) {
20
20
  const submissions = await Promise.all(initialSubmissions.map(({ id }) => {
21
21
  try {
22
- return SubmissionQuery_1.SubmissionQuery.byIdAsync(id, { useCache: false });
22
+ return SubmissionQuery_1.SubmissionQuery.byIdAsync(graphqlClient, id, { useCache: false });
23
23
  }
24
24
  catch (err) {
25
25
  log_1.default.debug('Failed to fetch the submission status', err);
@@ -1,4 +1,5 @@
1
1
  import { ExpoConfig } from '@expo/config';
2
- export declare function syncUpdatesConfigurationAsync(projectDir: string, exp: ExpoConfig, projectId: string): Promise<void>;
2
+ import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
3
+ export declare function syncUpdatesConfigurationAsync(graphqlClient: ExpoGraphqlClient, projectDir: string, exp: ExpoConfig, projectId: string): Promise<void>;
3
4
  export declare function readReleaseChannelSafelyAsync(projectDir: string): Promise<string | null>;
4
5
  export declare function readChannelSafelyAsync(projectDir: string): Promise<string | null>;
@@ -5,9 +5,9 @@ const config_plugins_1 = require("@expo/config-plugins");
5
5
  const platform_1 = require("../../platform");
6
6
  const projectUtils_1 = require("../../project/projectUtils");
7
7
  const utils_1 = require("../utils");
8
- async function syncUpdatesConfigurationAsync(projectDir, exp, projectId) {
8
+ async function syncUpdatesConfigurationAsync(graphqlClient, projectDir, exp, projectId) {
9
9
  (0, utils_1.ensureValidVersions)(exp, platform_1.RequestedPlatform.Android);
10
- const accountName = (await (0, projectUtils_1.getOwnerAccountForProjectIdAsync)(projectId)).name;
10
+ const accountName = (await (0, projectUtils_1.getOwnerAccountForProjectIdAsync)(graphqlClient, projectId)).name;
11
11
  const androidManifestPath = await config_plugins_1.AndroidConfig.Paths.getAndroidManifestAsync(projectDir);
12
12
  const androidManifest = await getAndroidManifestAsync(projectDir);
13
13
  const updatedAndroidManifest = config_plugins_1.AndroidConfig.Updates.setUpdatesConfig(projectDir, exp, androidManifest, accountName);
@@ -1,4 +1,5 @@
1
1
  import { ExpoConfig } from '@expo/config';
2
- export declare function syncUpdatesConfigurationAsync(projectDir: string, exp: ExpoConfig, projectId: string): Promise<void>;
2
+ import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
3
+ export declare function syncUpdatesConfigurationAsync(graphqlClient: ExpoGraphqlClient, projectDir: string, exp: ExpoConfig, projectId: string): Promise<void>;
3
4
  export declare function readReleaseChannelSafelyAsync(projectDir: string): Promise<string | null>;
4
5
  export declare function readChannelSafelyAsync(projectDir: string): Promise<string | null>;
@@ -7,9 +7,9 @@ const projectUtils_1 = require("../../project/projectUtils");
7
7
  const plist_1 = require("../../utils/plist");
8
8
  const vcs_1 = require("../../vcs");
9
9
  const utils_1 = require("../utils");
10
- async function syncUpdatesConfigurationAsync(projectDir, exp, projectId) {
10
+ async function syncUpdatesConfigurationAsync(graphqlClient, projectDir, exp, projectId) {
11
11
  (0, utils_1.ensureValidVersions)(exp, platform_1.RequestedPlatform.Ios);
12
- const accountName = (await (0, projectUtils_1.getOwnerAccountForProjectIdAsync)(projectId)).name;
12
+ const accountName = (await (0, projectUtils_1.getOwnerAccountForProjectIdAsync)(graphqlClient, projectId)).name;
13
13
  const expoPlist = await readExpoPlistAsync(projectDir);
14
14
  const updatedExpoPlist = config_plugins_1.IOSConfig.Updates.setUpdatesConfig(projectDir, exp, expoPlist, accountName);
15
15
  await writeExpoPlistAsync(projectDir, updatedExpoPlist);
@@ -1,17 +1,18 @@
1
+ import { ExpoGraphqlClient } from '../commandUtils/context/contextUtils/createGraphqlClient';
1
2
  import { PaginatedQueryOptions } from '../commandUtils/pagination';
2
3
  import { UpdateFragment } from '../graphql/generated';
3
4
  export declare const UPDATES_LIMIT = 50;
4
5
  export declare const UPDATE_GROUPS_LIMIT = 25;
5
- export declare function listAndRenderUpdateGroupsOnAppAsync({ projectId, paginatedQueryOptions, }: {
6
+ export declare function listAndRenderUpdateGroupsOnAppAsync(graphqlClient: ExpoGraphqlClient, { projectId, paginatedQueryOptions, }: {
6
7
  projectId: string;
7
8
  paginatedQueryOptions: PaginatedQueryOptions;
8
9
  }): Promise<void>;
9
- export declare function listAndRenderUpdateGroupsOnBranchAsync({ projectId, branchName, paginatedQueryOptions, }: {
10
+ export declare function listAndRenderUpdateGroupsOnBranchAsync(graphqlClient: ExpoGraphqlClient, { projectId, branchName, paginatedQueryOptions, }: {
10
11
  projectId: string;
11
12
  branchName: string;
12
13
  paginatedQueryOptions: PaginatedQueryOptions;
13
14
  }): Promise<void>;
14
- export declare function selectUpdateGroupOnBranchAsync({ projectId, branchName, paginatedQueryOptions, }: {
15
+ export declare function selectUpdateGroupOnBranchAsync(graphqlClient: ExpoGraphqlClient, { projectId, branchName, paginatedQueryOptions, }: {
15
16
  projectId: string;
16
17
  branchName: string;
17
18
  paginatedQueryOptions: PaginatedQueryOptions;
@@ -13,10 +13,10 @@ const queries_1 = require("../utils/queries");
13
13
  const utils_1 = require("./utils");
14
14
  exports.UPDATES_LIMIT = 50;
15
15
  exports.UPDATE_GROUPS_LIMIT = 25;
16
- async function listAndRenderUpdateGroupsOnAppAsync({ projectId, paginatedQueryOptions, }) {
16
+ async function listAndRenderUpdateGroupsOnAppAsync(graphqlClient, { projectId, paginatedQueryOptions, }) {
17
17
  var _a, _b;
18
18
  if (paginatedQueryOptions.nonInteractive) {
19
- const updateGroups = await queryUpdateGroupsOnAppAsync({
19
+ const updateGroups = await queryUpdateGroupsOnAppAsync(graphqlClient, {
20
20
  limit: (_a = paginatedQueryOptions.limit) !== null && _a !== void 0 ? _a : exports.UPDATE_GROUPS_LIMIT,
21
21
  offset: paginatedQueryOptions.offset,
22
22
  appId: projectId,
@@ -27,7 +27,7 @@ async function listAndRenderUpdateGroupsOnAppAsync({ projectId, paginatedQueryOp
27
27
  await (0, queries_1.paginatedQueryWithConfirmPromptAsync)({
28
28
  limit: (_b = paginatedQueryOptions.limit) !== null && _b !== void 0 ? _b : exports.UPDATE_GROUPS_LIMIT,
29
29
  offset: paginatedQueryOptions.offset,
30
- queryToPerform: (limit, offset) => queryUpdateGroupsOnAppAsync({ limit, offset, appId: projectId }),
30
+ queryToPerform: (limit, offset) => queryUpdateGroupsOnAppAsync(graphqlClient, { limit, offset, appId: projectId }),
31
31
  promptOptions: {
32
32
  title: 'Load more update groups?',
33
33
  renderListItems: updateGroups => renderUpdateGroupsOnAppAsTable(updateGroups, paginatedQueryOptions),
@@ -36,10 +36,10 @@ async function listAndRenderUpdateGroupsOnAppAsync({ projectId, paginatedQueryOp
36
36
  }
37
37
  }
38
38
  exports.listAndRenderUpdateGroupsOnAppAsync = listAndRenderUpdateGroupsOnAppAsync;
39
- async function listAndRenderUpdateGroupsOnBranchAsync({ projectId, branchName, paginatedQueryOptions, }) {
39
+ async function listAndRenderUpdateGroupsOnBranchAsync(graphqlClient, { projectId, branchName, paginatedQueryOptions, }) {
40
40
  var _a, _b;
41
41
  if (paginatedQueryOptions.nonInteractive) {
42
- const updateGroups = await queryUpdateGroupsOnBranchAsync({
42
+ const updateGroups = await queryUpdateGroupsOnBranchAsync(graphqlClient, {
43
43
  limit: (_a = paginatedQueryOptions.limit) !== null && _a !== void 0 ? _a : exports.UPDATE_GROUPS_LIMIT,
44
44
  offset: paginatedQueryOptions.offset,
45
45
  appId: projectId,
@@ -51,7 +51,12 @@ async function listAndRenderUpdateGroupsOnBranchAsync({ projectId, branchName, p
51
51
  await (0, queries_1.paginatedQueryWithConfirmPromptAsync)({
52
52
  limit: (_b = paginatedQueryOptions.limit) !== null && _b !== void 0 ? _b : exports.UPDATE_GROUPS_LIMIT,
53
53
  offset: paginatedQueryOptions.offset,
54
- queryToPerform: (limit, offset) => queryUpdateGroupsOnBranchAsync({ limit, offset, appId: projectId, branchName }),
54
+ queryToPerform: (limit, offset) => queryUpdateGroupsOnBranchAsync(graphqlClient, {
55
+ limit,
56
+ offset,
57
+ appId: projectId,
58
+ branchName,
59
+ }),
55
60
  promptOptions: {
56
61
  title: 'Load more update groups?',
57
62
  renderListItems: updateGroups => renderUpdateGroupsOnBranchAsTable({ updateGroups, branchName, paginatedQueryOptions }),
@@ -60,7 +65,7 @@ async function listAndRenderUpdateGroupsOnBranchAsync({ projectId, branchName, p
60
65
  }
61
66
  }
62
67
  exports.listAndRenderUpdateGroupsOnBranchAsync = listAndRenderUpdateGroupsOnBranchAsync;
63
- async function selectUpdateGroupOnBranchAsync({ projectId, branchName, paginatedQueryOptions, }) {
68
+ async function selectUpdateGroupOnBranchAsync(graphqlClient, { projectId, branchName, paginatedQueryOptions, }) {
64
69
  var _a;
65
70
  if (paginatedQueryOptions.nonInteractive) {
66
71
  throw new Error('Unable to select an update in non-interactive mode.');
@@ -68,7 +73,12 @@ async function selectUpdateGroupOnBranchAsync({ projectId, branchName, paginated
68
73
  const updateGroup = await (0, queries_1.paginatedQueryWithSelectPromptAsync)({
69
74
  limit: (_a = paginatedQueryOptions.limit) !== null && _a !== void 0 ? _a : exports.UPDATE_GROUPS_LIMIT,
70
75
  offset: paginatedQueryOptions.offset,
71
- queryToPerform: (limit, offset) => queryUpdateGroupsOnBranchAsync({ appId: projectId, branchName, limit, offset }),
76
+ queryToPerform: (limit, offset) => queryUpdateGroupsOnBranchAsync(graphqlClient, {
77
+ appId: projectId,
78
+ branchName,
79
+ limit,
80
+ offset,
81
+ }),
72
82
  promptOptions: {
73
83
  title: 'Load more update groups?',
74
84
  createDisplayTextForSelectionPromptListItem: updateGroup => (0, utils_1.formatUpdateTitle)(updateGroup[0]),
@@ -81,11 +91,11 @@ async function selectUpdateGroupOnBranchAsync({ projectId, branchName, paginated
81
91
  return updateGroup;
82
92
  }
83
93
  exports.selectUpdateGroupOnBranchAsync = selectUpdateGroupOnBranchAsync;
84
- async function queryUpdateGroupsOnBranchAsync(args) {
85
- return await UpdateQuery_1.UpdateQuery.viewUpdateGroupsOnBranchAsync(args);
94
+ async function queryUpdateGroupsOnBranchAsync(graphqlClient, args) {
95
+ return await UpdateQuery_1.UpdateQuery.viewUpdateGroupsOnBranchAsync(graphqlClient, args);
86
96
  }
87
- async function queryUpdateGroupsOnAppAsync(args) {
88
- return await UpdateQuery_1.UpdateQuery.viewUpdateGroupsOnAppAsync(args);
97
+ async function queryUpdateGroupsOnAppAsync(graphqlClient, args) {
98
+ return await UpdateQuery_1.UpdateQuery.viewUpdateGroupsOnAppAsync(graphqlClient, args);
89
99
  }
90
100
  function renderUpdateGroupsOnBranchAsTable({ updateGroups, branchName, paginatedQueryOptions: { json }, }) {
91
101
  var _a, _b;
@@ -1,8 +1,9 @@
1
1
  import { Response } from 'node-fetch';
2
+ import { ExpoGraphqlClient } from './commandUtils/context/contextUtils/createGraphqlClient';
2
3
  import { UploadSessionType } from './graphql/generated';
3
4
  import { PresignedPost } from './graphql/mutations/UploadSessionMutation';
4
5
  import { ProgressHandler } from './utils/progress';
5
- export declare function uploadFileAtPathToS3Async(type: UploadSessionType, path: string, handleProgressEvent: ProgressHandler): Promise<{
6
+ export declare function uploadFileAtPathToS3Async(graphqlClient: ExpoGraphqlClient, type: UploadSessionType, path: string, handleProgressEvent: ProgressHandler): Promise<{
6
7
  url: string;
7
8
  bucketKey: string;
8
9
  }>;
package/build/uploads.js CHANGED
@@ -10,8 +10,8 @@ const promise_retry_1 = tslib_1.__importDefault(require("promise-retry"));
10
10
  const url_1 = require("url");
11
11
  const fetch_1 = tslib_1.__importDefault(require("./fetch"));
12
12
  const UploadSessionMutation_1 = require("./graphql/mutations/UploadSessionMutation");
13
- async function uploadFileAtPathToS3Async(type, path, handleProgressEvent) {
14
- const presignedPost = await UploadSessionMutation_1.UploadSessionMutation.createUploadSessionAsync(type);
13
+ async function uploadFileAtPathToS3Async(graphqlClient, type, path, handleProgressEvent) {
14
+ const presignedPost = await UploadSessionMutation_1.UploadSessionMutation.createUploadSessionAsync(graphqlClient, type);
15
15
  (0, assert_1.default)(presignedPost.fields.key, 'key is not specified in in presigned post');
16
16
  const response = await uploadWithPresignedPostWithProgressAsync(path, presignedPost, handleProgressEvent);
17
17
  const location = (0, nullthrows_1.default)(response.headers.get('location'), `location does not exist in response headers (make sure you're uploading to AWS S3)`);