fluttersamsung-mobileandroid-13

Prevent install two instance of same app on samsung android 13 devices


Enabling dual messenger app feature in android 13 with samsung devices, flutter app get installed twice, how to prevent this behaviour?

I don't know what to do


Solution

  • I had this same problem and joined the flutter discord to find an answer. Someone suggested this command: flutter run --device-user 0

    Samsung uses users to enable stuff like dual apps and secure folder.

    If you run adb shell pm list users, you might see something similar to this:

    Users:
        UserInfo{0:<your name>:c13} running
        UserInfo{95:DUAL_APP:20001010} running
        UserInfo{151:Secure Folder:10061030} running
    

    0 is your main device, DUAL_APP and secure folder are what they sound like.

    flutter run --device-user 0 tells flutter to only install for user 0. i.e. your main device