-
Notifications
You must be signed in to change notification settings - Fork 24.3k
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
main.jsbundle does not exist. This must be a bug with #29356
Comments
This fixed it for me: |
Thanks @ioveracker Initially, just tried to get the value of $PROJECT_DIR on terminal but no error & no output. so, .bash_profile is updated like below export PATH="/usr/local/opt/node@10/bin:$PATH" export PROJECT_DIR="/Users/user/Documents/projects/projectRepo/ocb"alias OPEN_DEV_MENU='adb shell input keyevent 82' and then, followed those steps of #29351 (comment) & made changes at Build Phases -> Bundle React Native Code and Images cd $PROJECT_DIR/.. But still it produces the same error
if you have any idea, please share Thanks |
Hi @ioveracker, react-native bundle & #18313 helps me to fix this issue builds the javascript bundle for offline use Options: Finally, to fix this issue, i added Works fine!! Thanks |
For me, the bundle command executed by |
In my case, when compiling the bundle in release mode it was throwing a JS error, regarding using numbers like
|
For me, after struggling a bit with watchman, this problem appeared. The thing is, watchman found that a folder had "too much permissions" and suggested it to change it to chmod 0700. But, it wasn't actually a suggestion lol, instead this was blocking the bundle to build itself. After changing to the suggested permission it built nicely again |
Do you solve the problem? I have the same problem |
Upgrading |
@xlcrr can you please try to Archive a build now, because the error reappears for me with react-native v0.63.4 |
@SohaibKtb yes I was able to archive last night |
Weird, the error happens suddenly, I tried also with a new react-native project but still happening 🙁 |
|
same, here is the issue #31025 (comment) |
@stefanoeb May I ask how can we see the failure reason in the log? |
I tried absolutely everything I could find here and anywhere else but nothing helps - always ending up with the same error:
I even checked the dir and indeed, there is NO |
@Twisterking must be a syntax error on your JS
|
@xilin If you're building with Xcode check this place out: If you're using the CLI (like |
Thanks. We use fastlane gym running with Jenkins, which is a little different. Will try to find it in log next time. |
@stefanoeb Thanks, that was my case as well. I find crazy how it works fine during development, but only fails when I try to generate a build to production. I spent an entire day today trying to figure out what was wrong until I found your message 😡 Thanks again for helping! |
This was the case for me, I was using node v14.16.1 which worked fine, then switched to v15.14.0 where it started to fail in production release. |
The same error encountered after switching from 15 to 16 Node version. My solution was to remove and install again node_modules folder, but I hardly see why this helped. |
@haruhiroYakumo right?! closing simulator and reinstalling the pods were my solutions what is the reason for this issue? |
Turned out there was a syntax error in my source code, fixing the syntax error fixed the missing bundle error when archiving in Xcode. Not sure why Xcode didn't report the syntax error while bundling for Android in command-line did. |
'error: File /Users/user/Library/Developer/Xcode/DerivedData/NewApp-fvicxnfjlfuonigoqscurptyhntn/Build/Products/Release-iphonesimulator/NewApp.app/main.jsbundle does not exist. This must be a bug with'
React Native version:
react-native info
warn Your project is using deprecated "rnpm" config that will stop working from next release. Please use a "react-native.config.js" file to configure the React Native CLI. Migration guide: https://github.com/react-native-community/cli/blob/master/docs/configuration.md
warn The following packages use deprecated "rnpm" config that will stop working from next release:
Please notify their maintainers about it. You can find more details at https://github.com/react-native-community/cli/blob/master/docs/configuration.md#migration-guide.
info Fetching system and libraries information...
System:
OS: macOS Mojave 10.14.5
CPU: (8) x64 Intel(R) Core(TM) i7-4770HQ CPU @ 2.20GHz
Memory: 34.23 MB / 16.00 GB
Shell: 3.2.57 - /bin/sh
Binaries:
Node: 10.18.0 - /usr/local/opt/node@10/bin/node
Yarn: 1.16.0 - /usr/local/bin/yarn
npm: 6.13.4 - /usr/local/opt/node@10/bin/npm
Watchman: 4.9.0 - /usr/local/bin/watchman
SDKs:
iOS SDK:
Platforms: iOS 13.2, DriverKit 19.0, macOS 10.15, tvOS 13.2, watchOS 6.1
Android SDK:
API Levels: 23, 24, 25, 26, 27, 28
Build Tools: 25.0.0, 25.0.1, 25.0.2, 26.0.1, 26.0.2, 27.0.3, 28.0.0, 28.0.3, 29.0.2
System Images: android-23 | Intel x86 Atom_64, android-23 | Google APIs ARM EABI v7a, android-23 | Google APIs Intel x86 Atom_64, android-26 | Android TV Intel x86 Atom, android-26 | Google APIs Intel x86 Atom, android-26 | Google APIs Intel x86 Atom_64, android-26 | Google Play Intel x86 Atom, android-28 | Android TV Intel x86 Atom, android-28 | Google APIs Intel x86 Atom, android-28 | Google Play Intel x86 Atom, android-28 | Google Play Intel x86 Atom_64
IDEs:
Android Studio: 3.5 AI-191.8026.42.35.6010548
Xcode: 11.2.1/11B500 - /usr/bin/xcodebuild
npmPackages:
react: 16.9.0 => 16.9.0
react-native: 0.61.1 => 0.61.1
npmGlobalPackages:
react-native-cli: 2.0.1
react-native-log-ios: 1.5.0
Steps To Reproduce
issue:
'error: File /Users/user/Library/Developer/Xcode/DerivedData/NewApp-fvicxnfjlfuonigoqscurptyhntn/Build/Products/Release-iphonesimulator/NewApp.app/main.jsbundle does not exist. This must be a bug with'
Provide a detailed list of steps that reproduce the issue.
ways triaged to fix issue are below:
quit the currently running metro-bundler
quit the tsc compiler
quit xcode & simulator
sudo rm -rf node_modules
sudo yarn
applying permission Read & Write manually to node_modules & all of it's enclosed items
sudo watchman watch-del-all
sudo lsof -i :8081
sudo kill -9 processId
open ios/ProjectName.xcworkspace
But i have not reached any solution so far.
As i said before, on debug mode, it works fine, on release mode, throws the error and app did not launch
please help me out to fix this issue & go ahead
Thanks in Advance
The text was updated successfully, but these errors were encountered: