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

Example app crashes in iOS with react-native0.62.2 #789

Closed
Kta-M opened this issue May 27, 2020 · 8 comments
Closed

Example app crashes in iOS with react-native0.62.2 #789

Kta-M opened this issue May 27, 2020 · 8 comments

Comments

@Kta-M
Copy link

Kta-M commented May 27, 2020

Steps to reproduce

  1. npx react-native init example
  2. cd example
  3. npx pod-install
  4. copy App.js images/*, components/* from react-native-share/example/
  5. run app in ios simulator
  6. all buttons crashes the app

Expected behaviour

share menu comes in.

Actual behaviour

the app crashes without any messages.

Environment

  • React Native version:0.62.2
  • React Native platform + platform version: iPhone11, iOS 13.4.1

react-native-share

Version: 3.3.2

Link to repo (highly encouraged)

https://github.com/Kta-M/react-native-share-example-app

@Kta-M Kta-M added the bug label May 27, 2020
@Kta-M
Copy link
Author

Kta-M commented May 27, 2020

@MateusAndrade
Copy link
Collaborator

Thanks @Kta-M did you tested this on a fresh project with rn 0.62.2? I think we might need to look at the update in the example app to fix this.

@mikehardy
Copy link
Collaborator

Updating examples should never ever take maintainer time :-)
https://github.com/react-native-community/react-native-device-info/blob/master/refresh-example.sh

@MateusAndrade
Copy link
Collaborator

Updating examples should never ever take maintainer time :-)
https://github.com/react-native-community/react-native-device-info/blob/master/refresh-example.sh

Thanks, Mike! I will look forward to implementing this. 🙉

@Kta-M
Copy link
Author

Kta-M commented May 27, 2020

Thanks @MateusAndrade, yes, I tested this on a fresh project (https://github.com/Kta-M/react-native-share-example-app).

@MateusAndrade
Copy link
Collaborator

MateusAndrade commented May 27, 2020

Thanks @MateusAndrade, yes, I tested this on a fresh project (https://github.com/Kta-M/react-native-share-example-app).

Strange, I tested this here with a fresh project with the following version and it works fine. Also, I checked your project and your dependencies are matching with the ones that I tested here.

  "dependencies": {
    "react": "16.11.0",
    "react-native": "0.62.2",
    "react-native-share": "^3.3.2"
  }

I checked here, it looks that the example app is using a version 3.0.0 of react-native-share. (which throws the given error)Probably because it's using the master version, then the hash should be saved at the .lock. I will try to look at that, but I would appreciate it if you help me with this. 😄

@Kta-M
Copy link
Author

Kta-M commented May 28, 2020

I checked here, it looks that the example app is using a version 3.0.0 of react-native-share.

"the example app" is referring to my Kta-M/react-native-share-example-app or this repository's react-native-community/react-native-share/example?

My example app has a committed package-lock.json file and uses react-native-share 3.3.2. This does not work in my environment.
The example app in this repository will work. When I tried it, the hash was 10c72e4, the latest commit, not 3.0.0.

In addition, thinking that it might be a problem of the environment of the iOS simulator, I executed Device > Erase All Erase All Content and Settings, but after all my example app does not work😢

@Kta-M
Copy link
Author

Kta-M commented May 30, 2020

@MateusAndrade, I've solved it!

It was a problem on the react-native side.
facebook/react-native#28589

Upgrading Flipper in the Podfile from 0.33.1 to 0.37.0 solved the problem.

In react-native, the following pull requests have already been merged and it looks like they are going to include 0.63.0😄
facebook/react-native#28597
facebook/react-native#28545

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants