SDK 46 build error on expo-dev-menu

After upgrade to sdk 46, I have the following message

❌  error: Multiple commands produce '/Users/expo/Library/Developer/Xcode/DerivedData/niceandcomobile-hamodiixzgfsswgplhvlcrjjsoxo/Build/Intermediates.noindex/ArchiveIntermediates/niceandcomobile/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/EXDevMenu.framework/PrivateHeaders/DevMenuRNGestureHandlerStateManager.h'

    duplicate output file '/Users/expo/Library/Developer/Xcode/DerivedData/niceandcomobile-hamodiixzgfsswgplhvlcrjjsoxo/Build/Intermediates.noindex/ArchiveIntermediates/niceandcomobile/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/EXDevMenu.framework/PrivateHeaders/DevMenuRNGestureHandlerStateManager.h' on task: CpHeader /Users/expo/Library/Developer/Xcode/DerivedData/niceandcomobile-hamodiixzgfsswgplhvlcrjjsoxo/Build/Intermediates.noindex/ArchiveIntermediates/niceandcomobile/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/EXDevMenu.framework/PrivateHeaders/DevMenuRNGestureHandlerStateManager.h /Users/expo/workingdir/build/node_modules/expo-dev-menu/vendored/react-native-reanimated/ios/DevMenuRNGestureHandlerStateManager.h (in target 'expo-dev-menu' from project 'Pods')


In Xcode logs

note: Target 'expo-dev-menu' (project 'Pods') has copy command from '/Users/expo/workingdir/build/node_modules/expo-dev-menu/vendored/react-native-gesture-handler/ios/DevMenuRNGestureHandlerStateManager.h' to '/Users/expo/Library/Developer/Xcode/DerivedData/niceandcomobile-hamodiixzgfsswgplhvlcrjjsoxo/Build/Intermediates.noindex/ArchiveIntermediates/niceandcomobile/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/EXDevMenu.framework/PrivateHeaders/DevMenuRNGestureHandlerStateManager.h'

note: Target 'expo-dev-menu' (project 'Pods') has copy command from '/Users/expo/workingdir/build/node_modules/expo-dev-menu/vendored/react-native-reanimated/ios/DevMenuRNGestureHandlerStateManager.h' to '/Users/expo/Library/Developer/Xcode/DerivedData/niceandcomobile-hamodiixzgfsswgplhvlcrjjsoxo/Build/Intermediates.noindex/ArchiveIntermediates/niceandcomobile/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/EXDevMenu.framework/PrivateHeaders/DevMenuRNGestureHandlerStateManager.h'

Hi @mlecoq

Does expo doctor complain about anything? Maybe also try removing your node_modules and your package-lock.json / yarn.lock to re-installing your dependencies.

If that doesn’t help, please post your dependencies and devDependencies here.

Here is expo doctor result

Running "expo doctor"
- Finding all copies of expo-modules-autolinking
✔ Found all copies of expo-modules-autolinking
[06:01:25]   All copies of expo-modules-autolinking satisfy ~0.10.0
- Finding all copies of @expo/config-plugins
✔ Found all copies of @expo/config-plugins
[06:01:27]   All copies of @expo/config-plugins satisfy ^5.0.0
- Finding all copies of @expo/prebuild-config
✔ Found all copies of @expo/prebuild-config
[06:01:29]   All copies of @expo/prebuild-config satisfy ^5.0.1
[06:01:31] 🎉 Didn't find any issues with the project!

I’m trying with erase of yarn.lock file and removing / reinstalling node_modules

@wodin I have the same result, here is my package.json file

  "scripts": {
    "start": "expo start --dev-client",
    "web": "expo start --web",
    "eject": "expo eject",
    "prepare": "husky install",
    "android": "expo run:android",
    "ios": "expo run:ios",
    "postinstall": "patch-package"
  "dependencies": {
    "@expo/config-plugins": "^5.0.0",
    "@expo/webpack-config": "^0.16.27",
    "@gorhom/bottom-sheet": "^4.4.2",
    "@hookform/resolvers": "^2.9.6",
    "@react-native-community/datetimepicker": "6.2.0",
    "@react-native-firebase/app": "^15.2.0",
    "@react-native-firebase/auth": "^15.2.0",
    "@react-native-firebase/firestore": "^15.2.0",
    "@react-native-firebase/storage": "^15.2.0",
    "@react-native-masked-view/masked-view": "0.2.6",
    "@react-navigation/bottom-tabs": "^6.3.2",
    "@react-navigation/native": "^6.0.11",
    "@react-navigation/stack": "^6.2.2",
    "expo": "^46.0.0-beta.6",
    "expo-build-properties": "~0.3.0",
    "expo-camera": "~12.3.0",
    "expo-dev-client": "~1.1.0",
    "expo-font": "~10.2.0",
    "expo-image-picker": "~13.3.0",
    "expo-linear-gradient": "~11.4.0",
    "expo-linking": "~3.2.1",
    "expo-media-library": "~14.2.0",
    "expo-modules-autolinking": "~0.10.0",
    "expo-splash-screen": "~0.16.1",
    "expo-status-bar": "~1.4.0",
    "expo-updates": "~0.14.2",
    "nanoid": "^4.0.0",
    "native-base": "^3.4.9",
    "patch-package": "^6.4.7",
    "postinstall-postinstall": "^2.1.0",
    "react": "18.0.0",
    "react-dom": "18.0.0",
    "react-hook-form": "^7.33.1",
    "react-native": "0.69.1",
    "react-native-animated-pagination-dots": "^0.1.72",
    "react-native-gesture-handler": "~2.5.0",
    "react-native-get-random-values": "~1.8.0",
    "react-native-loading-spinner-overlay": "^3.0.0",
    "react-native-pager-view": "5.4.24",
    "react-native-reanimated": "~2.9.1",
    "react-native-safe-area-context": "4.3.1",
    "react-native-screens": "~3.15.0",
    "react-native-svg": "12.3.0",
    "react-native-toast-message": "^2.1.5",
    "react-native-web": "~0.18.7",
    "slugify": "^1.6.5",
    "styled-components": "^5.3.5",
    "styled-system": "^5.1.5",
    "zod": "^3.17.10"
  "devDependencies": {
    "@babel/core": "^7.18.9",
    "@babel/preset-env": "^7.18.9",
    "@babel/preset-typescript": "^7.18.6",
    "@commitlint/config-conventional": "^17.0.3",
    "@react-native-community/eslint-config": "^3.0.3",
    "@release-it/conventional-changelog": "^5.0.0",
    "@types/react": "~18.0.15",
    "@types/react-native": "~0.69.3",
    "@types/react-native-loading-spinner-overlay": "^0.5.3",
    "@types/styled-components": "^5.1.25",
    "@types/styled-components-react-native": "^5.1.3",
    "@typescript-eslint/eslint-plugin": "^5.30.7",
    "@typescript-eslint/parser": "^5.30.7",
    "commitlint": "^17.0.3",
    "eslint": "^8.20.0",
    "eslint-plugin-import": "^2.26.0",
    "eslint-plugin-prettier": "^4.2.1",
    "eslint-plugin-react": "^7.30.1",
    "eslint-plugin-react-native": "^4.0.0",
    "husky": "^8.0.1",
    "lint-staged": "^13.0.3",
    "prettier": "^2.7.1",
    "react-native-svg-transformer": "^1.0.0",
    "release-it": "^15.1.3",
    "stylelint": "^14.9.1",
    "stylelint-config-react-native-styled-components": "^0.5.0",
    "stylelint-processor-styled-components": "^1.10.0",
    "stylelint-react-native": "^2.4.0",
    "typescript": "^4.6.3"
  "lint-staged": {
    "*.ts?(x)": [
      "prettier --write",
    "*.js?(x)": [
      "prettier --write",
    "*.js": "eslint --cache --fix"
  "commitlint": {
    "extends": [
  "release-it": {
    "git": {
      "commitMessage": "chore: release ${version}",
      "tagName": "v${version}"
    "github": {
      "release": true
    "npm": {
      "publish": false
    "plugins": {
      "@release-it/conventional-changelog": {
        "preset": "angular"
  "private": true,
  "name": "niceandco-mobile",
  "version": "1.0.0"

Do you have any relevant config plugins or patches (I see you have patch-package installed).

I tried building with your dependencies and ran into a few issues:

1.) An apparent issue with “release-it”. I am not familiar with it, so I didn’t add the “release-it” section to my package.json. Seems unlikely that the error has something to do with that, but anyway… I just removed the devDependencies (other than @babel/core) which got thing further along:

Installing pods

Using Expo modules

[stderr] error Failed to load configuration of your project.

[!] Invalid `Podfile` file: 783: unexpected token at 'Error [ERR_PACKAGE_PATH_NOT_EXPORTED]: Package subpath './package.json' is not defined by "exports" in /Users/expo/workingdir/build/node_modules/@release-it/conventional-changelog/package.json

2.) Then I got some firebase-related errors. Maybe I’m missing a config plugin or something:

Installing react-native-safe-area-context (4.3.1)

[!] The following Swift pods cannot yet be integrated as static libraries:

The Swift pod `FirebaseCoreInternal` depends upon `GoogleUtilities`, which does not define modules. To opt into those targets generating module maps (which is necessary to import them from Swift when building as static libraries), you may set `use_modular_headers!` globally in your Podfile, or specify `:modular_headers => true` for particular dependencies.

The Swift pod `FirebaseStorage` depends upon `FirebaseStorageInternal`, `FirebaseAppCheckInterop`, `FirebaseAuthInterop`, `FirebaseCore`, and `FirebaseCoreExtension`, which do not define modules. To opt into those targets generating module maps (which is necessary to import them from Swift when building as static libraries), you may set `use_modular_headers!` globally in your Podfile, or specify `:modular_headers => true` for particular dependencies.

pod exited with non-zero code: 1

After removing all of the firebase dependencies it builds.

Ok, for your first issue (release-it and @release-it/conventional-changelog) I have 2 patches that are not related to expo since I have the same for pure rn project

patch for release-it

diff --git a/node_modules/release-it/package.json b/node_modules/release-it/package.json
index 0c43af1..909f3c9 100644
--- a/node_modules/release-it/package.json
+++ b/node_modules/release-it/package.json
@@ -38,7 +38,8 @@
   "type": "module",
   "exports": {
     ".": "./lib/index.js",
-    "./test/util/index.js": "./test/util/index.js"
+    "./test/util/index.js": "./test/util/index.js",
+    "./package.json": "./package.json"
   "files": [

patch for @release-it/conventional-changelog

diff --git a/node_modules/@release-it/conventional-changelog/package.json b/node_modules/@release-it/conventional-changelog/package.json
index 004a8b5..6ff5967 100644
--- a/node_modules/@release-it/conventional-changelog/package.json
+++ b/node_modules/@release-it/conventional-changelog/package.json
@@ -3,7 +3,10 @@
   "version": "5.0.0",
   "description": "Conventional changelog plugin for release-it",
   "type": "module",
-  "exports": "./index.js",
+  "exports": {
+    ".": "./index.js",
+    "./package.json": "./package.json"
+  },
   "scripts": {
     "test": "bron test.js --serial",
     "release": "release-it"

for the second issue, react-native-firebase needs additional config in app.json

 "plugins": [
      ["expo-build-properties", {"ios": {"useFrameworks": "dynamic"}}],

@wodin I have a small project where you can reproduce the issue

with the following command:

eas build --profile development --platform ios --local

@wodin fyi I still have the issue with sdk 46.0.1

I had a look over the weekend and went down a rabbit hole trying to figure out what was going on (I discovered that patch-package excludes package.json by default and when I tried to override that it I wasn’t able to!). Anyway, I have not figured out yet what the problem is, but I suggest you try to remove dependencies until it builds, or alternatively create a new app and add dependencies until it fails.

You can in theory do a binary search. i.e. Remove half of the dependencies. If it builds, the chances are the problem is in the other half. If it fails, try removing half of those. etc. So at each step you’ll be (approximately) halving the number of dependencies that could be causing the problem.

Then once you have narrowed it down to a specific dependency (or small set of dependencies) it should be easier to figure out what the problem is and find a solution or know where to log an issue.

in this project

when I remove
["expo-build-properties", {"ios": {"useFrameworks": "dynamic"}}], in app.json file, it builds successfully. Otherwise it fails with the message about DevMenuRNGestureHandlerStateManager.h

In this project this config is useless but for react-native-firebase it is mandatory

I already had an issue on sdk 45 with this configuration (as discussed with @notbrent in this topic : 'EXDevMenu-Swift.h' file not found - #13 by mlecoq)

Something new in sdk 46 about expo-build-properties ?

@wodin do you have enough information to reproduce the issue ?

It looks like there’s an incompatibility between react-native-reanimated and expo-dev-menu that was fixed here, but if you install expo-dev-client currently, you still get an older version of expo-dev-menu.

Try upgrading expo-dev-client to 1.1.1.
Also, I don’t think you need @expo/config-plugins and maybe not @expo/webpack-config.

Thanks for your feedback,

I have tried what you suggest and updated my example app and I have still the same issue

OK. I think that if you can reduce your example to the bare minimum list of dependencies that still fails to build, then it might make sense to create an issue on GitHub. (Of course if the problem only occurs when installing a third party dependency, then it probably makes sense to create the issue in their repository rather than Expo’s.)

I’m actually having the same issue. Has a GitHub issue been created for this?

Do you use expo-build-properties ?

I think it’s the cause of the issue

Yes. I have a very similar build to what you have listed.

My solution was rolling back to react 17 and Expo SDK 45. I dropped back to expo-build-properties ~0.2.0 as well. I’m using the Managed workflow right now.

If you’re using the bare workflow, it might be worth removing the expo-build-properties piece and doing the frameworks piece manually.