<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments for Non-Trivial House</title>
	<atom:link href="http://eblog.cybersnoopy.com/comments/feed/" rel="self" type="application/rss+xml" />
	<link>http://eblog.cybersnoopy.com</link>
	<description>Learn to labor &#38; to wait</description>
	<lastBuildDate>Sun, 05 Feb 2012 05:38:12 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>Comment on Sina weibo direct message export script by 新浪围脖私信导出脚本 - 剽悍牛仔的领地</title>
		<link>http://eblog.cybersnoopy.com/2012/02/04/sina-weibo-direct-message-export-script/comment-page-1/#comment-1509</link>
		<dc:creator>新浪围脖私信导出脚本 - 剽悍牛仔的领地</dc:creator>
		<pubDate>Sun, 05 Feb 2012 05:38:12 +0000</pubDate>
		<guid isPermaLink="false">http://eblog.cybersnoopy.com/?p=18#comment-1509</guid>
		<description>[...] 最近因为需要写了一个山寨的围脖私信导出脚本。Run了一个小时，导出了近两万条私信，效果还算可以。Google一下网上没人贴这种工具，所以野人献曝一下。具体的技术细节放在英文的blog上。测试环境是Ubuntu 11.11，需要用pip安装selenium，然后再去Chromium的页面下载Chrome的WebDriver binary。 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 # -*- coding: utf-8 –*- # A sina weibo DM export tool from selenium import webdriver from selenium.common.exceptions import TimeoutException from selenium.webdriver.support.ui import WebDriverWait # available since 2.4.0 import time import codecs &#160; f = codecs.open&#040;&#039;weibo.txt&#039;, encoding=&#039;utf-8&#039;, mode=&#039;w+&#039;&#041; &#160; # Create a new instance of the Chrome driver = webdriver.Chrome&#040;&#041; # Set 15 sec as default timeout (maximum waiting time if something can&#039;t be found) driver.implicitly_wait&#040;15&#041; # go to the direct message history page (for DM with one user) driver.get&#040;&quot;http://weibo.com/message/history?uid=xxxxxxxxxx&quot;&#041; &#160; # Find loginname input box loginnameInput = driver.find_element_by_id&#040;&quot;loginname&quot;&#041; loginnameInput.send_keys&#040;&quot;me@mydomain.com&quot;&#041; # Find password input box passwdInput = driver.find_element_by_id&#040;&quot;password&quot;&#041; passwdInput.send_keys&#040;&quot;mypasswd&quot;&#041; # Find the submit button submitButton = driver.find_element_by_id&#040;&quot;login_submit_btn&quot;&#041; # Submit submitButton.click&#040;&#041; &#160; n = 1 more = 1 while more:&lt;p&gt; # Find message box messages = driver.find_elements_by_class_name&#040;&quot;txt&quot;&#041;&lt;/p&gt;&lt;p&gt; # Find time tag box ts = driver.find_elements_by_css_selector&#040;&quot;em.W_textb.date&quot;&#041; f.write&#040;ts&#091;-1&#093;.text + &quot;n&quot;&#041; for msg in reversed&#040;messages&#041;: if &#040;msg.text != &#039;&#039;&#041;: f.write&#040;msg.text + &quot;n&quot;&#041; f.flush&#040;&#041; buttons = driver.find_elements_by_class_name&#040;&quot;W_btn_a&quot;&#041; more = 0 for button in buttons: # Next page or previous page if button.text == u&#039;上一页&#039;: more = 1 break if more: n += 1 print &#039;Page %d&#039; % n button.click&#040;&#041; time.sleep&#040;2&#041; f.close&#040;&#041; print &#039;All Done!&#039; driver.quit&#040;&#041;&lt;/p&gt; [...]</description>
		<content:encoded><![CDATA[<p>[...] 最近因为需要写了一个山寨的围脖私信导出脚本。Run了一个小时，导出了近两万条私信，效果还算可以。Google一下网上没人贴这种工具，所以野人献曝一下。具体的技术细节放在英文的blog上。测试环境是Ubuntu 11.11，需要用pip安装selenium，然后再去Chromium的页面下载Chrome的WebDriver binary。 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 # -*- coding: utf-8 –*- # A sina weibo DM export tool from selenium import webdriver from selenium.common.exceptions import TimeoutException from selenium.webdriver.support.ui import WebDriverWait # available since 2.4.0 import time import codecs &nbsp; f = codecs.open&#040;&#039;weibo.txt&#039;, encoding=&#039;utf-8&#039;, mode=&#039;w+&#039;&#041; &nbsp; # Create a new instance of the Chrome driver = webdriver.Chrome&#040;&#041; # Set 15 sec as default timeout (maximum waiting time if something can&#039;t be found) driver.implicitly_wait&#040;15&#041; # go to the direct message history page (for DM with one user) driver.get&#040;&quot;<a href="http://weibo.com/message/history?uid=xxxxxxxxxx&quot;&#038;#041" rel="nofollow">http://weibo.com/message/history?uid=xxxxxxxxxx&quot;&#038;#041</a>; &nbsp; # Find loginname input box loginnameInput = driver.find_element_by_id&#040;&quot;loginname&quot;&#041; loginnameInput.send_keys&#040;&quot;me@mydomain.com&quot;&#041; # Find password input box passwdInput = driver.find_element_by_id&#040;&quot;password&quot;&#041; passwdInput.send_keys&#040;&quot;mypasswd&quot;&#041; # Find the submit button submitButton = driver.find_element_by_id&#040;&quot;login_submit_btn&quot;&#041; # Submit submitButton.click&#040;&#041; &nbsp; n = 1 more = 1 while more:&lt;p&gt; # Find message box messages = driver.find_elements_by_class_name&#040;&quot;txt&quot;&#041;&lt;/p&gt;&lt;p&gt; # Find time tag box ts = driver.find_elements_by_css_selector&#040;&quot;em.W_textb.date&quot;&#041; f.write&#040;ts&#091;-1&#093;.text + &quot;n&quot;&#041; for msg in reversed&#040;messages&#041;: if &#040;msg.text != &#039;&#039;&#041;: f.write&#040;msg.text + &quot;n&quot;&#041; f.flush&#040;&#041; buttons = driver.find_elements_by_class_name&#040;&quot;W_btn_a&quot;&#041; more = 0 for button in buttons: # Next page or previous page if button.text == u&#039;上一页&#039;: more = 1 break if more: n += 1 print &#039;Page %d&#039; % n button.click&#040;&#041; time.sleep&#040;2&#041; f.close&#040;&#041; print &#039;All Done!&#039; driver.quit&#040;&#041;&lt;/p&gt; [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Have you ever kissed a girl? by loopmob</title>
		<link>http://eblog.cybersnoopy.com/2008/05/03/have-you-ever-kissed-a-girl/comment-page-1/#comment-1390</link>
		<dc:creator>loopmob</dc:creator>
		<pubDate>Thu, 03 Dec 2009 15:39:34 +0000</pubDate>
		<guid isPermaLink="false">http://eblog.cybersnoopy.com/?p=5#comment-1390</guid>
		<description>you just found a new daily reader</description>
		<content:encoded><![CDATA[<p>you just found a new daily reader</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Have you ever kissed a girl? by Rose</title>
		<link>http://eblog.cybersnoopy.com/2008/05/03/have-you-ever-kissed-a-girl/comment-page-1/#comment-1199</link>
		<dc:creator>Rose</dc:creator>
		<pubDate>Sun, 30 Aug 2009 22:52:40 +0000</pubDate>
		<guid isPermaLink="false">http://eblog.cybersnoopy.com/?p=5#comment-1199</guid>
		<description>Nice write up...usually I never reply to these thing but this time I will,Thanks for the great info.</description>
		<content:encoded><![CDATA[<p>Nice write up&#8230;usually I never reply to these thing but this time I will,Thanks for the great info.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Have you ever kissed a girl? by crimson</title>
		<link>http://eblog.cybersnoopy.com/2008/05/03/have-you-ever-kissed-a-girl/comment-page-1/#comment-1198</link>
		<dc:creator>crimson</dc:creator>
		<pubDate>Sun, 30 Aug 2009 15:57:43 +0000</pubDate>
		<guid isPermaLink="false">http://eblog.cybersnoopy.com/?p=5#comment-1198</guid>
		<description>But how many other companies have open sourced their everything? SUN is the only company doing that. IBM doesnt. MS doesnt. etc etc. During the buy of MySQL, MySQL wanted to close parts of their code, but SUN convinced MySQL to open everything. We should support companies switching from closed source to open source? Do we want more companies to switch to open source, or not?</description>
		<content:encoded><![CDATA[<p>But how many other companies have open sourced their everything? SUN is the only company doing that. IBM doesnt. MS doesnt. etc etc. During the buy of MySQL, MySQL wanted to close parts of their code, but SUN convinced MySQL to open everything. We should support companies switching from closed source to open source? Do we want more companies to switch to open source, or not?</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Have you ever kissed a girl? by joiseeestick</title>
		<link>http://eblog.cybersnoopy.com/2008/05/03/have-you-ever-kissed-a-girl/comment-page-1/#comment-88</link>
		<dc:creator>joiseeestick</dc:creator>
		<pubDate>Mon, 22 Sep 2008 02:19:57 +0000</pubDate>
		<guid isPermaLink="false">http://eblog.cybersnoopy.com/?p=5#comment-88</guid>
		<description>i am gonna show this to my friend, guy</description>
		<content:encoded><![CDATA[<p>i am gonna show this to my friend, guy</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Have you ever kissed a girl? by rliegh</title>
		<link>http://eblog.cybersnoopy.com/2008/05/03/have-you-ever-kissed-a-girl/comment-page-1/#comment-13</link>
		<dc:creator>rliegh</dc:creator>
		<pubDate>Sat, 21 Jun 2008 09:29:04 +0000</pubDate>
		<guid isPermaLink="false">http://eblog.cybersnoopy.com/?p=5#comment-13</guid>
		<description>This blog entry is old; but since no one else has answered you
Yes -it means exactly as you said. More precisely he&#039;s saying &quot;The only kind of person who would spend this much time thinking over a computer problem that they&#039;re not getting paid to solve is a zit-faced virgin nerd&quot; 
I can see the humor in it (12 years later) but I also get the brush-off too.

Take it easy!</description>
		<content:encoded><![CDATA[<p>This blog entry is old; but since no one else has answered you<br />
Yes -it means exactly as you said. More precisely he&#8217;s saying &#8220;The only kind of person who would spend this much time thinking over a computer problem that they&#8217;re not getting paid to solve is a zit-faced virgin nerd&#8221;<br />
I can see the humor in it (12 years later) but I also get the brush-off too.</p>
<p>Take it easy!</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Have you ever kissed a girl? by Snoopy</title>
		<link>http://eblog.cybersnoopy.com/2008/05/03/have-you-ever-kissed-a-girl/comment-page-1/#comment-6</link>
		<dc:creator>Snoopy</dc:creator>
		<pubDate>Wed, 07 May 2008 02:55:41 +0000</pubDate>
		<guid isPermaLink="false">http://eblog.cybersnoopy.com/?p=5#comment-6</guid>
		<description>@heavenshine,
this blog will purely be in English which won&#039;t bother readers like my parents.</description>
		<content:encoded><![CDATA[<p>@heavenshine,<br />
this blog will purely be in English which won&#8217;t bother readers like my parents.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Have you ever kissed a girl? by heavenshine</title>
		<link>http://eblog.cybersnoopy.com/2008/05/03/have-you-ever-kissed-a-girl/comment-page-1/#comment-5</link>
		<dc:creator>heavenshine</dc:creator>
		<pubDate>Wed, 07 May 2008 02:46:28 +0000</pubDate>
		<guid isPermaLink="false">http://eblog.cybersnoopy.com/?p=5#comment-5</guid>
		<description>I&#039;m really really confused by all your different blogsssssss= =#</description>
		<content:encoded><![CDATA[<p>I&#8217;m really really confused by all your different blogsssssss= =#</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Have you ever kissed a girl? by youbaji</title>
		<link>http://eblog.cybersnoopy.com/2008/05/03/have-you-ever-kissed-a-girl/comment-page-1/#comment-4</link>
		<dc:creator>youbaji</dc:creator>
		<pubDate>Sun, 04 May 2008 18:21:01 +0000</pubDate>
		<guid isPermaLink="false">http://eblog.cybersnoopy.com/?p=5#comment-4</guid>
		<description>板凳
+U+U</description>
		<content:encoded><![CDATA[<p>板凳<br />
+U+U</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Have you ever kissed a girl? by iCrazy</title>
		<link>http://eblog.cybersnoopy.com/2008/05/03/have-you-ever-kissed-a-girl/comment-page-1/#comment-3</link>
		<dc:creator>iCrazy</dc:creator>
		<pubDate>Sun, 04 May 2008 05:36:08 +0000</pubDate>
		<guid isPermaLink="false">http://eblog.cybersnoopy.com/?p=5#comment-3</guid>
		<description>沙发～
你居然参加了 SoC，赞啊～</description>
		<content:encoded><![CDATA[<p>沙发～<br />
你居然参加了 SoC，赞啊～</p>
]]></content:encoded>
	</item>
</channel>
</rss>

