Skip to content
This repository was archived by the owner on Feb 2, 2023. It is now read-only.

Conversation

Adlai-Holler
Copy link
Contributor

@appleguy Pursuant to #664 (comment) , here's a branch that just has the Travis updates. On my local machine using Xcode 7A220 I still get the same unrecognized selector errors for category properties like CALayer.asyncdisplaykit_node

@appleguy
Copy link
Contributor

Interesting, so it is an Xcode 7 specific issue with our test harness I would suppose? Testing often results in test-specific issues :(.

This code has been working since the late versions of Xcode 4.6 or so, and thus although it may need a change to handle the Xcode changes, I don't think it has been recently broken.

Can you confirm running the tests locally reproduces the issue? I'm away from a computer but if no one has figured it out by the time the plane boards, I will debug.

Sent from my iPhone

On Sep 19, 2015, at 10:06 PM, Adly Holler notifications@github.com wrote:

@appleguy Pursuant to #664 (comment) , here's a branch that just has the Travis updates. On my local machine using Xcode 7A220 I still get the same unrecognized selector errors for category properties like CALayer.asyncdisplaykit_node

You can view, comment on, or merge this pull request online at:

#671

Commit Summary

Bump SDK in build.sh
Bump the .travis.yml OS X image requirement for Xcode 7
File Changes

M .travis.yml (1)
M build.sh (4)
Patch Links:

https://github.com/facebook/AsyncDisplayKit/pull/671.patch
https://github.com/facebook/AsyncDisplayKit/pull/671.diff

Reply to this email directly or view it on GitHub.

@Adlai-Holler
Copy link
Contributor Author

Yep, running it locally does reproduce the issue.

The issue isn't test-specific – any code that calls CALayer.asyncdisplaykit_node would get the same unrecognized selector error.

EDIT: I was wrong about that. It happens only in the test harness

@appleguy
Copy link
Contributor

Spent some time looking into this, but have run out. I have a number of other priorities that I can't bump in the next couple weeks, and am worried I just won't have time to get the testing system running on Xcode 7 in September.

If anyone wants to take a deeper look, the help would be thoroughly appreciated! I got past several of the issues, but it remains a mystery why they are popping up at all (e.g., the implementation counterpart to the CALayer @dynamic for asyncdisplaykit_node indeed seems to be missing, and adding the implementation fixes that issue, but uncovers a bunch of similar ones). Before forging ahead to blindly "fix" anything "missing", we should go back to 6.4 to understand what might have changed / how it was working before. cc @nguyenhuy, @levi

@nguyenhuy
Copy link
Contributor

Thanks for cc'ing me, Scott. I strongly agree that we need to understand the root cause first. I can spend time on this issue later this week, or even early next week. I've been insanely unproductive these days due to my serious procrastination problem and/or having a cold. Anyway, if anyone can work on this before me, please do.

@Adlai-Holler
Copy link
Contributor Author

Note: I figured out how it's working normally – CALayer just lets you do arbitrary key-value storage, and it'll generate accessor implementations for any properties you add in categories with @dynamic.

@appleguy
Copy link
Contributor

Aha! Right, somehow I’d forgotten that. I wonder why the hell that is no longer working with Xcode 7, only in test targets…

On Sep 22, 2015, at 3:16 PM, Adly Holler notifications@github.com wrote:

Note: I figured out how it's working normally – CALayer just lets you do arbitrary key-value storage, and it'll generate accessor implementations for any properties you add in categories with @dynamic.


Reply to this email directly or view it on GitHub #671 (comment).

@appleguy
Copy link
Contributor

I spent more time investigating this. I'm actually pretty worried at this point, because I don't have a lead or a good idea for the debugging approach.

The tests are definitely running within a UIKit app. The stack traces that show the calling of the @dynamic methods (which crash for doesNotRespondToSelector) clearly show UIApplicationMain at the bottom of the stack. I don't think there should be any difference between the way CALayer handles the @dynamic methods in a regular running session vs the test app, but there quite clearly is.

There is at least one place where we may depend on the fact that CA makes the properties KVC-compliant when it generates them itself. I'm not sure if this would be supported if we manually implemented these methods, and would really like to avoid doing that until someone is able to help us understand the root cause for the behavior change. The biggest mystery here is not only why the same code behaves differently under Xcode 6.4 vs 7.0, but also why it only affects the test application.

I studied the project file / build configurations, but didn't see anything suspicious in the setup for the test environment.

I'm downloading Xcode 7.1 Beta 2 to try, although I don't expect it to fix the issue.

@appleguy
Copy link
Contributor

Xcode 7.1 Beta 2 has the same issue, as does 7.0.1.

@appleguy
Copy link
Contributor

appleguy commented Oct 1, 2015

I've opened a Radar and pinged the wizards at Apple to help investigate this unusual issue.

Hoping to unblock the wonderful #664 as soon as possible!

@appleguy
Copy link
Contributor

Sadly there is zero traction whatsoever on the Apple issues, so it is going to take months to land this. I am going to close the PR until we are on Xcode 7, and then reopen.

@appleguy
Copy link
Contributor

I worked around Apple's frustrating, still-unfixed bug with @dynamic properties on CALayer by avoiding use of them. It's a suboptimal solution as we lose certain capabilities, but I'm excited to get this in. A truly happy Christmas 2015, lol!

#994

appleguy added a commit that referenced this pull request Dec 25, 2015
Enable Xcode 7 by default for Travis build server.
@appleguy appleguy merged commit 406bcfa into facebookarchive:master Dec 25, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants