Revision 43ee6ae1 kamaki/cli/commands/astakos_cli.py

b/kamaki/cli/commands/astakos_cli.py
32 32
# or implied, of GRNET S.A.command
33 33

  
34 34
from kamaki.cli import command
35
from kamaki.clients.astakos import AstakosClient, ClientError
35
from kamaki.clients.astakos import AstakosClient
36 36
from kamaki.cli.utils import print_dict
37 37
from kamaki.cli.errors import raiseCLIError
38 38
from kamaki.cli.commands import _command_init
......
49 49
        base_url = self.config.get('astakos', 'url')\
50 50
            or self.config.get('global', 'url')
51 51
        if base_url is None:
52
            raise ClientError('no URL for astakos')
52
            raiseCLIError(None, 'Missing astakos server URL')
53 53
        self.client = AstakosClient(base_url=base_url, token=token)
54 54

  
55 55

  
......
61 61
        super(self.__class__, self).main()
62 62
        try:
63 63
            reply = self.client.authenticate(custom_token)
64
        except ClientError as err:
64
        except Exception as err:
65 65
            raiseCLIError(err)
66 66
        print_dict(reply)

Also available in: Unified diff