搞定gwibber

升级10.04之后,gwibber2.29开始使用pycurl来处理IO。结果一条更新都拿不下来,为此搜到很多相关、不相关的bug。最后终于自己找到问题,原来是pycurl.setopt方法传入字符串如果是unicode就会报typeerror。而通过gwibber配置界面输入的所有字符都是unicode编码,于是问题也就简单了。做个处理,在 /usr/lib/python2.6/dist-packages/gwibber/microblog/network.py 第18到21行:

    self.curl.setopt(pycurl.URL, str(url).encode('ascii'))

    if username and password:
      self.curl.setopt(pycurl.USERPWD, ("%s:%s" % (username, password)).encode('ascii'))

另外,使用StatusNet的Twitter兼容API来做Twitter API代理,需要把代理的目录名设置为api,因为/api这个路径是写死在gwibber代码里的。通过界面输入的,只是代理的domain。

说实在的gwibber还是挺烂的。

https://bugs.launchpad.net/bugs/542501

https://bugs.launchpad.net/bugs/543860

3 thoughts on “搞定gwibber

  1. Pingback: Tweets that mention 搞定gwibber | Here Comes The Sun -- Topsy.com

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>