Closed krystofwoldrich closed 1 year ago
@passy are you able to take this one?
@cortinico I don't know the internals of this well enough (i.e. not at all) but I'm happy to import it and try to find an internal reviewer.
@cortinico I don't know the internals of this well enough (i.e. not at all) but I'm happy to import it and try to find an internal reviewer.
I can import and review the changes 😊
@cortinico I don't know the internals of this well enough (i.e. not at all) but I'm happy to import it and try to find an internal reviewer.
I can import and review the changes 😊
Thanks @lblasa I can help with the review
Thank you for the help. @cortinico @passy @lblasa
Would anyone know how to build the library locally and try it with RN? I've described my steps in the description. I thought I'll build it and publish it to my local maven and then use it RN, but got an error mentioned above.
Would anyone know how to build the library locally and try it with RN? I've described my steps in the description. I thought I'll build it and publish it to my local maven and then use it RN, but got an error mentioned above.
Answered on Discord but I'll follow up here also for completeness:
Seems like prefab support is not working for -SNAPSHOT version (here the problem https://github.com/DanAlbert/prefab/blob/ab8529aa5163f071da02deb023037f3511bf90ce/api/src/main/kotlin/com/google/prefab/api/Package.kt#L31-L32).
It seems like this might be fixed in a later version of AGP though so there is probably nothing to report to Google.
To unblock you can
gradle.properties
./gradlew publishToMavenLocal -x signMavenPublication
mavenLocal()
set up in the repositories{}
block@lblasa has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.
Friendly ping @krystofwoldrich to move this forward
@krystofwoldrich has updated the pull request. You must reimport the pull request before landing.
@lblasa has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.
@krystofwoldrich has updated the pull request. You must reimport the pull request before landing.
I've tested it here https://github.com/facebook/react-native/compare/main...krystofwoldrich:react-native:kw-use-new-class-methods-from-fbjni-for-mixed-stack-traces
Everything looks good.
@lblasa merged this pull request in facebookincubator/fbjni@8efea4d089f3f88680c8937d5a7ea5b1ce2bef17.
Motivation
Why are you making this change?
To enable RN to retrieve details about Throwables.
Relates to https://github.com/facebook/react-native/pull/36925. Where these changes will be used.
Summary
What did you change?
Added
getMessage
to JThrowable.Added
getSimpleName
to JClass.How does the code work?
Uses dynamic Java method call like other similar methods.
Test Plan
How did you test this change?
Could anyone guide me on how to test my changes of
fbjni
in RN?I wanted to publish the package to my local Maven and add it to RN to verify the functionality, but it didn't work.
What I tried:
./gradlew publishToMavenLocal
generated0.3.1-SNAPSHOT
mavenLocal()
topackages/rn-tester/android/app/build.gradle
.I got this error:
Any change that adds functionality should add a unit test as well.