def get_spot_pricing(region, zone, instance_type):
    client = boto3.client('ec2', region_name=region)
    prod_desc = ['Linux/UNIX (Amazon VPC)']
    spot_price = client.describe_spot_price_history(InstanceTypes=[instance_type], MaxResults=1, ProductDescriptions=prod_desc, AvailabilityZone=zone)
    if (len(spot_price['SpotPriceHistory']) == 0):
        raise YBOpsRuntimeError('Invalid instance type {} for zone {}'.format(instance_type, zone))
    return spot_price['SpotPriceHistory'][0]['SpotPrice']
def get_spot_pricing(region, zone, instance_type):
    client = boto3.client('ec2', region_name=region)
    prod_desc = ['Linux/UNIX (Amazon VPC)']
    spot_price = client.describe_spot_price_history(InstanceTypes=[instance_type], MaxResults=1, ProductDescriptions=prod_desc, AvailabilityZone=zone)
    if (len(spot_price['SpotPriceHistory']) == 0):
        raise YBOpsRuntimeError('Invalid instance type {} for zone {}'.format(instance_type, zone))
    return spot_price['SpotPriceHistory'][0]['SpotPrice']