solvebio-python
solvebio-python copied to clipboard
Ability to save a dataset template as a local file for future use
It would be nice to be able to save a template to a local JSON file for future use.
To save locally:
dataset_template = dataset.template()
with open('template.json', 'w') as fp:
json.dump(dataset_template, fp)
To save on SolveBio in the same folder:
import json
Object.get_or_create_by_full_path(dataset.full_path + '.template.json', object_type='file', contents=json.dumps(dataset.template()))