def create_dataset(request):
    user = authorize(request)

    title = request.REQUEST.get('title','Untitled dataset')
    srid = int(request.REQUEST.get('srid', 4326))
    geometry_type=request.REQUEST.get('geometry_type', 'GEOMETRY')
    columns_definitions=json.loads(request.REQUEST.get('columns_definitions', "{}"))
    columns_definitions=((key, value) for key, value in columns_definitions.items())

    if request.REQUEST in 'parent':
        parent = Page.objects.get(slug=request.REQUEST['parent'])
        authorize(request, parent, add=True)
    else:
        parent = get_data_page_for_user(request.user)

    ds = SpatialiteDriver.create_dataset(
        title=title,
        parent=parent,
        srid=srid,
        geometry_type=geometry_type,
        columns_definitions=columns_definitions,
        owner=request.user
    )

    dispatch.api_accessed.send(sender=DataResource, instance=ds, user=user)
    dispatch.dataset_created.send(sender=DataResource, instance=ds, user=user)
    return json_or_jsonp(request, {'path' : ds.slug }, code=201)
dataset/ETHPy150Open hydroshare/hydroshare2/ga_resources/views/rest_data.py/create_dataset/swapped operands of `in`