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

Fix/agp support android #331

Merged
merged 2 commits into from
Jul 22, 2024
Merged

Fix/agp support android #331

merged 2 commits into from
Jul 22, 2024

Conversation

kenjdavidson
Copy link
Owner

@mardikarifqi and @larlin can you take a look at this?

Looking at the link react-native-community/discussions-and-proposals#671 this requires two changes:

  1. Adding the package to the build.gradle file
  2. Removing the package from the AndroidManifest.xml file

The latter was missed. The PR also used kjd.reactnative.android instead of kjd.reactnative.bluetooth which is in the manifest. Not sure if that really matters, but probably.

Anyhow, the kjd.reactnative.android package should be removed, all it's used for is back porting the BiConsumer to Java 7, which it should be able to skip now, as I have to update the library to Java 17 based on this document and the 0.73 details anyhow.

@kenjdavidson
Copy link
Owner Author

Some other options for this are:

  • Adding an environment variable in order to control this logic, so that pipelines that don't need it can turn it off.
  • Bumping the version to 0.71.x although, I'm not a huge fan of this since 0.70.x is supposed to support 0.73.x of react.

@larlin
Copy link

larlin commented Jul 16, 2024

I did a quick test first with my standard configuration on RN 0.69.7 that does not build without the package in the AndroidManifest.xml but that is fine as this version of RN is not supported by 0.70.

And made a quick test on RN 0.73.X without the package in the AndroidManifest.xml that works.

So for me it makes sense to make these change and for my project until I update things I will simply use the older version of this library.

@ShaneZhengNZ
Copy link

Totally support this. I have my project with 0.73 RN. Failed to build today due to the package in the AndroidManifest.xml file.

Since I have to build and release my app, I have to patch this change with yarn patch. It worked, but, obviously, not ideal.

@kenjdavidson
Copy link
Owner Author

Totally support this. I have my project with 0.73 RN. Failed to build today due to the package in the AndroidManifest.xml file.

Since I have to build and release my app, I have to patch this change with yarn patch. It worked, but, obviously, not ideal.

Right on, so just to confirm you've made these changes and 0.73 builds fine in your pipelines? I will merge and release it if so.

@ShaneZhengNZ
Copy link

What I can confirm is that the build worked immediately after I applied the patch. However, when my test engineer tested the app today, the app crashed, therefore, he was not able to carry on the complete test to make sure things are working. I don't think the crash is related, but I want to make sure it works properly.

@kenjdavidson
Copy link
Owner Author

I appreciate the follow up, I'll wait for your comments/discovery before merging.

@ShaneZhengNZ
Copy link

Just let you know, as what I expected, the crash has nothing to do with the library. The changes in PR fixed the build in my case, and I am confidently that it works as what I expect.

@kenjdavidson kenjdavidson merged commit 9df8b81 into main Jul 22, 2024
@kenjdavidson
Copy link
Owner Author

Works for me, second times the charm!! @ALL hopefully this doesn't blow anyone up.

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

Successfully merging this pull request may close these issues.

3 participants