addedd exception handeling for get_security_group

The get security group fails without the exception handeling