[Pyobjc-dev] [ pyobjc-Bugs-896018 ] def or class at beg. of file screws up XCode
Brought to you by:
ronaldoussoren
From: SourceForge.net <no...@so...> - 2004-02-12 20:19:13
|
Bugs item #896018, was opened at 2004-02-12 15:17 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=114534&aid=896018&group_id=14534 Category: None Group: None Status: Open Resolution: None Priority: 5 Submitted By: Jeremy Gore (jmg75) Assigned to: Nobody/Anonymous (nobody) Summary: def or class at beg. of file screws up XCode Initial Comment: XCode is constantly throwing me the following with certain .py files when attempting to view them within a cocoa-python project. Uncaught Exception: *** -[NSCFString characterAtIndex:]: Range or index out of bounds When attempting to view them on their own by dragging and dropping, the file will either open but the titlebar is greyed out adn the text not editable, or not open, or crash the program. My settings are for UTF-8. This only happens with certain files. Removing the .py extension and then restarting the project eliminated the problem, and putting it back on created it again, so it's safe to say there is some sort of problem with the pyobjc file template or something. Whichever code is involved in formatting/ labelling segments of python code isn't playing well with XCode's engine to do so. After some fiddling I discovered that declaring a def or class at the very beginning of the file causes the problem. Putting in an extra line or a comment or shebang makes it work again. Furthermore, simply typing "def: " as the first line doesn't do it, you actually have to say "def this(): " for it to happen. Although now I can actually use the code, please fix it. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=114534&aid=896018&group_id=14534 |