Skip to content
  • Iustin Pop's avatar
    Implement handling of luxi errors in cli.py · 03a8dbdc
    Iustin Pop authored
    Currently the generic handling of ganeti errors in cli.py (GenericMain
    and FormatError) only handles the core ganeti errors, and not the client
    protocol errors (which live in a separate hierarchy).
    
    This patch adds handling of luxi errors too, and also adds another luxi
    error for the case when the master is not running. This gives us a nice:
    
      gnta1:~# gnt-node list
      Cannot communicate with the master daemon.
      Is it running and listening on '/var/run/ganeti-master.sock'?
    
    error message instead of a traceback.
    
    Reviewed-by: amishchenko
    03a8dbdc