Skip to content

Archive broken on Xcode 16 for React Native 0.75 #48599

@Kadir-flipcause

Description

@Kadir-flipcause

Description

I have a production app built with react native that has the iOS Archive broken after an upgrade. This is a bare React Native project (not an expo project). I upgraded the following:

react-native version to 0.75.4
Xcode to v16

So I'm not really sure which of those upgrades are causing the problem.

Running the app in debug mode works ok, however when archiving (in order to publish a new version of the app) it throws the error: 'EMFILE too many files open' and looking the full logs I see that comes from Metro. That confuses me because as far as I know metro should not be running as part of the archive process, but this is fired from the react native scripts.

Any ideas?

I have tried to fix that Metro error by removing the line -reset-cache from react-native-xcode.sh and now it breaks in a different place. But I don't think touching the react native scripts is the way to go

Steps to reproduce

  1. build archive
    2.install ipa on iphone
  2. app is crashing on launchscreen

React Native Version

0.75.4

Affected Platforms

Runtime - iOS, Build - MacOS

Output of npx react-native info

System:
  OS: macOS 15.1.1
  CPU: (8) arm64 Apple M2
  Memory: 104.44 MB / 16.00 GB
  Shell:
    version: "5.9"
    path: /bin/zsh
Binaries:
  Node:
    version: 21.7.1
    path: /usr/local/bin/node
  Yarn: Not Found
  npm:
    version: 10.8.1
    path: /usr/local/bin/npm
  Watchman:
    version: 2024.03.25.00
    path: /opt/homebrew/bin/watchman
Managers:
  CocoaPods:
    version: 1.15.2
    path: /Users/raghunaik/.rubies/ruby-2.6.10/bin/pod
SDKs:
  iOS SDK:
    Platforms:
      - DriverKit 24.1
      - iOS 18.1
      - macOS 15.1
      - tvOS 18.1
      - visionOS 2.1
      - watchOS 11.1
  Android SDK: Not Found
IDEs:
  Android Studio: 2024.2 AI-242.23339.11.2421.12550806
  Xcode:
    version: 16.1/16B40
    path: /usr/bin/xcodebuild
Languages:
  Java:
    version: 17.0.10
    path: /usr/bin/javac
  Ruby:
    version: 2.6.10
    path: /Users/raghunaik/.rubies/ruby-2.6.10/bin/ruby
npmPackages:
  "@react-native-community/cli": Not Found
  react:
    installed: 18.3.1
    wanted: 18.3.1
  react-native:
    installed: 0.75.4
    wanted: 0.75.4
  react-native-macos: Not Found
npmGlobalPackages:
  "*react-native*": Not Found
Android:
  hermesEnabled: true
  newArchEnabled: false
iOS:
  hermesEnabled: true
  newArchEnabled: false

Metadata

Metadata

Assignees

No one assigned

    Labels

    Needs: Author FeedbackNeeds: ReproThis issue could be improved with a clear list of steps to reproduce the issue.StaleThere has been a lack of activity on this issue and it may be closed soon.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions