How to solve Failed to read file attributes for "/Users/path/myapp/Images.xcassets" in Xcode?

Suddenly I get an error message in beta version of Xcode 9

"Could not read file attributes for" /Users/path/myapp/Images.xcassets "in Xcode?" and unable to assemble, I just dragged the "Images.Xcassets" folder to pick it up.

I checked the goals, Copy Bundle resources, and the Images.Xcassets folder. But I can not build a project.

+12
source share
4 answers

I found out that the name of my folder is images.Xcassets , the name of the group and the full path of images.Xcassets . You should check the name of your group and the full path in the File Inspector.

enter image description here

EDIT:
Here are two solutions:
1. Remove the group from Project Navigator (ALT + 1) and add the files again (OPTION + ALT + A).
2. Click the folder icon from the โ€œFile inspectorโ€ (OPTION + ALT + 1) and select a new folder.

+27
source

This is the problem of the latest Xcode9. There are two ways to solve this problem.

Follow these steps:

  • Remove the link from the images.Xcassets file from your project. As soon as you remove it from the project and add it to the project, I solved my problem again.

enter image description here

  1. If parameter 1 does not work, delete (Trash) the complete images.Xcassets file and add all the icons again.

Make sure you add this to your name. Build Settings

+12
source

"Close Xcode and restart." it worked for me. I have the same problem with Xcode-9.0. I tried it in several ways, for example, deleting Derived data, clearing the project and closing Xcode, but nothing worked.

Delete your derived data and then close the code X Cmd + q exit xcode and reopen it.

+8
source

I had the same problem though, using local containers. Xcodebuild now seems to be case sensitive relative to resource path. ~ / Folder / MyProject! = ~ / Folder / MyProject

+2
source

Source: https://habr.com/ru/post/1269364/


All Articles