Sasidhar commited on
Commit
097fda5
·
1 Parent(s): 663d314

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -40,11 +40,11 @@ if st.button("Run Workflow"):
40
  # Export workflow configuration as YAML or JSON
41
  export_format = st.radio("Export Format", ["YAML", "JSON"])
42
 
43
- with open("workflow_config.yaml", "w") as yaml_file:
44
- yaml.dump(workflow_config, yaml_file)
45
 
46
- with open("workflow_config.yaml", "w") as yaml_file:
47
- st.download_button("Export Config",yaml_file)
48
 
49
  # if st.download_button("Export Workflow"):
50
  # if export_format == "YAML":
 
40
  # Export workflow configuration as YAML or JSON
41
  export_format = st.radio("Export Format", ["YAML", "JSON"])
42
 
43
+ with open("workflow_config.json", "w") as json_file:
44
+ json.dump(workflow_config, json_file, indent=4)
45
 
46
+ with open("workflow_config.json", "w") as json_file:
47
+ st.download_button("Export Config",json_file)
48
 
49
  # if st.download_button("Export Workflow"):
50
  # if export_format == "YAML":