Welcome to the Streamlit community, and thanks for your detailed question! If a top-level secret like MARKETLAB_ENABLE_OIDC_PROBE = true is present in your app’s Secrets panel but missing from both st.secrets and os.environ at runtime, the most common causes are TOML formatting issues, type handling, or a platform-side caching/desync problem. Streamlit expects secrets in TOML format, and top-level keys should be accessible via both st.secrets[“MARKETLAB_ENABLE_OIDC_PROBE”] and os.environ[“MARKETLAB_ENABLE_OIDC_PROBE”] (as a string, not a boolean).