Amplitude-ReactNative icon indicating copy to clipboard operation
Amplitude-ReactNative copied to clipboard

Errors found in AndroidManifest.xml

Open gilluminate opened this issue 1 year ago • 7 comments

After upgrading to latest version, when I run npx pod-install I get the following error:

Auto-generating `.xcode.env.local` with $NODE_BINARY=/Users/runner/hostedtoolcache/node/18.16.1/x64/bin/node
error Failed to build the app: No package name found.
Found errors in [...]/node_modules/@amplitude/react-native/android/src/main/AndroidManifest.xml.

gilluminate avatar Jul 11 '23 00:07 gilluminate

The same thing happens to me without updating dependencies

error Failed to build the app: No package name found. Found errors in node_modules/@amplitude/react-native/android/src/main/AndroidManifest.xml.

deivyrene avatar Jul 11 '23 13:07 deivyrene

This affects anyone using React Native 0.70 or earlier, see https://github.com/amplitude/Amplitude-ReactNative/pull/167.

ejain avatar Jul 12 '23 18:07 ejain

Thank you for choosing Amplitude. We are actively investigating this issue.

yuhao900914 avatar Jul 12 '23 21:07 yuhao900914

This is a bug related to RN and RN CLI. I found the same issue in the react-native-community/cli repo here.

And they have a fix here. Please follow their instruction to update the version.

The current React Native ^0.71.0 using react-native-community/cli ^10.0.0. So it should include the fix. Check here.

yuhao900914 avatar Jul 12 '23 22:07 yuhao900914

We're using React Native 0.70.x, doesn't look like the fix was backported to that version...

What versions of React Native does Amplitude-ReactNative support, officially?

ejain avatar Jul 12 '23 23:07 ejain

@ejain Let me get back to you after a discussion with our team.

yuhao900914 avatar Jul 12 '23 23:07 yuhao900914

Hi @ejain, since React-Native is still in beta, it's challenging for us to ensure backward compatibility when React-Native itself is not backward compatible. Therefore, we've decided to support only the latest version of React-Native until it is out of beta. Once React-Native reaches GA, we will improve our support and strive for backward compatibility.

In the meantime, please use the older version of our React-Native SDK to address this issue.

yuhao900914 avatar Jul 13 '23 17:07 yuhao900914