From 5bc89e00b70cd0f320ca54553b48d64f355aa77a Mon Sep 17 00:00:00 2001 From: JRZ141 <2022080903015@std.uestc.edu.cn> Date: Tue, 14 Jan 2025 12:06:20 +0800 Subject: [PATCH] Fix Streamlit Error streamlit.errors, Streamlit set_page_config() can only be called once per app page, and must be called as the first Streamlit command in your script --- apps/dataset-viewer/app.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/apps/dataset-viewer/app.py b/apps/dataset-viewer/app.py index 6285e018..591d7d87 100644 --- a/apps/dataset-viewer/app.py +++ b/apps/dataset-viewer/app.py @@ -10,6 +10,8 @@ from cot import Collection import yaml +st.set_page_config(page_title="ThoughtSource⚡", layout="wide") + with open(os.path.join(os.path.dirname(os.path.abspath(__file__)), 'config.yml'), 'r') as file: config = yaml.safe_load(file) @@ -156,7 +158,7 @@ def display_dataset(dataset): def run_app(): - st.set_page_config(page_title="ThoughtSource⚡", layout="wide") + # st.title('ThoughtSource⚡ Viewer')