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

[Bug]: AndroidIDE crashed #1050

Closed
2 tasks done
sourkr opened this issue Jun 19, 2023 · 2 comments
Closed
2 tasks done

[Bug]: AndroidIDE crashed #1050

sourkr opened this issue Jun 19, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@sourkr
Copy link

sourkr commented Jun 19, 2023

What happened?

AndroidIDE crashed in middle of editing

What's the expected behavior?

It should not crash in middle of editing of files.

What version of AndroidIDE you're using?

v2.4.0 (debug builds)

Relevant log output

AndroidIDE crash report
Manufacturer: samsung
Device: SM-A346E
ABI: arm64-v8a
SDK version: 33
App version: v2.4.1-beta (241)

 Stacktrace: 
java.lang.NullPointerException: Attempt to invoke interface method 'openjdk.source.tree.BlockTree openjdk.source.tree.MethodTree.getBody()' on a null object reference
	at com.itsaky.androidide.lsp.java.rewrite.AddException$$ExternalSyntheticLambda0.invoke(R8$$SyntheticClass:44)
	at com.itsaky.androidide.lsp.java.compiler.SynchronizedTask.get(SynchronizedTask.java:8)
	at com.itsaky.androidide.lsp.java.rewrite.AddException.rewrite(AddException.java:32)
	at com.itsaky.androidide.lsp.java.rewrite.Rewrite.asCodeActions(Rewrite.java:1)
	at com.itsaky.androidide.lsp.java.actions.BaseJavaCodeAction.performCodeAction(BaseJavaCodeAction.kt:55)
	at com.itsaky.androidide.lsp.java.actions.diagnostics.AddThrowsAction.postExec(AddThrowsAction.kt:26)
	at com.itsaky.androidide.actions.internal.DefaultActionsRegistry$execInBackground$2$$ExternalSyntheticLambda0.run(R8$$SyntheticClass:30)
	at android.os.Handler.handleCallback(Handler.java:942)
	at android.os.Handler.dispatchMessage(Handler.java:99)
	at android.os.Looper.loopOnce(Looper.java:226)
	at android.os.Looper.loop(Looper.java:313)
	at android.app.ActivityThread.main(ActivityThread.java:8757)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:571)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1067)

Duplicate issues

  • This issue has not been reported yet.

Code of Conduct

  • I agree to follow this project's Code of Conduct
@sourkr sourkr added the bug Something isn't working label Jun 19, 2023
@itsaky
Copy link
Member

itsaky commented Jun 24, 2023

Can you provide a way to reproduce this issue? I can't think of a scenario in which the AddThrows action is shown for a method which doesn't have a method body.

@sourkr
Copy link
Author

sourkr commented Jun 25, 2023 via email

@itsaky itsaky closed this as completed Sep 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants