-
Notifications
You must be signed in to change notification settings - Fork 130
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
UITextView autolayout goes crazy after a call to bindToEventNamed: #209
Comments
I've been able to recreate this locally and am investigating further |
It looks like it's something to do with what's inside the |
If I comment out the first call to
Then the issue doesn't present itself. Adding any of that code back in causes the issue to return |
Similarly, if I uncomment the first call to
Then the issue doesn't appear. I don't think this is related to libPusher, so will close this for now. If you think otherwise though, then please reopen and we can investigate further. Thanks! |
I'm reopening this just cause I've found some similarities that could worth investigating. See Issues #144 and #143. In both of them there are strange problems with bindToEventNamed: and handleWithBlock. It seems than neither of the two have a real solution to the issue besides moving code around. They referenced libPusher 1.5 in which the error was apparent by SIGSEGV, could it be that in 1.6 (the one I'm using) this do not lead to SIGSEGV but has some other (possibly memory related) subtle behaviour like the one I'm experiencing? That is: some bug lurking somewhere that has not been completely solved yet? I'm investigating further... this is getting interesting! |
Hi Hamiltom, Luke, Many thanks, On Thu, Apr 7, 2016 at 1:23 PM, Hamilton Chapman notifications@github.com
|
After some further investigation, I noticed that the code inside the handleWithBlock: is never executed, as you can easily check by adding a couple of breakpoint inside the parenthesis. So it's not the added code itself to produce the issue, rather something that happens inside the bindToEventNamed: function when handleWithBlock statement is not empty. It sound a little voodoo, but I'l keep digging... |
I'm in contact with Apple DTS to debug this issue and they say if any libpusher main developer would like to debug this with someone from Apple. Would you be so kind to investigate further with them? I can provide the follow up number that track this issue as you can see in Apple response here below: "I had a conversation with Apple's DTS management team and here is our feedback about your request:
Hopefully this makes sense to you." Many thanks |
Hi, I am investigating this now and will come back to you shortly. Thanks |
Hi, I've tried all morning to resolve some code signing issues that were present in the project you attached originally, but with no success. Could you please attach a current version? Thanks. |
Hi Nick, sry for the inconvenient. Please find the attached project, it is working for me running on simulator, I advise to use that. If you need to run on a real device you could either provide your own provisioning profile and click on 'fix issue' on the General property tab. If you feel it would be helpful, I can provide my skype credentials in order to set up a voice meeting, it could be easier to debug together. Many thanks |
Hi, For some reason, I still cannot code sign your project with any of my own profiles; even wildcards. I don't have this issue with other projects oddly. I'm not sure what the problem could be! I'm happy to keep trying to debug this issue for you, so any suggestions you may have would be great! Please note I'm using Xcode 8 with automatic signing. Thanks |
Hmm that's odd. I'll upgrade to Xcode 8 (I'm using 7.3 right now) in order to see if I can replicate the code sign issue and I'll come back to you. |
Hi Nick, I've reproduced the code sign issue, it seems that this is broken only on Xcode 8. PLease find the attached modified project, it should work now (at least works here for me). I've changed a couple of things, most importantly you need to select your team as per screenshot. Let me know if it builds now. ibapremiumTESTpusherLoginCrash - TO BE DELETED.zip thanks |
Hi Nick, did you have the chance to try the last project i sent you in the previous post? It should build now in Xcode 8. thx |
Hi, I'm afraid I was still unable to build this project due to code-signing issues. |
Oh this is unfortunate. I'm currently able to build on xcode 8 so it's weird. Please let me know if you are available for a meeting on skype so we can perhaps fix this together. thx |
or could you pls post the exact and complete error that codesign is writing in your console? |
Hi, I am seeing this error:
I have tried using my own profiles, which work on other projects. |
Hmmmm.. and nothing else? It usually write something more specific like 'provisioning profiel not found' or 'assets bundle error'. However, pls try the following:
Try also to select an actual device instead of a simulator, this sometimes makes the difference. many thx |
Hi, @hamchapman managed to get this to build through various workarounds, so I'll be looking at it today and tomorrow, and I'll get back to you with an update as soon as I can. Thanks |
Hi Nick, Many thanks |
Hi @sfaragnaus, unfortunately we didn't We weren't able to figure out what was going on. I'm more than happy to get in touch with Apple. Do you have a contact that I should reach out to? You can email me at hamilton@pusher.com if that's easier. Thanks! |
It seems that after a couple of call to bindToEventName:, selecting a UITextView for text insertion break its auto-layout constraints and position itself in apparently random position. I've attached a stripped down version of my project that exhibit this strange behaviour and a screenshot of the problem. To reproduce (you can use simulator):
I've found that this happens only if I execute the call to bindToEventNamed: in line 305 of ChatViewController.m. If you return from that function before that line, all is working correctly.
I've tried enabling all kind of Xcode 'magic' to debug memory problems (zombie, address sanitizer, etc.) and even open a ticket to Apple (they say it's probably related to libPusher and they won't investigate further on third party libs).
Many thanks in advance,
Andrea
ibapremiumTEST.zip
The text was updated successfully, but these errors were encountered: