a compiled APK will in no way help us debug what might be the cause for the crashes you’re reporting. Please upload the project source code to this location, which can only be accessed by Fuse team members: https://www.dropbox.com/request/ZgndLtJQm5eGzG9cicGK
We will then take it from there and see if we can find something.
to help us nail it down more quickly, are there any pointers to what should we be looking for?
Is there a particular thing that one needs to do in the app to make it crash (e.g. open a specific screen)? Does it crash immediately? Do you have to wait for it to crash?
Have you tried running fuse preview -tandroid targeting the device you know it crashes on, and do you know if the preview crashes too? And if it does, are there any errors thrown?
unfortunately and *for now i don’t have direct access to Android 6.0 mobile to run fuse preview -tandroid on that mobile, However i got reports provided with screenshots from clients and friends that app is crashes on their devices which all share same android version.
The app stops directly after opening, basically it never reach the login screen it always stops on the Splash screen and you don’t have to wait or to do any thing , the app just steps directly after launching.
Update:
i’ve just bought Samsung galaxy J5 device that runs 6.0.1 to do some testing after finishing with the setup i’ll provide with more details
ERROR: java.lang.SecurityException: getDeviceId: Neither user 10166 nor current process has android.permission.READ_PHONE_STATE.
Uno.Exception occured.
at Android.Base.JNI.TryGetException(Android.Base.Primitives.JNIEnvPtr,[string])
at Android.Base.JNI.CheckException(Android.Base.Primitives.JNIEnvPtr,[string])
at Android.Base.JNI.CheckException(Android.Base.Primitives.JNIEnvPtr)
at Device.UUID()
at Fuse.Scripting.NativeProperty`2.GetProperty(object[])
at Fuse.Scripting.V8.Marshaller.CallbackWrapper.Call(Fuse.Scripting.V8.Simple.JSValue[],Fuse.Scripting.V8.Simple.JSValue&)
at Fuse.Scripting.V8.V8SimpleExtensions.Call(Fuse.Scripting.V8.Simple.JSFunction,Fuse.Scripting.V8.Simple.JSContext,Fuse.Scripting.V8.Simple.JSObject,Fuse.Scripting.V8.Simple.JSValue[],Fuse.Scripting.V8.AutoReleasePool,Uno.Action<Fuse.Scripting.V8.Simple.JSScriptException>)
at Fuse.Scripting.V8.Object.CallMethod(string,object[])
at Fuse.Scripting.NativeEventEmitterModule.EmitClosure.Emit(Fuse.Scripting.Context,Fuse.Scripting.Object)
at Uno.Threading.IDispatcherExtensions.Arg2Invoke`2.Run()
at Fuse.Reactive.ThreadWorker.RunInner()
at Fuse.Reactive.ThreadWorker.Run()
but when i examined the code i found that the developer requested the permissions before the foreign code
// UUID platform specific implementations
[Foreign(Language.Java)]
[Require("AndroidManifest.RootElement", "<uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/>")]
[Require("AndroidManifest.RootElement", "<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>")]
[Require("AndroidManifest.RootElement", "<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>")]
private static extern(Android) string GetUUID()
@{
final android.app.Activity context = com.fuse.Activity.getRootActivity();
final TelephonyManager tm = (TelephonyManager)context.getSystemService(Context.TELEPHONY_SERVICE);
final String deviceId = "" + tm.getDeviceId();
final String serialNum = "" + tm.getSimSerialNumber();
final String androidId = "" + android.provider.Settings.Secure.getString(
context.getContentResolver(),
android.provider.Settings.Secure.ANDROID_ID
);
int macAdressId;
try {
// try to get MAC-address via NetworkInterface
final InetAddress ip = InetAddress.getLocalHost();
final NetworkInterface network = NetworkInterface.getByInetAddress(ip);
macAdressId = network.getHardwareAddress().hashCode();
} catch (Throwable e) {
// else get MAC-address via WifiManager
final WifiManager wifiManager = (WifiManager)context.getSystemService(Context.WIFI_SERVICE);
final boolean wifiEnabled = wifiManager.isWifiEnabled();
if (!wifiEnabled)
wifiManager.setWifiEnabled(true);
macAdressId = wifiManager.getConnectionInfo().getMacAddress().hashCode();
if (!wifiEnabled)
wifiManager.setWifiEnabled(false);
}
byte[] bytes = ByteBuffer.allocate(16)
.putInt(androidId.hashCode())
.putInt(macAdressId)
.putInt(serialNum.hashCode())
.putInt(deviceId.hashCode())
.array();
return UUID.nameUUIDFromBytes(bytes).toString().toUpperCase();
@}
This release introduces a new permissions model, where users can now directly manage app permissions at runtime. This model gives users improved visibility and control over permissions, while streamlining the installation and auto-update processes for app developers. Users can grant or revoke permissions individually for installed apps.
On your apps that target Android 6.0 (API level 23) or higher, make sure to check for and request permissions at runtime. To determine if your app has been granted a permission, call the new checkSelfPermission() method. To request a permission, call the new requestPermissions() method. Even if your app is not targeting Android 6.0 (API level 23), you should test your app under the new permissions model.
For details on supporting the new permissions model in your app, see Working with System Permissionss. For tips on how to assess the impact on your app, see Permissions Best Practices.
No actually i didn’t had enough time to try to fix it, finally i used a SECURITY_ID in android which can be used without asking for permissions. but in general i’m planning to submit a fix for the package soon, maybe after two days from now.