'DeepLinkDelegate' is ambiguous for type lookup in this context

On updating to latest version of Airship 15.0, getting error on using DeeplinkDelegate.

Following is the error

'DeepLinkDelegate' is ambiguous for type lookup in this context.

Didn't find what you were looking for?

New post

Comments

7 comments

  • Hi Gaurav,

    Thanks for reaching out to Airship Technical Support! In order for us to troubleshoot this issue further, could you please provide us with the following?

    • App Key
    • Elements of your implementation such as the UA codes and logs

    Also, I am linking the Airship iOS SDK Migration Guide in here for your reference: https://github.com/urbanairship/ios-library/blob/main/Documentation/Migration/migration-guide-14-15.md

    Regards,

    Arushi S.
    Technical Support Engineer
    Airship | San Francisco, CA

    Comment actions Permalink
  • Hi Arushi,

    Please find the details:

    • App Key: ZoNDqTExQfG7iQmoFEol4w -- Issue is generic not specific to any app.
    • Elements of your implementation such as the UA codes and logs -- I am inheriting DeepLinkDelegate on AppDelegate and doing so is throwing error on compile time. Error message is already shared. Also attaching code snippet where error is coming up. 

    I couldn't find any reference to DeepLinkDelegate on the github link shared.

    Comment actions Permalink
    0
  • Hi Gaurav,

    It would be great if you could please provide some more detail around the issue you're experiencing.

    Specifically, if you can provide any/all logs from Xcode that clearly show the errors you're getting, that will be useful if this is something we need to get to our Mobile Engineering team to resolve. Additionally, just so our Engineers can see, would you be able to provide the code snippets where you reference the DeepLinkDelegate from Airship and from your other 3rd party library?

    It would be helpful if we can see the full code/method that those calls are made in so we can see the full context of what's going on.

    Regards,
    Arushi S.
    Technical Support Engineer
    Airship | San Francisco, CA

    Comment actions Permalink
    0
  • Hi,

    I have already provided snapshot of code where error is coming up. Following is the error coming up while compiling it.

    /Users/gauravvig/Code/Viewlift/AppCMS/AppCMS/AppCMS/AppDelegate/AppDelegate.swift:108:133: error: 'DeepLinkDelegate' is ambiguous for type lookup in this context

    class AppDelegate: UIResponder, UIApplicationDelegate, AppConfigManagerDelegate, UITabBarControllerDelegate, AppsFlyerLibDelegate,  DeepLinkDelegate, PushNotificationDelegate, RegistrationDelegate {

                                                                                                                                        ^~~~~~~~~~~~~~~~

    /Users/gauravvig/Code/Viewlift/AppCMS/AppCMS/Pods/Airship/Airship/AirshipCore/Source/DeepLinkDelegate.swift:7:17: note: found this candidate

    public protocol DeepLinkDelegate {

                    ^

    AppsFlyerLib.DeepLinkDelegate:1:17: note: found this candidate

    public protocol DeepLinkDelegate : NSObjectProtocol {

    Regards

    Gaurav Vig

    Comment actions Permalink
    0
  • Hi Gaurav,

    I discussed with our Product Team internally, and it looks like this is a known issue that our Engineers are currently working on. Please keep an eye out for updates to the SDK that should fix this soon. 

    A quick workaround that should hopefully work, would be to create a new file with the following:

    import Airship
    
    public typealias AirshipDeepLinkDelegate = DeepLinkDelegate
    

    Then use AirshipDeepLinkDelegate instead of DeepLinkDelegate.

    Let us know if you have any additional questions or concerns.

    Regards,

    Arushi S.
    Technical Support Engineer
    Airship | San Francisco, CA

    Comment actions Permalink
    0
  • Hi Arushi,

    Did some other changes to make it work. I was thinking if the sdk would handle it internally. Anyway good to know issue is known to engineer and they are working on it. Thanks for another solution.

    Thanks

    Gaurav Vig

    Comment actions Permalink
    0
  • The error message "'DeepLinkDelegate' is ambiguous for type lookup in this context" indicates that there is a conflict or ambiguity in the usage of the DeepLinkDelegate class after updating to Airship version 15.0. This conflict can occur when there are multiple definitions or imports of the DeepLinkDelegate class in your code. To resolve this, you should ensure that you have only one import statement for the DeepLinkDelegate class and that it is not conflicting with any other classes or namespaces. If necessary, you can specify the full class name with its namespace to avoid any ambiguity. By resolving the conflicting imports or specifying the class name explicitly, you should be able to resolve the error and use the DeepLinkDelegate class successfully in your code.

    Comment actions Permalink
    0

Please sign in to leave a comment.