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

build apk went wrong #64

Open
Mae623 opened this issue Feb 20, 2023 · 18 comments
Open

build apk went wrong #64

Mae623 opened this issue Feb 20, 2023 · 18 comments

Comments

@Mae623
Copy link

Mae623 commented Feb 20, 2023

Hello, I meet a question as below. I try to update the 'ext.kotlin_version' as the latest-version but it failed.

What went wrong:
Execution failed for task ':cached_video_player:verifyReleaseResources'.

A failure occurred while executing com.android.build.gradle.tasks.VerifyLibraryResourcesTask$Action
Android resource linking failed
ERROR:/Users/suchengyu/.gradle/caches/transforms-3/5e083c06c9925c2309f02468fc66e376/transformed/core-1.7.0/res/values/values.xml:105:5-114:25: AAPT: error: resource android:attr/lStar not found.

Flutter Fix [!] Your project requires a newer version of the Kotlin Gradle plugin. Find the latest version on https://kotlinlang.org/docs/releases.html#release-details, then update /Users/suchengyu/Documents/Github/zilvbang_flutter/android/build.gradle: ext.kotlin_version = '<latest-version>'

@ciriousjoker
Copy link
Collaborator

The new kotlin extension probably requires a higher gradle version and this package contains an older one.

Our solution was to fork this package to set the same gradle version as our project.

@Mae623
Copy link
Author

Mae623 commented Feb 20, 2023

The new kotlin extension probably requires a higher gradle version and this package contains an older one.

Our solution was to fork this package to set the same gradle version as our project.

You explain a lot!
Thank you for your answer and advice~
hoping the author could update this package fastly.

@ciriousjoker
Copy link
Collaborator

I could change this package to a higher gradle version, but I don't know the implications of this. I fear that this would break all flutter create . default apps which use a relatively low gradle version.

@Mae623
Copy link
Author

Mae623 commented Mar 4, 2023

I could change this package to a higher gradle version, but I don't know the implications of this. I fear that this would break all flutter create . default apps which use a relatively low gradle version.

I will try it, I want to cache my videos

@tneils218
Copy link

cached_video_player:compileReleaseJavaWithJavac i have problem when build apk

@omar-alshyokh
Copy link

+1, any updates

@ArtyomKazan
Copy link

+1

@vikram25897
Copy link
Owner

Please try this branch and give feedback on it.

@filippo-orru
Copy link
Contributor

filippo-orru commented Mar 29, 2023

Just tried building my app after applying the changes from your branch to my fork, but it didn't fix the issue.
I no longer see the error Flutter Fix [!] Your project requires a newer version of the Kotlin Gradle plugin. but I still get

Execution failed for task ':cached_video_player:verifyReleaseResources'.
> A failure occurred while executing com.android.build.gradle.tasks.VerifyLibraryResourcesTask$Action
   > Android resource linking failed
     ERROR:/Users/ffactory/Development/git/.../build/cached_video_player/intermediates/merged_res/release/values/values.xml:141: AAPT: error: resource android:attr/lStar not found.

@vikram25897
Copy link
Owner

@ffactory-ofcl set targetSdkVersion to 33.

@filippo-orru
Copy link
Contributor

filippo-orru commented Mar 29, 2023

Worked, thanks!
At first I tried cherry-picking changes from https://github.com/ciriousjoker/flutter_cached_video_player/tree/dieringe to my fork, but the same issue persisted. Starting with your feature/gradle_version_bump branch and rebasing my changes on top did the trick.

@vikram25897
Copy link
Owner

Glad to hear. If the features in your fork are general purpose, then try creating PR for it.

@filippo-orru
Copy link
Contributor

filippo-orru commented Mar 29, 2023

Will do. The only relevant change is this: filippo-orru@e8a36bd, which fixes a version mismatch error that I was getting because my project uses both flutter_cached_video_player and video_player_macos:

Because every version of video_player_macos from git depends on video_player_platform_interface ^6.0.1 and every version of cached_video_player from git depends on video_player_platform_interface ^5.1.2, video_player_macos from git is incompatible with cached_video_player from git.

Edit: I've created a PR for this: #67

@applevald
Copy link

@vikram25897 I get your code from feature/gradle_version_bump branch .And set targetSdkVersion to 33.But it say: What went wrong:
Execution failed for task ':cached_video_player:verifyReleaseResources'.

A failure occurred while executing com.android.build.gradle.tasks.VerifyLibraryResourcesTask$Action
Android resource linking failed
ERROR:C:\Users\Administrator.gradle\caches\transforms-3\3c7d4f5d76f2377f61ef191eee76f2a9\transformed\core-1.7.0\res\values\values.xml:105:5-114:25: AAPT: error: resource android:
attr/lStar not found.

@heshesh2010
Copy link

@vikram25897 I get your code from feature/gradle_version_bump branch .And set targetSdkVersion to 33.But it say: What went wrong: Execution failed for task ':cached_video_player:verifyReleaseResources'.

A failure occurred while executing com.android.build.gradle.tasks.VerifyLibraryResourcesTask$Action
Android resource linking failed
ERROR:C:\Users\Administrator.gradle\caches\transforms-3\3c7d4f5d76f2377f61ef191eee76f2a9\transformed\core-1.7.0\res\values\values.xml:105:5-114:25: AAPT: error: resource android:
attr/lStar not found.

+1

@milan-ciganovic
Copy link

Thanks @vikram25897

Workaround for now:

 cached_video_player:
    git:
      url: https://github.com/vikram25897/flutter_cached_video_player
      ref: feature/gradle_version_bump

@edwinmrb
Copy link

This is working, hopefully an update will come soon

@tudosxxx
Copy link

my error is android:attr/lStar not found

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