iosxcodereact-nativeexpoeas

Expo eas build error: Xcode 16.3 and undefined template 'std::char_traits<unsigned char>' prevent building the app


I’m facing an unknown error when building my application made with React Native and Expo using the managed workflow. Everything was working fine during my previous builds until today, when I encountered this error in terminal.

iOS build failed:

The "Run fastlane" step failed because of an error in the Xcode build process. We automatically detected following errors in your Xcode build logs:

- implicit instantiation of undefined template 'std::char_traits<unsigned char>'

Refer to "Xcode Logs" below for additional, more detailed logs.

After doing some research online, I came across a thread that discusses this issue, Xcode 16.3 and undefined template 'std::char_traits' prevent building the app

but unfortunately, the solutions suggested—like downgrading the Xcode version—only apply to the React Native bare workflow.

I’m working with the managed workflow, and I don’t know how to fix this problem. My app has already been in production, and it’s when trying to push an update that I’m now running into this issue during the build with EAS.

Could someone please suggest a solution for the managed workflow? Thank you.


Solution

  • SOLUTION: Expo has updated the default build image to use Xcode 16.3. For apps using expo 51 or lower. They need to update EAS config to use an older Xcode in the build process. This can be done by adding the following to eas.json

    {
      "build": {
        [production|development|preview]: {
           "ios": {
              "image": "macos-sonoma-14.6-xcode-16.0"
           }
        }
      } 
    }