歡迎來到Linux教程網
Linux教程網
Linux教程網
Linux教程網
Linux教程網 >> Linux基礎 >> Linux教程 >> 解決Ubuntu 10.04上MSN登錄時遇到的“network error”問題

解決Ubuntu 10.04上MSN登錄時遇到的“network error”問題

日期:2017/2/28 16:30:43   编辑:Linux教程

原來一直使用的是Debian,使用Ubuntu 10.04後,發現pidgin被換成了empathy,連接msn有時會提示“network error”,重啟empathy也不行,剛開始以為是msn服務器有問題,結果等了兩天還是不行,最後在網上搜到了解決方法,分享一下:

killall telepathy-butterfly
然後重啟empathy(或者重新連接msn賬戶)!

Empathy是個托,python-papyon是個python實現的msn庫,telepathy-butterfly是個完成msn功能的python客戶端。

原文解釋如下:
telepathy-butterfly is the MSN connection manager for telepathy.
Telepathy is a flexible, modular communications framework that enables real-time communication via pluggable protocol backends.
Empathy uses Telepathy for protocol support and has a user interface based on Gossip.

關於ubuntu 10.04 LTS版本下的Empathy MSN群聊顯示昵稱方法,可以參考下面的文章:

1.關系普及
Empathy是個托,python-papyon是個python實現的msn庫,telepathy-butterfly是個完成msn功能的python客戶端。

2.修改辦法
sudo vim /usr/share/pyshared/papyon/conversation.py
查找 if message_type == 這個字符串
找到內容為:

代碼:
if message_type == ‘text/plain’:
msg = ConversationMessage(unicode(message.body, message_encoding),
TextFormat.parse(message_formatting),
self.__last_received_msn_objects)
try:
display_name = message.get_header(’P4-Context’)


將if判斷後try之前中間定義msg這一堆內容修改為如下:

代碼:
try:
msg = ConversationMessage(unicode(”["+message.get_header('P4-Context')+"]“+message.body, message_encoding),
TextFormat.parse(message_formatting),
self.__last_received_msn_objects)
except KeyError:
msg = ConversationMessage(unicode(message.body, message_encoding),
TextFormat.parse(message_formatting),
self.__last_received_msn_objects)

保存後重新啟動empathy,msn群裡就能顯示昵稱鳥。

Copyright © Linux教程網 All Rights Reserved