razorpay / react-native-razorpay

React Native wrapper for Razorpay's mobile SDKs
https://www.npmjs.com/package/react-native-razorpay
MIT License
121 stars 107 forks source link

eas cannot compile razorpay bundle #404

Closed alalfakawma closed 2 years ago

alalfakawma commented 2 years ago

Description

Build using eas-cli is failing using the command:

eas build --platform android --profile preview

It was working before, but as my builds for iOS were failing I updated to RN 66 which has better support for iOS 15 and xcode 13.

Razorpay Package Version :

v2.2.9

Xcode Version (iOS) :

I assume eas uses Xcode 13

Razorpay-pod version (iOS) :

Can't find lock file for pod in the files generated by expo prebuild.

What you did:

Tried to build using eas-cli

What happened:

Here is a link to Fastlane output.

Steps To Reproduce

Provide a detailed list of steps that reproduce the issue.

  1. On expo sdk 44, upgrade to RN 66.
  2. Use { "ios": { "image": "latest" } } in eas.json file.
  3. Run a preview build for ios

Suggested solution:

I'm not too sure what is happening as I'm not an iOS user or don't own any hardware to go into the nitty gritty of things.

Code example, screenshot, or link to a repository:

eas.json file:

{
    "cli": {
        "version": ">= 0.41.0"
    },
    "build": {
        "development": {
            "developmentClient": true,
            "distribution": "internal"
        },
        "preview": {
            "ios": {
                "image":"latest"
            },
            "distribution": "internal"
        },
        "production": {}
    },
    "submit": {
        "production": {}
    }
}

Expo env just incase that maybe helpful:

 expo-env-info 1.0.2 environment info:
    System:
      OS: Linux 5.10 Manjaro Linux
      Shell: 5.8 - /bin/zsh
    Binaries:
      Node: 16.12.0 - ~/.nvm/versions/node/v16.12.0/bin/node
      Yarn: 1.22.17 - ~/.nvm/versions/node/v16.12.0/bin/yarn
      npm: 8.1.2 - ~/.nvm/versions/node/v16.12.0/bin/npm
    SDKs:
      Android SDK:
        API Levels: 30, 31
        Build Tools: 29.0.2, 30.0.3, 31.0.0
        System Images: android-30 | Google APIs Intel x86 Atom_64, android-31 | Google APIs Intel x86 Atom_64
    IDEs:
      Android Studio: AI-203.7717.56.2031.7583922
    npmPackages:
      expo: ^44.0.0 => 44.0.6
      react: 17.0.2 => 17.0.1
      react-dom: 17.0.2 => 17.0.2
      react-native: 0.66.4 => 0.64.3
      react-native-web: 0.17.1 => 0.17.1
    npmGlobalPackages:
      eas-cli: 0.51.0
      expo-cli: 5.3.2
    Expo Workflow: bare

NOTE: This only happens on production builds. I've also tried this on a completely new project, built the project beforehand with the base expo dependencies which passed. As soon as I added the razorpay package, the build fails.

alalfakawma commented 2 years ago

Must have been an issues with eas build systems version instead. Works now.