viro icon indicating copy to clipboard operation
viro copied to clipboard

Looks like viro is dead for ios till update

Open ghost opened this issue 4 years ago • 62 comments

ITMS-90809: Deprecated API Usage - Apple will no longer accept submissions of new apps that use UIWebView as of April 30, 2020 and app updates that use UIWebView as of December 2020. Instead, use WKWebView for improved security and reliability. Learn more ( https://developer.apple.com/documentation/uikit/uiwebview ).

react-viro uses UIWebView component, so since April 30 2020 it's will be rejected by apple, when you are trying to publish it.

ghost avatar May 01 '20 02:05 ghost

Our app was all ready to be released as well, but due to this, we are stuck. This is going to prevent any new apps from making to App Store and eventually, by December, all existing apps will stop working as well. Sounds like a high priority item. Any plans from Viro team to tackle this soon ?

ranjanpoudel1234 avatar May 03 '20 17:05 ranjanpoudel1234

Guys any update on this issue? Apple already stopped receiving the UIWebView API. Now we are unable to upload the app

ManigandanRaamanathan avatar May 03 '20 18:05 ManigandanRaamanathan

@dthian please fix the OS deprecated UIWebView issue

ManigandanRaamanathan avatar May 03 '20 18:05 ManigandanRaamanathan

Hey @ManigandanRaamanathan, as mentioned in the other post, I'm not currently working on ViroReact, and that ViroReact and ViroCore are both open sourced - so that shouldn't be any blocking factors preventing you from viewing the source and patching the fix.

As mentioned, You would essentially need to abstract the GVR implementations away such that they aren't build into the renderer on iOS, that should remove the webview dependency (hopefully). @HedwigAR might have made some progress, so I would check in with him.

dthian avatar May 03 '20 22:05 dthian

@dthian, I tried @HedwigAr's GVR removed version v2.18.0, it works perfectly fine now

ManigandanRaamanathan avatar May 04 '20 10:05 ManigandanRaamanathan

@ManigandanRaamanathan If we remove GVR that means we can't have VR support on the app yeah?

MinhazMM avatar May 04 '20 11:05 MinhazMM

Yes @MinhazMM. That is indeed the case.

jogboms avatar May 04 '20 12:05 jogboms

@ManigandanRaamanathan , where can I access the v2.18.0(the one with GVR removed)? and what react-native version are you using it with ? Thank you in advance.

ranjanpoudel1234 avatar May 04 '20 13:05 ranjanpoudel1234

@ranjanpoudel1234 https://github.com/mendix/viro/pull/1

ManigandanRaamanathan avatar May 04 '20 13:05 ManigandanRaamanathan

Thank you very much @ManigandanRaamanathan . Please forgive my lack of knowledge on this. Did you use the github link(this one https://github.com/mendix/viro.git) directly on your package.json, or did you fork it and make npm package out of that build branch(which has the fix) ?

ranjanpoudel1234 avatar May 04 '20 14:05 ranjanpoudel1234

are we planing to release a new version that fix issue of Apple ? @ManigandanRaamanathan with https://github.com/mendix/viro.git, seems IOS ok but Android cannot run because it does not have gvr @mendix

diegothucao avatar May 27 '20 15:05 diegothucao

@diegothucao on my end, AR works on both android and ios version. I installed me ndix pull request version.

ManigandanRaamanathan avatar May 27 '20 16:05 ManigandanRaamanathan

I've also installed mendix version (master branch on https://github.com/mendix/viro.git) but after I run yarn install and react-native run-android --variant=arDebug to open the app (in code-sample folder) on my device, it crashed out. Do you have any idea, is there any step I'm missing? or I'm using the incorrect branch (or git link)? @ManigandanRaamanathan thank you so much.

namthan avatar May 27 '20 16:05 namthan

@namthan dont use master branch. Use the branch that is is pending merge request

ManigandanRaamanathan avatar May 27 '20 16:05 ManigandanRaamanathan

@namthan dont use master branch. Use the branch that is is pending merge request

Do you mean branch UpdateReactNative ? I'm trying it on. This is an urgent issue in my project, hopefully can get your supports. Thanks a lot.

namthan avatar May 27 '20 16:05 namthan

@diegothucao on my end, AR works on both android and ios version. I installed me ndix pull request version.

@ManigandanRaamanathan : I went to https://github.com/mendix/viro.git and do not see any pull request version ? Could you have time to support me a bit in detail how could I do ? thanks so much for your reply.

diegothucao avatar May 27 '20 16:05 diegothucao

@diegothucao https://github.com/mendix/viro/pull/1

ManigandanRaamanathan avatar May 27 '20 16:05 ManigandanRaamanathan

hi @ManigandanRaamanathan , thanks for your answer. I downloaded the build branch as in https://github.com/mendix/viro/pull/1 and run example with react-native run-android --variant=arDebug However it crashes when Android app comes up. Can the issue is about permission or missing something else from me?

diegothucao avatar May 27 '20 17:05 diegothucao

@diegothucao the same version works fine on android 10 samsung s10 and note 9

ManigandanRaamanathan avatar May 27 '20 17:05 ManigandanRaamanathan

Thanks @ManigandanRaamanathan I used note 9 as well. But still issue if you have any other idea for me. Please let me know. Thanks so much.

diegothucao avatar May 27 '20 18:05 diegothucao

Screen Shot 2020-05-30 at 12 20 03 PM After building successfully with medix pr, I'm running into this error. @ManigandanRaamanathan could you please help?

namthan avatar May 30 '20 05:05 namthan

Did anyone manage to create 2.18 alternative with reverted GVR removal? I would like to have an updated version with fix for #835 . I was trying to but I always get white screen in VR mode.

jpudysz avatar Jun 04 '20 11:06 jpudysz

Good news - Viro not dead for iOS! Making some further changes to the Viro source to get the static library compiling with no GVR (Viro in AR only mode), I was able to successfully upload to Apple/Testflight to get past the UIWebView blocker. Total hack, but happy to share what worked.

I'm now successfully using RN 0.62.2 and have Viro static library working great with no UIWebViews.

Note that below I'm using a temporary viro fork. This could be merged back to main if it meets the quality bar. I can't maintain a fork, I just want to contribute to viro. Below will take a couple of hours to figure out the details... it's taken me days to get this working, so I may be missing key steps.

Gist:

Part 1: Build the static lib with no GVR UIWebView:

  1. Clone my Viro repo git clone https://github.com/ktemby/viro (hacked edits to remove GVR from static library target, I make no claims to have quality tested properly, especially for Android).
  2. Build viro (from the viro folder, cd ios, pod install, then open ViroReact.xcworkspace in Xcode and build all the targets, the 'static lib' target last)

Part 2: Get your project to use my viro temp fork

  1. Remove Viro from your current project npm uninstall react-viro
  2. Install my github fork npm install git+https://github.com/ktemby/viro
  3. Clear your build folder by doing a clean build of your app.

Part 3: Copy the locally built static library over to your project

  1. Go back to where you built viro, we'll be copying the 'dist' (the static library files) over.
  2. cp /viro/ios/dist/* ~<your project in part 2>/node_modules/react-viro/ios/dist/
  3. Why? Because the static library files that I built won't upload to my repo (they're too large).

Part 4: Rebuild your app with the updated library

  1. Go back to your app directory.
  2. Ensure you're using the static lib in your Podfile (see https://docs.viromedia.com/docs/no_use_frameworks)
  3. Do pod install first from the ios folder.
  4. Now build in xcode or with NPX.
  5. Enjoy seeing your AR functionality now working in your app!
  6. Upload to Apple and enjoy the feeling of not being rejected due to UIWebView.

Next steps?

I can post a sample RN 0.62.2 + Viro project with key configurations on the weekend if more details needed.

Takeaway - I was able to get this to work, and successfully submitted to Apple, but the quality of my effort is a way lower bar than you want, so please proceed with caution and understand my good intentions for sharing what worked for me is no replacement for your own diligence!

ktemby avatar Jun 10 '20 07:06 ktemby

Thanks for your detail explanation Would you share the dist folder via google driver or dropbox ? Because I am struggling to build "Build viro (from the viro folder, cd ios, pod install, then open ViroReact.xcworkspace in Xcode and build all the targets, the 'static lib' target last)" stage all day long. My react-native version is "react-native": "0.59.9" When I build all the targets and 'static lib', it shows so many errors. Thanks in advance.

tscj3490 avatar Jun 10 '20 17:06 tscj3490

@tscj3490 I don't think this will work for you - but feel free to try https://drive.google.com/file/d/1XnIN0tPXGiLT1bRwEAxE1HWW1rU1edxc/view?usp=sharing. I'll run through the full steps of building a RN 0.62.2 test app, and post that over the weekend.

ktemby avatar Jun 11 '20 05:06 ktemby

Thanks for your dedicated effort and help. I will try again. Thanks again.

tscj3490 avatar Jun 11 '20 06:06 tscj3490

I just did as your guide and deployed app that GVR is removed to test flight. I did like below.

  1. Removed Viro from my current project npm uninstall react-viro
  2. Ran npm install git+https://github.com/ktemby/viro
  3. Copied to the dist folder you shared and pasted to {my work project}/node_modules/react-viro/ios/dist/ .
  4. Ran pod install again and then, I could build app successfully. But once I deploy app to test flight, apple doesn't still allow my app. It shows same error. (Apple doesn't allow UIWebView) Please guide me again.

tscj3490 avatar Jun 11 '20 07:06 tscj3490

I can't be sure- but you may need to clean your build folder completely first. I'd also isolate out what contains the UIWebview https://stackoverflow.com/questions/58091231/how-to-search-for-any-uiwebview-component-usage-inside-a-current-project. You may also want to ensure you're using the static lib - added step 2 to Part 4. I may have missed one of the steps I took, I'll do this for a clean test app on the weekend.

ktemby avatar Jun 11 '20 07:06 ktemby

I can't be sure- but you may need to clean your build folder completely first. I'd also isolate out what contains the UIWebview https://stackoverflow.com/questions/58091231/how-to-search-for-any-uiwebview-component-usage-inside-a-current-project. You may also want to ensure you're using the static lib - added step 2 to Part 4. I may have missed one of the steps I took, I'll do this for a clean test app on the weekend.

Hi, Ktemby. Did u do the work ? If you did, please share.. Thanks.

tscj3490 avatar Jun 15 '20 15:06 tscj3490

I can't be sure- but you may need to clean your build folder completely first. I'd also isolate out what contains the UIWebview https://stackoverflow.com/questions/58091231/how-to-search-for-any-uiwebview-component-usage-inside-a-current-project. You may also want to ensure you're using the static lib - added step 2 to Part 4. I may have missed one of the steps I took, I'll do this for a clean test app on the weekend.

Hi, ktemby I can't still deploy app to app store. Could you share source code that apple can approve ? Thanks in advance.

greenbaypayment avatar Jul 04 '20 17:07 greenbaypayment