Duplicate value for resource 'attr/strokeWidth' with config

makkhokher :

I just updated the support library from 27 to 28 and it is not successfully building with the following error:

Android resource compilation failed
Output:  /AndroidProjects/Brand App/app/build/intermediates/incremental/mergeDebugResources/merged.dir/values/values.xml:1052: error: duplicate value for resource 'attr/strokeWidth' with config ''.
/AndroidProjects/Brand App/app/build/intermediates/incremental/mergeDebugResources/merged.dir/values/values.xml:1052: error: resource previously defined here.

Command: /Users/apple/.gradle/caches/transforms-1/files-1.1/aapt2-3.2.0-4818971-osx.jar/509e285e62be11c8bb7437cdd445c1df/aapt2-3.2.0-4818971-osx/aapt2 compile --legacy \
        -o \
        /AndroidProjects/Brand App/app/build/intermediates/res/merged/debug \
        /AndroidProjects/Brand App/app/build/intermediates/incremental/mergeDebugResources/merged.dir/values/values.xml
Daemon:  AAPT2 aapt2-3.2.0-4818971-osx Daemon #0
Awais Tariq :

Faced the same issue, mine was attr/shape in config file, the issue is basically related to conflict of libraries that are using android default libraries, please paste the complete issue also update any thirdparty libraries you are using and it will work. I update one of the libraries and the issue is resolved. as i was using old version of com.facebook.shimmer and i just updated it in gradle and it worked.

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=70565&siteId=1