def newset_export_for(xform, export_type):
    return Export.objects.filter(xform=xform, export_type=export_type)\
        .latest('created_on')
Make sure you check that an export exists before calling this,
dataset/ETHPy150Open kobotoolbox/kobocat/onadata/libs/utils/export_tools.py/newset_export_for