@@ -0,0 +1,1132 @@
+#!/usr/bin/env python%0A%0A%22%22%22%0AOne-off script to import data when the web UI fails. To use it place this file in /opt/panda, copy your data file to /var/lib/panda/uploads/ and then run:%0A    $ manual_import.py filename.csv user@email.com%0A%0ADataset name, description etc are set to defaults. Change them in the web UI.%0A%22%22%22%0A%0Aimport os%0Aimport sys%0A%0Afrom django.core.management import setup_environ%0Afrom config import settings%0Asetup_environ(settings)%0A%0Afrom panda.models import Dataset, DataUpload, UserProxy%0A%0Adef main():%0A    filename = sys.argv%5B1%5D%0A    email = sys.argv%5B2%5D%0A%0A    path = os.path.join(settings.MEDIA_ROOT, filename)%0A    size = os.path.getsize(path)%0A    creator = UserProxy.objects.get(email=email)%0A%0A    upload = DataUpload.objects.create(%0A        filename=filename,%0A        original_filename=filename,%0A        size=size,%0A        creator=creator,%0A        dataset=None,%0A        encoding='utf-8')%0A %0A    dataset = Dataset.objects.create(%0A        name=filename,%0A        creator=creator,%0A        initial_upload=upload)%0A%0A    dataset.import_data(creator, upload)%0A    %0A    dataset.update_full_text()%0A%0Aif __name__ == '__main__':%0A    main()%0A%0A

Add manual upload script.