Troubleshooting
View as Markdown
Ask AI about this page
| Symptom | Fix |
|---|---|
Could not find com.qartvelo.ads:core:0.6.1 |
Make sure mavenCentral() is in allprojects.repositories in android/build.gradle; versions before 0.3.4 also need JitPack (Installation) |
| App crashes at start: “The Google Mobile Ads SDK was initialized incorrectly” | The adapter is on but the AdMob APPLICATION_ID meta-data is missing (legacy QartveloAds_admobEnabled=true setup). Add it, or set admob.androidAppId in the Expo plugin entry or the app.json key, which writes it for you (Installation) |
Promises reject with module_unavailable |
The app binary predates the package. Rebuild with npx react-native run-android |
Promises reject with unsupported_platform |
Running on web or another unsupported platform. Guard with QartveloAds.isSupported() |
initialize rejects with network_error on the emulator (local backend) |
Use http://10.0.2.2:<port>/, not localhost, and allow cleartext for it in debug |
initialize rejects with not_initialized |
The backend rejected the app key: check the key, that the package name equals your applicationId, and that the app is approved (or use testMode) |
| Options seem ignored | Initialization happens once per process; force-stop and restart the app after changing options |
Every load ends with fallbackStarted reason timeout |
The backend answered after the request timeout. Common on slow debug networks; raise the placement timeout in the dashboard while testing |
fallbackStarted but no AdMob ad |
The admob config is missing from the Expo plugin entry or app.json (or the legacy QartveloAds_admobEnabled flag is unset), admobFallback is false, the placement’s fallback is none, or no AdMob unit is configured for it |
| Banner stays empty | Check onLoadFailed; give the component a width (it defaults to 100%) and make sure only one banner per placement code is visible |
| Two banners on one screen, one stays empty | Banners of the same placement code share one ad. An anchored banner and a size="inline" banner on the same screen need two placement codes |
| A campaign shows a still image where the dashboard preview is animated | HTML5 ads need @qartvelo/react-native-ads 0.6.0 or later. Older versions get the static image versions of the same design |
| Two copies of React in Metro (local package) | Point Metro’s watchFolders at the package and block its node_modules/react(-native), as in the example app’s metro.config.js |
Setup warnings
Section titled “Setup warnings”| Warning code | Meaning | Fix |
|---|---|---|
package_mismatch |
The app key is registered for another package name or bundle ID (live mode only: test mode works with any package, e.g. a .dev debug build) |
Use the key of the app registered for this package, or correct the package in the dashboard |
platform_mismatch |
The app key belongs to an app not registered for this platform | Pass appKey: { android, ios } with each platform’s key, or one key when the app is registered for Android and iOS |
unknown_placement |
The placement code does not exist for this app | Create it in the dashboard with the format named in the warning |
format_mismatch |
The placement exists with another format | Use a placement of the right format, or change its format |
Build error naming admob.androidAppId or admob.iosAppId |
The AdMob App ID is missing or not an App ID (it must contain ~) |
Copy the App ID from AdMob, not an ad unit id (/) |
| Build error “in an Expo project” | A top-level "@qartvelo/react-native-ads" key in an Expo app.json |
Move it into the plugin entry in expo.plugins |
| Build error “already sets … AdMob App ID” | The app already declares a different AdMob App ID | Keep one App ID, in the Qartvelo config |
Android manifest merger error on com.google.android.gms.ads.DELAY_APP_MEASUREMENT_INIT |
Your own AndroidManifest.xml declares the flag with a value that differs from admob.delayAppMeasurementInit in the Qartvelo config (the library declares it only when that option is true) |
Keep one: remove the meta-data from your manifest, or set the option to match it |
iOS build error “cannot run node” or “cannot find the package” from @qartvelo/react-native-ads |
The Xcode build phase finds the package with the NODE_BINARY of ios/.xcode.env (and ios/.xcode.env.local) and does not store any machine path in your project |
Set NODE_BINARY there to your node, run npm install, then pod install |
More in the general Troubleshooting page.