-
Notifications
You must be signed in to change notification settings - Fork 62
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
After upgrading to react-native 0.60.x schemes other than production (default) do not work. #76
Comments
I suspect we'll need to release a new version to support 0.60.x. My suspicion is that the react-native-xcode.sh script has changed compared to the one we bundle, and that's likely the best place to start looking. Here's theirs: I don't currently have a React Native 60 project to test on, so a minimal reproduction case would really help me so I can get in and start looking at this efficiently. Otherwise I will absolutely accept pull requests if you're able to get this working with 60. |
Also please have a go with this branch to see if it solves your problem: #74 |
I tried with both the PR branch and with master which now seems to have the PR as well as other changes merged but it still doesn't work. I still get the same error i.e. the app cannot see the bundle after launching. |
I can confirm, I have the same problem: default scheme works and on the other schemes I get a black screen. Tried with current master. |
@thekevinbrown Any ideas how we can go about supporting the latest changes from 0.60.4? |
@ninjz, I don't have a project on v60 yet, so I'm not sure what exactly is broken. I'd be happy to accept a pull request and release a new major version to support v60 if someone else has time to debug this. |
I've tried to debug this. here is the minimal reproduction repo. I initialized a project from scratch with 0.59, added Custom debug scheme doesn't work. Tracked it down to this line. For some reason, Custom release scheme doesn't work too. However I managed to make it work by deleting tests. This PR should fix it. |
I managed to fix debug config too. RN0.60 uses cocoapods to build the project, and in cocoapods you have to explicitly specify if your custom build configuration is based on debug configuration. So I had to add the following line to my repro project linked in previous post:
and then reinstall pods. And it worked. |
Today When I made the change @doomsower recommended, I was able to build and run release builds and debug builds with custom schemes and build configurations without installing this library at all. The specific change to project 'MyProject',
'DevDebug' => :debug,
'StagingDebug' => :debug,
'Debug' => :debug,
'DevRelease' => :release,
'StagingRelease' => :release,
'Release' => :release (where EDIT: You'll also need to change the hash/map there. The keys (i.e. So as far as the react-native core 0.60+ goes, this library isn't needed it seems. For third-party deps though that don't use cocoapods it probably will be? I'm not familiar enough to say for sure. |
I tried installing this library to see what would happen and it fails on Steps:
(I only ran That command fails on this line of
With this error:
|
@bericp1 Did you have to do anything else for the duplicated debug schemes? When trying to build it runs into an error with the Tests target: |
@bericp1 you said you made the change @doomsower recommended... did you mean editing as well the Test file he referred to? (the one in react-native) ... or did you just edit the Podfile? |
Yep to get it to work with
Not that I remember. Did you apply the changes from this diff? Not sure what else would cause that error. |
@BericP, are you able to bring up the debug menu in schemes that aren't called, "Debug"? You could use schemes with React Native before 0.60, but debugging produced a release build in them. If you can bring up the debug menu in your custom schemes, then there is no need for this library. |
@thekevinbrown I followed @bericp1 except for applying this |
@influx6, awesome, in that case we don't need this library for 60. The other things it does are window dressing, as the main reason I created it was for debugging other schemes. I'd be happy to merge a PR to update the Readme to say so. |
@bericp1 regarding 0.60.5 . I made my react native project changes but am stuck at this issue:
any idea how to fix? I saw your comments above about the pod file with the project/scheme mappings. Just wondering if you have an example of this that worked for you? |
Per the convo here, if you're on or upgrade to The update you need to make in Based off the docs here, you generally need to add something like the following near the top of the file, right after project 'TheNameOfYourProjectWithoutTheXprojExtension',
'Debug' => :debug,
'Release' => :release,
'FooDebug' => :debug,
'FooRelease' => :release Where:
And then you need to run What you're essentially doing is converting your json build configuration map you had in your |
@bericp1 thanks for the response. Had everything correct except for not including this project anymore. Works great now! |
I have set up my project with schemes manager the same way as I did as before RN 0.60.5, but with these changes to get it working:
And the podfile addition mentioned by @bericp1 :
This way it satisfies both the pods and the non-pods dependencies |
This solved our issue , thanks! |
@ofiron01 i have tried the same and it stills failing for me any other hints on how to debug it, also what version of the manager i should be using ? |
Closing as this issue has been mitigated by removing the package and using the appropriate CocoaPods configuration instead, as described by various solutions above. |
This worked for me. Thanks!!! |
it's working for me as well 🏆 thank you so much for that @bericp1, you solved it for gooood! 🙏🏻 🎉 |
Going forward, the solution to this should probably be listed at the top of the readme... spent a while trying to get this to work only to realize I'm using RN >0.60, and most people that come across this package will be using newer versions of RN |
@jack-ayoka would you be willing to make a PR for the readme? |
Thank you sooo much, Really Appreciate it 😄. |
Steps to reproduce the behavior
Expected behavior
The app should install and run with the defines scheme
Actual behavior
When using cli (i.e.
react-native run-ios --scheme \"TheSampleApp-Development\" --configuration Debug.Development
) the command compiles successfully, the app is installed but opens with a blank black screen (after showing the splash screen) on the simulator.On the other hand when using xcode to build the development scheme, the app again installs and runs, reaches the splash screen and after that we get a white blank screen. In xcode the output is the following:
The bundler is already running separately in both occasions via
yarn start
as for some reason it stopped running automatically after/during building the app.The text was updated successfully, but these errors were encountered: