diff --git a/frappy_psi/sea.py b/frappy_psi/sea.py index 45a0f47..6922fad 100644 --- a/frappy_psi/sea.py +++ b/frappy_psi/sea.py @@ -182,10 +182,10 @@ class SeaClient(ProxyClient, Module): assert self.syncio.readline() == b'OK' self.syncio.writeline(b'seauser seaser') assert self.syncio.readline() == b'Login OK' - - result = self.raw_request('frappy_config %s %s' % (self.service, self.config)) - if result.startswith('ERROR:'): - raise CommunicationFailedError(f'reply from frappy_config: {result}') + if self.service and self.config: + result = self.raw_request('frappy_config %s %s' % (self.service, self.config)) + if result.startswith('ERROR:'): + raise CommunicationFailedError(f'reply from frappy_config: {result}') # frappy_async_client switches to the json protocol (better for updates) self.asynio.writeline(b'frappy_async_client') self.asynio.writeline(('get_all_param ' + ' '.join(self.objects)).encode())