Just tested my cam64 extn demo app on Google Pixel 4a, Android 13 with companion 2.73u, and get the same error:
Unable to load extensions.java.lang.StringIndexOutOfBoundsException: start 1, end 0, length 0
Does not then load the app in companion. So it seems not a device specific issue, but a bug in companion 2.73 on Android <14 ? Also tested on other aia projects with extensions, getting the same result.
[EDIT - also tested on my Genymotion Emulator, which runs an Android 12 Google Pixel 3XL. This also fails to load an aia project with the same error.]
I try on Samsung S20 FE 5G SM-G781B/DS. The problem still exists but not limited to only this. Lets see if this one resolves first then taking care of other issues.
tested on old Asus with Android 7 and Companion v. 2.73, on Honor Magic 5 lite and Companion v.2.73u and on Xiaomi Redmi 9 with Companion v.2.73 and with any extension
Temporarily use the companion app on those devices which work or test using the apk file while the MIT App Inventor team hopefully will look into this issue soon @Susan_Lane @ewpatton
This is the output I get from adb logcat *:E when connecting with code
11-22 09:26:56.625 14085 14085 E AssetFetcher: Error in form.loadComponents
11-22 09:26:56.625 14085 14085 E AssetFetcher: java.lang.StringIndexOutOfBoundsException: start 1, end 0, length 0
11-22 09:26:56.625 14085 14085 E AssetFetcher: at java.lang.AbstractStringBuilder.checkRangeSIOOBE(AbstractStringBuilder.java:1729)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at java.lang.AbstractStringBuilder.substring(AbstractStringBuilder.java:1022)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at java.lang.StringBuilder.substring(StringBuilder.java:87)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at java.lang.AbstractStringBuilder.substring(AbstractStringBuilder.java:973)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at java.lang.StringBuilder.substring(StringBuilder.java:87)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at com.google.appinventor.components.runtime.ReplForm.loadComponents(ReplForm.java:480)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at com.google.appinventor.components.runtime.util.AssetFetcher.loadExtensions(AssetFetcher.java:137)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at java.lang.reflect.Method.invoke(Native Method)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at gnu.expr.PrimProcedure.apply(PrimProcedure.java:285)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at gnu.mapping.CallContext.runUntilDone(CallContext.java:234)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at gnu.mapping.CallContext.runUntilValue(CallContext.java:298)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at gnu.mapping.MethodProc.applyN(MethodProc.java:113)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at gnu.mapping.ProcedureN.apply0(ProcedureN.java:24)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at kawa.lang.Promise.force(Promise.java:27)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at kawa.lang.Promise.force(Promise.java:37)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at kawa.lib.misc.force(misc.scm:99)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at com.google.youngandroid.runtime$frame9.lambda20(runtime4706405383590784482.scm:3569)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at com.google.youngandroid.runtime$frame9.apply0(runtime4706405383590784482.scm:3566)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at gnu.expr.ModuleMethod.apply0(ModuleMethod.java:186)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at gnu.mapping.RunnableClosure.run(RunnableClosure.java:78)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at android.os.Handler.handleCallback(Handler.java:942)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at android.os.Handler.dispatchMessage(Handler.java:99)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at android.os.Looper.loopOnce(Looper.java:201)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at android.os.Looper.loop(Looper.java:288)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at android.app.ActivityThread.main(ActivityThread.java:7918)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at java.lang.reflect.Method.invoke(Native Method)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548)
11-22 09:26:56.625 14085 14085 E AssetFetcher: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:936)
I have the same problem (getting the out-of-bounds message when trying to run latest version of companion). Running Android 13 on Samsung S20. Everything was working fine yesterday morning with older version of companion (2.70?). Accidently deleted it off my phone. Reloaded companion from Google Play. Gotten the error ever since. Any way to get access to older versions of companion to try?
I don't get this error, but I can't connect to the companion because the extension jar file isn't being sent, and neither are resources like images. Oddly enough, everything works fine on my locally compiled server.