Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error 'Plugin-Version' of 'unspecified' for 'com.android.build.gradle.LibraryPlugin #709

Closed
mivewi opened this issue Jun 16, 2021 · 40 comments

Comments

@mivewi
Copy link

mivewi commented Jun 16, 2021

Description:
When using gradlew bundleRelease I get the errors:

> Configure project :capacitor-cordova-android-plugins
Error 'Plugin-Version' of 'unspecified' for 'com.android.build.gradle.LibraryPlugin@139d3994' is not a valid version number

> Configure project :app
Error 'Plugin-Version' of 'unspecified' for 'com.android.build.gradle.AppPlugin@5347c145' is not a valid version number 
OneSignal Warning: Could not get AGP plugin version
google-services.json not found, google-services plugin not applied. Push Notifications won't work

Environment

Ionic info:

Ionic:

  Ionic CLI                     : 5.4.16
  Ionic Framework               : @ionic/angular 5.4.0        
  @angular-devkit/build-angular : 12.0.3
  @angular/cli                  : 12.0.3
  @ionic/angular-toolkit        : 2.3.3

Capacitor:

  Capacitor CLI   : 2.4.2
  @capacitor/core : 2.4.7

Cordova:

  Cordova CLI       : not installed
  Cordova Platforms : none
  Cordova Plugins   : no whitelisted plugins (0 plugins total)

Utility:

  cordova-res : 0.15.3
  native-run  : 1.4.0

System:

  Android SDK Tools : 26.1.1 (C:\Users\mivew\AppData\Local\Android\Sdk)
  NodeJS            : v14.15.4 (C:\Program Files\nodejs\node.exe)
  npm               : 6.14.10
  OS                : Windows 10

Onesignal versions:
"@ionic-native/onesignal": "^5.31.1"
"onesignal-cordova-plugin": "^2.11.4"

Steps to Reproduce Issue:
From a fresh new app with no other plugins added:

  1. ionic build --prod
  2. ionic cordova plugin add onesignal-cordova-plugin
  3. npm install onesignal-cordova-plugin
  4. npx cap sync
  5. npm install onesignal-cordova-plugin
  6. npx cap sync
  7. cd android && gradlew bundleRelease

I was following this setup: https://documentation.onesignal.com/docs/ionic-sdk-setup

I have tried with my project on two different pcs and tried to create a new project. The issue is still there.

Other people are having the same issue, with no solution yet:
https://stackoverflow.com/questions/67678333/error-plugin-version-of-unspecified-for-com-android-build-gradle-appplugin

On the github forum I couldn't find the solution either.

@distalx
Copy link

distalx commented Jun 24, 2021

I'm also getting a similar error with Cordova.

Error 'Plugin-Version' of 'unspecified' for 'com.android.build.gradle.AppPlugin@3553e522' is not a valid version number

I'm using the following version of SDK

onesignal-cordova-plugin 2.11.3

Steps to Reproduce Issue:

  1. cordova create hello com.example.hello HelloWorld
  2. cordova platform add ios android
  3. cordova plugin add onesignal-cordova-plugin@2.11.3 --save
  4. Add Required Code Step 3 And other necessary steps from the docs
  5. cordova build

This error occurs only while building apps. But there is no issue while running the app with cordova run command.

@reesz
Copy link

reesz commented Jul 7, 2021

I'm suddenly getting the same error when building android for production.
Is there anything known where this comes from or how to work around this? This wasn't the case a couple of months ago and I didn't really update anything in my app.

Ionic Info:

Ionic:

   Ionic CLI                     : 6.12.2 (/usr/local/lib/node_modules/@ionic/cli)
   Ionic Framework               : @ionic/angular 4.11.5
   @angular-devkit/build-angular : 0.10.7
   @angular-devkit/schematics    : 7.2.4
   @angular/cli                  : 7.2.4
   @ionic/angular-toolkit        : 1.3.0

Cordova:

   Cordova CLI       : 10.0.0
   Cordova Platforms : 6.0.0, android 8.1.0, browser, ios 5.1.1
   Cordova Plugins   : cordova-plugin-ionic-keyboard 2.2.0, cordova-plugin-ionic-webview 5.0.0, (and 24 other plugins)

Utility:

   cordova-res (update available: 0.15.3) : 0.15.0
   native-run (update available: 1.4.0)   : 0.3.0

System:

   Android SDK Tools : 26.1.1 (/Users/reesz/Library/Android/sdk)
   ios-deploy        : 1.10.0
   ios-sim           : 8.0.2
   NodeJS            : v11.15.0 (/usr/local/bin/node)
   npm               : 7.12.1
   OS                : macOS Big Sur
   Xcode             : Xcode 12.5 Build version 12E262

SDK version:
"onesignal-cordova-plugin": "^2.10.1",

The errors I'm getting:

> Configure project :app
WARNING: Configuration 'compile' is obsolete and has been replaced with 'implementation' and 'api'.
It will be removed at the end of 2018. For more information see: http://d.android.com/r/tools/update-dependency-configurations.html
Error 'Plugin-Version' of 'unspecified' for 'com.android.build.gradle.AppPlugin@1a3e9627' is not a valid version number

* Where:
Script '/Users/reesz/Desktop/Projekte/pizza/heat/dealtime-hybrid-app/dealtime-mobile/platforms/android/cordova-support-google-services/mobileapp-build.gradle' line: 16

* What went wrong:
A problem occurred evaluating project ':app'.
> Failed to apply plugin [class 'com.google.gms.googleservices.GoogleServicesPlugin']
   > All firebase libraries must be either above or below 14.0.0

For me it's pointing me towards the cordova-support-google-services plugin, while also saying something about the firebase libraries (used in OneSignal to send notifications on android)

@psnfrench
Copy link

I had this issue (plus several others), and the solution was to upgrade to cordova-android 9.1.0 ie.
ionic cordova platform remove android
ionic cordova platform add android@9

I also had to add in the cordova-plugin-androidx-adapter to get some of my other plugins to work

@SimonBrazell
Copy link

I had this problem myself with onesignal-cordova-plugin@2.11.4 and onesignal-cordova-plugin@3.0.0, was able to resolve it by downgrading to onesignal-cordova-plugin@2.11.3.

Perhaps the maintainers could chime in on this one as it's keeping me from upgrading to v3.

@SimonBrazell
Copy link

Here is my plugin list if that helps:

com.googlemaps.ios 3.9.0 "Google Maps SDK for iOS"
cordova-plugin-androidx-adapter 1.1.3 "cordova-plugin-androidx-adapter"
cordova-plugin-androidx 3.0.0 "cordova-plugin-androidx"
cordova-plugin-badge 0.8.8 "Badge"
cordova-plugin-camera 5.0.3 "Camera"
cordova-plugin-compat 1.2.0 "Compat"
cordova-plugin-device 2.0.3 "Device"
cordova-plugin-geolocation 4.0.2 "Geolocation"
cordova-plugin-googlemaps 2.7.1 "cordova-plugin-googlemaps"
cordova-plugin-inappbrowser 5.0.0 "InAppBrowser"
cordova-plugin-ionic-keyboard 2.2.0 "cordova-plugin-ionic-keyboard"
cordova-plugin-ionic-webview 5.0.0 "cordova-plugin-ionic-webview"
cordova-plugin-local-notification 0.9.3 "LocalNotification"
cordova-plugin-splashscreen 6.0.0 "Splashscreen"
cordova-plugin-statusbar 2.4.3 "StatusBar"
cordova-plugin-whitelist 1.3.5 "Whitelist"
cordova-sqlite-storage 5.0.0 "Cordova sqlite storage plugin - cordova-sqlite-storage plugin version"
onesignal-cordova-plugin 2.11.3 "OneSignal Push Notifications"

and my dev env info:

Ionic:

   Ionic CLI                     : 6.17.0 (/Users/.../.nvm/versions/node/v14.17.3/lib/node_modules/@ionic/cli)
   Ionic Framework               : @ionic/angular 5.4.4
   @angular-devkit/build-angular : 0.1102.12
   @angular-devkit/schematics    : 11.2.12
   @angular/cli                  : 11.2.12
   @ionic/angular-toolkit        : 3.1.1

Cordova:

   Cordova CLI       : 10.0.0
   Cordova Platforms : android 9.1.0, ios 6.2.0
   Cordova Plugins   : cordova-plugin-ionic-keyboard 2.2.0, cordova-plugin-ionic-webview 5.0.0, (and 14 other plugins)

Utility:

   cordova-res : 0.15.3
   native-run  : 1.4.0

System:

   Android SDK Tools : 26.1.1 (/Users/.../Library/Android/sdk/)
   ios-deploy        : 1.11.4
   ios-sim           : 8.0.2
   NodeJS            : v14.17.3 (/Users/.../.nvm/versions/node/v14.17.3/bin/node)
   npm               : 6.14.13
   OS                : macOS Big Sur
   Xcode             : Xcode 12.5.1 Build version 12E507

@gelinger777
Copy link

can confirm that happens also on latest ionic with cordova android@8 . Unfortunately can't upgrade to @9

@gelinger777
Copy link

@jkasten2 could you have a look?

@SimonBrazell
Copy link

@gelinger777 you should be fine to build the latest cordova android if you downgrade to 2.11.3, worked for with the above plugin list.

@gelinger777
Copy link

@SimonBrazell it's not true. I have tried both @8 and @9 and 3.0.0 and 2.11.3 and I am still getting that unspecified version error.

@SimonBrazell
Copy link

@gelinger777 have you included cordova-plugin-androidx-adapter and cordova-plugin-androidx in your project? If not perhaps this would help?

@gelinger777
Copy link

Yes, I have included them in cordova 8 , didn't helped . In cordova 9 you don't need to include the cordova-plugin-androidx because it supports it out of the box. Just you need to add specific tag in config.xml . That didn't helped unfortunately. To build APK I see you are using Android SDK Tools : 26.1.1 which is quite old one. Play Store will soon compulse to use SDK 30 on any app updates , and it's mandatory to have SDK 30 for new apps. probably that could be the reason .. I don't know. But the problem needs to be solved on Gradle Level IMHO .

@SimonBrazell
Copy link

I'm not sure why ionic info reports Android SDK Tools : 26.1.1 I've installed the latest SDK via Android Studio and it is used for builds...

Not sure if I can help you then, let me know if you have any luck.

@gelinger777
Copy link

Which one do you use? 31?

@SimonBrazell
Copy link

ls $ANDROID_HOME/platforms
android-29

Android 29 by the looks of it, so not the latest, perhaps that accounts for the difference here?

I've set android-targetSdkVersion to 29 in my config.xml file.

@SimonBrazell
Copy link

Oh wait just reading the Cordova Android platform guide, you need to use the obsolete Android SDK Tools (v26.1.1) which explains what ionic info is reporting.

@gelinger777
Copy link

I just discovered that I am hit by this issue
apache/cordova-android#830

It tries to build on SDK 28. Maybe that's the reason...

@SimonBrazell
Copy link

I've just updated my android-targetSdkVersion to 30 in the config.xml, I'll see if I'm able to build.

@SimonBrazell
Copy link

No luck, I'd stick with cordova-android@9 and target SDK 29 for now, seems to be some compatibility issues between cordova-android@10 and some of the plugins.

@gelinger777
Copy link

I will try to understand why it always sets the build to be on 28. Thanks for helping to debug

@SimonBrazell
Copy link

No problem, good luck.

@SimonBrazell
Copy link

Actually you'll need to target API 30 if it's a new app it seems so disregard what I just said, I'd only been updating existing apps until now so hadn't come across this before today.

https://developer.android.com/distribute/best-practices/develop/target-sdk

So I'm going to have to get API 30 working too...

@gelinger777
Copy link

I have tried now with 29, and with 30 . Problem is not solvable. If OneSignal team will not solve the problem , I am going to abandone this plugin and move to Firebase Messeging.

@gelinger777
Copy link

gelinger777 commented Aug 23, 2021

Dear @gdeglin Thank you for a great plugin which we were using since cordova 7. Now when we have to use other plugins which require androidx and cordova@9 , it seems your onesignal cordova plugin is incomplete and buggy in terms of gradle configuration. Unfortunately I don't have in the team core android developers, and thus we are using ionic framework with cordova . Because of this issue the plugin you provided is not anymore building properly and is useless.

I have spent almost 2 full days last weekend trying to make it work. I have tried cordova@8 and cordova@9 with native androidX enabler and/without with cordova-plugin-androidx . I have tries SDK 29, and 30 with Many different tricks. I have also uninstalled cordova-plugin-facebook-connect and cordova-appsflyer-sdk plugins. I have tried to add onesignal before and after and without it. I made almost 100 different tries to build it with no success. It's really frustrating. Could you please urge this issue to be solved internally? Since 11 days I am watching this issue with hope that one of team members would have a deeper look into it. Can we have a solution for this or we have to abandone onesignal?

@jkasten2 @Nightsd01 @mikechoch @Jeasmine @rgomezp @leemunroe @emawby @albertopq

@chacabuk
Copy link

chacabuk commented Aug 25, 2021

Remove onesignal-cordova-plugin 3.0.0
And use:

  • "onesignal-cordova-plugin": "^2.11.4"
  • "@ionic-native/onesignal": "^5.36.0"

Hope help somebody

ionic info

Ionic:

   Ionic CLI                     : 6.16.3 (C:\Users\Pablo\AppData\Roaming\npm\node_modules\@ionic\cli)
   Ionic Framework               : @ionic/angular 5.6.13
   @angular-devkit/build-angular : 12.2.2
   @angular-devkit/schematics    : 12.1.4
   @angular/cli                  : 12.2.2
   @ionic/angular-toolkit        : 4.0.0

Cordova:

   Cordova CLI       : 10.0.0
   Cordova Platforms : android 9.1.0
   Cordova Plugins   : cordova-plugin-ionic-keyboard 2.2.0, cordova-plugin-ionic-webview 4.2.1, (and 5 other plugins)

Utility:

   cordova-res (update available: 0.15.3) : 0.15.2
   native-run (update available: 1.4.0)   : 0.2.8

System:

   Android SDK Tools : 26.1.1 (C:\Users\Pablo\AppData\Local\Android\Sdk\)
   NodeJS            : v14.15.1 (C:\Program Files\nodejs\node.exe)
   npm               : 6.14.8
   OS                : Windows 10

cordova plugins

cordova-plugin-device 2.0.2 "Device"
cordova-plugin-ionic-keyboard 2.2.0 "cordova-plugin-ionic-keyboard"
cordova-plugin-ionic-webview 4.2.1 "cordova-plugin-ionic-webview"
cordova-plugin-splashscreen 5.0.2 "Splashscreen"
cordova-plugin-statusbar 2.4.2 "StatusBar"
cordova-plugin-whitelist 1.3.3 "Whitelist"
onesignal-cordova-plugin 2.11.4 "OneSignal Push Notifications"

No need: cordova-androidx-build 1.0.4 or similar

@gelinger777
Copy link

dear @chacabuk I have tried ^2.11.4 and ^2.11.3 and ^2.11.2 with corodova 8 and cordova 9. It does not work. I still get the same error

@gelinger777
Copy link

also you are using very few plugins , and you can live without androidx, but the combination I am using we are required to use androidx

@bradical1379
Copy link

bradical1379 commented Aug 28, 2021

I was facing this same error. Here is how I was able to get it to work.

  • Updated my Android Studio to Arctic Fox | Version 2020.3.1 Patch 1
  • Removed my existing gradle folder rm -rf ~/.gradle
  • Open new Android Studio and invalidate any project caches and restart
  • Rerun project

@gelinger777
Copy link

gelinger777 commented Aug 29, 2021

@bradical1379 I have updated the Android Studio. I have removed .gradle from home directory and invalidated.

App is building , and seems is working (before it was also building and working), but
Error 'Plugin-Version' of 'unspecified' for 'com.android.build.gradle.LibraryPlugin is not going anywhere.

@bradical1379
Copy link

@gelinger777 - which version of gradle are you using?

Are you using Capacitor or Cordova? Which versions of those?

@gelinger777
Copy link

@bradical1379 I am using Cordova. I wrote already up that I have tried to build on cordova@8, on cordova@9 and even on cordova@10. With very many different setups. Each Cordova version brings by default it;s own Gradle Settings and Versions. So I cannot say I am using Gradle 5 or 6 or 3. The latest try was on this one

Ionic:

   Ionic CLI                     : 6.17.0 (/home/bln77/.nvm/versions/node/v10.19.0/lib/node_modules/@ionic/cli)
   Ionic Framework               : @ionic/angular 5.6.13
   @angular-devkit/build-angular : 0.1000.8
   @angular-devkit/schematics    : 10.0.8
   @angular/cli                  : 10.0.8
   @ionic/angular-toolkit        : 2.3.3

Cordova:

   Cordova CLI       : 10.0.0
   Cordova Platforms : android 9.1.0
   Cordova Plugins   : cordova-plugin-ionic-keyboard 2.2.0, cordova-plugin-ionic-webview 4.2.1, (and 22 other plugins)

Utility:

   cordova-res                          : 0.15.3
   native-run (update available: 1.4.0) : 1.0.0

System:

   Android SDK Tools : 26.1.1 (/home/bln77/Android/Sdk)
   NodeJS            : v10.19.0 (/home/bln77/.nvm/versions/node/v10.19.0/bin/node)
   npm               : 6.14.1
   OS                : Linux 5.4

I guess it's 6.5


WARNING in /home/bln77/Desktop/ionic/avenue/src/store/store.module.ts depends on 'redux-observable-es6-compat'. CommonJS or AMD dependencies can cause optimization bailouts.
For more info see: https://angular.io/guide/build#configuring-commonjs-dependencies
> cordova build android --debug
Discovered plugin "mx.ferreyra.callnumber". Adding it to the project
Plugin "call-number" already installed on android.
config file *-Info.plist requested for changes not found at /home/bln77/Desktop/ionic/avenue/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /home/bln77/Desktop/ionic/avenue/platforms/android/*-Info.plist, ignoring
config file *-Info.plist requested for changes not found at /home/bln77/Desktop/ionic/avenue/platforms/android/*-Info.plist, ignoring
[Gradle Properties] Detected Gradle property "android.useAndroidX" with the value of "true", Cordova's recommended value is "false"
[Gradle Properties] Detected Gradle property "android.enableJetifier" with the value of "true", Cordova's recommended value is "false"
cordova-plugin-androidx-adapter: Processed 92 source files in 1154ms
Checking Java JDK and Android SDK versions
ANDROID_SDK_ROOT=/home/bln77/Android/Sdk (recommended setting)
ANDROID_HOME=/home/bln77/Android/Sdk (DEPRECATED)
Using Android SDK: /home/bln77/Android/Sdk
Subproject Path: CordovaLib
Subproject Path: app
Downloading https://services.gradle.org/distributions/gradle-6.5-all.zip
...........................................................................................................................................
Unzipping /home/bln77/.gradle/wrapper/dists/gradle-6.5-all/2oz4ud9k3tuxjg84bbf55q0tn/gradle-6.5-all.zip to /home/bln77/.gradle/wrapper/dists/gradle-6.5-all/2oz4ud9k3tuxjg84bbf55q0tn
Set executable permissions for: /home/bln77/.gradle/wrapper/dists/gradle-6.5-all/2oz4ud9k3tuxjg84bbf55q0tn/gradle-6.5/bin/gradle

Welcome to Gradle 6.5!

Here are the highlights of this release:
 - Experimental file-system watching
 - Improved version ordering
 - New samples

For more details see https://docs.gradle.org/6.5/release-notes.html

Starting a Gradle Daemon (subsequent builds will be faster)



And now I have followed your advice I am getting also

Mapping new ns http://schemas.android.com/repository/android/common/02 to old ns http://schemas.android.com/repository/android/common/01
Mapping new ns http://schemas.android.com/repository/android/generic/02 to old ns http://schemas.android.com/repository/android/generic/01
Mapping new ns http://schemas.android.com/sdk/android/repo/addon2/02 to old ns http://schemas.android.com/sdk/android/repo/addon2/01
Mapping new ns http://schemas.android.com/sdk/android/repo/repository2/02 to old ns http://schemas.android.com/sdk/android/repo/repository2/01
Mapping new ns http://schemas.android.com/sdk/android/repo/sys-img2/02 to old ns http://schemas.android.com/sdk/android/repo/sys-img2/01
Mapping new ns http://schemas.android.com/repository/android/common/02 to old ns http://schemas.android.com/repository/android/common/01
Mapping new ns http://schemas.android.com/repository/android/generic/02 to old ns http://schemas.android.com/repository/android/generic/01
Mapping new ns http://schemas.android.com/sdk/android/repo/addon2/02 to old ns http://schemas.android.com/sdk/android/repo/addon2/01
Mapping new ns http://schemas.android.com/sdk/android/repo/repository2/02 to old ns http://schemas.android.com/sdk/android/repo/repository2/01
Mapping new ns http://schemas.android.com/sdk/android/repo/sys-img2/02 to old ns http://schemas.android.com/sdk/android/repo/sys-img2/01
Mapping new ns http://schemas.android.com/repository/android/common/02 to old ns http://schemas.android.com/repository/android/common/01
Mapping new ns http://schemas.android.com/repository/android/generic/02 to old ns http://schemas.android.com/repository/android/generic/01
Mapping new ns http://schemas.android.com/sdk/android/repo/addon2/02 to old ns http://schemas.android.com/sdk/android/repo/addon2/01
Mapping new ns http://schemas.android.com/sdk/android/repo/repository2/02 to old ns http://schemas.android.com/sdk/android/repo/repository2/01
Mapping new ns http://schemas.android.com/sdk/android/repo/sys-img2/02 to old ns http://schemas.android.com/sdk/android/repo/sys-img2/01
Mapping new ns http://schemas.android.com/repository/android/common/02 to old ns http://schemas.android.com/repository/android/common/01
Mapping new ns http://schemas.android.com/repository/android/generic/02 to old ns http://schemas.android.com/repository/android/generic/01
Mapping new ns http://schemas.android.com/sdk/android/repo/addon2/02 to old ns http://schemas.android.com/sdk/andro

@bradical1379
Copy link

@gelinger777 - Understood. Thanks for the additional info.

Since I am using Capacitor 3, my environment is just a little different.

But, I am using Gradle 7.0, Cordova Android 7.0.0 and SDK Version 30 (which I believe is required now).

Previously, I was unable to build my app, but after my upgrade to the new Studio and clearing my user gradle cache, I am able to build the and sign the app. I do still see the Plugin issue log out during the build, however, I can confirm I am able to send Push Notifications to an actual device.

@gelinger777
Copy link

@bradical1379 thanks for your update.

@jkasten2
Copy link
Member

jkasten2 commented Sep 2, 2021

Error message is only informational

The error / warning noted here can safely be ignored as it doesn't cause any build issues. Check for any other errors before or after this entry:

Error 'Plugin-Version' of 'unspecified' for 'com.android.build.gradle.AppPlugin@5347c145' is not a valid version number 
OneSignal Warning: Could not get AGP plugin version

The "OneSignal Warning: Could not get AGP plugin version" message does come from the OneSignal-Gradle-Plugin but it safely defaults to Android Gradle Plugin 3.0.0 or newer logic when this message is shown.

We will be making an update to show "Error 'Plugin-Version' of 'unspecified'" as debug logging only so this isn't a miss leading as an error.

Errors building

As noted above the messages noted here won't cause a build failure. If your build fails please check for other errors in the log. If they seem to be related to OneSignal please open a new issue with relevant sections and can address them individually.

@gelinger777
Copy link

Dear @jkasten2 thank you for clarification. At least we know now that we can safely ignore it. Have a nice weekend

@JLWINC
Copy link

JLWINC commented Jan 20, 2022

Hello , unfortunately still get this error when using android@10.1.1 , SDK 30 :

Error 'Plugin-Version' of 'unspecified' for 'com.android.build.gradle.AppPlugin@63830252' is not a valid version number

i test version 3.0.1 and 2.3.1 of onesignal-cordova-plugin , but same error
i use cordova-plugin-androidx-adapter
and i test with Gradle 5.3.1 and 7.1.1

any solution ? thanks.

@gelinger777
Copy link

@JLWINC as stated by devs you can just ignore it. it's not something tragic. Things work despite of that error in build log

@bpsdesigns
Copy link

I am using Ionic Appflow to build by app and when I try to build the Android version it is failing with the attached errors so it seems this is still an issue.

errors

@jkasten2
Copy link
Member

@bpsdesigns The root of your error has to do with dependencies not resolving as noted by this line:

> Could not determine artifacts for com.onesignal:OneSignal:4.6.3: Skipping due to earlier error

More information could be above or below to help resolve your issue. If it isn't clear still I recommend copying the full log as text into this issue.

@bpsdesigns
Copy link

I managed to fix it by updating gradle to the latest version. It now builds successfully via Appflow

@suryakantarora
Copy link

Hi, it still happening with android 32,
Onesignal 3 do not work at all. when downgrading then version issue is there.
Error 'Plugin-Version' of 'unspecified' for 'com.android.build.gradle.AppPlugin@1eaafce8' is not a valid version number

Another error raised in android 32 is
> Task :app:processReleaseMainManifest FAILED /Users/it/Documents/apps/ibcool/ibprod/platforms/android/app/src/main/AndroidManifest.xml:78:9-84:20 Error: android:exported needs to be explicitly specified for element <activity#com.onesignal.NotificationOpenedActivityHMS>. Apps targeting Android 12 and higher are required to specify an explicit value for android:exportedwhen the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details. /Users/it/Documents/apps/ibcool/ibprod/platforms/android/app/src/main/AndroidManifest.xml:23:9-29:20 Error: android:exported needs to be explicitly specified for element <receiver#com.onesignal.ADMMessageHandler$Receiver>. Apps targeting Android 12 and higher are required to specify an explicit value forandroid:exportedwhen the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details. /Users/it/Documents/apps/ibcool/ibprod/platforms/android/app/src/main/AndroidManifest.xml:57:9-67:20 Error: android:exported needs to be explicitly specified for element <receiver#com.onesignal.GcmBroadcastReceiver>. Apps targeting Android 12 and higher are required to specify an explicit value forandroid:exportedwhen the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details. /Users/it/Documents/apps/ibcool/ibprod/platforms/android/app/src/main/AndroidManifest.xml:109:9-114:20 Error: android:exported needs to be explicitly specified for element <receiver#com.onesignal.BootUpReceiver>. Apps targeting Android 12 and higher are required to specify an explicit value forandroid:exportedwhen the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details. /Users/it/Documents/apps/ibcool/ibprod/platforms/android/app/src/main/AndroidManifest.xml:115:9-119:20 Error: android:exported needs to be explicitly specified for element <receiver#com.onesignal.UpgradeReceiver>. Apps targeting Android 12 and higher are required to specify an explicit value forandroid:exported` when the corresponding component has an intent filter defined. See https://developer.android.com/guide/topics/manifest/activity-element#exported for details.
Screenshot 2022-10-31 at 8 52 58 AM

`

Ionic & Onesignal both should look into it and provide some genune solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests