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

Exception when used with TimePickerDialog #77

Closed
prathimak86 opened this issue Jan 22, 2021 · 12 comments
Closed

Exception when used with TimePickerDialog #77

prathimak86 opened this issue Jan 22, 2021 · 12 comments

Comments

@prathimak86
Copy link

Following exception is thrown when I use the TimePickerDialog
Is this a known issue? Is there something I can do to resolve this issue?

android.view.InflateException: Binary XML file line #37: Binary XML file line #37: Error inflating class Button
Caused by: android.view.InflateException: Binary XML file line #37: Error inflating class Button
Caused by: java.lang.ClassNotFoundException: Didn't find class "android.view.Button" on path: DexPathList[[zip file "/data/app/com.checkpt.oatmobile-vckrE7QAdjG7AdRp2-Nnzg==/base.apk"],nativeLibraryDirectories=[/data/app/com.checkpt.oatmobile-vckrE7QAdjG7AdRp2-Nnzg==/lib/arm, /system/lib, /system/vendor/lib]]
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:125)
at java.lang.ClassLoader.loadClass(ClassLoader.java:379)
at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
at android.view.LayoutInflater.createView(LayoutInflater.java:606)
at android.view.LayoutInflater.onCreateView(LayoutInflater.java:703)
at android.view.LayoutInflater.onCreateView(LayoutInflater.java:720)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:788)
at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:730)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:863)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:824)
at android.view.LayoutInflater.rInflate(LayoutInflater.java:866)
at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:824)
at android.view.LayoutInflater.inflate(LayoutInflater.java:515)
at android.view.LayoutInflater.inflate(LayoutInflater.java:423)
at android.view.ViewStub.inflateViewNoAdd(ViewStub.java:269)
at android.view.ViewStub.inflate(ViewStub.java:302)
at com.android.internal.app.AlertController.resolvePanel(AlertController.java:514)
at com.android.internal.app.AlertController.setupView(AlertController.java:538)
at com.android.internal.app.AlertController.installContent(AlertController.java:275)
at android.app.AlertDialog.onCreate(AlertDialog.java:425)
at android.app.Dialog.dispatchOnCreate(Dialog.java:511)
at android.app.Dialog.show(Dialog.java:342)
at android.app.TimePickerDialog.show(TimePickerDialog.java:149)
at androidx.fragment.app.DialogFragment.onStart(Unknown Source:10)
at androidx.fragment.app.Fragment.w(Unknown Source:16)
at androidx.fragment.app.FragmentManagerImpl.a(Unknown Source:756)
at androidx.fragment.app.FragmentManagerImpl.l(Unknown Source:93)
at androidx.fragment.app.FragmentManagerImpl.a(Unknown Source:42)
at androidx.fragment.app.a.a(Unknown Source:173)
at androidx.fragment.app.FragmentManagerImpl.a(Unknown Source:38)
at androidx.fragment.app.FragmentManagerImpl.b(Unknown Source:113)
at androidx.fragment.app.FragmentManagerImpl.c(Unknown Source:88)
at androidx.fragment.app.FragmentManagerImpl.m(Unknown Source:21)
at androidx.fragment.app.FragmentManagerImpl$b.run(Unknown Source:2)
at android.os.Handler.handleCallback(Handler.java:790)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:164)
at android.app.ActivityThread.main(ActivityThread.java:7000)
at java.lang.reflect.Method.invoke(Method.java:-2)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:441)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1408)

@prathimak86 prathimak86 changed the title Exception when this the library with TimePickerDialog Exception when used with TimePickerDialog Jan 22, 2021
@B3nedikt
Copy link
Owner

@prathimak86 This is not a known issue, I just tried it myself and TimePickerDialog works for me.
Which versions of appcompat, ViewPump & restring are you using?

@prathimak86
Copy link
Author

Hi,
These are the versions which I am using

androidx.appcompat:appcompat:1.1.0
dev.b3nedikt.restring:restring:5.1.1
dev.b3nedikt.viewpump:viewpump:4.0.5
dev.b3nedikt.reword:reword:3.1.0

@B3nedikt
Copy link
Owner

B3nedikt commented Jan 24, 2021

I would recommend updating appcompat to 1.2.0, but that does not explain the crash. I cannot do more from my side here. Please fork this repository and change the example app so it reproduces your bug, then link it to this issue.

This looks weird though:

Caused by: java.lang.ClassNotFoundException: Didn't find class "android.view.Button" on path: DexPathList[[zip file "/data/app/com.checkpt.oatmobile-vckrE7QAdjG7AdRp2-Nnzg==/base.apk"],nativeLibraryDirectories=[/data/app/com.checkpt.oatmobile-vckrE7QAdjG7AdRp2-Nnzg==/lib/arm, /system/lib, /system/vendor/lib]]
at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:125)

Probably something about the way you integrate the dialog triggers this, maybe connected to proguard.

@B3nedikt
Copy link
Owner

Anyway I am closing this for now, if you manage to reproduce your issue with a fork of my libs example app feel free to open this issue again or open a PR if you think you fixed the issue :)

@prateekvijay
Copy link

It happens in android version 8.1

@B3nedikt
Copy link
Owner

@prateekvijay I just tested this, and managed to reproduce the crash on android 8.1 as well. No clue were the crash comes from though, I might look into it on the weekend if I find the time.

@B3nedikt B3nedikt reopened this Feb 18, 2021
@prathimak86
Copy link
Author

Yes this happens in 8.1 and Android 9 too.

@ravipardeshi02
Copy link

any updates on this bug?

@B3nedikt
Copy link
Owner

Just fixed it with ViewPump 4.0.6 :)

@ravipardeshi02
Copy link

Thank you very much Benedikt. It is working perfectly now.

@B3nedikt
Copy link
Owner

You`re welcome :)

@jorgecasariego
Copy link

Thanks @B3nedikt

After updating ViewPump is working fine!

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

5 participants