Comments (15)
No, I'd expect the auth request failure to bubble up to the delegate instead. Looks like I'm not checking for failure before trying to parse the auth response.
from libpusher.
This is happening a decent amount in a beta build of one of my apps since I'm using Heroku with only one Dyno and it's timing out. I would really appreciate a fix :)
from libpusher.
I think this should be enough to fix the issue; it looks like the appropriate delegate method will be called if the auth operation fails (the underlying connection error will be available in the NSError passed to the delegate method in the userInfo, with the NSUnderlyingErrorKey).
I think the only problem was the attempt to try and parse the response data when the response was not successful, resulting in the crash you were getting.
I'll trigger a new nightly build for you to download and try.
from libpusher.
Thanks man! I'll test and verify as soon as you post it.
from libpusher.
Works great. Thanks!
from libpusher.
I'm getting this crash on the nightly build and in 1.4.
from libpusher.
Hi, are you able to provide a backtrace?
from libpusher.
It's identical to what the original poster provided above. Do you need any additional information?
On Wednesday, October 3, 2012 at 4:52 AM, Luke Redpath wrote:
Hi, are you able to provide a backtrace?
—
Reply to this email directly or view it on GitHub (#44 (comment)).
from libpusher.
Okay, I was finally able to build libPusher from source (whew!), and I added this quick fix to PTPusherChannelAuthorizationOperation.m
if (responseData) {
authorizationData = [[PTJSON JSONParser] objectFromJSONData:responseData];
} else {
authorizationData = nil;
}
Without regard for matching your coding style or any other aspect of your code's logic (need to push an emergency update to the app store). Let me know if you'd like me to commit this fix.
The conditions are trying to authorize a private channel when the server is completely off and not even listening for connections.
from libpusher.
Thanks for this. If it works, please use it for our app. I will have a look at this tomorrow. The fix looks good, I'd just like to try and get a failing test case too. I plan to release a 1.4.1 release shortly so this will make it in.
from libpusher.
Great. Should I be attempting to push this over to you (getting 403 errors)?
from libpusher.
No need, thanks.
Sent from my iPad
On 3 Oct 2012, at 22:39, s5 [email protected] wrote:
Great. Should I be attempting to push this over to you (getting 403 errors)?
—
Reply to this email directly or view it on GitHub.
from libpusher.
I got the same error using the latest lib, is this not commited yet?
from libpusher.
For those having a problem with this, can you please try the latest HEAD (nightly build will be available tonight).
from libpusher.
This issue is still present. Hard to reproduce, but happens every so often for our clients
from libpusher.
Related Issues (20)
- Xcode 8 and iOS 10 HOT 10
- 'PTEventListener.h' file not found HOT 2
- No auth data sent in subscription event HOT 4
- Crash with PTNSJSONParser objectFromJSONString HOT 2
- [push notifications] Error callbacks? HOT 3
- Undefined symbols for architecture x86_64: "_OBJC_CLASS_$_PTPusher" HOT 1
- [Critical] Version Preprocessor Macro Crashes Cocoapods HOT 1
- Push lib crashes HOT 3
- Retain cycle in PTURLRequestOperation HOT 2
- ReactiveCocoa => ReactiveObjC for swift3
- Undefined symbols for architecture arm64 HOT 2
- Dynamic Channels HOT 4
- New release? HOT 4
- No current subscription to channel myChannel, or subscription in progress HOT 7
- Unable to read your certificate: failed to parse PKCS1 private key HOT 12
- Xcode 9 - PTPusherErrorDomain error while subscribing to private channel HOT 2
- Getting this error. "Value of type 'PTPusherPrivateChannel' has no member 'bind'" HOT 2
- 'WebSocketClient' is ambiguous for type lookup in this context
- Private channel not receiving pusher events. HOT 9
- add objective c documentation for Beam integration HOT 1
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 libpusher.