Android Question java.io.EOFException - but only sometimes

TheRealMatze

Active Member
Licensed User
Hi,
i got the following Error sometimes but only in debug. Most times it is enough to start the app again, sometimes i need to start the app two times - but then it works without error...

Any ideas what it can be?

B4X:
** Service (starter) Destroy (ignored)**
** Service (starter) Destroy (ignored)**
java.lang.RuntimeException: Unable to create service **name_removed**.starter: java.lang.RuntimeException: java.io.EOFException
    at android.app.ActivityThread.handleCreateService(ActivityThread.java:3544)
    at android.app.ActivityThread.access$1300(ActivityThread.java:199)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1666)
    at android.os.Handler.dispatchMessage(Handler.java:106)
    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.RuntimeException: java.io.EOFException
    at anywheresoftware.b4a.shell.Shell.virtualAssets(Shell.java:164)
    at anywheresoftware.b4a.shell.Shell.start(Shell.java:102)
    at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:92)
    at sx.datacollector.starter.onCreate(starter.java:34)
    at android.app.ActivityThread.handleCreateService(ActivityThread.java:3532)
    ... 8 more
Caused by: java.io.EOFException
    at java.io.DataInputStream.readFully(DataInputStream.java:200)
    at java.io.DataInputStream.readInt(DataInputStream.java:389)
    at anywheresoftware.b4a.shell.Shell.virtualAssets(Shell.java:136)
    ... 12 more
 

TheRealMatze

Active Member
Licensed User
Strange. I got the error on the emulator and on a real device - but indeed after removing all breakpoints it works. The error first occoured yesterday - so it wasn´t a problem the last 2 month... And i often use breakpoints in the development phase.

Thank you!
 
Upvote 0

drgottjr

Expert
Licensed User
Longtime User
it was pretty clear from the log that something was being accessed from dirassets but failing (eofexception) before completion. an ill-timed break might explain that interruption.
 
Upvote 0
Top