This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch master in repository x2gobroker. commit b8db201abdfb1b8bf2e15a2c747ee63c78e99599 Author: Mike Gabriel <mike.gabriel@das-netzwerkteam.de> Date: Fri Mar 27 10:18:01 2015 +0100 agent.py: Make agent query mode LOCAL behave similar to agent query mode SSH if things go wrong. --- debian/changelog | 2 ++ x2gobroker/agent.py | 6 ++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index 08c7622..6ad6066 100644 --- a/debian/changelog +++ b/debian/changelog @@ -247,6 +247,8 @@ x2gobroker (0.0.3.0-0x2go1) UNRELEASED; urgency=low - agent.py: Allow providing a custom logger instance in all functions. - LoadChecker.loadchecker(): Use load checker daemon's logger instance for logging actions taken place in agent.py. + - agent.py: Make agent query mode LOCAL behave similar to agent query mode + SSH if things go wrong. * debian/control: + Provide separate bin:package for SSH brokerage: x2gobroker-ssh. + Replace LDAP support with session brokerage support in LONG_DESCRIPTION. diff --git a/x2gobroker/agent.py b/x2gobroker/agent.py index 19b0c73..15486bf 100644 --- a/x2gobroker/agent.py +++ b/x2gobroker/agent.py @@ -144,12 +144,14 @@ def _call_local_broker_agent(username, task, cmdline_args=[], logger=None): result = agent_process.stdout.read().split('\n') except OSError: - pass + result = None if result: logger.info('Broker agent answered: {answer}'.format(answer="; ".join(result))) - if result[0].startswith('OK'): + if result and result[0].startswith('OK'): return (True, [ r for r in result[1:] if r ]) + else: + return (False, []) raise x2gobroker.x2gobroker_exceptions.X2GoBrokerAgentException('Query to local X2Go Broker Agent failed with no response') -- Alioth's /srv/git/code.x2go.org/x2gobroker.git//..//_hooks_/post-receive-email on /srv/git/code.x2go.org/x2gobroker.git