wiomoc/whatsappweb-rs

Error parsing node structure of contacts at login

azharuddinkhan8898 opened this issue · 7 comments

@wiomoc Thanks for the great project but getting below error after getting connected.

2018-07-05 20:27:43 INFO  [ws] Queuing connection to wss://w7.web.whatsapp.com/ws
2018-07-05 20:28:05 INFO  [presence] new state: Connected
thread '<unnamed>' panicked at 'called `Result::unwrap()` on an `Err` value: Error(Msg("Node has invalid binary format"), State { next_error:Some(Error(Msg("Couldn\'t read node content (list), node decription: response"), State { next_error: Some(Error(Msg("Couldn\'t read list item: 115, size: 37635"), State { next_error: Some(Error(Msg("Couldn\'t read attribute :notify, node decription: user"), State { next_error: Some(Error(Msg("invalid jid surfix N"), State { next_error: None, backtrace: InternalBacktrace { backtrace: None } })), backtrace: InternalBacktrace { backtrace: None } })), backtrace: InternalBacktrace { backtrace: None } })), backtrace: InternalBacktrace { backtrace: None } })), backtrace: InternalBacktrace { backtrace: None } })', libcore/result.rs:945:5
note: Run with `RUST_BACKTRACE=1` for a backtrace.
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: Any', libcore/result.rs:945:5

Is there any solution for this?
Thanks.

I get this error too. Can it be because of different lib version? Or what do you think?

@emehmet I tried everything but getting this error again, I am new to rust and I guess that's the reason I am not able to figure it out.
@wiomoc Can you please help us out?

I think We make a mistake when try install this on windows. Because you don't get same error. Maybe you can publish docs for full installation on windows. Maybe there is a wrong things for protoc installation.

@emehmet As I mentioned, the problem is related to the node parser I wrote, but I can't reproduce these problems. This code acts on every platform the same

Weird jid types definitely exist. I was running into this error until I patched my fork with this commit: eeeeeta@75d2545
With that, it runs, revealing the existence of a temp suffix:

WARN whatsappweb::node_wire - Invalid jid surfix temp

@azharuddinkhan8898 @eeeeeta One of the problems is addressed in #6

@eeeeeta I'm going to cherry-pick some of your changes soon

@wiomoc Sure, go ahead! Thanks for dacf1ef - I don't seem to have run into any endianness-related issues on my fork, yet, but it might be worth my cherrypicking and testing it anyways...