Android Studio doesn't find drawables during the build - android

When I try to build my project the ide gives me this error
AAPT2 error: check logs for details
Then it says it can't find any drawables in the folders and gives me this error for all of them
error: resource drawable/round_corner_valid (aka terzad.com.trinus:drawable/round_corner_valid) not found.
EDIT: this is the new output
Android resource linking failed Output:
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\activity_main.xml:33:
error: resource drawable/round_corner_valid (aka
terzad.com.trinus:drawable/round_corner_valid) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\activity_main.xml:42:
error: resource drawable/search_ (aka
terzad.com.trinus:drawable/search_) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\element_near_list.xml:21:
error: resource drawable/style_element_near_list (aka
terzad.com.trinus:drawable/style_element_near_list) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\fragment_home.xml:35:
error: resource drawable/round_corner_valid (aka
terzad.com.trinus:drawable/round_corner_valid) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\fragment_home.xml:44:
error: resource drawable/search_ (aka
terzad.com.trinus:drawable/search_) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\fragment_map.xml:16:
error: resource drawable/user_position (aka
terzad.com.trinus:drawable/user_position) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\fragment_option.xml:13:
error: resource drawable/round_corner (aka
terzad.com.trinus:drawable/round_corner) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\fragment_option.xml:22:
error: resource drawable/user (aka terzad.com.trinus:drawable/user)
not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\fragment_option.xml:42:
error: resource drawable/round_corner (aka
terzad.com.trinus:drawable/round_corner) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\itinerary_element_place.xml:23:
error: resource drawable/round_corner_section (aka
terzad.com.trinus:drawable/round_corner_section) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\list_item_generic.xml:15:
error: resource drawable/round_corner (aka
terzad.com.trinus:drawable/round_corner) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\list_item_generic.xml:23:
error: resource drawable/corner_img (aka
terzad.com.trinus:drawable/corner_img) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\list_item_generic.xml:28:
error: resource drawable/colosseum (aka
terzad.com.trinus:drawable/colosseum) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\nearest_place.xml:6:
error: resource drawable/round_corner_section (aka
terzad.com.trinus:drawable/round_corner_section) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\section_cost_place.xml:8:
error: resource drawable/round_corner_section (aka
terzad.com.trinus:drawable/round_corner_section) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\section_images_place.xml:8:
error: resource drawable/round_corner_section (aka
terzad.com.trinus:drawable/round_corner_section) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\section_info_place.xml:8:
error: resource drawable/round_corner_section (aka
terzad.com.trinus:drawable/round_corner_section) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\section_other.xml:8:
error: resource drawable/round_corner_section (aka
terzad.com.trinus:drawable/round_corner_section) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\section_place.xml:8:
error: resource drawable/round_corner_section (aka
terzad.com.trinus:drawable/round_corner_section) not found.
C:\Users\massi\Documents\Backup\Trinus\app\src\main\res\layout\section_rating_place.xml:8:
error: resource drawable/round_corner_section (aka
terzad.com.trinus:drawable/round_corner_section) not found.
Command:
C:\Users\massi.gradle\caches\transforms-1\files-1.1\aapt2-3.2.0-alpha17-4804415-windows.jar\965937a3c1ba8a6e7b389be4e8c3d0f5\aapt2-3.2.0-alpha17-4804415-windows\aapt2.exe
link -I\
C:\Users\massi\AppData\Local\Android\Sdk\platforms\android-27\android.jar\
--manifest\
C:\Users\massi\Documents\Backup\Trinus\app\build\intermediates\merged_manifests\debug\processDebugManifest\merged\AndroidManifest.xml\
-o\
C:\Users\massi\Documents\Backup\Trinus\app\build\intermediates\processed_res\debug\processDebugResources\out\resources-debug.ap_\
-R\
#C:\Users\massi\Documents\Backup\Trinus\app\build\intermediates\incremental\processDebugResources\resources-list-for-resources-debug.ap_.txt\
--auto-add-overlay\
--java\
C:\Users\massi\Documents\Backup\Trinus\app\build\generated\not_namespaced_r_class_sources\debug\processDebugResources\r\
--custom-package\
terzad.com.trinus\
-0\
apk\
--output-text-symbols\
C:\Users\massi\Documents\Backup\Trinus\app\build\intermediates\symbols\debug\R.txt\
--no-version-vectors Daemon: AAPT2 aapt2-3.2.0-alpha17-4804415-windows Daemon #0
EDIT 2

Check if drawable/round_corner_valid is available under drawable and not under drawable-v24 (or something similar).

Related

Cannot build app on android. Multiple Linking errors

when building my app on android studio, I'm getting the following error:
> Task :app:processDebugResources FAILED
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/a72fc6914174c60e99bb51c1d98759b9/material-1.1.0/res/values/values.xml","position":{"startLine":527,"startColumn":4,"startOffset":39038,"endLine":592,"endColumn":10,"endOffset":43834}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/a72fc6914174c60e99bb51c1d98759b9/material-1.1.0/res/values/values.xml:528:5-593:11: AAPT: error: style attribute 'android:attr/contextPopupMenuStyle' not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/a72fc6914174c60e99bb51c1d98759b9/material-1.1.0/res/values/values.xml","position":{"startLine":641,"startColumn":4,"startOffset":46880,"endLine":698,"endColumn":10,"endOffset":51129}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/a72fc6914174c60e99bb51c1d98759b9/material-1.1.0/res/values/values.xml:642:5-699:11: AAPT: error: style attribute 'android:attr/contextPopupMenuStyle' not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/a72fc6914174c60e99bb51c1d98759b9/material-1.1.0/res/values/values.xml","position":{"startLine":747,"startColumn":4,"startOffset":54189,"endLine":811,"endColumn":10,"endOffset":58892}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/a72fc6914174c60e99bb51c1d98759b9/material-1.1.0/res/values/values.xml:748:5-812:11: AAPT: error: style attribute 'android:attr/contextPopupMenuStyle' not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/a72fc6914174c60e99bb51c1d98759b9/material-1.1.0/res/values/values.xml","position":{"startLine":908,"startColumn":4,"startOffset":64921,"endLine":965,"endColumn":10,"endOffset":69086}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/a72fc6914174c60e99bb51c1d98759b9/material-1.1.0/res/values/values.xml:909:5-966:11: AAPT: error: style attribute 'android:attr/contextPopupMenuStyle' not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/a72fc6914174c60e99bb51c1d98759b9/material-1.1.0/res/values/values.xml","position":{"startLine":1022,"startColumn":4,"startOffset":72626,"endLine":1033,"endColumn":10,"endOffset":73681}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/a72fc6914174c60e99bb51c1d98759b9/material-1.1.0/res/values/values.xml:1023:5-1034:11: AAPT: error: style attribute 'android:attr/dialogCornerRadius' not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v26/values-v26.xml","position":{"startLine":4,"startColumn":4,"startOffset":217,"endLine":7,"endColumn":12,"endOffset":426}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v26/values-v26.xml:5:5-8:13: AAPT: error: resource android:attr/colorError not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v26/values-v26.xml","position":{"startLine":8,"startColumn":4,"startOffset":431,"endLine":11,"endColumn":12,"endOffset":652}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v26/values-v26.xml:9:5-12:13: AAPT: error: resource android:attr/colorError not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v26/values-v26.xml","position":{"startLine":12,"startColumn":4,"startOffset":657,"endLine":15,"endColumn":12,"endOffset":891}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v26/values-v26.xml:13:5-16:13: AAPT: error: style attribute 'android:attr/keyboardNavigationCluster' not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v28/values-v28.xml","position":{"startLine":4,"startColumn":4,"startOffset":217,"endLine":7,"endColumn":12,"endOffset":442}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v28/values-v28.xml:5:5-8:13: AAPT: error: resource android:attr/dialogCornerRadius not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v28/values-v28.xml","position":{"startLine":8,"startColumn":4,"startOffset":447,"endLine":11,"endColumn":12,"endOffset":684}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v28/values-v28.xml:9:5-12:13: AAPT: error: resource android:attr/dialogCornerRadius not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v23/values-v23.xml","position":{"startLine":37,"startColumn":4,"startOffset":2618,"endLine":40,"endColumn":12,"endOffset":2837}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v23/values-v23.xml:38:5-41:13: AAPT: error: style attribute 'android:attr/hyphenationFrequency' not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v23/values-v23.xml","position":{"startLine":37,"startColumn":4,"startOffset":2618,"endLine":40,"endColumn":12,"endOffset":2837}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v23/values-v23.xml:38:5-41:13: AAPT: error: style attribute 'android:attr/breakStrategy' not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v23/values-v23.xml","position":{"startLine":44,"startColumn":4,"startOffset":3177,"endLine":47,"endColumn":12,"endOffset":3402}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v23/values-v23.xml:45:5-48:13: AAPT: error: style attribute 'android:attr/hyphenationFrequency' not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v23/values-v23.xml","position":{"startLine":44,"startColumn":4,"startOffset":3177,"endLine":47,"endColumn":12,"endOffset":3402}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/102f4e5339e61a836806a4922c0ccf33/appcompat-1.1.0/res/values-v23/values-v23.xml:45:5-48:13: AAPT: error: style attribute 'android:attr/breakStrategy' not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/cb98cb7aa050aadd68368dde2f298c4f/cardview-1.0.0/res/values-v23/values-v23.xml","position":{"startLine":2,"startColumn":4,"startOffset":55,"endLine":4,"endColumn":12,"endOffset":200}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/cb98cb7aa050aadd68368dde2f298c4f/cardview-1.0.0/res/values-v23/values-v23.xml:3:5-5:13: AAPT: error: resource android:attr/colorBackgroundFloating not found.\n ","tool":"AAPT"}
AGPBI: {"kind":"error","text":"Android resource linking failed","sources":[{"file":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/a72fc6914174c60e99bb51c1d98759b9/material-1.1.0/res/values/values.xml","position":{"startLine":1708,"startColumn":4,"startOffset":117184,"endLine":1715,"endColumn":10,"endOffset":117611}}],"original":"/Users/prikshetsharma/.gradle/caches/transforms-2/files-2.1/a72fc6914174c60e99bb51c1d98759b9/material-1.1.0/res/values/values.xml:1709:5-1716:11: AAPT: error: style attribute 'android:attr/keyboardNavigationCluster' not found.\n ","tool":"AAPT"}
I also tried https://github.com/facebook/react-native/issues/30815, but still getting the same error. How to fix this?
Have a try by cleaning the project Gradle.
Run Below Command:
cd android
rm -rf android/.gradle
rm -rf .gradle
rm -rf ~/.gradle
./gradlew clean
Goto Android folder and Run ./gradlew clean
Remove caches folder from /Users/prikshetsharma/.gradle/caches/
And Go to android/gradle/wrapper/gradle-wrappers.properties and replace distrubution url to 6.3 instead of 6.2 like this,
distributionUrl=https://services.gradle.org/distributions/gradle-6.3-all.zip
NOTE: check targetSdkVersion in build.gradle, it should be greater than 26.
Error is because you are inheriting the wrong theme in styles.xml. Make sure you are using the correct App Theme. I Can't show you the exact code seeing your post but that's the problem I can see.

How to fix android resource linking failed error in Android

I trying to open an Android project in Android Studio but I am getting the following error
Android resource linking failed
Output: C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2331: error: resource anim/abc_popup_enter (aka com.example.kontrol.mydictation:anim/abc_popup_enter) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2332: error: resource anim/abc_popup_exit (aka com.example.kontrol.mydictation:anim/abc_popup_exit) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2335: error: resource anim/abc_grow_fade_in_from_bottom (aka com.example.kontrol.mydictation:anim/abc_grow_fade_in_from_bottom) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2336: error: resource anim/abc_shrink_fade_out_from_bottom (aka com.example.kontrol.mydictation:anim/abc_shrink_fade_out_from_bottom) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2339: error: resource anim/abc_tooltip_enter (aka com.example.kontrol.mydictation:anim/abc_tooltip_enter) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2340: error: resource anim/abc_tooltip_exit (aka com.example.kontrol.mydictation:anim/abc_tooltip_exit) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2503: error: resource color/abc_btn_colored_borderless_text_material (aka com.example.kontrol.mydictation:color/abc_btn_colored_borderless_text_material) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2506: error: resource color/abc_btn_colored_text_material (aka com.example.kontrol.mydictation:color/abc_btn_colored_text_material) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2560: error: resource drawable/abc_list_selector_holo_dark (aka com.example.kontrol.mydictation:drawable/abc_list_selector_holo_dark) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2612: error: resource drawable/abc_list_selector_holo_dark (aka com.example.kontrol.mydictation:drawable/abc_list_selector_holo_dark) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2644: error: resource color/abc_background_cache_hint_selector_material_dark (aka com.example.kontrol.mydictation:color/abc_background_cache_hint_selector_material_dark) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2647: error: resource color/abc_primary_text_material_dark (aka com.example.kontrol.mydictation:color/abc_primary_text_material_dark) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2648: error: resource color/abc_primary_text_material_light (aka com.example.kontrol.mydictation:color/abc_primary_text_material_light) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2649: error: resource color/abc_primary_text_disable_only_material_dark (aka com.example.kontrol.mydictation:color/abc_primary_text_disable_only_material_dark) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2650: error: resource color/abc_secondary_text_material_dark (aka com.example.kontrol.mydictation:color/abc_secondary_text_material_dark) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2651: error: resource color/abc_secondary_text_material_light (aka com.example.kontrol.mydictation:color/abc_secondary_text_material_light) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2652: error: resource color/abc_secondary_text_material_dark (aka com.example.kontrol.mydictation:color/abc_secondary_text_material_dark) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2653: error: resource color/abc_secondary_text_material_light (aka com.example.kontrol.mydictation:color/abc_secondary_text_material_light) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2654: error: resource color/abc_hint_foreground_material_dark (aka com.example.kontrol.mydictation:color/abc_hint_foreground_material_dark) not found.
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml:2655: error: resource color/abc_hint_foreground_material_light (aka com.example.kontrol.mydictation:color/abc_hint_foreground_material_light) not found.
>Command: C:\Users\kontrol\.gradle\caches\transforms-1\files-1.1\aapt2-3.2.1-4818971-windows.jar\f2b7042c25ae8ac78b6339cc492412a8\aapt2-3.2.1-4818971-windows\aapt2.exe link -I\
C:\Users\kontrol\AppData\Local\Android\Sdk\platforms\android-28\android.jar\
--manifest\
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\merged_manifests\debug\processDebugManifest\merged\AndroidManifest.xml\
-o\
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\processed_res\debug\processDebugResources\out\resources-debug.ap_\
-R\
#C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\incremental\processDebugResources\resources-list-for-resources-debug.ap_.txt\
--auto-add-overlay\
--java\
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\generated\not_namespaced_r_class_sources\debug\processDebugResources\r\
--custom-package\
com.example.kontrol.mydictation\
-0\
apk\
--output-text-symbols\
C:\Users\kontrol\AndroidStudioProjects\MyDictation\app\build\intermediates\symbols\debug\R.txt\
--no-version-vectors
Daemon: AAPT2 aapt2-3.2.1-4818971-windows Daemon #0
I am using Android Studio 3.4.1. I don't understand what is causing this problem?

com.android.builder.internal.aapt.v2.Aapt2Exception After updating android studio to 3.2

i have recently updated my android studio to version 3.2 since then i am receiving com.android.builder.internal.aapt.v2.Aapt2Exception exception
i looked into solutions on stackoverflow but couldn't find the right one.
the drawable files as the error says are missing are already present there and the project was running fine before i updated the android studio to latest version 3.2.1
Error:
Caused by: com.android.builder.internal.aapt.v2.Aapt2Exception: Android resource linking failed
Output: warn: removing resource com.example.mohit.chatapp:string/com_facebook_loginview_logged_in_using_facebook_f1gender without required default value.
E:\andriodProjects\ChatApp\app\src\main\res\layout\activity_chat_box.xml:25: error: resource drawable/white_view (aka com.example.mohit.chatapp:drawable/white_view) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\activity_chat_box.xml:49: error: resource drawable/message_back (aka com.example.mohit.chatapp:drawable/message_back) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\activity_main.xml:54: error: resource drawable/fb (aka com.example.mohit.chatapp:drawable/fb) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\activity_splash_screen.xml:10: error: resource drawable/ic_place_black_24dp (aka com.example.mohit.chatapp:drawable/ic_place_black_24dp) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\fragment_profile.xml:19: error: resource drawable/profilepicture (aka com.example.mohit.chatapp:drawable/profilepicture) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\fragment_profile.xml:58: error: resource drawable/white_view (aka com.example.mohit.chatapp:drawable/white_view) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\fragment_profile.xml:152: error: resource drawable/white_view (aka com.example.mohit.chatapp:drawable/white_view) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\fragment_profile.xml:169: error: resource drawable/white_view (aka com.example.mohit.chatapp:drawable/white_view) not found.
E:\andriodProjects\ChatApp\app\src\main\res\mipmap-anydpi-v26\ic_launcher.xml:3: error: resource drawable/ic_launcher_background (aka com.example.mohit.chatapp:drawable/ic_launcher_background) not found.
E:\andriodProjects\ChatApp\app\src\main\res\mipmap-anydpi-v26\ic_launcher_round.xml:3: error: resource drawable/ic_launcher_background (aka com.example.mohit.chatapp:drawable/ic_launcher_background) not found.
error: failed linking file resources.
Command: C:\Users\Mohit\.gradle\caches\transforms-1\files-1.1\aapt2-3.2.1-4818971-windows.jar\1558dd943061657e6b17ed05cad5fd2f\aapt2-3.2.1-4818971-windows\aapt2.exe link -I\
C:\Users\Mohit\AppData\Local\Android\Sdk\platforms\android-28\android.jar\
--manifest\
E:\andriodProjects\ChatApp\app\build\intermediates\merged_manifests\debug\processDebugManifest\merged\AndroidManifest.xml\
-o\
E:\andriodProjects\ChatApp\app\build\intermediates\processed_res\debug\processDebugResources\out\resources-debug.ap_\
-R\
#E:\andriodProjects\ChatApp\app\build\intermediates\incremental\processDebugResources\resources-list-for-resources-debug.ap_.txt\
--auto-add-overlay\
--java\
E:\andriodProjects\ChatApp\app\build\generated\not_namespaced_r_class_sources\debug\processDebugResources\r\
--proguard-main-dex\
E:\andriodProjects\ChatApp\app\build\intermediates\legacy_multidex_aapt_derived_proguard_rules\debug\processDebugResources\manifest_keep.txt\
--custom-package\
com.example.mohit.chatapp\
-0\
apk\
--output-text-symbols\
E:\andriodProjects\ChatApp\app\build\intermediates\symbols\debug\R.txt\
--no-version-vectors
Daemon: AAPT2 aapt2-3.2.1-4818971-windows Daemon #0
Output: warn: removing resource com.example.mohit.chatapp:string/com_facebook_loginview_logged_in_using_facebook_f1gender without required default value.
E:\andriodProjects\ChatApp\app\src\main\res\layout\activity_chat_box.xml:25: AAPT: error: resource drawable/white_view (aka com.example.mohit.chatapp:drawable/white_view) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\activity_chat_box.xml:49: AAPT: error: resource drawable/message_back (aka com.example.mohit.chatapp:drawable/message_back) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\activity_main.xml:54: AAPT: error: resource drawable/fb (aka com.example.mohit.chatapp:drawable/fb) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\activity_splash_screen.xml:10: AAPT: error: resource drawable/ic_place_black_24dp (aka com.example.mohit.chatapp:drawable/ic_place_black_24dp) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\fragment_profile.xml:19: AAPT: error: resource drawable/profilepicture (aka com.example.mohit.chatapp:drawable/profilepicture) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\fragment_profile.xml:58: AAPT: error: resource drawable/white_view (aka com.example.mohit.chatapp:drawable/white_view) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\fragment_profile.xml:152: AAPT: error: resource drawable/white_view (aka com.example.mohit.chatapp:drawable/white_view) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\fragment_profile.xml:169: AAPT: error: resource drawable/white_view (aka com.example.mohit.chatapp:drawable/white_view) not found.
E:\andriodProjects\ChatApp\app\src\main\res\mipmap-anydpi-v26\ic_launcher.xml:3: AAPT: error: resource drawable/ic_launcher_background (aka com.example.mohit.chatapp:drawable/ic_launcher_background) not found.
E:\andriodProjects\ChatApp\app\src\main\res\mipmap-anydpi-v26\ic_launcher_round.xml:3: AAPT: error: resource drawable/ic_launcher_background (aka com.example.mohit.chatapp:drawable/ic_launcher_background) not found.
error: failed linking file resources.
Command: C:\Users\Mohit\.gradle\caches\transforms-1\files-1.1\aapt2-3.2.1-4818971-windows.jar\1558dd943061657e6b17ed05cad5fd2f\aapt2-3.2.1-4818971-windows\aapt2.exe link -I\
C:\Users\Mohit\AppData\Local\Android\Sdk\platforms\android-28\android.jar\
--manifest\
E:\andriodProjects\ChatApp\app\build\intermediates\merged_manifests\debug\processDebugManifest\merged\AndroidManifest.xml\
-o\
E:\andriodProjects\ChatApp\app\build\intermediates\processed_res\debug\processDebugResources\out\resources-debug.ap_\
-R\
#E:\andriodProjects\ChatApp\app\build\intermediates\incremental\processDebugResources\resources-list-for-resources-debug.ap_.txt\
--auto-add-overlay\
--java\
E:\andriodProjects\ChatApp\app\build\generated\not_namespaced_r_class_sources\debug\processDebugResources\r\
--proguard-main-dex\
E:\andriodProjects\ChatApp\app\build\intermediates\legacy_multidex_aapt_derived_proguard_rules\debug\processDebugResources\manifest_keep.txt\
--custom-package\
com.example.mohit.chatapp\
-0\
apk\
--output-text-symbols\
E:\andriodProjects\ChatApp\app\build\intermediates\symbols\debug\R.txt\
--no-version-vectors
Daemon: AAPT2 aapt2-3.2.1-4818971-windows Daemon #0
at com.android.build.gradle.internal.res.Aapt2ErrorUtils.rewriteException(Aapt2ErrorUtils.kt:97)
at com.android.build.gradle.internal.res.Aapt2ErrorUtils.rewriteLinkException(Aapt2ErrorUtils.kt:73)
at com.android.build.gradle.internal.res.LinkApplicationAndroidResourcesTask.invokeAaptForSplit(LinkApplicationAndroidResourcesTask.java:527)
at com.android.build.gradle.internal.res.LinkApplicationAndroidResourcesTask.doFullTaskAction(LinkApplicationAndroidResourcesTask.java:275)
at com.android.build.gradle.internal.tasks.IncrementalTask.taskAction(IncrementalTask.java:106)
at sun.reflect.GeneratedMethodAccessor224.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.gradle.internal.reflect.JavaMethod.invoke(JavaMethod.java:73)
at org.gradle.api.internal.project.taskfactory.IncrementalTaskAction.doExecute(IncrementalTaskAction.java:50)
at org.gradle.api.internal.project.taskfactory.StandardTaskAction.execute(StandardTaskAction.java:39)
at org.gradle.api.internal.project.taskfactory.StandardTaskAction.execute(StandardTaskAction.java:26)
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter$1.run(ExecuteActionsTaskExecuter.java:124)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:336)
at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:328)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:199)
at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:110)
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeAction(ExecuteActionsTaskExecuter.java:113)
at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:95)
... 33 more
Caused by: com.android.builder.internal.aapt.v2.Aapt2Exception: Android resource linking failed
Output: warn: removing resource com.example.mohit.chatapp:string/com_facebook_loginview_logged_in_using_facebook_f1gender without required default value.
E:\andriodProjects\ChatApp\app\src\main\res\layout\activity_chat_box.xml:25: error: resource drawable/white_view (aka com.example.mohit.chatapp:drawable/white_view) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\activity_chat_box.xml:49: error: resource drawable/message_back (aka com.example.mohit.chatapp:drawable/message_back) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\activity_main.xml:54: error: resource drawable/fb (aka com.example.mohit.chatapp:drawable/fb) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\activity_splash_screen.xml:10: error: resource drawable/ic_place_black_24dp (aka com.example.mohit.chatapp:drawable/ic_place_black_24dp) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\fragment_profile.xml:19: error: resource drawable/profilepicture (aka com.example.mohit.chatapp:drawable/profilepicture) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\fragment_profile.xml:58: error: resource drawable/white_view (aka com.example.mohit.chatapp:drawable/white_view) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\fragment_profile.xml:152: error: resource drawable/white_view (aka com.example.mohit.chatapp:drawable/white_view) not found.
E:\andriodProjects\ChatApp\app\src\main\res\layout\fragment_profile.xml:169: error: resource drawable/white_view (aka com.example.mohit.chatapp:drawable/white_view) not found.
E:\andriodProjects\ChatApp\app\src\main\res\mipmap-anydpi-v26\ic_launcher.xml:3: error: resource drawable/ic_launcher_background (aka com.example.mohit.chatapp:drawable/ic_launcher_background) not found.
E:\andriodProjects\ChatApp\app\src\main\res\mipmap-anydpi-v26\ic_launcher_round.xml:3: error: resource drawable/ic_launcher_background (aka com.example.mohit.chatapp:drawable/ic_launcher_background) not found.
error: failed linking file resources.
Command: C:\Users\Mohit\.gradle\caches\transforms-1\files-1.1\aapt2-3.2.1-4818971-windows.jar\1558dd943061657e6b17ed05cad5fd2f\aapt2-3.2.1-4818971-windows\aapt2.exe link -I\
C:\Users\Mohit\AppData\Local\Android\Sdk\platforms\android-28\android.jar\
--manifest\
E:\andriodProjects\ChatApp\app\build\intermediates\merged_manifests\debug\processDebugManifest\merged\AndroidManifest.xml\
-o\
E:\andriodProjects\ChatApp\app\build\intermediates\processed_res\debug\processDebugResources\out\resources-debug.ap_\
-R\
#E:\andriodProjects\ChatApp\app\build\intermediates\incremental\processDebugResources\resources-list-for-resources-debug.ap_.txt\
--auto-add-overlay\
--java\
E:\andriodProjects\ChatApp\app\build\generated\not_namespaced_r_class_sources\debug\processDebugResources\r\
--proguard-main-dex\
E:\andriodProjects\ChatApp\app\build\intermediates\legacy_multidex_aapt_derived_proguard_rules\debug\processDebugResources\manifest_keep.txt\
--custom-package\
com.example.mohit.chatapp\
-0\
apk\
--output-text-symbols\
E:\andriodProjects\ChatApp\app\build\intermediates\symbols\debug\R.txt\
--no-version-vectors
Daemon: AAPT2 aapt2-3.2.1-4818971-windows Daemon #0
at com.android.builder.internal.aapt.v2.Aapt2DaemonImpl.doLink(Aapt2DaemonImpl.kt:177)
at com.android.builder.internal.aapt.v2.Aapt2Daemon.link(Aapt2Daemon.kt:103)
at com.android.builder.internal.aapt.v2.Aapt2DaemonManager$LeasedAaptDaemon.link(Aapt2DaemonManager.kt:176)
at com.android.builder.core.AndroidBuilder.processResources(AndroidBuilder.java:823)
at com.android.build.gradle.internal.res.LinkApplicationAndroidResourcesTask.invokeAaptForSplit(LinkApplicationAndroidResourcesTask.java:525)
... 49 more

Many errors appeared after i added a recycler-view dependency in my project

My app worked fine and compilated untill i added
com.android.support:recyclerview-v7:28.0.0-alpha1 in my project.
Here are my errors:
Information:Gradle tasks [:app:generateDebugSources, :app:generateDebugAndroidTestSources, :app:mockableAndroidJar]
C:\Users\Smith\.gradle\caches\transforms-1\files-1.1\appcompat-v7-25.3.1.aar\455a076f8084ee34b277fdfdb97836e0\res\values\values.xml
Error:(203, 5) error: resource android:attr/fontStyle not found.
Error:(203, 5) error: resource android:attr/font not found.
Error:(203, 5) error: resource android:attr/fontWeight not found.
Error:(203, 5) error: resource android:attr/fontVariationSettings not found.
Error:(203, 5) error: resource android:attr/ttcIndex not found.
C:\Users\Smith\AndroidStudioProjects\DontSleepManager\app\build\intermediates\incremental\mergeDebugResources\merged.dir\values\values.xml
Error:(314) resource android:attr/fontStyle not found.
Error:(314) resource android:attr/font not found.
Error:(314) resource android:attr/fontWeight not found.
Error:(314) resource android:attr/fontVariationSettings not found.
Error:(314) resource android:attr/ttcIndex not found.
Error:failed linking references.
Error:java.util.concurrent.ExecutionException: java.util.concurrent.ExecutionException: com.android.tools.aapt2.Aapt2Exception: AAPT2 error: check logs for details
Error:java.util.concurrent.ExecutionException: com.android.tools.aapt2.Aapt2Exception: AAPT2 error: check logs for details
Error:com.android.tools.aapt2.Aapt2Exception: AAPT2 error: check logs for details
Error:Execution failed for task ':app:processDebugResources'.
> Failed to execute aapt
Information:BUILD FAILED in 29s
Information:15 errors
Information:0 warnings
Information:See complete output in console
If i add the line
android.enableAapt2=false
in gradle-properties then i get next warnings:
Please help me to figure out that
Try to change com.android.support:recyclerview-v7:28.0.0-alpha1 to com.android.support:recyclerview-v7:25.3.1.
And take a look at this question

AppTheme not found error in android studio

Failed to execute aapt
Information:BUILD FAILED in 20s
Information:11 errors
Information:0 warnings
Information:See complete output in console
Information:Gradle tasks [:sample-videochat-webrtc:assembleDevDebug]
Error:resource style/AppTheme (aka com.quickblox.sample.groupchatwebrtc:style/AppTheme) not found.
Error:resource style/Theme.AppCompat.Light.NoActionBar (aka com.quickblox.sample.groupchatwebrtc:style/Theme.AppCompat.Light.NoActionBar) not found.
Error:resource style/MatchWidth (aka com.quickblox.sample.groupchatwebrtc:style/MatchWidth) not found.
Error:resource style/WrapContent (aka com.quickblox.sample.groupchatwebrtc:style/WrapContent) not found.
Error:resource style/Widget.AppCompat.Toolbar (aka com.quickblox.sample.groupchatwebrtc:style/Widget.AppCompat.Toolbar) not found.
Error:resource style/AppTheme (aka com.quickblox.sample.groupchatwebrtc:style/AppTheme) not found.
Error:failed linking references.
Error:java.util.concurrent.ExecutionException: java.util.concurrent.ExecutionException: com.android.tools.aapt2.Aapt2Exception: AAPT2 error: check logs for details
Error:java.util.concurrent.ExecutionException: com.android.tools.aapt2.Aapt2Exception: AAPT2 error: check logs for details
Error:com.android.tools.aapt2.Aapt2Exception: AAPT2 error: check logs for details
Error:Execution failed for task ':sample-videochat-webrtc:processDevDebugResources'.
How to fix this error? Thanks in advance

Categories

Resources