diff --git a/src/streamlit_app.py b/src/streamlit_app.py index 7b4fbda..1d61fc3 100644 --- a/src/streamlit_app.py +++ b/src/streamlit_app.py @@ -310,7 +310,7 @@ def trading_journal_page(): update_trade(trade_id, updates) st.success("Trade updated successfully!") - st.experimental_rerun() + st.experimental_set_query_params(rerun=True) except Exception as e: st.error(f"Error updating trade: {str(e)}") else: @@ -723,7 +723,7 @@ def trading_system_page(): try: update_portfolio_value(new_value, new_cash, notes) st.success("Portfolio value updated successfully!") - st.experimental_rerun() + st.experimental_set_query_params(rerun=True) except Exception as e: st.error(f"Error updating portfolio value: {str(e)}") @@ -966,7 +966,7 @@ def trading_plan_page(): save_trading_plan(plan) st.success("Trading plan created successfully!") - st.experimental_rerun() + st.experimental_set_query_params(rerun=True) except Exception as e: st.error(f"Error creating trading plan: {str(e)}") @@ -997,7 +997,7 @@ def trading_plan_page(): plan.status = PlanStatus(status) update_trading_plan(plan) st.success("Plan updated successfully!") - st.experimental_rerun() + st.experimental_set_query_params(rerun=True) except Exception as e: st.error(f"Error updating plan: {str(e)}") else: