Skip to content
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

RN 0.42.0 Fails to compile the Xcode project #12795

Closed
akashdmahali opened this issue Mar 8, 2017 · 2 comments
Closed

RN 0.42.0 Fails to compile the Xcode project #12795

akashdmahali opened this issue Mar 8, 2017 · 2 comments
Labels
Resolution: Locked This issue was locked by the bot.

Comments

@akashdmahali
Copy link

Description

Action Taken : Upgraded from RN version 0.41.0 to version 0.42.0.
Expected : RN iOS project should compile and run properly (using Xcode 7.3).
Actual : The RN iOS project fails to compile the file "react-native/React/Profiler/RCTProfile.m" (#line 386)

Here is the code that fails :

#if !TARGET_OS_TV
      UIActivityViewController *activityViewController = [[UIActivityViewController alloc] initWithActivityItems:@[[NSURL fileURLWithPath:outFile]]
                                                                                           applicationActivities:nil];
      activityViewController.completionWithItemsHandler = ^(__unused UIActivityType activityType,
                                                            __unused BOOL completed,
                                                            __unused NSArray *items,
                                                            __unused NSError *error) {
        RCTProfileControlsWindow.hidden = NO;
      };
      RCTProfileControlsWindow.hidden = YES;
      dispatch_async(dispatch_get_main_queue(), ^{
        [[[[[UIApplication sharedApplication] delegate] window] rootViewController] presentViewController:activityViewController
                                                                                                 animated:YES
                                                                                               completion:nil];
      });

#endif

Reproduction

Steps to reproduce : Upgrade the RN project from version 0.41.0 to 0.42.0

Solution

After commenting out the code mentioned above, the project compiles and runs successfully, however this by no means should be considered a solution. The developer who did those changes would be in a better position to address this (refer the point 1 in more information below)

More Information

  1. Github commit which has caused this issue
  2. Xcode version : 7.3
  3. People here are facing this issue too

Additional Information

  • React Native version: [RN 0.42.0 : YES]
  • Platform: iOS only
  • Operating System : MacOS
@gbau
Copy link

gbau commented Mar 8, 2017

@akashdmahali thanks for the detailed information. I ran into this recently as well, and while it didn't get to the bottom of the issue, updating Xcode from 7.3.1 to 8.2.1 allowed me to build successfully.

@hramos
Copy link
Contributor

hramos commented Mar 8, 2017

You'll need Xcode 8. Our tests are done using Xcode 8, therefore we cannot guarantee older versions are fully supported. You can still target older iOS versions than iOS 10 using Xcode 8.

Thanks for bringing this to our attention, the docs will be updated.

@hramos hramos closed this as completed Mar 8, 2017
facebook-github-bot pushed a commit that referenced this issue Mar 9, 2017
Summary:
It's sometimes helpful to provide the Xcode version being used, as in the case of #12795.
Closes #12811

Differential Revision: D4677123

Pulled By: hramos

fbshipit-source-id: 28890d1ac65400d4e98ae2eb77e2d7a1a02b9d05
@facebook facebook locked as resolved and limited conversation to collaborators May 24, 2018
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Jul 18, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

4 participants