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

java.lang.BootstrapMethodError: Exception from call site #1 bootstrap method #1598

Open
wwwjiandan opened this issue Mar 30, 2020 · 3 comments

Comments

@wwwjiandan
Copy link

wwwjiandan commented Mar 30, 2020

when I migrate to AndroidX, upgrade butterknife from 8.4.0 to 10.2.1, when I run app, App crash and exception like
"java.lang.BootstrapMethodError: Exception from call site #1 bootstrap method" ,I also try 10.1.0,has the same question

D/AndroidRuntime: Shutting down VM
E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.knowin.iot.debug, PID: 12307
java.lang.BootstrapMethodError: Exception from call site #1 bootstrap method
at butterknife.internal.DebouncingOnClickListener.(DebouncingOnClickListener.java:12)
at com.knowin.iot.business.scene.SceneFragment_ViewBinding.(SceneFragment_ViewBinding.java:38)
at java.lang.reflect.Constructor.newInstance0(Native Method)
at java.lang.reflect.Constructor.newInstance(Constructor.java:343)
at butterknife.ButterKnife.bind(ButterKnife.java:170)
at com.knowin.base_frame.base.BaseFragment.onCreateView(BaseFragment.java:133)
at androidx.fragment.app.Fragment.performCreateView(Fragment.java:2600)
at androidx.fragment.app.FragmentManagerImpl.moveToState(FragmentManagerImpl.java:881)
at androidx.fragment.app.FragmentManagerImpl.moveFragmentToExpectedState(FragmentManagerImpl.java:1238)
at androidx.fragment.app.BackStackRecord.executeOps(BackStackRecord.java:434)
at androidx.fragment.app.FragmentManagerImpl.executeOps(FragmentManagerImpl.java:2079)
at androidx.fragment.app.FragmentManagerImpl.executeOpsTogether(FragmentManagerImpl.java:1869)
at androidx.fragment.app.FragmentManagerImpl.removeRedundantOperationsAndExecute(FragmentManagerImpl.java:1824)
at androidx.fragment.app.FragmentManagerImpl.execPendingActions(FragmentManagerImpl.java:1727)
at androidx.fragment.app.FragmentManagerImpl$2.run(FragmentManagerImpl.java:150)
at android.os.Handler.handleCallback(Handler.java:873)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:193)
at android.app.ActivityThread.main(ActivityThread.java:6669)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858)
Caused by: java.lang.ClassCastException: Bootstrap method returned null
at butterknife.internal.DebouncingOnClickListener.(DebouncingOnClickListener.java:12) 
at com.knowin.iot.business.scene.SceneFragment_ViewBinding.(SceneFragment_ViewBinding.java:38) 
at java.lang.reflect.Constructor.newInstance0(Native Method) 
at java.lang.reflect.Constructor.newInstance(Constructor.java:343) 
at butterknife.ButterKnife.bind(ButterKnife.java:170) 
at com.knowin.base_frame.base.BaseFragment.onCreateView(BaseFragment.java:133) 
at androidx.fragment.app.Fragment.performCreateView(Fragment.java:2600) 
at androidx.fragment.app.FragmentManagerImpl.moveToState(FragmentManagerImpl.java:881) 
at androidx.fragment.app.FragmentManagerImpl.moveFragmentToExpectedState(FragmentManagerImpl.java:1238) 
at androidx.fragment.app.BackStackRecord.executeOps(BackStackRecord.java:434) 
at androidx.fragment.app.FragmentManagerImpl.executeOps(FragmentManagerImpl.java:2079) 
at androidx.fragment.app.FragmentManagerImpl.executeOpsTogether(FragmentManagerImpl.java:1869) 
at androidx.fragment.app.FragmentManagerImpl.removeRedundantOperationsAndExecute(FragmentManagerImpl.java:1824) 
at androidx.fragment.app.FragmentManagerImpl.execPendingActions(FragmentManagerImpl.java:1727) 
at androidx.fragment.app.FragmentManagerImpl$2.run(FragmentManagerImpl.java:150) 
at android.os.Handler.handleCallback(Handler.java:873) 
at android.os.Handler.dispatchMessage(Handler.java:99) 
at android.os.Looper.loop(Looper.java:193) 
at android.app.ActivityThread.main(ActivityThread.java:6669) 
at java.lang.reflect.Method.invoke(Native Method) 
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493) 
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:858) 
I/Process: Sending signal. PID: 12307 SIG: 9

@wwwjiandan
Copy link
Author

Java8 has config,but never work for me.

@JakeWharton
Copy link
Owner

Are you using the latest AGP? Can you provide a sample that reproduces the crash?

@Proxcentaur
Copy link

add this on your build.gradle(module)
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants