So let my question not be "why does this happen", but "what do I do to fix it"? Update: OK, I found out why it complains, which is that the Foundation module is using ScriptingBridge to dynamically generate the classes - presumably pydev isn't actually importing the module to see what classes are inside, it's just looking for. When I can use that class without any problem from the command-line interpreter? So why does PyDev complain about "Undefined variable from import: NSDictionary" on this class: import Foundation Type "help", "copyright", "credits" or "license" for more information. Now that path is the correct path to the Foundation module in OS X, as evinced by the command-line interpreter: $ python I used 'Auto Config' to set up my Python interpreter: it correctly found /usr/bin/python (which is Python version 2.6.1) and added various system folders to the PYTHONPATH, including /System/Library/Frameworks/amework/Versions/2.6/Extras/lib/python/PyObjC. I've installed and configured PyDev version 1.020317 inside Eclipse, running on Mac OS X 10.6.6:
0 Comments
Leave a Reply. |