Closed GiannisS closed 1 year ago
@GiannisS you have to upgrade the kotlin version of your project to 1.8.0
@jepiqueau thank you for the fast reply. Does this also requires an sdk target version of 33?
Now i get the following errors:
Dependency 'androidx.appcompat:appcompat-resources:1.6.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs.
:app is currently compiled against android-32.
Dependency 'androidx.appcompat:appcompat:1.6.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs.
:app is currently compiled against android-32.
Dependency 'androidx.activity:activity-ktx:1.6.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs.
:app is currently compiled against android-32.
Dependency 'androidx.activity:activity:1.6.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs.
:app is currently compiled against android-32.
Dependency 'androidx.core:core:1.9.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs.
:app is currently compiled against android-32.
Dependency 'androidx.core:core-ktx:1.9.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs.
:app is currently compiled against android-32.
Dependency 'androidx.annotation:annotation-experimental:1.3.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs.
:app is currently compiled against android-32.
and on every error i get this recommendation:
Recommended action: Update this project to use a newer compileSdkVersion of at least 33, for example 33. Note that updating a library or application's compileSdkVersion (which allows newer APIs to be used) can be done separately from updating targetSdkVersion (which opts the app in to new runtime behavior) and minSdkVersion (which determines which devices the app can be installed on).
Removing the plugin solves every issue.
@GiannisS build.gradle (Project android)
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
ext.kotlin_version = '1.8.0'
repositories {
google()
mavenCentral()
}
dependencies {
classpath 'com.android.tools.build:gradle:7.2.2'
classpath 'com.google.gms:google-services:4.3.13'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
...
variables.gradle (Project android)
ext { minSdkVersion = 22 compileSdkVersion = 33 targetSdkVersion = 33 androidxActivityVersion = '1.4.0' androidxAppCompatVersion = '1.6.0' androidxCoordinatorLayoutVersion = '1.2.0' androidxCoreVersion = '1.8.0' androidxFragmentVersion = '1.4.1' junitVersion = '4.13.2' androidxJunitVersion = '1.1.5' androidxEspressoCoreVersion = '3.5.1' cordovaAndroidVersion = '10.1.1' coreSplashScreenVersion = '1.0.0-rc01' androidxWebkitVersion = '1.4.0' }
Gradle JDK 11
Android Gradle Plugin Version 7.2.2
Gradle Version 7.4.2
you can have a look to [angular-photoviewer-app](https://github.com/jepiqueau/angular-photoviewer-app) version 1.1.2
@jepiqueau thank you for the fast reply. Does this also requires an sdk target version of 33?
Now i get the following errors:
- Dependency 'androidx.appcompat:appcompat-resources:1.6.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs. :app is currently compiled against android-32.
- Dependency 'androidx.appcompat:appcompat:1.6.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs. :app is currently compiled against android-32.
- Dependency 'androidx.activity:activity-ktx:1.6.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs. :app is currently compiled against android-32.
- Dependency 'androidx.activity:activity:1.6.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs. :app is currently compiled against android-32.
- Dependency 'androidx.core:core:1.9.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs. :app is currently compiled against android-32.
- Dependency 'androidx.core:core-ktx:1.9.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs. :app is currently compiled against android-32.
- Dependency 'androidx.annotation:annotation-experimental:1.3.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs. :app is currently compiled against android-32.
and on every error i get this recommendation:
Recommended action: Update this project to use a newer compileSdkVersion of at least 33, for example 33. Note that updating a library or application's compileSdkVersion (which allows newer APIs to be used) can be done separately from updating targetSdkVersion (which opts the app in to new runtime behavior) and minSdkVersion (which determines which devices the app can be installed on).
Removing the plugin solves every issue.
@jepiqueau thank you for the fast reply. Does this also requires an sdk target version of 33?
Now i get the following errors:
- Dependency 'androidx.appcompat:appcompat-resources:1.6.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs. :app is currently compiled against android-32.
- Dependency 'androidx.appcompat:appcompat:1.6.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs. :app is currently compiled against android-32.
- Dependency 'androidx.activity:activity-ktx:1.6.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs. :app is currently compiled against android-32.
- Dependency 'androidx.activity:activity:1.6.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs. :app is currently compiled against android-32.
- Dependency 'androidx.core:core:1.9.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs. :app is currently compiled against android-32.
- Dependency 'androidx.core:core-ktx:1.9.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs. :app is currently compiled against android-32.
- Dependency 'androidx.annotation:annotation-experimental:1.3.0' requires libraries and applications that depend on it to compile against version 33 or later of the Android APIs. :app is currently compiled against android-32.
and on every error i get this recommendation:
Recommended action: Update this project to use a newer compileSdkVersion of at least 33, for example 33. Note that updating a library or application's compileSdkVersion (which allows newer APIs to be used) can be done separately from updating targetSdkVersion (which opts the app in to new runtime behavior) and minSdkVersion (which determines which devices the app can be installed on).
Removing the plugin solves every issue.
l have same issue
@GiannisS yes see wha i sent to you earlier fir the variables.gradle
@jepiqueau Thanks for you answers! That last comment wasn't mine. @bravao911 commented and said he has the same problem. I finally managed to configure the plugin to work correctly with your suggestions on variables.gradle and build.android. Thank you again. It's kinda weird though that it forces me to go on android sdk version 33 but it's fine!
l have followed all steps that you mentioned and does not working.
l have npm uninstall @capacitor-community/photoviewer
andnpx cap sync
. Then l installed npm install @capacitor-community/photoviewer@next
https://github.com/capacitor-community/photoviewer/blob/main/info_releases.md and its working fine on ios and android .
@bravao911 you shoud not install @next but @latest
@GiannisS sorry for this. Hope this move to API 33 will not break anything in your development
@jepiqueau No problem it seems all worked seamlessly. Thank you
@bravao911 you shoud not install @next but @latest
l dont know . l did that and his working fine now .
@bravao911 Release @next is release 2.0.0-0 where the latest is 2.0.10
@GiannisS @bravao911 As i do not hear anything, i assume that this is fixed on your side so i close the issue
Describe the bug the below issue occurs when building project in android studio:
Project versions
Additional context In my android/build.gradle file i have this
classpath 'org.jetbrains.kotlin:kotlin-gradle-plugin:1.6.10'
but still the problem persists