Skip to content
This repository has been archived by the owner on Dec 4, 2018. It is now read-only.

ARC not enabled in CocoaPods Podspec #142

Closed
jacksonh opened this issue Jan 8, 2014 · 9 comments
Closed

ARC not enabled in CocoaPods Podspec #142

jacksonh opened this issue Jan 8, 2014 · 9 comments
Assignees
Labels

Comments

@jacksonh
Copy link
Contributor

jacksonh commented Jan 8, 2014

I think I'm missing something obvious with OctoKit. This is a small sample app I wrote this morning:

https://github.com/jacksonh/octophile

Running this app in Instruments with the Leaks template each time I tap the Fetch User Info my OCTResponse objects are shown as leaking.

Am I doing something wrong with my subscriptions here?

@jspahrsummers
Copy link
Collaborator

No, it looks fine to me.

Can you upload the full trace somewhere?

@jacksonh
Copy link
Contributor Author

jacksonh commented Jan 8, 2014

You can grap my trace from here, I let snapshotting go every 10 seconds, the first set of leaks is the login, then after that tapping the fetch button.

http://hsc.io/octophile.trace.zip

@jspahrsummers
Copy link
Collaborator

Sooo… it looks like we might be creating retain cycles from RACSignals to themselves (because of the hidden self in NSAssert).

We've not seen this issue because we don't use CocoaPods, so the Release build of OctoKit doesn't have assertions.

trololo

jspahrsummers added a commit that referenced this issue Jan 8, 2014
Because `NSAssert` is a huge trollface. Hopefully fixes #142.
@ghost ghost assigned jspahrsummers Jan 8, 2014
@jacksonh
Copy link
Contributor Author

jacksonh commented Jan 9, 2014

Thank you! That also explains why I couldn't duplicate with GroceryList

@joshaber
Copy link
Contributor

So this looks like a problem with how CocoaPods is configuring OctoKit for octophile. It's not compiling OctoKit with ARC (and maybe the same for all the other dependencies?). You can see this by Analyzing or inserting retain/release/autoreleases in OctoKit.

@jacksonh
Copy link
Contributor Author

OK, I'll work on this since its somewhat critical for me. And yes, I was wondering why the hell I could release things when testing.

@jacksonh
Copy link
Contributor Author

Sigh, you are correct. The Pods project had ARC disabled. Confirmed that there are no leaks with that fixed.

@ghost ghost assigned jacksonh Jan 21, 2014
@jacksonh
Copy link
Contributor Author

OK, this is fixed in CocoaPods. CocoaPods/Specs#7144

@joshaber
Copy link
Contributor

🤘

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants