I am testing 9-patch image .
Before everything works fine , and i rename drawable
file ic_button_beat_box_default.png
to ic_button_beat_box_d
I had the same issue by changing only file name, when I saved the image in 9-patch-tool issue solved.
I have red other similar questions and answers to them on SO, regarding that "file crunching failed, see logs for details" error. Nothing helped.So,I reverted all "SO" changes I made with gradle and other files and removed ".9" in that png.9 files and it began work. Then I recreated all *.9.png files again. Hence, in my case the cause was wrong editing of 9.pngs in external png editors.
On Windows I had a "BUILD FAILED Failed to crunch file [path]" error and solved it by closing the Android Studio project, copying the entire project folder into a location with a shorter directory path, such as my C: folder and then opening the project in the new location. Hope it helps