def parse(exc):
    """Takes in an exception and returns the boto
    `Message, Code` properties if they exist - else `None, None`
    """
    if exc is not None and hasattr(exc, 'response'
        ) and exc.response is not None:
        error = exc.response.get('Error', {})
        code = error.get('Code', None)
        message = error.get('Message', None)
        return message, code
    return None, None
