@expo/build-tools 1.0.170 → 1.0.172
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.
- package/dist/buildErrors/userErrorHandlers.js +3 -3
- package/dist/buildErrors/userErrorHandlers.js.map +1 -1
- package/dist/common/setup.js +2 -5
- package/dist/common/setup.js.map +1 -1
- package/dist/steps/utils/expoUpdates.js +1 -1
- package/dist/steps/utils/expoUpdates.js.map +1 -1
- package/package.json +4 -4
|
@@ -48,7 +48,7 @@ exports.userErrorHandlers = [
|
|
|
48
48
|
// [11:17:29] [android.dangerous]: withAndroidDangerousBaseMod: Cannot copy google-services.json from /home/expo/workingdir/build/test/test-google-services.json to /home/expo/workingdir/build/android/app/google-services.json. Please make sure the source and destination paths exist.
|
|
49
49
|
// [11:17:29] Error: [android.dangerous]: withAndroidDangerousBaseMod: Cannot copy google-services.json from /home/expo/workingdir/build/test/test-google-services.json to /home/expo/workingdir/build/android/app/google-services.json. Please make sure the source and destination paths exist.
|
|
50
50
|
regexp: /Cannot copy google-services\.json/,
|
|
51
|
-
createError: () => new UserFacingError('EAS_BUILD_MISSING_GOOGLE_SERVICES_JSON_ERROR', '"google-services.json" is missing, make sure that the file exists. Remember that EAS Build only uploads the files tracked by git. Use EAS
|
|
51
|
+
createError: () => new UserFacingError('EAS_BUILD_MISSING_GOOGLE_SERVICES_JSON_ERROR', '"google-services.json" is missing, make sure that the file exists. Remember that EAS Build only uploads the files tracked by git. Use EAS environment variables to provide EAS Build with the file.', 'https://docs.expo.dev/eas/environment-variables/#file-environment-variables'),
|
|
52
52
|
},
|
|
53
53
|
{
|
|
54
54
|
platform: eas_build_job_1.Platform.ANDROID,
|
|
@@ -57,7 +57,7 @@ exports.userErrorHandlers = [
|
|
|
57
57
|
// > File google-services.json is missing. The Google Services Plugin cannot function without it.
|
|
58
58
|
// Searched Location:
|
|
59
59
|
regexp: /File google-services\.json is missing\. The Google Services Plugin cannot function without it/,
|
|
60
|
-
createError: () => new UserFacingError('EAS_BUILD_MISSING_GOOGLE_SERVICES_JSON_ERROR', '"google-services.json" is missing, make sure that the file exists. Remember that EAS Build only uploads the files tracked by git. Use EAS
|
|
60
|
+
createError: () => new UserFacingError('EAS_BUILD_MISSING_GOOGLE_SERVICES_JSON_ERROR', '"google-services.json" is missing, make sure that the file exists. Remember that EAS Build only uploads the files tracked by git. Use EAS environment variables to provide EAS Build with the file.', 'https://docs.expo.dev/eas/environment-variables/#file-environment-variables'),
|
|
61
61
|
},
|
|
62
62
|
{
|
|
63
63
|
platform: eas_build_job_1.Platform.IOS,
|
|
@@ -65,7 +65,7 @@ exports.userErrorHandlers = [
|
|
|
65
65
|
// example log:
|
|
66
66
|
// [08:44:18] ENOENT: no such file or directory, copyfile '/Users/expo/workingdir/build/managed/abc' -> '/Users/expo/workingdir/build/managed/ios/testapp/GoogleService-Info.plist'
|
|
67
67
|
regexp: /ENOENT: no such file or directory, copyfile .*GoogleService-Info.plist/,
|
|
68
|
-
createError: () => new UserFacingError('EAS_BUILD_MISSING_GOOGLE_SERVICES_PLIST_ERROR', '"GoogleService-Info.plist" is missing, make sure that the file exists. Remember that EAS Build only uploads the files tracked by git. Use EAS
|
|
68
|
+
createError: () => new UserFacingError('EAS_BUILD_MISSING_GOOGLE_SERVICES_PLIST_ERROR', '"GoogleService-Info.plist" is missing, make sure that the file exists. Remember that EAS Build only uploads the files tracked by git. Use EAS environment variables to provide EAS Build with the file.', 'https://docs.expo.dev/eas/environment-variables/#file-environment-variables'),
|
|
69
69
|
},
|
|
70
70
|
{
|
|
71
71
|
platform: eas_build_job_1.Platform.IOS,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"userErrorHandlers.js","sourceRoot":"","sources":["../../src/buildErrors/userErrorHandlers.ts"],"names":[],"mappings":";;;AAAA,uDAAwF;AAExF,iDAAiE;AAEjE,IAAO,eAAe,GAAG,sBAAM,CAAC,eAAe,CAAC;AAEnC,QAAA,iBAAiB,GAAoC;IAChE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ACJ;IACD;QACE,QAAQ,EAAE,wBAAQ,CAAC,GAAG;QACtB,KAAK,EAAE,gCAAiB;QACxB,wNAAwN;QACxN,oEAAoE;QACpE,8JAA8J;QAC9J,sRAAsR;QACtR,+DAA+D;QAC/D,gTAAgT;QAChT,mMAAmM;QACnM,gDAAgD;QAChD,yJAAyJ;QACzJ,kNAAkN;QAClN,iMAAiM;QACjM,MAAM,EAAE,YAAY;QACpB,WAAW,EAAE,CAAC,WAAW,EAAE,EAAE,CAC3B,IAAI,eAAe,CACjB,mBAAmB,EACnB,wJAAwJ,WAAW;aAChK,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,KAAK,CAAC,OAAO,CAAC,SAAS,EAAE,EAAE,CAAC,EAAE,CAAC;aACnD,IAAI,CAAC,IAAI,CAAC,mEAAmE,CACjF;KACJ;IACD;QACE,QAAQ,EAAE,wBAAQ,CAAC,GAAG;QACtB,KAAK,EAAE,0BAAU,CAAC,YAAY;QAC9B,MAAM,EAAE,IAAI;QACZ,WAAW,EAAE,GAAG,EAAE,CAChB,IAAI,eAAe,CACjB,sBAAM,CAAC,SAAS,CAAC,sBAAsB,EACvC,uHAAuH,CACxH;KACJ;CACF,CAAC","sourcesContent":["import { BuildMode, BuildPhase, errors, Platform, Workflow } from '@expo/eas-build-job';\n\nimport { ErrorHandler, XCODE_BUILD_PHASE } from './errors.types';\n\nimport UserFacingError = errors.UserFacingError;\n\nexport const userErrorHandlers: ErrorHandler<UserFacingError>[] = [\n {\n platform: Platform.IOS,\n phase: BuildPhase.INSTALL_PODS,\n regexp: /requires CocoaPods version/,\n // example log:\n // [!] `React` requires CocoaPods version `>= 1.10.1`, which is not satisfied by your current version, `1.10.0`.\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_UNSUPPORTED_COCOAPODS_VERSION_ERROR',\n `Your project requires a newer version of CocoaPods. You can update it in the build profile in eas.json by either:\n- changing the current version under key \"cocoapods\"\n- switching to an image that supports that version under key \"image\"`,\n 'https://docs.expo.dev/build-reference/eas-json/'\n ),\n },\n {\n platform: Platform.IOS,\n phase: BuildPhase.RUN_FASTLANE,\n regexp: /Could not find 'bundler' (.*) required by your/,\n // example log:\n // /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/dependency.rb:313:in `to_specs': Could not find 'bundler' (2.2.3) required by your /Users/expo/project/build/ios/Gemfile.lock. (Gem::MissingSpecVersionError)\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_UNSUPPORTED_BUNDLER_VERSION_ERROR',\n `Your project requires a different version of the Ruby \"bundler\" program than the version installed in this EAS Build environment. You can specify which version of \"bundler\" to install by specifying the version under \"build\"→[buildProfileName]→\"ios\"→\"bundler\" in eas.json.`,\n 'https://docs.expo.dev/build-reference/eas-json/'\n ),\n },\n {\n platform: Platform.ANDROID,\n phase: BuildPhase.RUN_GRADLEW,\n // example log:\n // > Failed to read key keyalias from store \"/build/workingdir/build/generic/keystore-5787e6af-3002-4cb7-8a57-3e73d13313c2.jks\": Invalid keystore format\n regexp: /Invalid keystore format/,\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_INVALID_KEYSTORE_FORMAT_ERROR',\n 'The keystore used in this build is malformed or it has an unsupported type. Make sure you provided the correct file.'\n ),\n },\n {\n platform: Platform.ANDROID,\n phase: BuildPhase.RUN_GRADLEW,\n // example log:\n // > Failed to read key keyalias from store \"/build/workingdir/build/generic/keystore-286069a8-4bb9-48a6-add9-acf6b58ea06d.jks\": null\n regexp: /Failed to read key[^\\n]+from store/,\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_INVALID_KEYSTORE_ALIAS_ERROR',\n 'The alias specified for this keystore does not exist. Make sure you specified the correct value.'\n ),\n },\n {\n platform: Platform.ANDROID,\n phase: BuildPhase.PREBUILD,\n // example log:\n // [15:42:05] Error: Cannot copy google-services.json from /build/workingdir/build/managed/abc to /build/workingdir/build/managed/android/app/google-services.json\n // or\n // [11:17:29] [android.dangerous]: withAndroidDangerousBaseMod: Cannot copy google-services.json from /home/expo/workingdir/build/test/test-google-services.json to /home/expo/workingdir/build/android/app/google-services.json. Please make sure the source and destination paths exist.\n // [11:17:29] Error: [android.dangerous]: withAndroidDangerousBaseMod: Cannot copy google-services.json from /home/expo/workingdir/build/test/test-google-services.json to /home/expo/workingdir/build/android/app/google-services.json. Please make sure the source and destination paths exist.\n regexp: /Cannot copy google-services\\.json/,\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_MISSING_GOOGLE_SERVICES_JSON_ERROR',\n '\"google-services.json\" is missing, make sure that the file exists. Remember that EAS Build only uploads the files tracked by git. Use EAS secrets to provide EAS Build with the file.',\n 'https://docs.expo.dev/build-reference/variables/#how-to-upload-a-secret-file-and'\n ),\n },\n {\n platform: Platform.ANDROID,\n phase: BuildPhase.RUN_GRADLEW,\n // Execution failed for task ':app:processReleaseGoogleServices'.\n // > File google-services.json is missing. The Google Services Plugin cannot function without it.\n // Searched Location:\n regexp:\n /File google-services\\.json is missing\\. The Google Services Plugin cannot function without it/,\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_MISSING_GOOGLE_SERVICES_JSON_ERROR',\n '\"google-services.json\" is missing, make sure that the file exists. Remember that EAS Build only uploads the files tracked by git. Use EAS secrets to provide EAS Build with the file.',\n 'https://docs.expo.dev/build-reference/variables/#how-to-upload-a-secret-file-and'\n ),\n },\n {\n platform: Platform.IOS,\n phase: BuildPhase.PREBUILD,\n // example log:\n // [08:44:18] ENOENT: no such file or directory, copyfile '/Users/expo/workingdir/build/managed/abc' -> '/Users/expo/workingdir/build/managed/ios/testapp/GoogleService-Info.plist'\n regexp: /ENOENT: no such file or directory, copyfile .*GoogleService-Info.plist/,\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_MISSING_GOOGLE_SERVICES_PLIST_ERROR',\n '\"GoogleService-Info.plist\" is missing, make sure that the file exists. Remember that EAS Build only uploads the files tracked by git. Use EAS secrets to provide EAS Build with the file.',\n 'https://docs.expo.dev/build-reference/variables/#how-to-upload-a-secret-file-and'\n ),\n },\n {\n platform: Platform.IOS,\n phase: BuildPhase.INSTALL_PODS,\n // example log:\n // [!] CocoaPods could not find compatible versions for pod \"react-native-google-maps\"\n // In Podfile:\n // react-native-google-maps (from `/Users/expo/workingdir/build/node_modules/react-native-maps`)\n // Specs satisfying the `react-native-google-maps (from `/Users/expo/workingdir/build/node_modules/react-native-maps`)` dependency were found, but they required a higher minimum deployment target.\n // Error: Compatible versions of some pods could not be resolved.\n regexp:\n /Specs satisfying the `(.*)` dependency were found, but they required a higher minimum deployment target/,\n createError: (_, { job }) => {\n return new UserFacingError(\n 'EAS_BUILD_HIGHER_MINIMUM_DEPLOYMENT_TARGET_ERROR',\n `Some pods require a higher minimum deployment target.\n${\n 'type' in job && job.type === Workflow.MANAGED\n ? 'You can use the expo-build-properties config plugin (https://docs.expo.dev/versions/latest/sdk/build-properties/) to override the default native build properties and set a different minimum deployment target.'\n : 'You need to manually update the minimum deployment target in your project to resolve this issue.'\n}\n`\n );\n },\n },\n {\n platform: Platform.IOS,\n phase: BuildPhase.INSTALL_PODS,\n // example log:\n // [!] CocoaPods could not find compatible versions for pod \"Firebase/Core\":\n // In snapshot (Podfile.lock):\n // Firebase/Core (= 6.14.0)\n // In Podfile:\n // EXFirebaseCore (from `../node_modules/expo-firebase-core/ios`) was resolved to 3.0.0, which depends on\n // Firebase/Core (= 7.7.0)\n // You have either:\n // * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.\n // * changed the constraints of dependency `Firebase/Core` inside your development pod `EXFirebaseCore`.\n // You should run `pod update Firebase/Core` to apply changes you've made.\n regexp: /CocoaPods could not find compatible versions for pod /,\n createError: () => {\n return new UserFacingError(\n 'EAS_BUILD_INCOMPATIBLE_PODS_ERROR',\n `Compatible versions of some pods could not be resolved.\nYou are seeing this error because either:\n - Some of the pods used in your project depend on different versions of the same pod. See logs for more information.\n - If you are caching Podfile.lock using \"cache\" field in eas.json, then versions there might not match required values in Podspecs of some installed libraries. To fix this, you can re-run build command with \"--clear-cache\" option, or select \"Clear cache and retry build\" on the build page.\n`\n );\n },\n },\n {\n phase: BuildPhase.INSTALL_DEPENDENCIES,\n // example log:\n // [stderr] npm ERR! Fix the upstream dependency conflict, or retry\n // [stderr] npm ERR! this command with --force, or --legacy-peer-deps\n // [stderr] npm ERR! to accept an incorrect (and potentially broken) dependency resolution.\n regexp:\n /Fix the upstream dependency conflict, or retry.*\\s.*this command with --force, or --legacy-peer-deps/,\n createError: (matchResult: RegExpMatchArray) => {\n if (matchResult.length >= 2) {\n return new UserFacingError(\n 'EAS_BUILD_NPM_CONFLICTING_PEER_DEPENDENCIES',\n `Some of your peer dependencies are not compatible. The recommended approach is to fix your dependencies by resolving any conflicts listed by \"npm install\". As a temporary workaround you can:\n- Add \".npmrc\" file with \"legacy-peer-deps=true\" and commit that to your repo.\n- Delete package-lock.json and use yarn instead. It does not enforce peer dependencies.\n- Downgrade to older version of npm on EAS Build, by adding \"npm install -g npm@version\" in \"eas-build-pre-install\" script in package.json.`\n );\n }\n return undefined;\n },\n },\n {\n phase: BuildPhase.INSTALL_DEPENDENCIES,\n // example log:\n // [stderr] error https://github.com/expo/react-native/archive/sdk-41.0.0.tar.gz: Integrity check failed for \"react-native\" (computed integrity doesn't match our records, got \"sha512-3jHI2YufrJi7eIABRf/DN/I2yOkmIZ0vAyezTz+PAUJiEs4v//5LLojWEU+W53AZsnuaEMcl/4fVy4bd+OuUbA== sha1-o9QuQTXIkc8VozXPaZIullB9a40=\")\n regexp: /Integrity check failed for \"(.*)\" \\(computed integrity doesn't match our records, got/,\n createError: (matchResult: RegExpMatchArray) => {\n if (matchResult.length >= 2) {\n return new UserFacingError(\n 'EAS_BUILD_YARN_LOCK_CHECKSUM_ERROR',\n `Checksum for package \"${matchResult[1]}\" does not match value in registry. To fix that:\n- run \"yarn cache clean\"\n- remove yarn.lock (or only the section for that package)\n- run \"yarn install --force\"`\n );\n }\n return undefined;\n },\n },\n {\n phase: BuildPhase.INSTALL_DEPENDENCIES,\n // example log:\n // yarn install v1.22.17\n // [1/4] Resolving packages...\n // [2/4] Fetching packages...\n // [1/4] Resolving packages...\n // [2/4] Fetching packages...\n // [stderr] error https://registry.yarnpkg.com/jest-util/-/jest-util-26.6.2.tgz: Extracting tar content of undefined failed, the file appears to be corrupt: \"ENOENT: no such file or directory, chmod '/Users/expo/Library/Caches/Yarn/v6/npm-jest-util-26.6.2-907535dbe4d5a6cb4c47ac9b926f6af29576cbc1-integrity/node_modules/jest-util/build/pluralize.d.ts'\"\n regexp:\n /\\[1\\/4\\] Resolving packages...\\s*\\[2\\/4\\] Fetching packages...\\s*\\[1\\/4\\] Resolving packages...\\s*\\[2\\/4\\] Fetching packages.../,\n createError: (matchResult: RegExpMatchArray) => {\n if (matchResult) {\n return new UserFacingError(\n 'EAS_BUILD_YARN_MULTIPLE_INSTANCES_ERROR',\n `One of project dependencies is starting new install process while the main one is still in progress, which might result in corrupted packages. Most likely the reason for error is \"prepare\" script in git-referenced dependency of your project. Learn more: https://github.com/yarnpkg/yarn/issues/7212#issuecomment-493720324`\n );\n }\n return undefined;\n },\n },\n {\n platform: Platform.IOS,\n phase: XCODE_BUILD_PHASE,\n // Prepare packages\n // Computing target dependency graph and provisioning inputs\n // Create build description\n // Build description signature: 33a5c28977280822abe5e7bd7fe02529\n // Build description path: /Users/expo/Library/Developer/Xcode/DerivedData/testapp-fazozgerxcvvfifkipojsjftgyih/Build/Intermediates.noindex/ArchiveIntermediates/testapp/IntermediateBuildFilesPath/XCBuildData/33a5c28977280822abe5e7bd7fe02529-desc.xcbuild\n // note: Building targets in dependency order\n // /Users/expo/workingdir/build/managed/ios/Pods/Pods.xcodeproj: error: Signing for \"EXConstants-EXConstants\" requires a development team. Select a development team in the Signing & Capabilities editor. (in target 'EXConstants-EXConstants' from project 'Pods')\n // /Users/expo/workingdir/build/managed/ios/Pods/Pods.xcodeproj: error: Signing for \"React-Core-AccessibilityResources\" requires a development team. Select a development team in the Signing & Capabilities editor. (in target 'React-Core-AccessibilityResources' from project 'Pods')\n // warning: Run script build phase '[CP-User] Generate app.manifest for expo-updates' will be run during every build because it does not specify any outputs. To address this warning, either add output dependencies to the script phase, or configure it to run in every build by unchecking \"Based on dependency analysis\" in the script phase. (in target 'EXUpdates' from project 'Pods')\n // warning: Run script build phase 'Start Packager' will be run during every build because it does not specify any outputs. To address this warning, either add output dependencies to the script phase, or configure it to run in every build by unchecking \"Based on dependency analysis\" in the script phase. (in target 'testapp' from project 'testapp')\n // warning: Run script build phase 'Bundle React Native code and images' will be run during every build because it does not specify any outputs. To address this warning, either add output dependencies to the script phase, or configure it to run in every build by unchecking \"Based on dependency analysis\" in the script phase. (in target 'testapp' from project 'testapp')\n // warning: Run script build phase '[CP-User] Generate app.config for prebuilt Constants.manifest' will be run during every build because it does not specify any outputs. To address this warning, either add output dependencies to the script phase, or configure it to run in every build by unchecking \"Based on dependency analysis\" in the script phase. (in target 'EXConstants' from project 'Pods')\n // /Users/expo/workingdir/build/managed/ios/Pods/Pods.xcodeproj: error: Signing for \"EXUpdates-EXUpdates\" requires a development team. Select a development team in the Signing & Capabilities editor. (in target 'EXUpdates-EXUpdates' from project 'Pods')\n regexp: /error: Signing for \"[a-zA-Z-0-9_]+\" requires a development team/,\n createError: (_, { job }) =>\n 'type' in job && job.type === Workflow.MANAGED\n ? new UserFacingError(\n 'XCODE_RESOURCE_BUNDLE_CODE_SIGNING_ERROR',\n `Starting from Xcode 14, resource bundles are signed by default, which requires setting the development team for each resource bundle target.\nTo resolve this issue, downgrade to an older Xcode version using the \"image\" field in eas.json, or upgrade to SDK 46 or higher.`,\n 'https://docs.expo.dev/build-reference/infrastructure/#ios-build-server-configurations'\n )\n : new UserFacingError(\n 'XCODE_RESOURCE_BUNDLE_CODE_SIGNING_ERROR',\n `Starting from Xcode 14, resource bundles are signed by default, which requires setting the development team for each resource bundle target.\nTo resolve this issue, downgrade to an older Xcode version using the \"image\" field in eas.json, or turn off signing resource bundles in your Podfile: https://expo.fyi/r/disable-bundle-resource-signing`,\n 'https://docs.expo.dev/build-reference/infrastructure/#ios-build-server-configurations'\n ),\n },\n {\n platform: Platform.ANDROID,\n phase: BuildPhase.RUN_GRADLEW,\n regexp: /.*/,\n createError: () =>\n new UserFacingError(\n errors.ErrorCode.UNKNOWN_GRADLE_ERROR,\n 'Gradle build failed with unknown error. See logs for the \"Run gradlew\" phase for more information.'\n ),\n },\n {\n platform: Platform.IOS,\n phase: BuildPhase.RUN_FASTLANE,\n mode: BuildMode.RESIGN,\n regexp: /No provisioning profile for application: '(.+)' with bundle identifier '(.+)'/,\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_RESIGN_PROVISIONING_PROFILE_MISMATCH_ERROR',\n `The bundle identifier in provisioning profile used to resign the app does not match the bundle identifier of the app selected to be resigned. See logs above for more information.`\n ),\n },\n {\n platform: Platform.IOS,\n phase: BuildPhase.RUN_FASTLANE,\n mode: BuildMode.RESIGN,\n regexp: /.*/,\n createError: () =>\n new UserFacingError(\n errors.ErrorCode.UNKNOWN_FASTLANE_RESIGN_ERROR,\n `The \"Run fastlane\" step failed with an unknown error.`\n ),\n },\n {\n platform: Platform.IOS,\n phase: XCODE_BUILD_PHASE,\n // MkDir /Users/expo/workingdir/build/packages/apps/NFLNetwork/ios/build/Build/Products/Release-iphonesimulator/expo-dev-launcher/EXDevLauncher.bundle (in target 'expo-dev-launcher-EXDevLauncher' from project 'Pods')\n // cd /Users/expo/workingdir/build/packages/apps/NFLNetwork/ios/Pods\n // /bin/mkdir -p /Users/expo/workingdir/build/packages/apps/NFLNetwork/ios/build/Build/Products/Release-iphonesimulator/expo-dev-launcher/EXDevLauncher.bundle\n // ProcessXCFramework /Users/expo/workingdir/build/packages/video/ios/Vendor/dependency/ProgrammaticAccessLibrary.xcframework /Users/expo/workingdir/build/packages/apps/NFLNetwork/ios/build/Build/Products/Release-iphonesimulator/ProgrammaticAccessLibrary.framework ios simulator\n // cd /Users/expo/workingdir/build/packages/apps/NFLNetwork/ios\n // builtin-process-xcframework --xcframework /Users/expo/workingdir/build/packages/video/ios/Vendor/dependency/ProgrammaticAccessLibrary.xcframework --platform ios --environment simulator --target-path /Users/expo/workingdir/build/packages/apps/NFLNetwork/ios/build/Build/Products/Release-iphonesimulator\n // /Users/expo/workingdir/build/packages/video/ios/Vendor/dependency/ProgrammaticAccessLibrary.xcframework:1:1: error: The signature of “ProgrammaticAccessLibrary.xcframework” cannot be verified.\n // note: A sealed resource is missing or invalid\n // note: /Users/expo/workingdir/build/packages/video/ios/Vendor/dependency/ProgrammaticAccessLibrary.xcframework: a sealed resource is missing or invalid\n // file modified: /Users/expo/workingdir/build/packages/video/ios/Vendor/dependency/ProgrammaticAccessLibrary.xcframework/ios-arm64_x86_64-simulator/ProgrammaticAccessLibrary.framework/ProgrammaticAccessLibrary\n // file modified: /Users/expo/workingdir/build/packages/video/ios/Vendor/dependency/ProgrammaticAccessLibrary.xcframework/ios-arm64/ProgrammaticAccessLibrary.framework/ProgrammaticAccessLibrary\n regexp: /error: .+/g,\n createError: (matchResult) =>\n new UserFacingError(\n 'XCODE_BUILD_ERROR',\n `The \"Run fastlane\" step failed because of an error in the Xcode build process. We automatically detected following errors in your Xcode build logs:\\n${matchResult\n .map((match) => `- ${match.replace('error: ', '')}`)\n .join('\\n')}\\nRefer to \"Xcode Logs\" below for additional, more detailed logs.`\n ),\n },\n {\n platform: Platform.IOS,\n phase: BuildPhase.RUN_FASTLANE,\n regexp: /.*/,\n createError: () =>\n new UserFacingError(\n errors.ErrorCode.UNKNOWN_FASTLANE_ERROR,\n `The \"Run fastlane\" step failed with an unknown error. Refer to \"Xcode Logs\" below for additional, more detailed logs.`\n ),\n },\n];\n"]}
|
|
1
|
+
{"version":3,"file":"userErrorHandlers.js","sourceRoot":"","sources":["../../src/buildErrors/userErrorHandlers.ts"],"names":[],"mappings":";;;AAAA,uDAAwF;AAExF,iDAAiE;AAEjE,IAAO,eAAe,GAAG,sBAAM,CAAC,eAAe,CAAC;AAEnC,QAAA,iBA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9C,uDAAuD,CACxD;KACJ;IACD;QACE,QAAQ,EAAE,wBAAQ,CAAC,GAAG;QACtB,KAAK,EAAE,gCAAiB;QACxB,wNAAwN;QACxN,oEAAoE;QACpE,8JAA8J;QAC9J,sRAAsR;QACtR,+DAA+D;QAC/D,gTAAgT;QAChT,mMAAmM;QACnM,gDAAgD;QAChD,yJAAyJ;QACzJ,kNAAkN;QAClN,iMAAiM;QACjM,MAAM,EAAE,YAAY;QACpB,WAAW,EAAE,CAAC,WAAW,EAAE,EAAE,CAC3B,IAAI,eAAe,CACjB,mBAAmB,EACnB,wJAAwJ,WAAW;aAChK,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,KAAK,CAAC,OAAO,CAAC,SAAS,EAAE,EAAE,CAAC,EAAE,CAAC;aACnD,IAAI,CAAC,IAAI,CAAC,mEAAmE,CACjF;KACJ;IACD;QACE,QAAQ,EAAE,wBAAQ,CAAC,GAAG;QACtB,KAAK,EAAE,0BAAU,CAAC,YAAY;QAC9B,MAAM,EAAE,IAAI;QACZ,WAAW,EAAE,GAAG,EAAE,CAChB,IAAI,eAAe,CACjB,sBAAM,CAAC,SAAS,CAAC,sBAAsB,EACvC,uHAAuH,CACxH;KACJ;CACF,CAAC","sourcesContent":["import { BuildMode, BuildPhase, errors, Platform, Workflow } from '@expo/eas-build-job';\n\nimport { ErrorHandler, XCODE_BUILD_PHASE } from './errors.types';\n\nimport UserFacingError = errors.UserFacingError;\n\nexport const userErrorHandlers: ErrorHandler<UserFacingError>[] = [\n {\n platform: Platform.IOS,\n phase: BuildPhase.INSTALL_PODS,\n regexp: /requires CocoaPods version/,\n // example log:\n // [!] `React` requires CocoaPods version `>= 1.10.1`, which is not satisfied by your current version, `1.10.0`.\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_UNSUPPORTED_COCOAPODS_VERSION_ERROR',\n `Your project requires a newer version of CocoaPods. You can update it in the build profile in eas.json by either:\n- changing the current version under key \"cocoapods\"\n- switching to an image that supports that version under key \"image\"`,\n 'https://docs.expo.dev/build-reference/eas-json/'\n ),\n },\n {\n platform: Platform.IOS,\n phase: BuildPhase.RUN_FASTLANE,\n regexp: /Could not find 'bundler' (.*) required by your/,\n // example log:\n // /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/dependency.rb:313:in `to_specs': Could not find 'bundler' (2.2.3) required by your /Users/expo/project/build/ios/Gemfile.lock. (Gem::MissingSpecVersionError)\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_UNSUPPORTED_BUNDLER_VERSION_ERROR',\n `Your project requires a different version of the Ruby \"bundler\" program than the version installed in this EAS Build environment. You can specify which version of \"bundler\" to install by specifying the version under \"build\"→[buildProfileName]→\"ios\"→\"bundler\" in eas.json.`,\n 'https://docs.expo.dev/build-reference/eas-json/'\n ),\n },\n {\n platform: Platform.ANDROID,\n phase: BuildPhase.RUN_GRADLEW,\n // example log:\n // > Failed to read key keyalias from store \"/build/workingdir/build/generic/keystore-5787e6af-3002-4cb7-8a57-3e73d13313c2.jks\": Invalid keystore format\n regexp: /Invalid keystore format/,\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_INVALID_KEYSTORE_FORMAT_ERROR',\n 'The keystore used in this build is malformed or it has an unsupported type. Make sure you provided the correct file.'\n ),\n },\n {\n platform: Platform.ANDROID,\n phase: BuildPhase.RUN_GRADLEW,\n // example log:\n // > Failed to read key keyalias from store \"/build/workingdir/build/generic/keystore-286069a8-4bb9-48a6-add9-acf6b58ea06d.jks\": null\n regexp: /Failed to read key[^\\n]+from store/,\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_INVALID_KEYSTORE_ALIAS_ERROR',\n 'The alias specified for this keystore does not exist. Make sure you specified the correct value.'\n ),\n },\n {\n platform: Platform.ANDROID,\n phase: BuildPhase.PREBUILD,\n // example log:\n // [15:42:05] Error: Cannot copy google-services.json from /build/workingdir/build/managed/abc to /build/workingdir/build/managed/android/app/google-services.json\n // or\n // [11:17:29] [android.dangerous]: withAndroidDangerousBaseMod: Cannot copy google-services.json from /home/expo/workingdir/build/test/test-google-services.json to /home/expo/workingdir/build/android/app/google-services.json. Please make sure the source and destination paths exist.\n // [11:17:29] Error: [android.dangerous]: withAndroidDangerousBaseMod: Cannot copy google-services.json from /home/expo/workingdir/build/test/test-google-services.json to /home/expo/workingdir/build/android/app/google-services.json. Please make sure the source and destination paths exist.\n regexp: /Cannot copy google-services\\.json/,\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_MISSING_GOOGLE_SERVICES_JSON_ERROR',\n '\"google-services.json\" is missing, make sure that the file exists. Remember that EAS Build only uploads the files tracked by git. Use EAS environment variables to provide EAS Build with the file.',\n 'https://docs.expo.dev/eas/environment-variables/#file-environment-variables'\n ),\n },\n {\n platform: Platform.ANDROID,\n phase: BuildPhase.RUN_GRADLEW,\n // Execution failed for task ':app:processReleaseGoogleServices'.\n // > File google-services.json is missing. The Google Services Plugin cannot function without it.\n // Searched Location:\n regexp:\n /File google-services\\.json is missing\\. The Google Services Plugin cannot function without it/,\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_MISSING_GOOGLE_SERVICES_JSON_ERROR',\n '\"google-services.json\" is missing, make sure that the file exists. Remember that EAS Build only uploads the files tracked by git. Use EAS environment variables to provide EAS Build with the file.',\n 'https://docs.expo.dev/eas/environment-variables/#file-environment-variables'\n ),\n },\n {\n platform: Platform.IOS,\n phase: BuildPhase.PREBUILD,\n // example log:\n // [08:44:18] ENOENT: no such file or directory, copyfile '/Users/expo/workingdir/build/managed/abc' -> '/Users/expo/workingdir/build/managed/ios/testapp/GoogleService-Info.plist'\n regexp: /ENOENT: no such file or directory, copyfile .*GoogleService-Info.plist/,\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_MISSING_GOOGLE_SERVICES_PLIST_ERROR',\n '\"GoogleService-Info.plist\" is missing, make sure that the file exists. Remember that EAS Build only uploads the files tracked by git. Use EAS environment variables to provide EAS Build with the file.',\n 'https://docs.expo.dev/eas/environment-variables/#file-environment-variables'\n ),\n },\n {\n platform: Platform.IOS,\n phase: BuildPhase.INSTALL_PODS,\n // example log:\n // [!] CocoaPods could not find compatible versions for pod \"react-native-google-maps\"\n // In Podfile:\n // react-native-google-maps (from `/Users/expo/workingdir/build/node_modules/react-native-maps`)\n // Specs satisfying the `react-native-google-maps (from `/Users/expo/workingdir/build/node_modules/react-native-maps`)` dependency were found, but they required a higher minimum deployment target.\n // Error: Compatible versions of some pods could not be resolved.\n regexp:\n /Specs satisfying the `(.*)` dependency were found, but they required a higher minimum deployment target/,\n createError: (_, { job }) => {\n return new UserFacingError(\n 'EAS_BUILD_HIGHER_MINIMUM_DEPLOYMENT_TARGET_ERROR',\n `Some pods require a higher minimum deployment target.\n${\n 'type' in job && job.type === Workflow.MANAGED\n ? 'You can use the expo-build-properties config plugin (https://docs.expo.dev/versions/latest/sdk/build-properties/) to override the default native build properties and set a different minimum deployment target.'\n : 'You need to manually update the minimum deployment target in your project to resolve this issue.'\n}\n`\n );\n },\n },\n {\n platform: Platform.IOS,\n phase: BuildPhase.INSTALL_PODS,\n // example log:\n // [!] CocoaPods could not find compatible versions for pod \"Firebase/Core\":\n // In snapshot (Podfile.lock):\n // Firebase/Core (= 6.14.0)\n // In Podfile:\n // EXFirebaseCore (from `../node_modules/expo-firebase-core/ios`) was resolved to 3.0.0, which depends on\n // Firebase/Core (= 7.7.0)\n // You have either:\n // * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.\n // * changed the constraints of dependency `Firebase/Core` inside your development pod `EXFirebaseCore`.\n // You should run `pod update Firebase/Core` to apply changes you've made.\n regexp: /CocoaPods could not find compatible versions for pod /,\n createError: () => {\n return new UserFacingError(\n 'EAS_BUILD_INCOMPATIBLE_PODS_ERROR',\n `Compatible versions of some pods could not be resolved.\nYou are seeing this error because either:\n - Some of the pods used in your project depend on different versions of the same pod. See logs for more information.\n - If you are caching Podfile.lock using \"cache\" field in eas.json, then versions there might not match required values in Podspecs of some installed libraries. To fix this, you can re-run build command with \"--clear-cache\" option, or select \"Clear cache and retry build\" on the build page.\n`\n );\n },\n },\n {\n phase: BuildPhase.INSTALL_DEPENDENCIES,\n // example log:\n // [stderr] npm ERR! Fix the upstream dependency conflict, or retry\n // [stderr] npm ERR! this command with --force, or --legacy-peer-deps\n // [stderr] npm ERR! to accept an incorrect (and potentially broken) dependency resolution.\n regexp:\n /Fix the upstream dependency conflict, or retry.*\\s.*this command with --force, or --legacy-peer-deps/,\n createError: (matchResult: RegExpMatchArray) => {\n if (matchResult.length >= 2) {\n return new UserFacingError(\n 'EAS_BUILD_NPM_CONFLICTING_PEER_DEPENDENCIES',\n `Some of your peer dependencies are not compatible. The recommended approach is to fix your dependencies by resolving any conflicts listed by \"npm install\". As a temporary workaround you can:\n- Add \".npmrc\" file with \"legacy-peer-deps=true\" and commit that to your repo.\n- Delete package-lock.json and use yarn instead. It does not enforce peer dependencies.\n- Downgrade to older version of npm on EAS Build, by adding \"npm install -g npm@version\" in \"eas-build-pre-install\" script in package.json.`\n );\n }\n return undefined;\n },\n },\n {\n phase: BuildPhase.INSTALL_DEPENDENCIES,\n // example log:\n // [stderr] error https://github.com/expo/react-native/archive/sdk-41.0.0.tar.gz: Integrity check failed for \"react-native\" (computed integrity doesn't match our records, got \"sha512-3jHI2YufrJi7eIABRf/DN/I2yOkmIZ0vAyezTz+PAUJiEs4v//5LLojWEU+W53AZsnuaEMcl/4fVy4bd+OuUbA== sha1-o9QuQTXIkc8VozXPaZIullB9a40=\")\n regexp: /Integrity check failed for \"(.*)\" \\(computed integrity doesn't match our records, got/,\n createError: (matchResult: RegExpMatchArray) => {\n if (matchResult.length >= 2) {\n return new UserFacingError(\n 'EAS_BUILD_YARN_LOCK_CHECKSUM_ERROR',\n `Checksum for package \"${matchResult[1]}\" does not match value in registry. To fix that:\n- run \"yarn cache clean\"\n- remove yarn.lock (or only the section for that package)\n- run \"yarn install --force\"`\n );\n }\n return undefined;\n },\n },\n {\n phase: BuildPhase.INSTALL_DEPENDENCIES,\n // example log:\n // yarn install v1.22.17\n // [1/4] Resolving packages...\n // [2/4] Fetching packages...\n // [1/4] Resolving packages...\n // [2/4] Fetching packages...\n // [stderr] error https://registry.yarnpkg.com/jest-util/-/jest-util-26.6.2.tgz: Extracting tar content of undefined failed, the file appears to be corrupt: \"ENOENT: no such file or directory, chmod '/Users/expo/Library/Caches/Yarn/v6/npm-jest-util-26.6.2-907535dbe4d5a6cb4c47ac9b926f6af29576cbc1-integrity/node_modules/jest-util/build/pluralize.d.ts'\"\n regexp:\n /\\[1\\/4\\] Resolving packages...\\s*\\[2\\/4\\] Fetching packages...\\s*\\[1\\/4\\] Resolving packages...\\s*\\[2\\/4\\] Fetching packages.../,\n createError: (matchResult: RegExpMatchArray) => {\n if (matchResult) {\n return new UserFacingError(\n 'EAS_BUILD_YARN_MULTIPLE_INSTANCES_ERROR',\n `One of project dependencies is starting new install process while the main one is still in progress, which might result in corrupted packages. Most likely the reason for error is \"prepare\" script in git-referenced dependency of your project. Learn more: https://github.com/yarnpkg/yarn/issues/7212#issuecomment-493720324`\n );\n }\n return undefined;\n },\n },\n {\n platform: Platform.IOS,\n phase: XCODE_BUILD_PHASE,\n // Prepare packages\n // Computing target dependency graph and provisioning inputs\n // Create build description\n // Build description signature: 33a5c28977280822abe5e7bd7fe02529\n // Build description path: /Users/expo/Library/Developer/Xcode/DerivedData/testapp-fazozgerxcvvfifkipojsjftgyih/Build/Intermediates.noindex/ArchiveIntermediates/testapp/IntermediateBuildFilesPath/XCBuildData/33a5c28977280822abe5e7bd7fe02529-desc.xcbuild\n // note: Building targets in dependency order\n // /Users/expo/workingdir/build/managed/ios/Pods/Pods.xcodeproj: error: Signing for \"EXConstants-EXConstants\" requires a development team. Select a development team in the Signing & Capabilities editor. (in target 'EXConstants-EXConstants' from project 'Pods')\n // /Users/expo/workingdir/build/managed/ios/Pods/Pods.xcodeproj: error: Signing for \"React-Core-AccessibilityResources\" requires a development team. Select a development team in the Signing & Capabilities editor. (in target 'React-Core-AccessibilityResources' from project 'Pods')\n // warning: Run script build phase '[CP-User] Generate app.manifest for expo-updates' will be run during every build because it does not specify any outputs. To address this warning, either add output dependencies to the script phase, or configure it to run in every build by unchecking \"Based on dependency analysis\" in the script phase. (in target 'EXUpdates' from project 'Pods')\n // warning: Run script build phase 'Start Packager' will be run during every build because it does not specify any outputs. To address this warning, either add output dependencies to the script phase, or configure it to run in every build by unchecking \"Based on dependency analysis\" in the script phase. (in target 'testapp' from project 'testapp')\n // warning: Run script build phase 'Bundle React Native code and images' will be run during every build because it does not specify any outputs. To address this warning, either add output dependencies to the script phase, or configure it to run in every build by unchecking \"Based on dependency analysis\" in the script phase. (in target 'testapp' from project 'testapp')\n // warning: Run script build phase '[CP-User] Generate app.config for prebuilt Constants.manifest' will be run during every build because it does not specify any outputs. To address this warning, either add output dependencies to the script phase, or configure it to run in every build by unchecking \"Based on dependency analysis\" in the script phase. (in target 'EXConstants' from project 'Pods')\n // /Users/expo/workingdir/build/managed/ios/Pods/Pods.xcodeproj: error: Signing for \"EXUpdates-EXUpdates\" requires a development team. Select a development team in the Signing & Capabilities editor. (in target 'EXUpdates-EXUpdates' from project 'Pods')\n regexp: /error: Signing for \"[a-zA-Z-0-9_]+\" requires a development team/,\n createError: (_, { job }) =>\n 'type' in job && job.type === Workflow.MANAGED\n ? new UserFacingError(\n 'XCODE_RESOURCE_BUNDLE_CODE_SIGNING_ERROR',\n `Starting from Xcode 14, resource bundles are signed by default, which requires setting the development team for each resource bundle target.\nTo resolve this issue, downgrade to an older Xcode version using the \"image\" field in eas.json, or upgrade to SDK 46 or higher.`,\n 'https://docs.expo.dev/build-reference/infrastructure/#ios-build-server-configurations'\n )\n : new UserFacingError(\n 'XCODE_RESOURCE_BUNDLE_CODE_SIGNING_ERROR',\n `Starting from Xcode 14, resource bundles are signed by default, which requires setting the development team for each resource bundle target.\nTo resolve this issue, downgrade to an older Xcode version using the \"image\" field in eas.json, or turn off signing resource bundles in your Podfile: https://expo.fyi/r/disable-bundle-resource-signing`,\n 'https://docs.expo.dev/build-reference/infrastructure/#ios-build-server-configurations'\n ),\n },\n {\n platform: Platform.ANDROID,\n phase: BuildPhase.RUN_GRADLEW,\n regexp: /.*/,\n createError: () =>\n new UserFacingError(\n errors.ErrorCode.UNKNOWN_GRADLE_ERROR,\n 'Gradle build failed with unknown error. See logs for the \"Run gradlew\" phase for more information.'\n ),\n },\n {\n platform: Platform.IOS,\n phase: BuildPhase.RUN_FASTLANE,\n mode: BuildMode.RESIGN,\n regexp: /No provisioning profile for application: '(.+)' with bundle identifier '(.+)'/,\n createError: () =>\n new UserFacingError(\n 'EAS_BUILD_RESIGN_PROVISIONING_PROFILE_MISMATCH_ERROR',\n `The bundle identifier in provisioning profile used to resign the app does not match the bundle identifier of the app selected to be resigned. See logs above for more information.`\n ),\n },\n {\n platform: Platform.IOS,\n phase: BuildPhase.RUN_FASTLANE,\n mode: BuildMode.RESIGN,\n regexp: /.*/,\n createError: () =>\n new UserFacingError(\n errors.ErrorCode.UNKNOWN_FASTLANE_RESIGN_ERROR,\n `The \"Run fastlane\" step failed with an unknown error.`\n ),\n },\n {\n platform: Platform.IOS,\n phase: XCODE_BUILD_PHASE,\n // MkDir /Users/expo/workingdir/build/packages/apps/NFLNetwork/ios/build/Build/Products/Release-iphonesimulator/expo-dev-launcher/EXDevLauncher.bundle (in target 'expo-dev-launcher-EXDevLauncher' from project 'Pods')\n // cd /Users/expo/workingdir/build/packages/apps/NFLNetwork/ios/Pods\n // /bin/mkdir -p /Users/expo/workingdir/build/packages/apps/NFLNetwork/ios/build/Build/Products/Release-iphonesimulator/expo-dev-launcher/EXDevLauncher.bundle\n // ProcessXCFramework /Users/expo/workingdir/build/packages/video/ios/Vendor/dependency/ProgrammaticAccessLibrary.xcframework /Users/expo/workingdir/build/packages/apps/NFLNetwork/ios/build/Build/Products/Release-iphonesimulator/ProgrammaticAccessLibrary.framework ios simulator\n // cd /Users/expo/workingdir/build/packages/apps/NFLNetwork/ios\n // builtin-process-xcframework --xcframework /Users/expo/workingdir/build/packages/video/ios/Vendor/dependency/ProgrammaticAccessLibrary.xcframework --platform ios --environment simulator --target-path /Users/expo/workingdir/build/packages/apps/NFLNetwork/ios/build/Build/Products/Release-iphonesimulator\n // /Users/expo/workingdir/build/packages/video/ios/Vendor/dependency/ProgrammaticAccessLibrary.xcframework:1:1: error: The signature of “ProgrammaticAccessLibrary.xcframework” cannot be verified.\n // note: A sealed resource is missing or invalid\n // note: /Users/expo/workingdir/build/packages/video/ios/Vendor/dependency/ProgrammaticAccessLibrary.xcframework: a sealed resource is missing or invalid\n // file modified: /Users/expo/workingdir/build/packages/video/ios/Vendor/dependency/ProgrammaticAccessLibrary.xcframework/ios-arm64_x86_64-simulator/ProgrammaticAccessLibrary.framework/ProgrammaticAccessLibrary\n // file modified: /Users/expo/workingdir/build/packages/video/ios/Vendor/dependency/ProgrammaticAccessLibrary.xcframework/ios-arm64/ProgrammaticAccessLibrary.framework/ProgrammaticAccessLibrary\n regexp: /error: .+/g,\n createError: (matchResult) =>\n new UserFacingError(\n 'XCODE_BUILD_ERROR',\n `The \"Run fastlane\" step failed because of an error in the Xcode build process. We automatically detected following errors in your Xcode build logs:\\n${matchResult\n .map((match) => `- ${match.replace('error: ', '')}`)\n .join('\\n')}\\nRefer to \"Xcode Logs\" below for additional, more detailed logs.`\n ),\n },\n {\n platform: Platform.IOS,\n phase: BuildPhase.RUN_FASTLANE,\n regexp: /.*/,\n createError: () =>\n new UserFacingError(\n errors.ErrorCode.UNKNOWN_FASTLANE_ERROR,\n `The \"Run fastlane\" step failed with an unknown error. Refer to \"Xcode Logs\" below for additional, more detailed logs.`\n ),\n },\n];\n"]}
|
package/dist/common/setup.js
CHANGED
|
@@ -85,10 +85,7 @@ async function setupAsync(ctx) {
|
|
|
85
85
|
if (!ctx.env.EAS_BUILD_DISABLE_EXPO_DOCTOR_STEP && hasExpoPackage) {
|
|
86
86
|
await ctx.runBuildPhase(eas_build_job_1.BuildPhase.RUN_EXPO_DOCTOR, async () => {
|
|
87
87
|
try {
|
|
88
|
-
|
|
89
|
-
if (!stdout.match(/Didn't find any issues with the project/)) {
|
|
90
|
-
ctx.markBuildPhaseHasWarnings();
|
|
91
|
-
}
|
|
88
|
+
await runExpoDoctor(ctx);
|
|
92
89
|
}
|
|
93
90
|
catch (err) {
|
|
94
91
|
if (err instanceof DoctorTimeoutError) {
|
|
@@ -209,7 +206,7 @@ async function validateAppConfigAsync(ctx, appConfig) {
|
|
|
209
206
|
}
|
|
210
207
|
else if (isUsingDynamicConfig) {
|
|
211
208
|
extraMessage =
|
|
212
|
-
'If you are using environment variables to switch between projects in app.config.js/app.config.ts, make sure those variables are also set inside EAS Build. You can do that using "env" field in eas.json or EAS
|
|
209
|
+
'If you are using environment variables to switch between projects in app.config.js/app.config.ts, make sure those variables are also set inside EAS Build. You can do that using "env" field in eas.json or EAS environment variables. ';
|
|
213
210
|
}
|
|
214
211
|
throw new errors_1.UserFacingError('EAS_BUILD_PROJECT_ID_MISMATCH', `The value of the "extra.eas.projectId" field (${appConfig.extra.eas.projectId}) in the app config does not match the current project id (${ctx.env.EAS_BUILD_PROJECT_ID}). ${extraMessage}Learn more: https://expo.fyi/eas-config-mismatch.`);
|
|
215
212
|
}
|
package/dist/common/setup.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"setup.js","sourceRoot":"","sources":["../../src/common/setup.ts"],"names":[],"mappings":";;;;;;AAAA,gDAAwB;AAExB,sEAAwD;AACxD,wDAA0B;AAC1B,uDAA+E;AAC/E,4DAA+D;AAC/D,4DAAoC;AAEpC,4DAAkE;AAGlE,8CAAmE;AACnE,0CAAwD;AACxD,0CAAiD;AACjD,4DAA6D;AAC7D,8CAAmD;AACnD,kDAA4E;AAE5E,qDAA8D;AAC9D,+DAAqF;AACrF,yDAA+F;AAE/F,MAAM,0BAA0B,GAAG,EAAE,GAAG,IAAI,CAAC;AAC7C,MAAM,oCAAoC,GAAG,EAAE,GAAG,EAAE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D,CAAC;QACD,MAAM,oBAAoB,GACxB,CAAC,MAAM,kBAAE,CAAC,UAAU,CAAC,cAAI,CAAC,IAAI,CAAC,GAAG,CAAC,8BAA8B,EAAE,EAAE,eAAe,CAAC,CAAC,CAAC;YACvF,CAAC,MAAM,kBAAE,CAAC,UAAU,CAAC,cAAI,CAAC,IAAI,CAAC,GAAG,CAAC,8BAA8B,EAAE,EAAE,eAAe,CAAC,CAAC,CAAC,CAAC;QAC1F,MAAM,aAAa,GAAG,GAAG,CAAC,GAAG,CAAC,WAAW,KAAK,qBAAY,CAAC,qBAAqB,CAAC;QACjF,IAAI,YAAY,GAAG,EAAE,CAAC;QACtB,IAAI,aAAa,IAAI,oBAAoB,EAAE,CAAC;YAC1C,YAAY;gBACV,mOAAmO,CAAC;QACxO,CAAC;aAAM,IAAI,aAAa,EAAE,CAAC;YACzB,YAAY,GAAG,8EAA8E,CAAC;QAChG,CAAC;aAAM,IAAI,oBAAoB,EAAE,CAAC;YAChC,YAAY;gBACV,2NAA2N,CAAC;QAChO,CAAC;QACD,MAAM,IAAI,wBAAe,CACvB,+BAA+B,EAC/B,iDAAiD,SAAS,CAAC,KAAK,CAAC,GAAG,CAAC,SAAS,8DAA8D,GAAG,CAAC,GAAG,CAAC,oBAAoB,MAAM,YAAY,mDAAmD,CAC9O,CAAC;IACJ,CAAC;SAAM,IAAI,GAAG,CAAC,GAAG,CAAC,oBAAoB,IAAI,CAAC,CAAA,MAAA,MAAA,SAAS,aAAT,SAAS,uBAAT,SAAS,CAAE,KAAK,0CAAE,GAAG,0CAAE,SAAS,CAAA,EAAE,CAAC;QAC7E,GAAG,CAAC,MAAM,CAAC,KAAK,CAAC,kEAAkE,CAAC,CAAC;QACrF,GAAG,CAAC,yBAAyB,EAAE,CAAC;IAClC,CAAC;AACH,CAAC","sourcesContent":["import path from 'path';\n\nimport spawn, { SpawnResult } from '@expo/turtle-spawn';\nimport fs from 'fs-extra';\nimport { BuildJob, BuildPhase, Ios, Job, Platform } from '@expo/eas-build-job';\nimport { BuildTrigger } from '@expo/eas-build-job/dist/common';\nimport nullthrows from 'nullthrows';\nimport { ExpoConfig } from '@expo/config';\nimport { UserFacingError } from '@expo/eas-build-job/dist/errors';\n\nimport { BuildContext } from '../context';\nimport { deleteXcodeEnvLocalIfExistsAsync } from '../ios/xcodeEnv';\nimport { Hook, runHookIfPresent } from '../utils/hooks';\nimport { setUpNpmrcAsync } from '../utils/npmrc';\nimport { isAtLeastNpm7Async } from '../utils/packageManager';\nimport { readPackageJson } from '../utils/project';\nimport { getParentAndDescendantProcessPidsAsync } from '../utils/processes';\n\nimport { prepareProjectSourcesAsync } from './projectSources';\nimport { installDependenciesAsync, resolvePackagerDir } from './installDependencies';\nimport { resolveEnvFromBuildProfileAsync, runEasBuildInternalAsync } from './easBuildInternal';\n\nconst MAX_EXPO_DOCTOR_TIMEOUT_MS = 30 * 1000;\nconst INSTALL_DEPENDENCIES_WARN_TIMEOUT_MS = 15 * 60 * 1000;\nconst INSTALL_DEPENDENCIES_KILL_TIMEOUT_MS = 30 * 60 * 1000;\n\nclass DoctorTimeoutError extends Error {}\nclass InstallDependenciesTimeoutError extends Error {}\n\nexport async function setupAsync<TJob extends BuildJob>(ctx: BuildContext<TJob>): Promise<void> {\n await ctx.runBuildPhase(BuildPhase.PREPARE_PROJECT, async () => {\n await prepareProjectSourcesAsync(ctx);\n await setUpNpmrcAsync(ctx, ctx.logger);\n if (ctx.job.platform === Platform.IOS && ctx.env.EAS_BUILD_RUNNER === 'eas-build') {\n await deleteXcodeEnvLocalIfExistsAsync(ctx as BuildContext<Ios.Job>);\n }\n if (ctx.job.triggeredBy === BuildTrigger.GIT_BASED_INTEGRATION) {\n // We need to setup envs from eas.json before\n // eas-build-pre-install hook is called.\n const env = await resolveEnvFromBuildProfileAsync(ctx, {\n cwd: ctx.getReactNativeProjectDirectory(),\n });\n ctx.updateEnv(env);\n }\n });\n\n await ctx.runBuildPhase(BuildPhase.PRE_INSTALL_HOOK, async () => {\n await runHookIfPresent(ctx, Hook.PRE_INSTALL);\n });\n\n const packageJson = await ctx.runBuildPhase(BuildPhase.READ_PACKAGE_JSON, async () => {\n ctx.logger.info('Using package.json:');\n const packageJson = readPackageJson(ctx.getReactNativeProjectDirectory());\n ctx.logger.info(JSON.stringify(packageJson, null, 2));\n return packageJson;\n });\n\n await ctx.runBuildPhase(BuildPhase.INSTALL_DEPENDENCIES, async () => {\n await runInstallDependenciesAsync(ctx);\n });\n\n await ctx.runBuildPhase(BuildPhase.READ_APP_CONFIG, async () => {\n const appConfig = ctx.appConfig;\n ctx.logger.info('Using app configuration:');\n ctx.logger.info(JSON.stringify(appConfig, null, 2));\n await validateAppConfigAsync(ctx, appConfig);\n });\n\n if (ctx.job.triggeredBy === BuildTrigger.GIT_BASED_INTEGRATION) {\n await ctx.runBuildPhase(BuildPhase.EAS_BUILD_INTERNAL, async () => {\n if (!ctx.appConfig.ios?.bundleIdentifier && ctx.job.platform === Platform.IOS) {\n throw new Error(\n 'The \"ios.bundleIdentifier\" is required to be set in app config for builds triggered by GitHub integration. Learn more: https://docs.expo.dev/versions/latest/config/app/#bundleidentifier.'\n );\n }\n if (!ctx.appConfig.android?.package && ctx.job.platform === Platform.ANDROID) {\n throw new Error(\n 'The \"android.package\" is required to be set in app config for builds triggered by GitHub integration. Learn more: https://docs.expo.dev/versions/latest/config/app/#package.'\n );\n }\n const { newJob, newMetadata } = await runEasBuildInternalAsync({\n job: ctx.job,\n env: ctx.env,\n logger: ctx.logger,\n cwd: ctx.getReactNativeProjectDirectory(),\n projectRootOverride: ctx.env.EAS_NO_VCS ? ctx.buildDirectory : undefined,\n });\n ctx.updateJobInformation(newJob, newMetadata);\n });\n }\n\n const hasExpoPackage = !!packageJson.dependencies?.expo;\n if (!ctx.env.EAS_BUILD_DISABLE_EXPO_DOCTOR_STEP && hasExpoPackage) {\n await ctx.runBuildPhase(BuildPhase.RUN_EXPO_DOCTOR, async () => {\n try {\n const { stdout } = await runExpoDoctor(ctx);\n if (!stdout.match(/Didn't find any issues with the project/)) {\n ctx.markBuildPhaseHasWarnings();\n }\n } catch (err) {\n if (err instanceof DoctorTimeoutError) {\n ctx.logger.error(err.message);\n } else {\n ctx.logger.error({ err }, 'Command \"expo doctor\" failed.');\n }\n ctx.markBuildPhaseHasWarnings();\n }\n });\n }\n}\n\nasync function runExpoDoctor<TJob extends Job>(ctx: BuildContext<TJob>): Promise<SpawnResult> {\n ctx.logger.info('Running \"expo doctor\"');\n let timeout: NodeJS.Timeout | undefined;\n let timedOut = false;\n const isAtLeastNpm7 = await isAtLeastNpm7Async();\n try {\n const argsPrefix = isAtLeastNpm7 ? ['-y'] : [];\n const promise = spawn('npx', [...argsPrefix, 'expo-doctor'], {\n cwd: ctx.getReactNativeProjectDirectory(),\n logger: ctx.logger,\n env: ctx.env,\n });\n timeout = setTimeout(async () => {\n timedOut = true;\n const ppid = nullthrows(promise.child.pid);\n const pids = await getParentAndDescendantProcessPidsAsync(ppid);\n pids.forEach((pid) => {\n process.kill(pid);\n });\n ctx.reportError?.(`\"expo doctor\" timed out`, undefined, {\n extras: { buildId: ctx.env.EAS_BUILD_ID },\n });\n }, MAX_EXPO_DOCTOR_TIMEOUT_MS);\n return await promise;\n } catch (err: any) {\n if (timedOut) {\n throw new DoctorTimeoutError('\"expo doctor\" timed out, skipping...');\n }\n throw err;\n } finally {\n if (timeout) {\n clearTimeout(timeout);\n }\n }\n}\n\nasync function runInstallDependenciesAsync<TJob extends Job>(\n ctx: BuildContext<TJob>\n): Promise<void> {\n let warnTimeout: NodeJS.Timeout | undefined;\n let killTimeout: NodeJS.Timeout | undefined;\n let killTimedOut: boolean = false;\n try {\n const installDependenciesSpawnPromise = (\n await installDependenciesAsync(ctx, {\n logger: ctx.logger,\n infoCallbackFn: () => {\n if (warnTimeout) {\n warnTimeout.refresh();\n }\n if (killTimeout) {\n killTimeout.refresh();\n }\n },\n cwd: resolvePackagerDir(ctx),\n })\n ).spawnPromise;\n\n warnTimeout = setTimeout(() => {\n ctx.logger.warn(\n '\"Install dependencies\" phase takes longer then expected and it did not produce any logs in the past 15 minutes. Consider evaluating your package.json file for possible issues with dependencies'\n );\n }, INSTALL_DEPENDENCIES_WARN_TIMEOUT_MS);\n\n killTimeout = setTimeout(async () => {\n killTimedOut = true;\n ctx.logger.error(\n '\"Install dependencies\" phase takes a very long time and it did not produce any logs in the past 30 minutes. Most likely an unexpected error happened with your dependencies which caused the process to hang and it will be terminated'\n );\n const ppid = nullthrows(installDependenciesSpawnPromise.child.pid);\n const pids = await getParentAndDescendantProcessPidsAsync(ppid);\n pids.forEach((pid) => {\n process.kill(pid);\n });\n ctx.reportError?.('\"Install dependencies\" phase takes a very long time', undefined, {\n extras: { buildId: ctx.env.EAS_BUILD_ID },\n });\n }, INSTALL_DEPENDENCIES_KILL_TIMEOUT_MS);\n\n await installDependenciesSpawnPromise;\n } catch (err: any) {\n if (killTimedOut) {\n throw new InstallDependenciesTimeoutError(\n '\"Install dependencies\" phase was inactive for over 30 minutes. Please evaluate your package.json file'\n );\n }\n throw err;\n } finally {\n if (warnTimeout) {\n clearTimeout(warnTimeout);\n }\n if (killTimeout) {\n clearTimeout(killTimeout);\n }\n }\n}\n\nasync function validateAppConfigAsync(\n ctx: BuildContext<Job>,\n appConfig: ExpoConfig\n): Promise<void> {\n if (\n appConfig?.extra?.eas?.projectId &&\n ctx.env.EAS_BUILD_PROJECT_ID &&\n appConfig.extra.eas.projectId !== ctx.env.EAS_BUILD_PROJECT_ID\n ) {\n const isUsingDynamicConfig =\n (await fs.pathExists(path.join(ctx.getReactNativeProjectDirectory(), 'app.config.ts'))) ||\n (await fs.pathExists(path.join(ctx.getReactNativeProjectDirectory(), 'app.config.js')));\n const isGitHubBuild = ctx.job.triggeredBy === BuildTrigger.GIT_BASED_INTEGRATION;\n let extraMessage = '';\n if (isGitHubBuild && isUsingDynamicConfig) {\n extraMessage =\n 'Make sure you connected your GitHub repository to the correct Expo project and if you are using environment variables to switch between projects in app.config.js/app.config.ts remember to set those variables in eas.json too. ';\n } else if (isGitHubBuild) {\n extraMessage = 'Make sure you connected your GitHub repository to the correct Expo project. ';\n } else if (isUsingDynamicConfig) {\n extraMessage =\n 'If you are using environment variables to switch between projects in app.config.js/app.config.ts, make sure those variables are also set inside EAS Build. You can do that using \"env\" field in eas.json or EAS Secrets. ';\n }\n throw new UserFacingError(\n 'EAS_BUILD_PROJECT_ID_MISMATCH',\n `The value of the \"extra.eas.projectId\" field (${appConfig.extra.eas.projectId}) in the app config does not match the current project id (${ctx.env.EAS_BUILD_PROJECT_ID}). ${extraMessage}Learn more: https://expo.fyi/eas-config-mismatch.`\n );\n } else if (ctx.env.EAS_BUILD_PROJECT_ID && !appConfig?.extra?.eas?.projectId) {\n ctx.logger.error(`The \"extra.eas.projectId\" field is missing from your app config.`);\n ctx.markBuildPhaseHasWarnings();\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"setup.js","sourceRoot":"","sources":["../../src/common/setup.ts"],"names":[],"mappings":";;;;;;AAAA,gDAAwB;AAExB,sEAAwD;AACxD,wDAA0B;AAC1B,uDAA+E;AAC/E,4DAA+D;AAC/D,4DAAoC;AAEpC,4DAAkE;AAGlE,8CAAmE;AACnE,0CAAwD;AACxD,0CAAiD;AACjD,4DAA6D;AAC7D,8CAAmD;AACnD,kDAA4E;AAE5E,qDAA8D;AAC9D,+DAAqF;AACrF,yDAA+F;AAE/F,MAAM,0BAA0B,GAAG,EAAE,GAAG,IAAI,CAAC;AAC7C,MAAM,oCAAoC,GAAG,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC;AAC5D,MAAM,oCAAoC,GAAG,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC;AAE5D,MAAM,kBAAmB,SAAQ,KAAK;CAAG;AACzC,MAAM,+BAAgC,SAAQ,KAAK;CAAG;AAE/C,KAAK,UAAU,UAAU,CAAwB,GAAuB;;IAC7E,MAAM,GAAG,CAAC,aAAa,CAAC,0BAAU,CAAC,eAAe,EAAE,KAAK,IAAI,EAAE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B,EAAE,CAAC;YAC1C,YAAY;gBACV,mOAAmO,CAAC;QACxO,CAAC;aAAM,IAAI,aAAa,EAAE,CAAC;YACzB,YAAY,GAAG,8EAA8E,CAAC;QAChG,CAAC;aAAM,IAAI,oBAAoB,EAAE,CAAC;YAChC,YAAY;gBACV,yOAAyO,CAAC;QAC9O,CAAC;QACD,MAAM,IAAI,wBAAe,CACvB,+BAA+B,EAC/B,iDAAiD,SAAS,CAAC,KAAK,CAAC,GAAG,CAAC,SAAS,8DAA8D,GAAG,CAAC,GAAG,CAAC,oBAAoB,MAAM,YAAY,mDAAmD,CAC9O,CAAC;IACJ,CAAC;SAAM,IAAI,GAAG,CAAC,GAAG,CAAC,oBAAoB,IAAI,CAAC,CAAA,MAAA,MAAA,SAAS,aAAT,SAAS,uBAAT,SAAS,CAAE,KAAK,0CAAE,GAAG,0CAAE,SAAS,CAAA,EAAE,CAAC;QAC7E,GAAG,CAAC,MAAM,CAAC,KAAK,CAAC,kEAAkE,CAAC,CAAC;QACrF,GAAG,CAAC,yBAAyB,EAAE,CAAC;IAClC,CAAC;AACH,CAAC","sourcesContent":["import path from 'path';\n\nimport spawn, { SpawnResult } from '@expo/turtle-spawn';\nimport fs from 'fs-extra';\nimport { BuildJob, BuildPhase, Ios, Job, Platform } from '@expo/eas-build-job';\nimport { BuildTrigger } from '@expo/eas-build-job/dist/common';\nimport nullthrows from 'nullthrows';\nimport { ExpoConfig } from '@expo/config';\nimport { UserFacingError } from '@expo/eas-build-job/dist/errors';\n\nimport { BuildContext } from '../context';\nimport { deleteXcodeEnvLocalIfExistsAsync } from '../ios/xcodeEnv';\nimport { Hook, runHookIfPresent } from '../utils/hooks';\nimport { setUpNpmrcAsync } from '../utils/npmrc';\nimport { isAtLeastNpm7Async } from '../utils/packageManager';\nimport { readPackageJson } from '../utils/project';\nimport { getParentAndDescendantProcessPidsAsync } from '../utils/processes';\n\nimport { prepareProjectSourcesAsync } from './projectSources';\nimport { installDependenciesAsync, resolvePackagerDir } from './installDependencies';\nimport { resolveEnvFromBuildProfileAsync, runEasBuildInternalAsync } from './easBuildInternal';\n\nconst MAX_EXPO_DOCTOR_TIMEOUT_MS = 30 * 1000;\nconst INSTALL_DEPENDENCIES_WARN_TIMEOUT_MS = 15 * 60 * 1000;\nconst INSTALL_DEPENDENCIES_KILL_TIMEOUT_MS = 30 * 60 * 1000;\n\nclass DoctorTimeoutError extends Error {}\nclass InstallDependenciesTimeoutError extends Error {}\n\nexport async function setupAsync<TJob extends BuildJob>(ctx: BuildContext<TJob>): Promise<void> {\n await ctx.runBuildPhase(BuildPhase.PREPARE_PROJECT, async () => {\n await prepareProjectSourcesAsync(ctx);\n await setUpNpmrcAsync(ctx, ctx.logger);\n if (ctx.job.platform === Platform.IOS && ctx.env.EAS_BUILD_RUNNER === 'eas-build') {\n await deleteXcodeEnvLocalIfExistsAsync(ctx as BuildContext<Ios.Job>);\n }\n if (ctx.job.triggeredBy === BuildTrigger.GIT_BASED_INTEGRATION) {\n // We need to setup envs from eas.json before\n // eas-build-pre-install hook is called.\n const env = await resolveEnvFromBuildProfileAsync(ctx, {\n cwd: ctx.getReactNativeProjectDirectory(),\n });\n ctx.updateEnv(env);\n }\n });\n\n await ctx.runBuildPhase(BuildPhase.PRE_INSTALL_HOOK, async () => {\n await runHookIfPresent(ctx, Hook.PRE_INSTALL);\n });\n\n const packageJson = await ctx.runBuildPhase(BuildPhase.READ_PACKAGE_JSON, async () => {\n ctx.logger.info('Using package.json:');\n const packageJson = readPackageJson(ctx.getReactNativeProjectDirectory());\n ctx.logger.info(JSON.stringify(packageJson, null, 2));\n return packageJson;\n });\n\n await ctx.runBuildPhase(BuildPhase.INSTALL_DEPENDENCIES, async () => {\n await runInstallDependenciesAsync(ctx);\n });\n\n await ctx.runBuildPhase(BuildPhase.READ_APP_CONFIG, async () => {\n const appConfig = ctx.appConfig;\n ctx.logger.info('Using app configuration:');\n ctx.logger.info(JSON.stringify(appConfig, null, 2));\n await validateAppConfigAsync(ctx, appConfig);\n });\n\n if (ctx.job.triggeredBy === BuildTrigger.GIT_BASED_INTEGRATION) {\n await ctx.runBuildPhase(BuildPhase.EAS_BUILD_INTERNAL, async () => {\n if (!ctx.appConfig.ios?.bundleIdentifier && ctx.job.platform === Platform.IOS) {\n throw new Error(\n 'The \"ios.bundleIdentifier\" is required to be set in app config for builds triggered by GitHub integration. Learn more: https://docs.expo.dev/versions/latest/config/app/#bundleidentifier.'\n );\n }\n if (!ctx.appConfig.android?.package && ctx.job.platform === Platform.ANDROID) {\n throw new Error(\n 'The \"android.package\" is required to be set in app config for builds triggered by GitHub integration. Learn more: https://docs.expo.dev/versions/latest/config/app/#package.'\n );\n }\n const { newJob, newMetadata } = await runEasBuildInternalAsync({\n job: ctx.job,\n env: ctx.env,\n logger: ctx.logger,\n cwd: ctx.getReactNativeProjectDirectory(),\n projectRootOverride: ctx.env.EAS_NO_VCS ? ctx.buildDirectory : undefined,\n });\n ctx.updateJobInformation(newJob, newMetadata);\n });\n }\n\n const hasExpoPackage = !!packageJson.dependencies?.expo;\n if (!ctx.env.EAS_BUILD_DISABLE_EXPO_DOCTOR_STEP && hasExpoPackage) {\n await ctx.runBuildPhase(BuildPhase.RUN_EXPO_DOCTOR, async () => {\n try {\n await runExpoDoctor(ctx);\n } catch (err) {\n if (err instanceof DoctorTimeoutError) {\n ctx.logger.error(err.message);\n } else {\n ctx.logger.error({ err }, 'Command \"expo doctor\" failed.');\n }\n ctx.markBuildPhaseHasWarnings();\n }\n });\n }\n}\n\nasync function runExpoDoctor<TJob extends Job>(ctx: BuildContext<TJob>): Promise<SpawnResult> {\n ctx.logger.info('Running \"expo doctor\"');\n let timeout: NodeJS.Timeout | undefined;\n let timedOut = false;\n const isAtLeastNpm7 = await isAtLeastNpm7Async();\n try {\n const argsPrefix = isAtLeastNpm7 ? ['-y'] : [];\n const promise = spawn('npx', [...argsPrefix, 'expo-doctor'], {\n cwd: ctx.getReactNativeProjectDirectory(),\n logger: ctx.logger,\n env: ctx.env,\n });\n timeout = setTimeout(async () => {\n timedOut = true;\n const ppid = nullthrows(promise.child.pid);\n const pids = await getParentAndDescendantProcessPidsAsync(ppid);\n pids.forEach((pid) => {\n process.kill(pid);\n });\n ctx.reportError?.(`\"expo doctor\" timed out`, undefined, {\n extras: { buildId: ctx.env.EAS_BUILD_ID },\n });\n }, MAX_EXPO_DOCTOR_TIMEOUT_MS);\n return await promise;\n } catch (err: any) {\n if (timedOut) {\n throw new DoctorTimeoutError('\"expo doctor\" timed out, skipping...');\n }\n throw err;\n } finally {\n if (timeout) {\n clearTimeout(timeout);\n }\n }\n}\n\nasync function runInstallDependenciesAsync<TJob extends Job>(\n ctx: BuildContext<TJob>\n): Promise<void> {\n let warnTimeout: NodeJS.Timeout | undefined;\n let killTimeout: NodeJS.Timeout | undefined;\n let killTimedOut: boolean = false;\n try {\n const installDependenciesSpawnPromise = (\n await installDependenciesAsync(ctx, {\n logger: ctx.logger,\n infoCallbackFn: () => {\n if (warnTimeout) {\n warnTimeout.refresh();\n }\n if (killTimeout) {\n killTimeout.refresh();\n }\n },\n cwd: resolvePackagerDir(ctx),\n })\n ).spawnPromise;\n\n warnTimeout = setTimeout(() => {\n ctx.logger.warn(\n '\"Install dependencies\" phase takes longer then expected and it did not produce any logs in the past 15 minutes. Consider evaluating your package.json file for possible issues with dependencies'\n );\n }, INSTALL_DEPENDENCIES_WARN_TIMEOUT_MS);\n\n killTimeout = setTimeout(async () => {\n killTimedOut = true;\n ctx.logger.error(\n '\"Install dependencies\" phase takes a very long time and it did not produce any logs in the past 30 minutes. Most likely an unexpected error happened with your dependencies which caused the process to hang and it will be terminated'\n );\n const ppid = nullthrows(installDependenciesSpawnPromise.child.pid);\n const pids = await getParentAndDescendantProcessPidsAsync(ppid);\n pids.forEach((pid) => {\n process.kill(pid);\n });\n ctx.reportError?.('\"Install dependencies\" phase takes a very long time', undefined, {\n extras: { buildId: ctx.env.EAS_BUILD_ID },\n });\n }, INSTALL_DEPENDENCIES_KILL_TIMEOUT_MS);\n\n await installDependenciesSpawnPromise;\n } catch (err: any) {\n if (killTimedOut) {\n throw new InstallDependenciesTimeoutError(\n '\"Install dependencies\" phase was inactive for over 30 minutes. Please evaluate your package.json file'\n );\n }\n throw err;\n } finally {\n if (warnTimeout) {\n clearTimeout(warnTimeout);\n }\n if (killTimeout) {\n clearTimeout(killTimeout);\n }\n }\n}\n\nasync function validateAppConfigAsync(\n ctx: BuildContext<Job>,\n appConfig: ExpoConfig\n): Promise<void> {\n if (\n appConfig?.extra?.eas?.projectId &&\n ctx.env.EAS_BUILD_PROJECT_ID &&\n appConfig.extra.eas.projectId !== ctx.env.EAS_BUILD_PROJECT_ID\n ) {\n const isUsingDynamicConfig =\n (await fs.pathExists(path.join(ctx.getReactNativeProjectDirectory(), 'app.config.ts'))) ||\n (await fs.pathExists(path.join(ctx.getReactNativeProjectDirectory(), 'app.config.js')));\n const isGitHubBuild = ctx.job.triggeredBy === BuildTrigger.GIT_BASED_INTEGRATION;\n let extraMessage = '';\n if (isGitHubBuild && isUsingDynamicConfig) {\n extraMessage =\n 'Make sure you connected your GitHub repository to the correct Expo project and if you are using environment variables to switch between projects in app.config.js/app.config.ts remember to set those variables in eas.json too. ';\n } else if (isGitHubBuild) {\n extraMessage = 'Make sure you connected your GitHub repository to the correct Expo project. ';\n } else if (isUsingDynamicConfig) {\n extraMessage =\n 'If you are using environment variables to switch between projects in app.config.js/app.config.ts, make sure those variables are also set inside EAS Build. You can do that using \"env\" field in eas.json or EAS environment variables. ';\n }\n throw new UserFacingError(\n 'EAS_BUILD_PROJECT_ID_MISMATCH',\n `The value of the \"extra.eas.projectId\" field (${appConfig.extra.eas.projectId}) in the app config does not match the current project id (${ctx.env.EAS_BUILD_PROJECT_ID}). ${extraMessage}Learn more: https://expo.fyi/eas-config-mismatch.`\n );\n } else if (ctx.env.EAS_BUILD_PROJECT_ID && !appConfig?.extra?.eas?.projectId) {\n ctx.logger.error(`The \"extra.eas.projectId\" field is missing from your app config.`);\n ctx.markBuildPhaseHasWarnings();\n }\n}\n"]}
|
|
@@ -9,7 +9,7 @@ async function configureEASUpdateAsync({ job, workingDirectory, logger, inputs,
|
|
|
9
9
|
const runtimeVersion = (_c = (_a = inputs.runtimeVersion) !== null && _a !== void 0 ? _a : (_b = job.version) === null || _b === void 0 ? void 0 : _b.runtimeVersion) !== null && _c !== void 0 ? _c : inputs.resolvedRuntimeVersion;
|
|
10
10
|
if ((metadata === null || metadata === void 0 ? void 0 : metadata.runtimeVersion) && metadata.runtimeVersion !== runtimeVersion) {
|
|
11
11
|
logger.warn(`Runtime version from the app config evaluated on your local machine (${metadata.runtimeVersion}) does not match the one resolved here (${runtimeVersion}).`);
|
|
12
|
-
logger.warn("If you're using conditional app configs, e.g. depending on an environment variable, make sure to set the variable in eas.json or configure it with EAS
|
|
12
|
+
logger.warn("If you're using conditional app configs, e.g. depending on an environment variable, make sure to set the variable in eas.json or configure it with EAS environment variables.");
|
|
13
13
|
}
|
|
14
14
|
const jobOrInputChannel = (_d = inputs.channel) !== null && _d !== void 0 ? _d : (_e = job.updates) === null || _e === void 0 ? void 0 : _e.channel;
|
|
15
15
|
if (isEASUpdateConfigured(appConfig, logger)) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"expoUpdates.js","sourceRoot":"","sources":["../../../src/steps/utils/expoUpdates.ts"],"names":[],"mappings":";;;AAAA,uDAAwE;AAIxE,mDAI2B;AAC3B,uDAI+B;AAExB,KAAK,UAAU,uBAAuB,CAAC,EAC5C,GAAG,EACH,gBAAgB,EAChB,MAAM,EACN,MAAM,EACN,SAAS,EACT,QAAQ,GAYT;;IACC,MAAM,cAAc,GAClB,MAAA,MAAA,MAAM,CAAC,cAAc,mCAAI,MAAA,GAAG,CAAC,OAAO,0CAAE,cAAc,mCAAI,MAAM,CAAC,sBAAsB,CAAC;IAExF,IAAI,CAAA,QAAQ,aAAR,QAAQ,uBAAR,QAAQ,CAAE,cAAc,KAAI,QAAQ,CAAC,cAAc,KAAK,cAAc,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AAQ,EAAE,CAAC;QACrB,KAAK,wBAAQ,CAAC,OAAO,CAAC,CAAC,CAAC;YACtB,OAAO,MAAM,IAAA,mDAAqC,EAAC,gBAAgB,CAAC,CAAC;QACvE,CAAC;QACD,KAAK,wBAAQ,CAAC,GAAG,CAAC,CAAC,CAAC;YAClB,OAAO,MAAM,IAAA,+CAAiC,EAAC,gBAAgB,CAAC,CAAC;QACnE,CAAC;QACD;YACE,MAAM,IAAI,KAAK,CAAC,4BAA4B,CAAC,CAAC;IAClD,CAAC;AACH,CAAC;AAED,KAAK,UAAU,8BAA8B,CAC3C,GAAQ,EACR,cAAsB,EACtB,gBAAwB;IAExB,QAAQ,GAAG,CAAC,QAAQ,EAAE,CAAC;QACrB,KAAK,wBAAQ,CAAC,OAAO,CAAC,CAAC,CAAC;YACtB,MAAM,IAAA,mDAAqC,EAAC,cAAc,EAAE,gBAAgB,CAAC,CAAC;YAC9E,OAAO;QACT,CAAC;QACD,KAAK,wBAAQ,CAAC,GAAG,CAAC,CAAC,CAAC;YAClB,MAAM,IAAA,+CAAiC,EAAC,cAAc,EAAE,gBAAgB,CAAC,CAAC;YAC1E,OAAO;QACT,CAAC;QACD;YACE,MAAM,IAAI,KAAK,CAAC,4BAA4B,CAAC,CAAC;IAClD,CAAC;AACH,CAAC","sourcesContent":["import { BuildJob, Job, Metadata, Platform } from '@expo/eas-build-job';\nimport { bunyan } from '@expo/logger';\nimport { ExpoConfig } from '@expo/config';\n\nimport {\n iosGetNativelyDefinedChannelAsync,\n iosSetChannelNativelyAsync,\n iosSetRuntimeVersionNativelyAsync,\n} from './ios/expoUpdates';\nimport {\n androidGetNativelyDefinedChannelAsync,\n androidSetChannelNativelyAsync,\n androidSetRuntimeVersionNativelyAsync,\n} from './android/expoUpdates';\n\nexport async function configureEASUpdateAsync({\n job,\n workingDirectory,\n logger,\n inputs,\n appConfig,\n metadata,\n}: {\n job: BuildJob;\n workingDirectory: string;\n logger: bunyan;\n inputs: {\n runtimeVersion?: string;\n channel?: string;\n resolvedRuntimeVersion?: string;\n };\n appConfig: ExpoConfig;\n metadata: Metadata | null;\n}): Promise<void> {\n const runtimeVersion =\n inputs.runtimeVersion ?? job.version?.runtimeVersion ?? inputs.resolvedRuntimeVersion;\n\n if (metadata?.runtimeVersion && metadata.runtimeVersion !== runtimeVersion) {\n logger.warn(\n `Runtime version from the app config evaluated on your local machine (${metadata.runtimeVersion}) does not match the one resolved here (${runtimeVersion}).`\n );\n logger.warn(\n \"If you're using conditional app configs, e.g. depending on an environment variable, make sure to set the variable in eas.json or configure it with EAS environment variables.\"\n );\n }\n\n const jobOrInputChannel = inputs.channel ?? job.updates?.channel;\n\n if (isEASUpdateConfigured(appConfig, logger)) {\n if (jobOrInputChannel) {\n await configureEASUpdate(job, logger, jobOrInputChannel, workingDirectory);\n } else {\n const channel = await getChannelAsync(job, workingDirectory);\n const isDevelopmentClient = job.developmentClient ?? false;\n\n if (channel) {\n const configFile = job.platform === Platform.ANDROID ? 'AndroidManifest.xml' : 'Expo.plist';\n logger.info(`The channel name for EAS Update in ${configFile} is set to \"${channel}\"`);\n } else if (isDevelopmentClient) {\n // NO-OP: Development clients don't need to have a channel set\n } else {\n const easUpdateUrl = appConfig.updates?.url ?? null;\n const jobProfile = job.buildProfile ?? null;\n logger.warn(\n `This build has an invalid EAS Update configuration: update.url is set to \"${easUpdateUrl}\" in app config, but a channel is not specified${\n jobProfile ? '' : ` for the current build profile \"${jobProfile}\" in eas.json`\n }.`\n );\n logger.warn(`- No channel will be set and EAS Update will be disabled for the build.`);\n logger.warn(\n `- Run \\`eas update:configure\\` to set your channel in eas.json. For more details, see https://docs.expo.dev/eas-update/getting-started/#configure-your-project`\n );\n }\n }\n } else {\n logger.info(`Expo Updates is not configured, skipping configuring Expo Updates.`);\n }\n\n if (runtimeVersion) {\n logger.info('Updating runtimeVersion in Expo.plist');\n await setRuntimeVersionNativelyAsync(job, runtimeVersion, workingDirectory);\n }\n}\n\nexport function isEASUpdateConfigured(appConfig: ExpoConfig, logger: bunyan): boolean {\n const rawUrl = appConfig.updates?.url;\n if (!rawUrl) {\n return false;\n }\n try {\n const url = new URL(rawUrl);\n return ['u.expo.dev', 'staging-u.expo.dev'].includes(url.hostname);\n } catch (err) {\n logger.error({ err }, `Cannot parse expo.updates.url = ${rawUrl} as URL`);\n logger.error(`Assuming EAS Update is not configured`);\n return false;\n }\n}\n\nasync function configureEASUpdate(\n job: Job,\n logger: bunyan,\n channel: string,\n workingDirectory: string\n): Promise<void> {\n const newUpdateRequestHeaders: Record<string, string> = {\n 'expo-channel-name': channel,\n };\n\n const configFile = job.platform === Platform.ANDROID ? 'AndroidManifest.xml' : 'Expo.plist';\n logger.info(\n `Setting the update request headers in '${configFile}' to '${JSON.stringify(\n newUpdateRequestHeaders\n )}'`\n );\n\n switch (job.platform) {\n case Platform.ANDROID: {\n await androidSetChannelNativelyAsync(channel, workingDirectory);\n return;\n }\n case Platform.IOS: {\n await iosSetChannelNativelyAsync(channel, workingDirectory);\n return;\n }\n default:\n throw new Error(`Platform is not supported.`);\n }\n}\n\nasync function getChannelAsync(job: Job, workingDirectory: string): Promise<string | null> {\n switch (job.platform) {\n case Platform.ANDROID: {\n return await androidGetNativelyDefinedChannelAsync(workingDirectory);\n }\n case Platform.IOS: {\n return await iosGetNativelyDefinedChannelAsync(workingDirectory);\n }\n default:\n throw new Error(`Platform is not supported.`);\n }\n}\n\nasync function setRuntimeVersionNativelyAsync(\n job: Job,\n runtimeVersion: string,\n workingDirectory: string\n): Promise<void> {\n switch (job.platform) {\n case Platform.ANDROID: {\n await androidSetRuntimeVersionNativelyAsync(runtimeVersion, workingDirectory);\n return;\n }\n case Platform.IOS: {\n await iosSetRuntimeVersionNativelyAsync(runtimeVersion, workingDirectory);\n return;\n }\n default:\n throw new Error(`Platform is not supported.`);\n }\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@expo/build-tools",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.172",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -25,14 +25,14 @@
|
|
|
25
25
|
"@expo/config": "10.0.6",
|
|
26
26
|
"@expo/config-plugins": "9.0.12",
|
|
27
27
|
"@expo/downloader": "1.0.118",
|
|
28
|
-
"@expo/eas-build-job": "1.0.
|
|
28
|
+
"@expo/eas-build-job": "1.0.172",
|
|
29
29
|
"@expo/env": "^0.4.0",
|
|
30
30
|
"@expo/logger": "1.0.117",
|
|
31
31
|
"@expo/package-manager": "1.7.0",
|
|
32
32
|
"@expo/plist": "^0.2.0",
|
|
33
33
|
"@expo/repack-app": "0.0.6",
|
|
34
34
|
"@expo/results": "^1.0.0",
|
|
35
|
-
"@expo/steps": "1.0.
|
|
35
|
+
"@expo/steps": "1.0.172",
|
|
36
36
|
"@expo/template-file": "1.0.117",
|
|
37
37
|
"@expo/turtle-spawn": "1.0.117",
|
|
38
38
|
"@expo/xcpretty": "^4.3.1",
|
|
@@ -75,5 +75,5 @@
|
|
|
75
75
|
"node": "20.14.0",
|
|
76
76
|
"yarn": "1.22.21"
|
|
77
77
|
},
|
|
78
|
-
"gitHead": "
|
|
78
|
+
"gitHead": "3fb33bcfe632cfa8e3a0e8fcceda82a8214c79c5"
|
|
79
79
|
}
|