OK, finally near the bottom of this problem.

It turned out that I had an override of -didTurnIntoFault in my tree item 
entity. In there I was nil'ing out a couple of relationships (which are in 
principle nil'ed out by the nullify delete rule) - I did this while trying to 
track down some other document closing bug. These 3 lines of code made it into 
my test app, so I saw the problem there too. It's not clear to me why doing 
this caused this problem on 10.6.8 (and not on 10.7 or 10.8) but the Apple 
support guy said I shouldn't do it in -didTurnIntoFault.

Anyway, removing that override (which is not needed anyway) fixes the problem. 
Simple when you know!

Best wishes,

Martin

On Jan 15, 2013, at 05:41 PM, Martin Hewitson <martin.hewit...@aei.mpg.de> 
wrote:

> 
> On 14, Jan, 2013, at 03:31 PM, Jerry Krinock <je...@ieee.org> wrote:
> 
>>> Will -autorelease work with ARC?
>> 
>> I don't think so.  I didn't realize you were using ARC.  I suppose you could 
>> opt out of ARC in your Method Replacement file, in order to compile that 
>> -autorelease.
>> 
>>> Could you hint how to do that? A category on NSTreeController?
>> 
>> 
>> I can't find the article on Apple's site any more, but here it is from the 
>> horses's mouth, probably written better…
>> 
>> http://mikeash.com/pyblog/friday-qa-2010-01-29-method-replacement-for-fun-and-profit.html
>> 
>> Method Replacement is a good occasional last resort, particularly in 
>> troubleshooting, but you can ship it if necessary.
> 
> Thanks for the pointers. Though after some further work, the test app now has 
> only a very few lines of custom code, and the 'bug' is still there. The use 
> of [NSTreeController selectedObjects] is gone, so that was a red herring 
> (though the retaining may still be going on behind the scenes). 
> 
> So I've opened a ticket with Apple to get some support. I'll post back if 
> they come up with a solution.
> 
> Many thanks,
> 
> Martin
> 
> 
> 
> 
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Martin Hewitson
Albert-Einstein-Institut
Max-Planck-Institut fuer 
    Gravitationsphysik und Universitaet Hannover
Callinstr. 38, 30167 Hannover, Germany
Tel: +49-511-762-17121, Fax: +49-511-762-5861
E-Mail: martin.hewit...@aei.mpg.de
WWW: http://www.aei.mpg.de/~hewitson
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~






_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to