SagarU
SagarU

Reputation: 426

dyld: Symbol not found: __TWPVs11AnyHashables20_AnyHashableProtocols

My app started crashing once I updated XCode to 8.3 with the below error:

  dyld: Symbol not found: __TWPVs11AnyHashables20_AnyHashableProtocols
  Referenced from: /Users/faidmit/Library/Developer/CoreSimulator/Devices/C7E102B3-69B4-42EC-A699-0D2FDF768A86/data/Containers/Bundle/Application/341C0D73-B57B-4E30-A639-3A23B1D7CAA6/MVP-INT.app/Frameworks/Alamofire.framework/Alamofire
  Expected in: /Users/faidmit/Library/Developer/CoreSimulator/Devices/C7E102B3-69B4-42EC-A699-0D2FDF768A86/data/Containers/Bundle/Application/341C0D73-B57B-4E30-A639-3A23B1D7CAA6/MVP-INT.app/Frameworks/libswiftCore.dylib

What have I tried:

Upvotes: 4

Views: 2892

Answers (2)

andrei
andrei

Reputation: 1403

For me, deleting the app's derived data solved the problem. In Xcode 8.3, this can be done by going to XCode > Preferences > Locations. There you will find the path of the derived data with a right arrow next to it. Clicking on the arrow should launch Finder with the path to Derived Data. There you should look for any folder whose name begins with your app name and delete it

Upvotes: 2

SagarU
SagarU

Reputation: 426

For most of the people stuck with the same problem, the steps mentioned in the question itself might work (in the same order). What I did was kind of a last ditch effort. Something that I wanted to try before I just rolled back the update. Steps below:

  1. Check the Deployment Target for your project (for me, this was 8.1)
  2. Download Alamofire from GitHub and check the Deployment Target (8.0).
  3. Change the Deployment Target for Alamofire to match the one for your project (8.1).
  4. Compile and include the generate .framework in your project.

I agree that this is not a universal approach. It may be difficult especially if you are using pods. Since I am not, it worked for me.

Upvotes: 2

Related Questions