LogmeinRescue / Android-SDK

Rescue In-App Support Android SDK
http://secure.logmeinrescue.com/welcome/webhelp/EN/SDKa/MobileSDK/c_rasdk_overview.html
Other
5 stars 6 forks source link

CreationException when trying to connect to a session via PIN #54

Closed veggie2go closed 2 years ago

veggie2go commented 2 years ago

Hi there,

We are currently getting a CreationException when trying to connect to a support session using a pin code from an Android app.

We are using version 3.7.2 of the Android SDK and the exception is not reproduceable on all devices, though it occurs on a range of Android OS versions from 7.1.1 to 11.0 We were unable to find any information/complaint related to this. I hope you can help us sort this out.

Thank you, Diana

com.google.inject.CreationException: Unable to create injector, see the following errors:
1) com.logmein.rescuesdk.internal.fg$b is public, but has a method that returns a non-public type: com.logmein.rescuesdk.internal.fg. Due to limitations with java.lang.reflect.Proxy, this is not allowed. Please either make the factory non-public or the return type public.

1 error at com.google.inject.internal.Errors.throwCreationExceptionIfErrorsExist(Errors.java:2) at com.google.inject.internal.InternalInjectorCreator.initializeStatically(InternalInjectorCreator.java:21) at com.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:5) at com.google.inject.internal.InjectorImpl.createChildInjector(InjectorImpl.java:4) at com.google.inject.internal.InjectorImpl.createChildInjector(InjectorImpl.java:5) at com.logmein.rescuesdk.internal.ah.a(SourceFile:2) at com.logmein.rescuesdk.internal.tf$a.run(SourceFile:1) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641) at java.lang.Thread.run(Thread.java:923)

tbalogh commented 2 years ago

Hi @veggie2go!

We will investigate the issue and get back to you with the result.

tbalogh commented 2 years ago

Hi @veggie2go!

We were unable to reproduce the issue internally. Could you share a specific device and OS version, where you are able to reproduce the issue?

veggie2go commented 2 years ago

Hi there,

Thank you for looking into it. I am attaching screenshots with the requested device and OS info.

Thank you, Diana @Voxme Software Inc

Device_Models Android_OS_versions Manufacturers
veggie2go commented 2 years ago

Hello again,

Did the investigation of this issue drop by the wayside? We are still awaiting an answer/resolution as we are still experiencing the issue.

Thank you, Diana Diaconu

Voxme Software

tamasgyongyosi commented 2 years ago

Hi @veggie2go,

I'm sorry but we are still unable to reproduce this issue even testing it on the specific devices. Could you answer the following questions to help determine what is causing the problem.

Thank you

veggie2go commented 2 years ago

Hi,

We did experience the issue with the previous SDK versions (3.6.*), too. I hoped the current/latest SDK version had the issue fixed.

We are using AppScreenStreaming.

dependencies { implementation("com.logmein.rescuesdk:appscreenstreaming:3.7.2@aar") { transitive = true } implementation("com.logmein.rescuesdk:deviceinfo:3.7.2@aar") { transitive = true } ... }

The account email address is support@voxme.com

Thank you, Diana Diaconu diana@voxme.com

Voxme Software

tamasgyongyosi commented 2 years ago

@veggie2go

What version of JDK do you use? Did you add the resources and core dependencies too?

implementation('com.logmein.rescuesdk:resources:3.7.2@aar') {
      transitive = false // avoid resources dependencies
}
implementation('com.logmein.rescuesdk:core:3.7.2@aar') {
      transitive = true 
}

Thank you

tamasgyongyosi commented 2 years ago

@veggie2go

Have you reproduced this issue internally? I have created a new 'test' branch in the GitHub repository. It contains the same but not obfuscated code like version 3.7.2. https://github.com/LogmeinRescue/Android-SDK/commit/8d3b2d6a0b69b479ff493071b802cb2ce57da543 Could you build your app with this version of SDK to identify the problematic class?

Please modify the branch of SDK repository to 'test' in your top level gradle file:

allprojects {
    repositories {
      maven {
            url 'https://raw.githubusercontent.com/logmeinrescue/android-sdk/test/maven/repository'
        }
    }
}

and version of SDK in your app gradle file to 3.7.3-null-SNAPSHOT (a little bit hacky name :) ):

dependencies {
    implementation("com.logmein.rescuesdk:resources:3.7.3-null-SNAPSHOT@aar") {
        transitive = false // avoid resources dependencies
    }
    implementation("com.logmein.rescuesdk:core:3.7.3-null-SNAPSHOT@aar") {
        transitive = true
    }
    implementation("com.logmein.rescuesdk:deviceinfo:3.7.3-null-SNAPSHOT@aar") {
        transitive = true
    }
    implementation("com.logmein.rescuesdk:appscreenstreaming:3.7.3-null-SNAPSHOT@aar") {
        transitive = true
    }
}

Thank you

veggie2go commented 2 years ago

Hello,

and thank you! As mentioned in my original email we were unable to reproduce the issue internally, hence reaching out for support. I will try building with the dependencies above and will let you know.

Thank you, Diana

cswagner commented 2 years ago

Hi all,

I've started running into this issue (or at least a similar issue) after updating to v7.1.x of the Android Gradle plugin. It seems this version of the plugin has changes to the resource shrinker that may be causing this issue, since I only see it in release builds (with the resource shrinker enabled).

1) com.logmein.rescuesdk.internal.aj$b is public, but has a method that returns a non-public type: com.logmein.rescuesdk.internal.aj. Due to limitations with java.lang.reflect.Proxy, this is not allowed. Please either make the factory non-public or the return type public.

    1 error
        at com.google.inject.internal.Errors.throwCreationExceptionIfErrorsExist(:470)
        at com.google.inject.internal.InternalInjectorCreator.initializeStatically(:155)
        at com.google.inject.internal.InternalInjectorCreator.build(:107)
        at com.google.inject.internal.InjectorImpl.createChildInjector(:232)
        at com.google.inject.internal.InjectorImpl.createChildInjector(:236)
        at com.logmein.rescuesdk.internal.bk.a(:28)
        at com.logmein.rescuesdk.internal.oi$a.run(:108)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
        at java.lang.Thread.run(Thread.java:920)

No crash with:

Crash with:

veggie2go commented 2 years ago

Hmmm... thank you for that. It did not solve the issue for me, but I am now able to consistently reproduce the issue by adding the following to the gradle file for the debug build { minifyEnabled true multiDexEnabled true shrinkResources true } which basically mimics what is happening for the release build.

After adding the following line to the proguard file I got more specific class info in the CreationException:

-keep class com.logmein.rescuesdk.* { ; }

1) com.logmein.rescuesdk.internal.session.DescriptorAcquiringState$Factory is public, but has a method that returns a non-public type: com.logmein.rescuesdk.internal.session.DescriptorAcquiringState. Due to limitations with java.lang.reflect.Proxy, this is not allowed. Please either make the factory non-public or the return type public.

1 error at com.google.inject.internal.Errors.throwCreationExceptionIfErrorsExist(Errors.java:470) at com.google.inject.internal.InternalInjectorCreator.initializeStatically(InternalInjectorCreator.java:155) at com.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:107) at com.google.inject.internal.InjectorImpl.createChildInjector(InjectorImpl.java:232) at com.google.inject.internal.InjectorImpl.createChildInjector(InjectorImpl.java:236) at com.logmein.rescuesdk.internal.session.InternalSessionFactoryImpl.create(InternalSessionFactoryImpl.java:28) at com.logmein.rescuesdk.internal.session.BareSession$1.run(BareSession.java:108) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1133) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:607) at java.lang.Thread.run(Thread.java:761)

tamasgyongyosi commented 2 years ago

Hi @veggie2go ,

We've released the 3.8.0 version of SDK. Please check if this issue is resolved.

veggie2go commented 2 years ago

Hi Tamas,

I can not reproduce the issue with the new build. So the issue looks to be resolved.

Thank you! Diana