no such file or directory - swiftdoc swiftmodule swiftsourceinfo swiftdoc
Asked Answered
G

2

6

I have a project where I write XCUITests. I would like to place the accessibility IDs in a separate framework along with other things so that they can be read in the project and in the tests.

MyProject
 - MyProject.xcworkscapce
 - MyFramework 
 - MyApp
   -MyApp (main-target)
   -MyAppUITests (uiTest-target)

Loading MyFramework in the project is no problem. To make it visible for the UITests I import MyFramework into the UITests. The class and the static variables (Acc-Ids) are public. The completion also recognises everything, no errors are shown in the code, I can also navigate to the variables. The app works.

Now when I run the test, I get 4 error messages, which unfortunately tell me nothing at all:

/Users/john.doe/Library/Developer/Xcode/DerivedData/ALIS-ffdwrkfpekfzrggbfmnsazmrxelm/Build/Intermediates.noindex/MyApp.build/Debug-iphonesimulator/MyAppUITests.build/Objects-normal/x86_64/MyAppUITests.abi.json /Users/john.doe/Library/Developer/Xcode/DerivedData/ALIS-ffdwrkfpekfzrggbfmnsazmrxelm/Build/Intermediates.noindex/MyApp.build/Debug-iphonesimulator/MyAppUITests.build/Objects-normal/x86_64/MyAppUITests.abi.json: No such file or directory

/Users/john.doe/Library/Developer/Xcode/DerivedData/ALIS-ffdwrkfpekfzrggbfmnsazmrxelm/Build/Intermediates.noindex/MyApp.build/Debug-iphonesimulator/MyAppUITests.build/Objects-normal/x86_64/MyAppUITests.swiftdoc /Users/john.doe/Library/Developer/Xcode/DerivedData/ALIS-ffdwrkfpekfzrggbfmnsazmrxelm/Build/Intermediates.noindex/MyApp.build/Debug-iphonesimulator/MyAppUITests.build/Objects-normal/x86_64/MyAppUITests.swiftdoc: No such file or directory

/Users/john.doe/Library/Developer/Xcode/DerivedData/ALIS-ffdwrkfpekfzrggbfmnsazmrxelm/Build/Intermediates.noindex/MyApp.build/Debug-iphonesimulator/MyAppUITests.build/Objects-normal/x86_64/MyAppUITests.swiftmodule /Users/john.doe/Library/Developer/Xcode/DerivedData/ALIS-ffdwrkfpekfzrggbfmnsazmrxelm/Build/Intermediates.noindex/MyApp.build/Debug-iphonesimulator/MyAppUITests.build/Objects-normal/x86_64/MyAppUITests.swiftmodule: No such file or directory

/Users/john.doe/Library/Developer/Xcode/DerivedData/ALIS-ffdwrkfpekfzrggbfmnsazmrxelm/Build/Intermediates.noindex/MyApp.build/Debug-iphonesimulator/MyAppUITests.build/Objects-normal/x86_64/MyAppUITests.swiftsourceinfo /Users/john.doe/Library/Developer/Xcode/DerivedData/ALIS-ffdwrkfpekfzrggbfmnsazmrxelm/Build/Intermediates.noindex/MyApp.build/Debug-iphonesimulator/MyAppUITests.build/Objects-normal/x86_64/MyAppUITests.swiftsourceinfo: No such file or directory

What I tried:

  • clean project
  • delete derived data
  • the framework is in Copy Bundle Resources?
  • copy bundle resources: is there something red

This is a special "no such file or directory" error that some people seem to get. Any help appreciated.

Goforth answered 24/1, 2023 at 10:13 Comment(6)
We're facing the same issue but don't have a solution.Spark
Did you finally find any solution for this? @BenThomas @brainray?Vogler
@DJ-Glock: Glad you could fix it. No luck here. I will have to tryout Xcode 15 with this.Goforth
@Goforth that's sad. Did you try to uninstall XCode, then clean all data using devcleaner and then install XCode?Vogler
@DJ-Glock: haven't seen the error in a while. But just a minute ago, I had it again after trying to update a SPM package by changing the allowed version number. The above symptoms plus a lots of other errors. Then I found that there was a redeclaration of an enum. Deleted the senseless one - all fine. I'll try your fix the next time I'm out of ideas, promised ;-)Goforth
My latest advice: restarting the Mac helped hereGoforth
V
0

I found a possible solution for this issue. What I did: I started migrating to new project and was really surprised when newly created project failed with the same errors. So I suspected Xcode.

Once I reinstalled XCode - errors have gone. Hope it will help someone.

Vogler answered 14/7, 2023 at 20:16 Comment(1)
Simply restarting XCode solved the issue for me. Weird.Coastwise
C
0

I found this to be a red herring -- the actual problem was a separate compilation error. (Well actually... multiple errors.) Fixing those errors resolved the swiftmodule etc.!

Comprehend answered 15/10 at 3:45 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.