[X2Go-Commits] pyhoca-gui.git - build-59a18b6e3b5d3f1dd8f07f26433d37fe5984a57d (branch) updated: 3709ceac2e9a269cd6139031ddae5ea25420c367

X2Go dev team git-admin at x2go.org
Tue Aug 27 13:20:40 CEST 2013


The branch, build-59a18b6e3b5d3f1dd8f07f26433d37fe5984a57d has been updated
       via  3709ceac2e9a269cd6139031ddae5ea25420c367 (commit)
      from  ad90e137cd0d485e0cbd647140c825c95ce1cab7 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
-----------------------------------------------------------------------

Summary of changes:
 pyhoca/wxgui/frontend.py |    5 +++++
 pyhoca/wxgui/logon.py    |   15 +++++++++++++--
 pyhoca/wxgui/notify.py   |    1 +
 3 files changed, 19 insertions(+), 2 deletions(-)

The diff of changes is:
diff --git a/pyhoca/wxgui/frontend.py b/pyhoca/wxgui/frontend.py
index b43c706..b72aeee 100644
--- a/pyhoca/wxgui/frontend.py
+++ b/pyhoca/wxgui/frontend.py
@@ -260,6 +260,11 @@ class PyHocaGUI(wx.App, x2go.X2goClient):
         except x2go.AuthenticationException:
             _logon_window = logon.PyHocaGUI_DialogBoxPassword(self, self.current_profile_name, caller=self )
             self._sub_windows.append(_logon_window)
+        except gevent.dns.DNSError, e:
+            self.notifier.send('%s - connect error' % self.current_profile_name, '%s!' % e.strerror, icon='auth_error', timeout=4000)
+        except gevent.socket.error, e:
+            self.notifier.send('%s - connect error' % self.current_profile_name, '%s!' % e.strerror, icon='auth_error', timeout=4000)
+
         if self._X2goClient__is_session_connected(session_uuid):
             self.notifier.send('%s - connect' % self.current_profile_name, 'Public SSH key authentication has been successful.', icon='auth_success', timeout=4000)
         else:
diff --git a/pyhoca/wxgui/logon.py b/pyhoca/wxgui/logon.py
index b78bc06..b373985 100644
--- a/pyhoca/wxgui/logon.py
+++ b/pyhoca/wxgui/logon.py
@@ -161,10 +161,8 @@ class PyHocaGUI_DialogBoxPassword(wx.Dialog):
         username = self.userTxt.GetValue()
         password = self.passwordTxt.GetValue()
         if len(username) == 0:
-            #Message(self,1)
             return
         if len(password) == 0:
-            #Message(self,2)
             return
 
         session_uuid = self._PyHocaGUI._X2goClient__client_registered_sessions_of_name(self.current_profile_name)[0].get_uuid()
@@ -182,6 +180,19 @@ class PyHocaGUI_DialogBoxPassword(wx.Dialog):
                                              text='Authentication failed!',
                                              icon='auth_failed')
 
+        except gevent.dns.DNSError, e:
+            self._PyHocaGUI.notifier.prepare('AUTH_%s' % self.current_profile_name, 
+                                             title='%s - connect error' % self.current_profile_name, 
+                                             text='%s!' % e.strerror,
+                                             icon='auth_error')
+
+        except gevent.socket.error, e:
+            self._PyHocaGUI.notifier.prepare('AUTH_%s' % self.current_profile_name, 
+                                             title='%s - connect error' % self.current_profile_name, 
+                                             text='%s!' % e.strerror,
+                                             icon='auth_error')
+
+
         self._PyHocaGUI.notifier.send(self.current_profile_name, context='AUTH_%s' % self.current_profile_name, timeout=4000)
         self.Destroy()
 
diff --git a/pyhoca/wxgui/notify.py b/pyhoca/wxgui/notify.py
index 4be571c..55f3787 100644
--- a/pyhoca/wxgui/notify.py
+++ b/pyhoca/wxgui/notify.py
@@ -40,6 +40,7 @@ class libnotify_NotifierPopup(object):
 
     icon_hash = { 'auth_success': 'from-gtk/32x32/dialog-apply.png',
                   'auth_failed': 'from-gtk/32x32/dialog-warning.png',
+                  'auth_error': 'from-gtk/32x32/dialog-error.png',
                   'auth_disconnect': 'from-gtk/32x32/network-wired.png',
                   'session_start': 'from-x2go/32x32/x2go.png',
                   'session_resume': 'from-x2go/32x32/x2go.png',


hooks/post-receive
-- 
pyhoca-gui.git (Python X2Go Client (wxPython GUI))

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "pyhoca-gui.git" (Python X2Go Client (wxPython GUI)).




More information about the x2go-commits mailing list