Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

iOS internal distribution build is failing during Pods Install step #2308

Closed
speedhawk21 opened this issue Mar 31, 2024 · 3 comments
Closed
Labels
needs review Issue is ready to be reviewed by a maintainer

Comments

@speedhawk21
Copy link

speedhawk21 commented Mar 31, 2024

Build/Submit details page URL

https://expo.dev/accounts/briansc/projects/toprecall/builds/ca8d63fc-542b-4de4-807a-b27612d4301e

Summary

When I push to EAS, the build fails at the Install Pods stage. Expo Doctor on EAS also shows an error, with strip-ansi related to Metro.

Locally the build succeeds and there are no issues with Expo Doctor. I'm able to run the app in the IOS simulator without issue and also run a local web build.

The error only occurs when deploying to EAS when it reaches the Pod Install stage. Here is the error:

Using Expo modules
[Expo] Enabling modular headers for pod ExpoModulesCore
[!] Invalid `Podfile` file: undefined method `[]' for nil:NilClass.
   from /Users/expo/workingdir/build/ios/Podfile:42
   -------------------------------------------
     use_expo_modules!
 >    config = use_native_modules!
   
   -------------------------------------------

Here is my package.json:

{
  "name": "toprecall",
  "version": "0.0.1",
  "main": "expo-router/entry",
  "scripts": {
    "start": "expo start",
    "android": "expo run:android",
    "ios": "expo run:ios",
    "web": "expo start --web",
    "preview:ios": "EXPO_DEBUG=true eas build --profile preview --platform ios --non-interactive",
    "build:web": "expo export -p web",
    "serve": "serve dist",
    "prettier:write": "npx prettier --write ./src/**/*.{js,jsx,ts,tsx,json} && npx prettier --write *.{js,jsx,ts,tsx,json}",
    "lint": "tsc --noEmit && eslint --ext .js,.jsx,.ts,.tsx ./src/"
  },
  "dependencies": {
    "@aws-amplify/react-native": "^1.0.24",
    "@aws-amplify/rtn-web-browser": "^1.0.25",
    "@aws-amplify/ui-react-native": "^2.1.4",
    "@tanstack/query-async-storage-persister": "^5.18.0",
    "@tanstack/react-query": "^5.17.15",
    "@tanstack/react-query-persist-client": "^5.18.0",
    "aws-amplify": "^6.0.23",
    "react-native-gesture-handler": "~2.14.0",
    "react-native-get-random-values": "~1.8.0",
    "react-native-reanimated": "~3.6.2",
    "@expo/vector-icons": "^14.0.0",
    "@react-navigation/native": "^6.0.2",
    "expo": "~50.0.14",
    "expo-font": "~11.10.3",
    "expo-linking": "~6.2.2",
    "expo-router": "~3.4.8",
    "expo-splash-screen": "~0.26.4",
    "expo-status-bar": "~1.11.1",
    "expo-system-ui": "~2.9.3",
    "expo-web-browser": "~12.8.2",
    "react": "18.2.0",
    "react-dom": "18.2.0",
    "react-native": "0.73.6",
    "react-native-safe-area-context": "4.8.2",
    "react-native-screens": "~3.29.0",
    "react-native-web": "~0.19.6",
    "@react-native-async-storage/async-storage": "1.21.0"
  },
  "devDependencies": {
    "@babel/core": "^7.20.0",
    "@babel/eslint-parser": "^7.23.10",
    "@babel/plugin-proposal-export-namespace-from": "^7.18.9",
    "@react-native-community/eslint-config": "^3.2.0",
    "@tanstack/eslint-plugin-query": "^5.17.7",
    "@types/react": "~18.2.45",
    "eslint": "^8.56.0",
    "eslint-plugin-react": "^7.33.2",
    "eslint-plugin-react-native": "^4.1.0",
    "jest": "^29.2.1",
    "jest-expo": "~50.0.4",
    "prettier": "^3.2.4",
    "react-test-renderer": "18.2.0",
    "typescript": "^5.1.3"
  },
  "private": true
}

Managed or bare?

Managed

Environment

npx expo-doctor
✔ Check Expo config for common issues
✔ Check package.json for common issues
✔ Check dependencies for packages that should not be installed directly
✔ Check for issues with metro config
✔ Check for common project setup issues
✔ Check npm/ yarn versions
✔ Check Expo config (app.json/ app.config.js) schema
✔ Check that packages match versions required by installed Expo SDK
✔ Check native tooling versions
✔ Check for legacy global CLI installed locally
✔ Check that native modules do not use incompatible support packages
✔ Check that native modules use compatible support package versions for installed Expo SDK
npx expo-env-info
Need to install the following packages:
[email protected]
Ok to proceed? (y) 

  expo-env-info 1.2.0 environment info:
    System:
      OS: macOS 14.3.1
      Shell: 5.9 - /bin/zsh
    Binaries:
      Node: 18.18.2 - ~/.nvm/versions/node/v18.18.2/bin/node
      Yarn: 1.22.21 - ~/.nvm/versions/node/v18.18.2/bin/yarn
      npm: 9.8.1 - ~/.nvm/versions/node/v18.18.2/bin/npm
    Managers:
      CocoaPods: 1.14.3 - /usr/local/bin/pod
    SDKs:
      iOS SDK:
        Platforms: DriverKit 23.4, iOS 17.4, macOS 14.4, tvOS 17.4, visionOS 1.1, watchOS 10.4
    IDEs:
      Xcode: 15.3/15E204a - /usr/bin/xcodebuild
    npmPackages:
      expo: ~50.0.14 => 50.0.14 
      expo-router: ~3.4.8 => 3.4.8 
      react: 18.2.0 => 18.2.0 
      react-dom: 18.2.0 => 18.2.0 
      react-native: 0.73.6 => 0.73.6 
      react-native-web: ~0.19.6 => 0.19.10 
    npmGlobalPackages:
      eas-cli: 7.6.2
    Expo Workflow: managed

Error output

Using Expo modules
[Expo] Enabling modular headers for pod ExpoModulesCore
[!] Invalid `Podfile` file: undefined method `[]' for nil:NilClass.
 #  from /Users/expo/workingdir/build/ios/Podfile:42
 #  -------------------------------------------
 #    use_expo_modules!
 >    config = use_native_modules!
 #  
 #  -------------------------------------------
Error: Unknown error. See logs of the Install pods build phase for more information.

Reproducible demo or steps to reproduce from a blank project

This error occurs when running the build command:

eas build --profile preview --platform ios --non-interactive

@speedhawk21 speedhawk21 added the needs review Issue is ready to be reviewed by a maintainer label Mar 31, 2024
@speedhawk21
Copy link
Author

Was able to resolve this by removing plugins and pages. The issue was unrelated to the eas-cli after all so closing this.

@charlestbell
Copy link

What did you remove?

@speedhawk21
Copy link
Author

I believe it was the local storage package that caused the build error. It conflicted with the amplify version I was using and failed on the version of Linux eas used in their cloud build step. So not an eas issue but rather just two incompatible packages. I downgraded to an earlier version and the error resolved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs review Issue is ready to be reviewed by a maintainer
Projects
None yet
Development

No branches or pull requests

2 participants