ankidroid / Anki-Android

AnkiDroid: Anki flashcards on Android. Your secret trick to achieve superhuman information retention.
GNU General Public License v3.0
8.51k stars 2.21k forks source link

[BUG] Storage permission is asked in Android 13 and can't be granted [F-Droid/Full] #15463

Open alexanderadam opened 8 months ago

alexanderadam commented 8 months ago

Checked for duplicates?

What are the steps to reproduce this bug?

It's exactly the same issue as mentioned in #14423 but I was asked to open a separate issue. :shrug:

Expected behaviour

It complains with the message "Please grant AnkiDroid the storage permission" which unfortunately can't be given

Actual behaviour

Anki already has the permissions for

but it wants moooore :wink:

Debug info

I can't even open the app so how should I provide this information? :wink:

(Optional) Anything else you want to share?

And how do other apps access data if Anki isn't allowed to do it any more?
For instance the Video player NOVA can access data from various paths. And the same is true for VLC player of course.

Furthermore I have PDF viewers and other document apps that can access files.
What's the difference here? 🤔

Research

david-allison commented 8 months ago

What version of the app are you using?

The permission (which has been fixed in 2.17) is all files access, which Android does not include in the 'app info' screen

On my phone, this is either searchable, or:

alexanderadam commented 8 months ago

What version of the app are you using?

The permission (which has been fixed in 2.17)

That might be the culprit here as the latest version on F-Droid is 2.16.5 and the metadata doesn't mention 2.17 either.

david-allison commented 8 months ago

The steps provided should work for 2.16.5.

2.17 has an improved permissions dialog screen, rather than the toast message

alexanderadam commented 8 months ago

I followed the mentioned flow and gave the permission (the file permission was missing indeed). I killed AnkiDroid even afterwards but it still shows the error toast and redirects to the 'wrong' permission dialogue.

david-allison commented 8 months ago

What version of Android are you on?

alexanderadam commented 8 months ago

Android 13 Samsung One UI 5.1

soshial commented 8 months ago

I have the same problem on Samsung Galaxy S22 with Android 14 with the latest F-Droid v2.16.5.

david-allison commented 8 months ago

@soshial Any issues with the 'full' build of the 2.17beta?

soshial commented 8 months ago

Thanks, @david-allison! AnkiDroid-2.17beta2-full-universal.apk worked well, it asked for MANAGE_EXTERNAL_STORAGE successfully and I was able to create a test deck and add a card.

Although, I must admit I cannot possibly allow an app having such a grave permission installed on my phone. Do the Google Play and F-Droid versions have this permission removed? Which builds employ app-specific storage instead?

david-allison commented 8 months ago

The play variant (also distributed on Google Play) doesn't request the permission.

F-Droid uses full, which requires it.

If you're using play, be sure to sync regularly. Without that permission, uninstalling wipes all data and backups from your device

AbdullahAhmadAAK commented 7 months ago

I have the same issue on my Samsung Galaxy A32.

tasmo commented 7 months ago

Also not possible in Android 14 with GrapheneOS and Fdroid version 2.17.1.

github-actions[bot] commented 1 month ago

Hello 👋, this issue has been opened for more than 3 months with no activity on it. If the issue is still here, please keep in mind that we need community support and help to fix it! Just comment something like still searching for solutions and if you found one, please open a pull request! You have 7 days until this gets closed automatically