-
Notifications
You must be signed in to change notification settings - Fork 485
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.61.4 crash - No such method putMap #781
Comments
I'm still not sure why viro decided to have a hard-linked react-viro aar file, but I ended up rebuilding it from source (from 2.17 tag) and compiled it against RN 0.61.4. Seems to be working fine. However, this should really not be needed... react_viro is small and an aar shouldn't be needed, just include the source and let it compile! Please, update your code so RN is not hard linked like this, this can break very, very easily, and will always blow up at runtime instead of compile time. |
I have the same problem, I do not know how to solve. |
If I am not mistaken, ViroReact does not support RN >.59.9. Might render just fine but most functionality will not. They have this information on the release docs.
|
I am planning to use this for our AR project. |
Does any one know if they're working on a newer version that supports RN 0.6x.x ? And if so, is there a estimated release date? |
The fix to support RN 0.6x.x is actually rather easy, and my team also needed to run on 0.6x.x. So we have deployed a npm package that supports this version. You can use this in the meantime until we get around to push this fix upstream when we find the time. You still have to manually link pods/android project as you are used to with the official version. |
@Hless Thanks a lot! Quick question - Have you done anything about the GVRSDK/UIWebView issue in that repo? |
Not yet, but it appears we are able to submit our app without fixing that problem. We will have to take a look at some point. I'm unsure when Apple will actually start rejecting apps using UIWebView... Edit: |
@Hless So you didn't even receive the warning about using deprecated UIWebView? How long ago did you submit the app to the store? Sorry for hijacking the thread, FYI: https://developer.apple.com/news/?id=12232019ba |
We did receive the warning, but we submitted our app anyway last Saturday.
It did get rejected because of something entirely unrelated. We are
resubmitting after Christmas. Will report back when it's out of review.
Edit: Didn't see your edit. Those of us that already released an app should be good for at least a year then, if you submit your app before April. I think the absolute deadline for removing GVRSDK from ViroCore should be start of March... Issue is getting tracked seperately in the ViroCore repo for those willing to participate:
viromedia/virocore#320
|
Thanks so much for posting the repo @Hless ! With your version, I'm happily running my app in react-native: 0.61.5 on android. |
Hi @Hless How do I implement your version? Is it similar to copy "node_modules\react-viro\bin\files\javascript*" ? |
Did you manage to run Viro with updated React? |
@TrejoCode Exactly the same as you would with the official repo, except that you would use the I know it's not ideal, but this was purely meant as a quick in-between solution for our app, as we needed to move forward with our app, it would be wise to keep following this thread for when rn 61.x support lands in the official viro repo. |
@TrejoCode like I said above, I just re-built the react-viro aar file from source but against RN 0.61.x and then copied that new aar file into my viro's npm folder. Ugly fix, I know, but it worked for my very basic use case. |
@cristianoccazinsp Keep in mind that if you only copy the Android aar file, it would not work on iOS |
Interesting... I don't know how, but it is working for iOS just fine, but then again, I'm only using a few basic features and not the whole AR stuff. |
Hey @Hless, I'm looking at https://github.com/citychallenge/viro (thanks again for this). Shouldn't you also replace the |
Never mind... I see they are built straight from the directory in |
@cristianoccazinsp sorry but, what do you mean with re-build react-viro aar file from source, i have installed @Hless fork, now i have error with putMap, |
This is what I did, but as said above, this only fixes it for Android, and not for iOS (although I haven't had issues with iOS yet), so use it carefully.
Again, I have no idea why would the viro team include the aar file like that in the npm package instead of just providing the source code and letting it build with RN like above. A simple change to do that would save us from this this headache each time RN is updated. |
@Hless (or @ anybody really...) If you find the time and the patience, could you sketch real quick how to add I'm struggling with the Much obliged! |
Well, there is not much to sketch. It's just very much the same installation steps as the regular Edit: |
I wanted to also be able to upgrade the react-native version. This is what I had to do:
in viro/test/package.json change dependencies to
Then run After this copy over the packages in viro/android/react_viro to your own project Follow https://react-native-community.github.io/upgrade-helper/?from=0.59.9&to=0.61.2 to upgrade rest of project. |
RN 0.62 is coming soon... Will most likely need to repeat the above with this new version. How hard would it be to remove the |
@Hless Hi Hless, is this package of @citychallenge/react-viro solved the problem about UIWebView ? Until this April, apple will stop accepting the App with using UIWebView. Right now I am facing this problem:( |
I've been trying to upgrade react's version to 0.61.5 in this branch (https://github.com/cristianoccazinsp/viro/tree/rn-upgrade-attempt) alongside updating google SDKs for iOS to remove some deprecation warnings. Compilation of the new android aar file seems fine, but the iOS migration step is harder than I thought and I can't seem to make it compile with the new podspec file. If someone is interested in taking it from there... I'm most likely not putting more effort into this and will be searching for another 360 viewer shortly. |
@rgouzal |
android/app/build.gradle:
App's android/build.gradle:
|
can you try |
Still getting notifications from this thread, so to quickly help you out, setting the minSdkVersion is not going to solve it. To be precise, pretty sure you did not correctly build and/or copy an .aar file that was linked against RN 0.61.x+. I suppose you didn't follow all steps carefully. |
Furthermore, if you want an easy fix and still want to use Viro you could use my fork (@citychallenge) or the one in this thread: I would advise to think twice though, we switched to a different solution. Currently there are just too many problems that need too much effort to fix: UIWebView deprecation being one, and we found out some stuff simply isn't working on iOS14. |
I second @Hless. I have also switched to @citychallenge here is my settings.gradle
|
@hokaiyipFS I did tried. But no luck. |
@rgouzal forgot to mention that I have switched to react-viro/@citychallenge |
@hokaiyipFS I did used that, but it was crashing throwing the following exception:
and the following exception:
|
@hokaiyipFS I am planing to use react-native mapbox AR navigation which requires viro. |
With some tweak it will work, make sure you have the following, and rebuild your android app. package.json
settings.gradle
app/build.gradle
|
@hokaiyipFS ok it is not crashing now thank you sir for your help, but I see a black screen and I don't see a camera view with "Hello World" what could be that I am doing wrong here? |
emulator or real device? |
@hokaiyipFS real device Samsung M31 |
@rgouzal oh I think I noticed there is an exception thrown: BTW my project is initialized by react-native and not expo.
|
@hokaiyipFS never mind about that exception I think that's older by 2 hours for another app. But I still see black screen. |
@rgouzal camera permission? |
@hokaiyipFS exists on manifest and allowed. |
@hokaiyipFS Reading here #115, I find that the issue of the black screen could be because of no API key intialized, but I think viro does not require API key anymore. So whats the solution for this? |
Could it be something I am missing in my code? App render function:
ViroAR scene component:
|
hm.. it looks fine to me. can you see test in the view ? try setting the outer most view like
|
@hokaiyipFS Still shows black screen, I actually at first tried returning directly instead of the above:
So I said to my self maybe I need to wrap it inside View component but no luck. |
@rgouzal
I have used viro-react for more than 1 year. initially with react native 0.59.9, now upgrade to 0.63.2 |
@hokaiyipFS Just tried to install react-native-camera but still same problem, if camera view is not invoked it should at least show the Hello World text scene. It's not showing that scene at all. I am trying to integrate react-viro which required by react-native-mapbox-ar to my project for AR navigation. |
@hokaiyipFS I tried adb logcat nothing interesting. |
@hokaiyipFS Also is this compatible with react-navigation? I mean the ViroSceneARNavigator is it compatible with react-navigation should react-navigation wrap ViroSceneARNavigator or ViroSceneARNavigator should wrap react-navigation navigator? |
@hokaiyipFS Never mind I found the problem, for anyone that could have it in future I was missing the line in application node in AndroidManifest.xml:
This was mentioned below page, but I could not see line that should be added I had to insepect element on the documentation page to see the line it was hidden: https://docs.viromedia.com/docs/integrating-existing-projects-android#for-ar |
I think you need to use both, as I am also using both. |
@hokaiyipFS yes but I meant which navigation should be root or top parent navigation react-navigation? |
@Hless I tried to use "@citychallenge/react-viro": "^2.17.4", for eather react native 0.61.5 and react native 0.62.2.
app/build.gradle
App.js
the app build successful , but when I opened it , it crashed ;( Could you help me please to resolve this issue |
Environment
Please provide the following information about your environment:
Description
This looks like a bug related to an internal change with maps from RN and also related to #756
Viro just fails to open under RN 0.61.4, but works fine on 0.60
Crash logs:
Reproducible Demo
Something similar to this
The text was updated successfully, but these errors were encountered: