Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Synthetic stacktrace didn't have enough elements: are you using proguard? #1

Closed
Isanderthul opened this issue Feb 6, 2017 · 5 comments

Comments

@Isanderthul
Copy link

After adding your library, I am now getting these errors, causing crashes

02-06 13:03:55.226 22472-23118/za.co.demo.app 
E/AndroidRuntime: FATAL EXCEPTION: SyncAdapterThread-2
  Process: za.co.demo.app, PID: 22472
  java.lang.IllegalStateException: Synthetic stacktrace didn't have enough elements: are you using proguard?
      at timber.log.BaseTree.getTag(BaseTree.java:54)
      at timber.log.Timber$Tree.prepareLog(Timber.java:521)
      at timber.log.Timber$Tree.d(Timber.java:417)
      at timber.log.Timber$1.d(Timber.java:239)
      at timber.log.Timber.d(Timber.java:34)
      at za.co.demo.app.adaptors.SyncAdapter.onPerformSync(SyncAdapter.java:278)
      at android.content.AbstractThreadedSyncAdapter$SyncThread.run(AbstractThreadedSyncAdapter.java:272)
@Isanderthul
Copy link
Author

I thought it might be related to Timber.i so I changed all my Timber.i("") to Timber.d("") but it did not help.

@Isanderthul
Copy link
Author

I am using Timber. (not L.)

 } else {
            Timber.d("Upload Sync: ending");
            unlockTheSync();
        }

@MFlisar
Copy link
Owner

MFlisar commented Feb 6, 2017

What happens if you just try L.d(...)? My BaseTree is actually just and extended version of the debug tree of timber and I manually deifne a correct stack trace depth here: https://github.com/MFlisar/Lumberjack/blob/master/library/src/main/java/timber/log/BaseTree.java#L24. This depth only is correct, if you use L.d(...)... The normal timber log tree only has a depth of 5, I need a higher depth, because my functions are wrappnig the normal timber calls...

@Isanderthul
Copy link
Author

aah ok.

@MFlisar
Copy link
Owner

MFlisar commented Feb 7, 2017

I'll close this, I think we can discuss possible solutions in the other issue

@MFlisar MFlisar closed this as completed Feb 7, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants