Skip to content
This repository has been archived by the owner on Jul 4, 2024. It is now read-only.

Do not require Timber. #42

Open
NathanRussak opened this issue Feb 9, 2021 · 0 comments
Open

Do not require Timber. #42

NathanRussak opened this issue Feb 9, 2021 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@NathanRussak
Copy link

Is your feature request related to a problem? Please describe.
If an app adds com.github.Fitbit:bitgatt as a dependency but does NOT add timber it will crash as soon as FitbitGatt attempts to setup.

Example build.gradle:

dependencies {
    implementation 'com.github.Fitbit:bitgatt:0.9.2-RC4'
    // No timber!
    ...
}

Example Crash:

2021-02-08 23:10:56.813 18446-18446/com.myapp.demo.debug E/AndroidRuntime: FATAL EXCEPTION: main
    Process: com.myapp.demo.debug, PID: 18446
    java.lang.NoClassDefFoundError: Failed resolution of: Ltimber/log/Timber;
        at com.fitbit.bluetooth.fbgatt.FitbitGatt.setup(FitbitGatt.java:161)
        at com.fitbit.bluetooth.fbgatt.FitbitGatt.getInstance(FitbitGatt.java:146)
        ...
     Caused by: java.lang.ClassNotFoundException: Didn't find class "timber.log.Timber" on path: DexPathList[[zip file "/data/app/~~buWpUy0wluCeKRNDidVUzA==/com.myapp.demo.debug-Zm3_EyFVTFzsRcNbP_PGQg==/base.apk"],nativeLibraryDirectories=[/data/app/~~buWpUy0wluCeKRNDidVUzA==/com.myapp.demo.debug-Zm3_EyFVTFzsRcNbP_PGQg==/lib/arm64, /system/lib64, /system_ext/lib64]]
        at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:207)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
        at com.fitbit.bluetooth.fbgatt.FitbitGatt.setup(FitbitGatt.java:161) 
        at com.fitbit.bluetooth.fbgatt.FitbitGatt.getInstance(FitbitGatt.java:146) 
        ...

Describe the solution you'd like
Timber is a great logging library but, if it isn't too much trouble, it would be nice to not REQUIRE all apps that use FitbitGatt
to also use Timber.

Describe alternatives you've considered
N/A

Additional context
N/A

@ionutlepi ionutlepi self-assigned this Feb 10, 2021
@ionutlepi ionutlepi added the bug Something isn't working label Feb 10, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants