-
Notifications
You must be signed in to change notification settings - Fork 32
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
APKMirror Installer: .apkm fails to install on devices running MIUI #116
Comments
Try disabling miui optimizations, install app, and re-enable miui optimizations. Xiaomi.eu team fixed this issue in their weekly roms, but for SAI, not APKmirror installer. |
@panhoong Can you please confirm whether this works? @the4anoni Do you have the relevant thread url where the fix was mentioned? I'm curious what the problem may be. It's probably not going to get fixed on older devices. I wonder if we can detect whether MIUI optimizations are on programmatically and pop something up to disable them. |
Kacskrz is from xiaomi.eu team |
Thank you.
I don't know anything about the fix itself, but I doubt it's specific to SAI. SAI just shows a warning to MIUI users, and I'm afraid we have no choice but to do the same. However, the good news is we managed to get in touch with a Xiaomi engineer and have given him the details of the issue, so maybe something will happen as a result. |
I've left a note for MIUI users in the app description, and we're probably going to show a warning in the event of an installation failure. Our developer ordered a Poco device, so we'll be able to test the fix soon. |
Hi! Im having issues trying to checkmark Architecture part. Is there anything I can do? Im using an androidbox t95. |
@asesinopr Please open a separate issue and explain it in more detail. It doesn't seem related to this MIUI issue. |
I'm Igor from Xiaomi.eu team. APKMirror Installer works fine here. Tested by installing Netflix APKM bundle. No issues at all. The reason being that we disable the restriction that only allows select few package names to initiate installer sessions on our ROMs. (it can also be disabled by disabling MIUI optimization, which we remove from our ROMs as it's not relevant since we disable nonsense like that ourselves by default). |
@IgorEisberg Are you confirming that your ROMs have added |
No, I confirmed that we have no blacklist/whitelist, I completely disabled the restriction, any installer should work fine, like on AOSP ROMs. |
Thank you. Now if only Xiaomi would remove this ridiculous limitation from their core ROMs, but so far our attempts to convince their engineer have failed. |
As far as I understand, from security stand-point, the purpose is to prevent malicious installers from silently pushing malicious apps... but there's already a security measure for that: the "Install unknown apps" special permission which has to be explicitly granted by the user. So... I really don't see the actual purpose of this restriction. |
It can't be done silently if it already asks the user to confirm the installation anyway via the OS dialog, so this behavior is useless and not needed. Are you guys saying that starting from some Android/MIUI version this behavior is gone? If so, from which? |
Only from Xiaomi.eu 20.2.20 and never. Stock Miui still has this problem. |
@the4anoni Stock? Xiaomi has various types of MIUI ? One for Europe and one for something else (China?) ? Why the need for it? Why can't they use the standard that developers can handle? Once an app tries to install another app, the OS already asks the user if it's ok to install. Xiaomi is one of the most terrible ones on the https://dontkillmyapp.com/ website, with made up rules that are turned on by default, breaking apps. Users usually don't even notice because of white-lists of popular apps, and when they do, they blame the developers because it works fine on the popular apps. And developers have nothing to do about it... Xiaomi should stop with these made up rules, at least by default. Let only users who enable them (manually, when they reach the settings) deal with the breaking of apps. It's unfair that Xiaomi lets some apps work fine and some not, by default. |
Xiaomi has many stock ROMs:
Xiaomi.eu is Custom rom based on China, both Stable or weekly. |
@the4anoni Why is it called "Xiaomi.eu" ? I thought it means "Europe" . Which of those stock ROMs has the problematic behavior and which don't? How in code do you check that it has it? This was mentioned above:
Is it official? Can it be used without worrying ? How can I find more of such special flags (example the "auto-start" permission of Xiaomi) ? And is there an Intent that developers can use to reach the exact setting for users to reach and enable/disable them there? |
Because this project started long time before Xiaomi made Miui for other regions than China. All stock ROMs don't work with SAI or apkmirror installer. |
@the4anoni Didn't you guys say that the restriction was removed from MIUI at some point and it should work fine ? Maybe it's from some MIUI version, or something? Quotes: "APKMirror Installer works fine here. Tested by installing Netflix APKM bundle. No issues at all" On SAI, it claims it should not be needed from MIUI 20.2.20 , and I've found only one forum thread that only has a clue about this, but nothing official: https://xiaomi.eu/community/threads/need-to-turn-off-miui-optimization-for-mi-9.54624/ Is it possible that on some stock ROMs of Xiaomi, starting from this version, the restriction is disabled by default (or doesn't even exist) ? |
Xiaomi.eu is still a Miui |
@the4anoni You didn't answer the question... |
I did, read all discussion again. Nobody said this was fixed in stock Xiaomi ROMs. |
@the4anoni I gave you quotes about it, showing that the dev of Xiaomi said it worked fine for him, and that he disabled the restriction. Also, SAI says as such (search for "installer_miui_warning_message") :
|
Anyway, attached here a sample POC to check on Xiaomi's restriction. Hope this could help anyone here. |
Look, I'm not exactly into testing what happens when MIUI optimizations are off, this isn't one of our usage scenarios. One example to what happens when disabling it (might have been changed already, don't know) is that Always-on display setting is being displayed on devices with LCD screens. Those devices don't have the MiuiAod.apk that is responsible for AOD, so clicking that setting will cause Settings app to crash because the activity can't be found. |
@IgorEisberg I now tested on Xiaomi Redmi 8, and disabling MIUI optimizations didn't cause a crash when enabling/disabling always-on-display. However, I don't think it does anything, with or without MIUI optimizations turned on. I don't get why it even exists... I tried to restart the OS even (when both of these are turned on), but this feature doesn't do anything, and it got even weirder: the feature of always-on-display was gone. Seems that disabling MIUI optimizations lets you see always-on-display setting, even though it doesn't do anything at all. |
Of course it doesn't. The actual AOD content is in MiuiAod.apk which isn't included with devices with LCD screens. It used to crash when AOD was accessible from a preference with an Intent attached to it. No longer an issue, but still reveals settings that aren't supposed to be shown. |
@IgorEisberg It should be very easy to avoid this case. Add a condition: If it's LCD screen, don't show the setting, ever. |
I never argued that it's hard to hide... I just said that I have no reason to. We have no MIUI optimization-related issues that I know of. |
@IgorEisberg You already explained there is a reason: It can crash or not do anything at all. |
It can crash if MIUI optimization is disabled, not the other way around... hence I see no reason to touch it. |
@IgorEisberg Right, and since users can disable it (and they might, because it's a custom ROM so it's power users and developers audience), it is an issue. |
Not my issue. I'm not a babysitter. |
@IgorEisberg Crashing or doing nothing for a setting is a bug. Doesn't matter how user reached it. Anyway, your choice. I have Pixel 4 :) |
Of course it does matter. If it's not normally accessible to the end-user and the user unlocked developer mode (which is common practice in MIUI apps) or used Activity Launcher of some sort, and the activity crashed or the user reached some page that's not being used by the OS normally, then it's the user's problem. |
@IgorEisberg OK. I don't agree. |
Doesn't matter if you agree or not. That's the reality of how Android is built, especially non-stock Android. |
@IgorEisberg Xiaomi ruined Android in various ways. This is just one of those cases. |
On problem with disabling optimizations is it also cancels all permissions of all apps. Thus results in, after enabling optimizations one has to give permissions to every freakin app. |
I am noting that even though Xiaomi restricts installation of apks using third party installers, |
I need advice on getting Apk mirror on , LG. Stylo 6 metro pcs phone |
The latest stable version of MIUI China is now working fine. |
Well this is great news, thanks for letting us know. |
Not work on MIUI13 China Edition |
Does this happen to apk apkms or only a specific one? I haven't seen this error before (or at least in a long time), and you're the only person who reported it. |
Actually I tried to install 'Sonic Forces' moded apk file downloaded from some external sources, where while installing the same I got this error. |
Actual behavior
When I try to install the Netflix .apkm file using the APKMirror Installer, it gives me an error message: "App installation failed. The system failed to install the package because of system issues."
On Xiaomi Mi 8 running on Android 10 (MIUI 11.0.6 China Stable release, QEACNXM)
The text was updated successfully, but these errors were encountered: