OneSignalDevelopers / OneSignal-Cordova-Example

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

OneSignal Cordova Not Working with Android Api 29

sync-by-unito opened this issue · comments

Description:

I am not able to build Ionic 5 app with OneSignal plugin. It works with cordova-android@8.1.0 (Android target: android-28) but it does not work with cordova-android@9.0.0 (Android target: android-29).

Environment

  1. OneSignal: 2.11.1
  2. Cordova platform: android 9.0.0
  3. Android target: android-29

Anything else:

Configure project :app
WARNING: The onesignal-gradle-plugin MUST be before com.android.application!
Please put onesignal-gradle-plugin first OR update to com.android.tools.build:gradle:3.0.0 or newer!

Task :app:mergeDebugResources
OneSignalPlugin: WARNING: OneSignalPlugin: Downgraded 'com.android.support:23+' ->
28 to prevent compile errors! Recommend updating your project's compileSdkVersion!
Task :app:mergeDebugResources FAILED
FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ':app:mergeDebugResources'.

Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
Could not find com.android.support:support-v4:28.
Searched in the following locations:

Could not find com.android.support:support-annotations:28.
Searched in the following locations:

Could not find com.android.support:appcompat-v7:28.
Searched in the following locations:

Could not find com.android.support:support-v4:28.
Searched in the following locations:

Could not find com.android.support:cardview-v7:28.
Searched in the following locations:

Could not find com.android.support:support-fragment:28.
Searched in the following locations:

Could not find com.android.support:customtabs:28.
Searched in the following locations:

Could not find com.android.support:support-annotations:28.
Searched in the following locations:

Could not find com.android.support:support-core-utils:28.
Searched in the following locations:

Could not find com.android.support:support-v4:28.
Searched in the following locations:

Could not find com.android.support:appcompat-v7:28.
Searched in the following locations:

Could not find com.android.support:cardview-v7:28.
Searched in the following locations:

Could not find com.android.support:customtabs:28.
Searched in the following locations:

Could not find com.android.support:support-v4:28.
Searched in the following locations:

┆Issue is synchronized with this Asana task by Unito

➤ Bijoy Haldar commented:

I need fix too

➤ TraceDeTrail commented:

Hello, I have exactly the same problem...

➤ Luan Menezes commented:

I have the same problem... Any solution?

➤ rahulsindal commented:

issue solved after update cordova lateset pre-release plugin.
npm i cordova@10.0.1-nightly.2020.9.15.51fb44c0