Hello.
I have old question in a bit different form.
Description:
MSN requires users to have auth before sending messages.
I.e. I can't just send message to some random user [EMAIL PROTECTED]
First I should send <presence type='subscribe' to='[EMAIL PROTECTED]'/>, 
wait for user to authorise me and send only then.
This works not so stable but still usable when used personally.
Though when it comes to writing automated program this unreliability becomes a 
problem.
F.e.: I need to write script that will randomly chat with thousands of 
different MSN contacts (not spim - it will be dialogs for several minutes 
each). To not clobber jabber's and MSN's rosters I choosed to do the 
following:
1) send "subscribe"
2) wait for "subscribed"
3) chat
4) remove item from roster
That way appeared to be not good because of two problems:
a) chatting with same contact lately becomes a problem - it seems that step 
(4) sets the user as "blocked" but step (1) not removes the block
b) Typing notifications _from_ MSN not work. The interesting thing is if we 
stop script somewhere in step (3) then on next start it sees contact as 
online and TN starting to work.

Question:
If there is some recipe to achieve my task?
I'l shortly reevaluate:
I need the reliable (doh!) way to chat with MSN contact using TNs and not 
keeping this contact constantly in roster.
-- 
Respectfully
Alexey Nezhdanov
From [EMAIL PROTECTED]  Thu Apr 27 17:39:07 2006
From: [EMAIL PROTECTED] (Alexey Nezhdanov)
Date: Thu Apr 27 17:39:15 2006
Subject: [py-transports] MSN's TN
Message-ID: <[EMAIL PROTECTED]>

Hello.
Thank you for your transport.
After some trickery with pyMSN-t I finally found something that really not 
works correctly for me:
If contact A (pyMSN-t) asks for auth, contact B (gaim, f.e.) authorises it and 
asks for auth too and contact A(pyMSN-t) authorises it - then both parties 
beginning to see each other. But Typing Nofifications not work at this 
moment.
If contactg A (pyMSN-t) will go offline and online - then all becoming fine, 
TNs work both directions. But not on first time.
Can you please fix this bug or point me to the place where I should dig myself 
(in transport).
I really need TN working immidiatedly after auth because I'm targeting at MSN 
relaying for random visitors that may never return anymore.

Thank you for your time.

-- 
Respectfully
Alexey Nezhdanov
From [EMAIL PROTECTED]  Thu Apr 27 18:47:24 2006
From: [EMAIL PROTECTED] (Maarten Fonville)
Date: Thu Apr 27 18:48:11 2006
Subject: [py-transports] PyMSNt Fullname for MSN nickname
Message-ID: <[EMAIL PROTECTED]>

I thought that the nickname for Google Talk PyMSNt users should be
fetched correctly from the Fullname field of the vCard, but with the
latter revisions I found out that this doesn't work correctly, the code
which is involved is from session.py:

> name = ""
>                         for e in vCard.elements():
>                                 if e.name == "NICKNAME":
>                                         name = e.__str__()
>                                 if not name and e.name == "FN":
>                                         # Give priority to nickname
>                                         name = e.__str__()


I suspect that the problem could be that the nickname field has been
send after the fullname field and so the name will be empty(!) and so
the updateNickName method will use the JID user part for nickname.

James, could you please fix this, I suspect that putting an "not name
and " part before the NICKNAME 'if' will do the trick

Maarten

Reply via email to