Hello !
I am building a navigation app for Android which mainly act as a compass. To achieve this, I use the DeviceMotion API from ‘expo-sensors’ in order to get the user’s device orientation relative to the north.
My problem is : Users without a compass in their device can download the app. Without this sensor, the app simply doesn’t work. I guess I could make the app check if there is a compass available with Magnetometer.isAvailableAsync()
and display something in that case, but I’d prefer the app not to be available in the PlayStore for users without a compass.
When I upload my .aab
bundle to the Google Play console and inspect the bundle here is what I see :
The feature android.hardware.sensor.compass
is missing.
Because I am in managed workflow, I can not edit the AndroidManifest.xml myself and add the line : <uses-feature android:name="android.hardware.sensor.compass" android:required="true" />
Is there a way to declare the use of this feature ?
Expo CLI 3.28.5 environment info:
System:
OS: macOS Mojave 10.14.6
Shell: 5.3 - /bin/zsh
Binaries:
Node: 12.18.0 - ~/.nvm/versions/node/v12.18.0/bin/node
Yarn: 1.17.3 - ~/.yarn/bin/yarn
npm: 6.14.4 - ~/.nvm/versions/node/v12.18.0/bin/npm
SDKs:
iOS SDK:
Platforms: iOS 13.2, DriverKit 19.0, macOS 10.15, tvOS 13.2, watchOS 6.1
Android SDK:
API Levels: 28
Build Tools: 28.0.3, 29.0.3
System Images: android-22 | Google APIs Intel x86 Atom, android-27 | Google Play Intel x86 Atom, android-29 | Google APIs Intel x86 Atom
IDEs:
Android Studio: 3.6 AI-192.7142.36.36.6241897
Xcode: 11.3.1/11C504 - /usr/bin/xcodebuild
npmPackages:
@expo/webpack-config: ^0.12.16 => 0.12.38
expo: ^39.0.4 => 39.0.4
react: 16.13.1 => 16.13.1
react-dom: 16.13.1 => 16.13.1
react-native: https://github.com/expo/react-native/archive/sdk-39.0.0.tar.gz => 0.63.2
react-native-web: ~0.13.16 => 0.13.16
npmGlobalPackages:
expo-cli: 3.28.5
Expo Workflow: managed