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

Gradle task failure #8

Open
Lucas9595 opened this issue Jan 19, 2018 · 3 comments
Open

Gradle task failure #8

Lucas9595 opened this issue Jan 19, 2018 · 3 comments

Comments

@Lucas9595
Copy link

I am using Gradle 4.1, Android plugin 3.0.1, have little experience with Android Studio, and keep getting gradle related problems. The message log is below. What do I change/remove/update in order to get this working?

...

Information:Gradle tasks [:app:generateDebugSources, :app:generateDebugAndroidTestSources, :app:mockableAndroidJar]
/Users/lucascessford/StudioProjects/CSipSimple/app/src/main/res/values/styles.xml
Error:(34, 5) error: invalid resource type 'attr' for parent of style.
Error:(25, 5) error: invalid resource type 'attr' for parent of style.
/Users/lucascessford/StudioProjects/CSipSimple/app/build/intermediates/incremental/mergeDebugResources/merged.dir/values/values.xml
Error:(1490) invalid resource type 'attr' for parent of style.
Error:(1494) invalid resource type 'attr' for parent of style.
Error:java.util.concurrent.ExecutionException: com.android.tools.aapt2.Aapt2Exception: AAPT2 error: check logs for details
Error:Execution failed for task ':app:mergeDebugResources'.

Error: java.util.concurrent.ExecutionException: com.android.tools.aapt2.Aapt2Exception: AAPT2 error: check logs for details
Information:BUILD FAILED in 3s
Information:6 errors
Information:0 warnings
Information:See complete output in console

@tqcenglish
Copy link
Owner

@Lucas9595
Copy link
Author

Thank you, a combination of this branch and deleting 'android build version 25' from build.gradle file has resolved the first issues in the error message. The error regarding the 'attr' still remains though. It doesn't recognise attr in the resource xml. What do I need to do to resolve this? do I change it to something, do I remove the 'attr'
This is an example of one of the lines that AS has an issue with

parent="@android:attr/textAppearanceMedium">
invalid resource type 'attr' for parent of style

@grahasmsoni
Copy link

use parent="@android:style/TextAppearance.Medium">
also disable AAPT2
also remove appcompatv7 and include actionbarsherlock in your dependencies

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

3 participants