Disable new Android permission system
adb install -g package.apk
I had a similar issue in automated testing: when launching the app the permission dialog popped up. The adb shell pm grant … command did not help but there is the  -g option of adb install to grant all permissions upon install. This solved the problem for me.
From adb --help:

Android Debug Bridge version 1.0.41
Version 30.0.5-6877874
[…]
app installation (see also `adb shell cmd package help`):
 install [-lrtsdg] [--instant] PACKAGE
     push a single package to the device and install it
[…]
    -g: grant all runtime permissions
[…]