def present(name, cidr_block, instance_tenancy=None, dns_support=None,
            dns_hostnames=None, tags=None, region=None, key=None, keyid=None,
            profile=None):
    ret = {'name': name,
           'result': True,
           'comment': '',
           'changes': {}
           }

    r = __salt__['boto_vpc.exists'](name=name, tags=tags, region=region,
                                    key=key, keyid=keyid, profile=profile)

    if 'error' in r:
        ret['result'] = False
        ret['comment'] = 'Failed to create VPC: {0}.'.format(r['error']['message'])
        return ret

    if not r.get('exists'):
        if __opts__['test']:
            ret['comment'] = 'VPC {0} is set to be created.'.format(name)
            ret['result'] = None
            return ret
        r = __salt__['boto_vpc.create'](cidr_block, instance_tenancy=instance_tenancy, vpc_name=name,
                                        enable_dns_support=dns_support, enable_dns_hostnames=dns_hostnames,
                                        tags=tags, region=region, key=key, keyid=keyid,
                                        profile=profile)
        if not r.get('created'):
            ret['result'] = False
            ret['comment'] = 'Failed to create VPC: {0}.'.format(r['error']['message'])
            return ret
        _describe = __salt__['boto_vpc.describe'](vpc_id=r['id'], region=region, key=key,
                                                  keyid=keyid, profile=profile)
        ret['changes']['old'] = {'vpc': None}
        ret['changes']['new'] = _describe
        ret['comment'] = 'VPC {0} created.'.format(name)
        return ret
    ret['comment'] = 'VPC present.'
    return ret
Parameters
dataset/ETHPy150Open saltstack/salt/salt/states/boto_vpc.py/present--crossover with--dataset/ETHPy150Open Axelrod-Python/Axelrod/axelrod/strategies/axelrod_first.py/Joss.__init__