I have an app with a custom Swift framework that is used to share business rules across different plateform. Every time I try to use a class from this framework, Xcode is showing me errors but everything compiles well. It also preventing me from using autocompletion regarding this framework.
I already try cleaning and deleting derived data but without any results.
My framework is included in my main projet via a submodule and manually linked on my main project.
Any thoughts on this ?

I think your problem is with the framework's search path. I assume its now set for the target but not for the project (or incorrectly set on the project). You can set it only for the project and let Xcode handle target path.
Xcode has a separate compilation process for computing autocomplete references, from the compilation process for actually building your project. If you accidentally set the framework search path for your target instead of the project as a whole, your project will seem to build fine. https://medium.com/@_achou/one-weird-trick-to-fix-autocomplete-in-xcode-9f19dc856944
Solution 1: Fix framework search path in Project - Build Settings.
Solution 2: Remove the framework from your project, head to Targets - Build Phase - Embeded Frameworks, click on + (add) and then Add Other and find it in your directory.
Try removing your framework then CMD+B close XCODE open it again add the framework again and CMD+B. By the way have you moved your project folder recently??

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With