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
Error Building the app in release mode "main.jsbundle does not exist" #36886
Comments
This issue is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days. |
I had this same issue Realized it was because I changed the Discovered this error by adding the below to package.json
and running |
This issue is waiting for author's feedback since 24 days. Please provide the requested feedback or this will be closed in 7 days. |
This issue was closed because it has been stalled for 7 days with no activity. |
I had to update |
Thanks for resolution. It works for me with a minor difference. My node binary was Hope helps to other. |
I solved it with this: background with me: When packaging The key to the solution is to use the correct node version when packaging. |
And the official documentation has given the hint: https://reactnative.dev/docs/environment-setup?guide=native#optional-configuring-your-environment |
Hi same issue after updating react-native to 0.72.4 from 0.70.5. |
I need to run everytime im creating archive, please some tips? |
It solved our issue... but I do not know if we still do that for every build
|
react-native repo will automatically bundle when create iOS archive |
After I forced Xcode to use the same Node.js version as my project, this issue stopped happening. To force the Node.js version, I simply set the default version to the correct one using the command:
|
thanks for sharing |
export PATH=/opt/homebrew/bin:$PATH Add the following lines in build phases under "Bundle React Native Code and Images" |
Thanks for sharing, it works in my trial. |
Posting my experiece since it might help someone else. I had a look at the script responsible for building the To get to this line I haven't figure out why If anyone knows why |
@roancoetzee you won't believe it, but you already helped someone (10h from your comment). Thank you, for pointing it out! Just noticed the same thing even on the latest react native version (0.73.5). p.s if you find out why it wasn't set, please share with us as well :) |
@roancoetzee You are super on point here! Can you explain to us how you came to this solution? What was the debugging process? |
@VitDev17 Glad it helped. Debugging wise it wasn't anything special. In xcode you can view the build logs by doing The error appeared under the |
@roancoetzee thanks, after hours of debugging this is the only solution works for me |
this help-me with error "Make sure you're running a packager server or have included a .jsbundle file in your application bundle." Thank you man. |
I appreciate your response, as it is very useful for my React-Native version 0.63.4. |
Description
We are building a react native application and we are facing this issue sometimes, without any changes building can work or fail
`▸ Running script 'Bundle React Native code and images'
the transform cache was reset.
❌ error: File /Users/runner/Library/Developer/Xcode/DerivedData/-eulgfyrcmjmgohfphedrvfvwygma/Build/Products/Release-iphoneos/***.app/main.jsbundle does not exist. This must be a bug with React Native, please report it here: https://github.com/facebook/react-native/issues
▸ Generating '**********.app.dSYM'
** BUILD FAILED **
The following build commands failed:
PhaseScriptExecution Bundle\ React\ Native\ code\ and\ images /Users/runner/Library/Developer/Xcode/DerivedData/-eulgfyrcmjmgohfphedrvfvwygma/Build/Intermediates.noindex/**********.build/Release-iphoneos/.build/Script-00DD1BFF1BD5951E806B06BC.sh
(1 failure)
##[error]Error: /usr/bin/xcodebuild failed with return code: 65`
th
React Native Version
0.71.6
Output of
npx react-native info
System:
OS: macOS 12.6.4
CPU: (3) x64 Intel(R) Xeon(R) CPU E5-1650 v2 @ 3.50GHz
Memory: 5.16 GB / 14.00 GB
Shell: 3.2.57 - /bin/bash
Binaries:
Node: 16.16.0 - ~/hostedtoolcache/node/16.16.0/x64/bin/node
Yarn: 1.22.19 - ~/.yarn/bin/yarn
npm: 8.11.0 - ~/hostedtoolcache/node/16.16.0/x64/bin/npm
Watchman: Not Found
Managers:
CocoaPods: 1.12.0 - /usr/local/lib/ruby/gems/3.0.0/bin/pod
SDKs:
iOS SDK:
Platforms: DriverKit 22.2, iOS 16.2, macOS 13.1, tvOS 16.1, watchOS 9.1
Android SDK:
API Levels: 27, 28, 29, 30, 31, 32, 33, 33, 33
Build Tools: 27.0.0, 27.0.1, 27.0.2, 27.0.3, 28.0.0, 28.0.1, 28.0.2, 28.0.3, 29.0.0, 29.0.1, 29.0.2, 29.0.3, 30.0.0, 30.0.1, 30.0.2, 30.0.3, 31.0.0, 32.0.0, 33.0.0, 33.0.1, 33.0.2
Android NDK: 25.2.9519653
IDEs:
Android Studio: Not Found
Xcode: 14.2/14C18 - /usr/bin/xcodebuild
Languages:
Java: 1.8.0_362 - /usr/bin/javac
npmPackages:
@react-native-community/cli: Not Found
react: 18.2.0 => 18.2.0
react-native: 0.71.6 => 0.71.6
react-native-macos: Not Found
npmGlobalPackages:
react-native: Not Found
Steps to reproduce
Build the app, in an azure pipeline enviroemnt, and its not stable on my local machine, I get
Snack, code example, screenshot, or link to a repository
npx react-native run-ios --configuration Release
The text was updated successfully, but these errors were encountered: