UIWebView deprecation

7 posts, 1 answers
  1. Sean
    Sean avatar
    2 posts
    Member since:
    Jul 2018

    Posted 20 Sep 2019 Link to this post

    I've recently gotten this message when submitting to Test Flight:
    ITMS-90809: Deprecated API Usage - Apple will stop accepting submissions of apps that use UIWebView APIs . See https://developer.apple.com/documentation/uikit/uiwebview for more information.

    I am not using UIWebView anywhere in my application, so I'm wondering do any of the Telerik Xamarin controls use it?
  2. Answer
    Lance | Manager - Technical Support
    Admin
    Lance | Manager - Technical Support avatar
    1096 posts

    Posted 20 Sep 2019 Link to this post

    Hi Sean,

    I've recently encountered this as well and was also confused about where it was coming from. I am aware that we do not use UIWebView, so after further investigation I found problem is with Xamarin.Forms.

    You can find a Github conversation with different solutions here - https://github.com/xamarin/Xamarin.Forms/issues/7323.

    If this answers your question, you can let me know by using the ticket's "Mark as resolved" button (in the email or ticket page). If you have any further questions about UI for Xamarin, feel free to open a new ticket so we can assist further.

    Regards,
    Lance | Technical Support Engineer, Principal
    Progress Telerik

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
  3. Sean
    Sean avatar
    2 posts
    Member since:
    Jul 2018

    Posted 20 Sep 2019 in reply to Lance | Manager - Technical Support Link to this post

    Thank you, Lance! :)
  4. Jennifer
    Jennifer avatar
    2 posts
    Member since:
    Feb 2020

    Posted 11 Apr Link to this post

    I am following the advice on that article:

    1) Updated Xamarin.Forms to the latest 4.5.x

    2) Set mTouch parameter to "--optimize=experimental-xforms-product-type"

    3) Set Linker Behavior to "Link All"

     

    I also updated Telerik Xamarin UI to the latest stable NuGet.

     

    My app builds are now approved when I upload them, but they crash when launching. I have also tried these same sattings locally by changing the Debug builds to use these same settings and I get this error on the simulator and also on devices:

    System.NullReferenceException has been thrown

    Data: {System.Collections.ListDictionaryInternal}

    HResult: -2147467261

    InnerException: (null)

    Message: Object reference not set to an instance of an object

    Source: Telerik.XamarinForms.Common

    StackTrace: Telerik.XamarinForms.Common.TelerikLocalizationManager

     

  5. Lance | Manager - Technical Support
    Admin
    Lance | Manager - Technical Support avatar
    1096 posts

    Posted 13 Apr Link to this post

    Hi Jennifer,

    The reason for the error looks like the Microsoft Xamarin.iOS linker stripped out the Telerik.XamarinForms.Common assembly from the app package when it was compiled.  

    We do not support full linking (i.e. "LinkAll") as it is very aggressive and strips out any dependencies that has not direct usage in your app code.

    Solution

    There are two ways you can solve this:

    Option 1

    Set the linker to SDK Assemblies Only so that it doesn't strip out 3rd party libraries

    Option 2

    Use linkskip for the Telerik assemblies. See Linking on iOS - Controlling the Linker - Skipping Assemblies documentation.

    Specifically, to avoid this error, you would skip Telerik.XamarinForms.Common.

    --linkskip=Telerik.XamarinForms.Common

    However, to be safe, I would skip all the other ones that are referenced in that project as well.

    --linkskip=Telerik.XamarinForms.Common --linkskip=Telerik.xxxxxx --linkskip=Telerik.xxxxxx --linkskip=Telerik.xxxxxx

    Further Assistance

    If you run into any further trouble after setting the LinkerBehavior or linkskip, open a Support Ticket here so that the Xamarin team can directly assist.

    Regards,
    Lance | Team Lead - US DevTools Support
    Progress Telerik

    Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
    Our thoughts here at Progress are with those affected by the outbreak.
  6. Jennifer
    Jennifer avatar
    2 posts
    Member since:
    Feb 2020

    Posted 27 Apr in reply to Lance | Manager - Technical Support Link to this post

    Option 1 still produces the same problem (see below), we will try with option 2 and see how it goes. Thanks.

    Dear Developer,<br><br>We identified one or more issues with a recent delivery for your app, "Fake ZoApp" 1.0.14 (1.0.14). Your delivery was successful, but you may wish to correct the following issues in your next delivery:<br><br><strong>ITMS-90809: Deprecated API Usage - </strong>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).<br><br>After you’ve corrected the issues, you can upload a new binary to App Store Connect.<br><br>Best regards,<br><br>The App Store Team
  7. Lance | Manager - Technical Support
    Admin
    Lance | Manager - Technical Support avatar
    1096 posts

    Posted 28 Apr Link to this post

    Hello Jennifer,

    I recommend staying with Option 1. The error is unrelated to the linker or Telerik UI for Xamarin, let me explain.

    That reason for that error comes from Xamarin.Forms itself. They stopped using UIWebView a while ago, however there still some references to it in the code. This is why the static code analysis from Apple thinks you're using UI WebView.

    Microsoft fixed this in Xamarin.Forms 4.5, so the fix for you is easy: update Xamarin.Forms to Xamarin.Forms 4.5 (I recommend the latest version of 4.5 available)

    Important Note: In the Android project be sure to stay on API 28 so that you do not compile with AndroidX assemblies.

    Regards,
    Lance | Team Lead - US DevTools Support
    Progress Telerik

    Progress is here for your business, like always. Read more about the measures we are taking to ensure business continuity and help fight the COVID-19 pandemic.
    Our thoughts here at Progress are with those affected by the outbreak.
Back to Top