yowsup icon indicating copy to clipboard operation
yowsup copied to clipboard

Yowsup v0.82 sync issue

Open hooddy opened this issue 12 years ago • 30 comments

Thanks for updated Yowsup. Registration works well but sync still don't.

Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

hooddy avatar Mar 22 '14 07:03 hooddy

Yes it does.

shirioko avatar Mar 23 '14 20:03 shirioko

No, it doesn't :(


./yowsup-cli -c 346974884XX --sync +346580830XX Detected cc: 34 Syncing 1 contacts

  • and doesn't show anymore

./yowsup-cli -c 346974884XX --sync "+346580830XX" -d Detected cc: 34 Syncing 1 contacts {'Content-Type': 'application/x-www-form-urlencoded', 'Authorization': 'X-WAWA: username="34697488495",realm="s.whatsapp.net",nonce="0",cnonce="33kyqmm7bz",nc="00000001",qop="auth",digest-uri="WAWA/s.whatsapp.net",response="43c11b31c49a15fc4deac14009e70e17",charset="utf-8"', 'Accept': 'text/json', 'User-Agent': 'WhatsApp/2.12.15 S40Version/14.26 Device/Nokia302'} Opening connection to sro.whatsapp.net Sending POST request to /v2/sync/a

  • and doesn't show anymore

ikerfp avatar Mar 26 '14 12:03 ikerfp

./yowsup-cli --config num --sync +553484XXXXXX -d Syncing 1 contacts {'Content-Type': 'application/x-www-form-urlencoded', 'Authorization': 'X-WAWA: username="553484XXXXXX",realm="s.whatsapp.net",nonce="0",cnonce="485un5a3y2",nc="00000001",qop="auth",digest-uri="WAWA/s.whatsapp.net",response="e62c93f74bbfebbcd643a3417c9f361a",charset="utf-8"', 'Accept': 'text/json', 'User-Agent': 'WhatsApp/2.12.15 S40Version/14.26 Device/Nokia302'} Opening connection to sro.whatsapp.net Sending POST request to /v2/sync/a Traceback (most recent call last): File "./yowsup-cli", line 302, in result = wsync.send() File "/root/teste/yowsup/src/Yowsup/Contacts/contacts.py", line 47, in send auth = self.authReq.send() File "/root/teste/yowsup/src/Yowsup/Common/Http/warequest.py", line 98, in send return self.sendPostRequest(parser) File "/root/teste/yowsup/src/Yowsup/Common/Http/warequest.py", line 161, in sendPostRequest self.response = WARequest.sendRequest(host, port, path, headers, params, "POST") File "/root/teste/yowsup/src/Yowsup/Common/Http/warequest.py", line 194, in sendRequest conn.request(reqType, path, params, headers); File "/usr/lib64/python2.6/httplib.py", line 914, in request self._send_request(method, url, body, headers) File "/usr/lib64/python2.6/httplib.py", line 951, in _send_request self.endheaders() File "/usr/lib64/python2.6/httplib.py", line 908, in endheaders self._send_output() File "/usr/lib64/python2.6/httplib.py", line 780, in _send_output self.send(msg) File "/usr/lib64/python2.6/httplib.py", line 739, in send self.connect() File "/usr/lib64/python2.6/httplib.py", line 1112, in connect sock = socket.create_connection((self.host, self.port), self.timeout) File "/usr/lib64/python2.6/socket.py", line 567, in create_connection raise error, msg socket.error: [Errno 110] Connection timed out

douglasfsti avatar Mar 26 '14 18:03 douglasfsti

Happens the same to me. Any clues?

chelorossi avatar Mar 28 '14 04:03 chelorossi

Looks like yowsup is still using the old contact sync.

shirioko avatar Mar 28 '14 09:03 shirioko

then..? Btw, thanks for all your work, it's great!

ikerfp avatar Mar 29 '14 17:03 ikerfp

Then switch to the WAUTH2 branch and port the SendSync method from WhatsAPI

shirioko avatar Mar 29 '14 22:03 shirioko

Hi shirioko, Thank you for all your work, time and input. Highly appreciated. I would be really grateful if you could let me know the procedure/command to switch to WAUTH2 branch and port the SendSync method from WhatsApi. Being a complete noob to Git, this instruction is proving to be very difficult for me and google is not being much of a help. I hope you would spare some of your precious time and provide a solution to this dilemma. Thanks.

devaj68 avatar Apr 08 '14 07:04 devaj68

Switch branch and download ZIP: yowsup

SendSync in WhatsAPI: https://github.com/venomous0x/WhatsAPI/blob/master/src/php/whatsprot.class.php#L1608

Output should be like this:

<iq to="[email protected]" type="get" id="sendsync_12432531"xmlns="urn:xmpp:whatsapp:sync">
    <sync mode="delta" context="interactive" sid="2344123532432" index="0" last="true">
        <user>+phoneNumber1</user>
        <user>+phoneNumber2</user>
        etc.
    </sync>
</iq>

shirioko avatar Apr 08 '14 08:04 shirioko

Wow, thank you for replying. I expected to be shredded to bits by you for asking such a noobie question. Now to figure out the part of porting the SendSync method from php to python in order to use it with yowsup. Anything I should look out for, any pointers would be greatly appreciated. Thank you once again.

devaj68 avatar Apr 08 '14 10:04 devaj68

@devaj68 Im currently trying to do the same thing. If by change you get it working, share it :D

aleperno avatar Apr 11 '14 05:04 aleperno

Any solution to use sync contacts ? Thank you

Marcorele avatar May 28 '14 21:05 Marcorele

no solution, you should code it yourself and share to users

CODeRUS avatar May 29 '14 06:05 CODeRUS

@CODeRUs port SendSync method from WhatsAPI is not so easy. Yowsup without sync method is not useful, some updates are made for WhatsAPI, nothing for Yowsup...it's a pain; as you can see, many users are trying using sync with Yowsup...

Marcorele avatar Jun 13 '14 22:06 Marcorele

Is there any update for sync contact number using yowsup ? I

kulbhushansharma avatar Jun 20 '14 10:06 kulbhushansharma

Nope https://github.com/shirioko/WhatsApiNet-SyncUtil

shirioko avatar Jun 20 '14 13:06 shirioko

I haven't password on my account. SyncUtil requires password in anyway?

hooddy avatar Jun 21 '14 14:06 hooddy

The problem is known, yowsup using old sync contact method, you can use new WA contact sync method that found in WhatsApi. Currently I'm using my own hack. I'm add this code to CmdClient.

    def sendSync(self, contacts):
        command = 'cd ' + Config.WHATSAPI_PATH + ' && php wacsync.php %s' % (contacts)
        cmmnd = subprocess.Popen(command, stdout=subprocess.PIPE, stderr=subprocess.PIPE, shell=True)
        output, error = cmmnd.communicate()
        print output
        print error

The main concept is execute contact sync using php file from WhatsAPI.

ardianys avatar Jul 12 '14 07:07 ardianys

Dear brainiacs can you just fix Yowsup for sync?

hooddy avatar Jul 12 '14 07:07 hooddy

As said above, you have to code it yourself.

mgp25 avatar Jul 12 '14 23:07 mgp25