0

I'm trying to get my SmashTag app to load on my phone. All the certificates and things are in order (i.e., I've been able to load other apps from Xcode onto the phone) but when I try to load Smashtag I get errors related to the Twitter framework.

I load the app, my iPhone appears to launch the app, and then Xcode gives me this message in the console:

dyld: Symbol not found: __TWvdvC7Twitter4User10screenNameSS Referenced from: /var/containers/Bundle/Application/AB50558C-00A2-4C61-B81D-F862C8B25EDA/Smashtag.app/Smashtag Expected in: /System/Library/Frameworks/Twitter.framework/Twitter in /var/containers/Bundle/Application/AB50558C-00A2-4C61-B81D-F862C8B25EDA/Smashtag.app/Smashtag

I've done a bit of SO research and it looks like this is some kind of framework issue. In my Smashtag project, the Linked Frameworks and Libraries section has Twitter.Framework, and it's "required", and in Smashtag's Frameworks folder contains Twitter.xcodeproj, and nothing is red or giving any errors or warnings. Can someone tell me what I'm doing wrong? Thank you.

(I tried removing and readding the framework, didn't help)

Jonathan Tuzman
  • 11,568
  • 18
  • 69
  • 129
  • I have watched Standford CS193 on Youtube, the source code may not be update to date, any time I load the code, there is build errors, Xcode is a maybe 2 versions higher since this course,everything in constant flux, the code is Swift 2.3 too probably. I would suggest running on the emulator and not focusing too much on trying to get it running on an iPhone,is your time worth it? Rewrite yourself from scratch if you really want it running on your iPhone – Brian Ogden Feb 24 '17 at 04:44
  • There are currently many question about this, so I assume this is the current course which teaches Swift 3 and not 2.3, so nothing is really in flux anymore, we have source stability (except for code that should have never compiled). @Jonathan you can always search for the error message, does [this](http://stackoverflow.com/questions/24043532/dyld-symbol-not-found-nsurlauthenticationmethodclientcertificate-when-trying) help? – HAS Feb 24 '17 at 06:13
  • Yes I searched and it looks like a framework issue but I can't figure out what's actually wrong. – Jonathan Tuzman Feb 24 '17 at 09:28

1 Answers1

1

First, convert the Twitter framework to the Current Swift Syntax (Edit menu, Convert item, you then still have to update the asPropertyList dictionary type in User.swift from AnyObject to [String: Any]).

Then, be sure the Twitter framework also appears in the Embedded Binaries section of the Smashtag project (as it does in the Linked Framework and Libraries section).

Yet Another Code Maker
  • 1,625
  • 1
  • 10
  • 5