Comments (12)
@l4u thank you for providing the sample project!! I've tried several things, and am unable to get it to build (the cocoapod configuration appears to be messed up). If you have time to fix it so that a typical pod install call will work, that would be great (I tried having a local checkout of AsyncDisplayKit where the path points to, and still no luck).
I appreciate you reporting this issue. Another alternative would be to copy/paste the stack trace you are seeing and any other console logs.
from asyncdisplaykit.
Thanks! I've updated the repo to use a remote git pod spec. Please let me know if it works for you.
from asyncdisplaykit.
log: https://gist.github.com/l4u/2556d1c67ac376c14a57
from asyncdisplaykit.
It crashes when a kitten image is set on a background thread.
from asyncdisplaykit.
@appleguy @l4u I can reproduce on the device (iPhone 4S iOS 8.0.2)
The _imageNode.nodeLoaded property become YES at this line (it should be NO):
https://github.com/facebook/AsyncDisplayKit/blob/master/examples/Kittens/Sample/KittenNode.m#L148
Accessing the nodeLoaded
property is not safe here, maybe ASDisplayNode should provide some mechanism to perform a block with this property locked.
from asyncdisplaykit.
@l4u with your sample code I also encounter another crash at this lineοΌ
'NSInvalidArgumentException', reason: '*** setObjectForKey: object cannot be nil (key: <NSIndexPath: 0x396230> {length = 2, path = 0 - 2})'
When you switch pages fast enough, the ViewController is deallocated, but the sizing task is still running and will get a nil _delegate.
from asyncdisplaykit.
Yes, sometimes I can see that crash too. Still finding ways to fix this.
from asyncdisplaykit.
@l4u @lldong, I verified this issue late last week and we have a fix planned (should be landing in the coming week).
Basically, ASImageNode should allow you to set the .image property off the main thread, even after its corresponding view has been created. It's a simple error that it is asserting thread affinity, because it already has locking installed to protect the property during use on multiple threads.
Thanks again for reporting this (and providing the sample project, which I got to work). Apologies for the inconvenience here, and let us know if you have any other questions about the framework!
from asyncdisplaykit.
@l4u β both of these issues should now be fixed. Thanks for the report and sample project!
from asyncdisplaykit.
This can still happen. I use ASTableViews inside UICollectionViewCells (i know, bit strange, but optimal in my situation) and if i scroll pretty fast through the collectionview i get this crash consistently.
from asyncdisplaykit.
@megakode, if you can confirm that this issue is the cause of your crash, we should either re-open this issue or you should file a new one.
from asyncdisplaykit.
We haven't seen any reports of this particular crash recently, but please do file a new issue if they recur. The thread-affinity API is something we've been wanting to remove for a while, and it's on our radar for AsyncDisplayKit 1.3 β subscribe to #134 if you'd like to follow along.
from asyncdisplaykit.
Related Issues (20)
- Custom flow layout did not work in ASCollectionNode ,But work in UICollectionView
- Build failed with XCode Version 9.3 (9E145) HOT 12
- How to reload SupplementaryElement (UICollectionElementKindSectionHeader)
- [ASTableNode] When tableNode is reloading I see several empty rows, but they have the content
- collectionNode always lost several cells and give me some blank cells HOT 1
- Change maximumNumberOfLines from 5 to 0, The text is stretched. HOT 2
- Full screen button doesn't appear on ASVideoPlayerNode HOT 2
- Dictionary Parsing Problem HOT 1
- Expected method to read dictionary element not found on object of type 'id<NSObject>' HOT 3
- I need a error log while playing ASVideoPlayerNode HOT 1
- page control HOT 1
- updateContentSize HOT 1
- ASTableNode will scroll to the top after insert rows
- enableSubtreeRasterization causes ASButtonNode to not receive touch event HOT 1
- ASButtonNode highlighted titles shifts to the right HOT 2
- CollectionNode fetches all content from NSFetchResultsController
- willDisplayNodeContentWithRenderingContext not work HOT 2
- Sometimes `ASPerformMainThreadDeallocation` does not work HOT 2
- ASTextKitContext.mm(line 62) return nil.
- How to get ASCellNode location on ASCollectionNode
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from asyncdisplaykit.