1

When asked to upgrade to the newest Gradle 4.1? (2018-04-14) I get very weird errors I have never seen before. The app runs for years without this issue.

enter image description here

After searching the complete project again, I did find a @android:attr/windowEnterAnimation, in a place I did not expect.

For appt2 errors? Here is a nice article on how to move forward.

tm1701
  • 7,307
  • 17
  • 79
  • 168
  • What did you change in order to update gradle ? Did you change the file `gradle-wrapper.properties` ? Did you try to rollback to the previous version of gradle to see if the compilation runs ok ? – xiaomi Apr 14 '18 at 13:17
  • Did you try by changing your gradle keywords to the replaced ones? For e.g.: compile to implementation? https://developer.android.com/studio/build/gradle-plugin-3-0-0-migration.html#new_configurations – Debanjan Apr 14 '18 at 16:03

2 Answers2

2
<!-- When referencing resources from the 'android' namespace, omit the '@' symbol. -->
<item name="@android:windowEnterAnimation"/>

When building the module, AAPT2 now throws the following build error: Error: style attribute '@android:attr/windowEnterAnimation' not found

I am quite sure, in some of your animation file you have used '@'. Remove that.

If you use the new gradle, you have to follow the structures and rules properly, this entire details is put in their website. https://developer.android.com/studio/build/gradle-plugin-3-0-0-migration.html#new_configurations

Debanjan
  • 2,817
  • 2
  • 24
  • 43
-1

replace "@android:attr/" with "?attr" maybe it will solve your problem.

Hitesh Sarsava
  • 666
  • 4
  • 15