From 8facc6c42b2da7c351e0421e74e1d520af6f5699 Mon Sep 17 00:00:00 2001 From: greg Date: Fri, 8 Sep 2006 08:46:56 +0000 Subject: [PATCH] get userpic data git-svn-id: file:///home/svn/ljdump/trunk@17 7994a137-d0a5-da11-ade6-0050bffea3d9 --- ljdump.py | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/ljdump.py b/ljdump.py index 066f976..2df93f3 100755 --- a/ljdump.py +++ b/ljdump.py @@ -156,6 +156,15 @@ except: pass origlastsync = lastsync +r = server.LJ.XMLRPC.login(dochallenge({ + 'username': Username, + 'ver': 1, + 'getpickws': 1, + 'getpickwurls': 1, +}, Password)) +userpics = dict(zip(r['pickws'], r['pickwurls'])) +userpics['*'] = r['defaultpicurl'] + while True: r = server.LJ.XMLRPC.syncitems(dochallenge({ 'username': Username, @@ -247,6 +256,14 @@ f = open("%s/user.map" % Username, "w") pickle.dump(usermap, f) f.close() +f = open("%s/userpics.xml" % Username, "w") +print >>f, """""" +print >>f, "" +for p in userpics: + print >>f, """""" % (p, userpics[p]) +print >>f, "" +f.close() + newmaxid = maxid maxid = lastmaxid while True: -- 2.39.5