Troubleshooting Streamlit in Snowflake¶
The following scenarios can help you troubleshoot issues that can occur when working with Streamlit in Snowflake.
You can’t connect to the Snowflake backend¶
In some cases, browser extensions can make local network access (LNA) requests as part of normal operation. For example, a security extension may detect Streamlit in Snowflake’s cross-origin traffic and then make an LNA request. Chrome 142 introduced mandatory LNA restrictions. Because you can’t configure LNA at the extension level, you must either disable the extension or allow LNA for Snowsight. For more information about Chrome’s LNA restrictions, see New permission prompt for Local Network Access in the Chrome for Developers blog.
Error | Unable to connect to the Snowflake backend. |
|---|---|
Cause | A browser extension attempted to make a local network access (LNA) request that was blocked by Chrome’s LNA restrictions. |
Solution | Disable the browser extension or allow LNA for Snowsight. |
Contact Snowflake support if the issue persists after performing the following steps:
Verify you’re on the latest Snowsight release.
Verify that the “Local network access” permission is enabled for Snowsight. If you use an enterprise managed browser, contact your IT administrator.
Verify that load failures continue after temporarily disabling extensions.
Verify that load failures continue after disabling the Chrome flag via
chrome://flags#local-network-access-check.
You can’t load the Streamlit app¶
Each Streamlit app running in Streamlit in Snowflake uses a unique subdomain.
Ensure that *.snowflake.app and *.snowflake.com are on the allowlist in your network (including content filtering systems), and can connect to Snowflake. When these domains are on the allowlist, your apps can communicate with Snowflake servers without any restrictions. However, in some cases adding these domains may not be sufficient due to network policies blocking subpaths under them. If this occurs, contact your network administrator.
In addition, to prevent any issues connecting to the Snowflake backend, ensure that WebSockets are not blocked in your network configuration.
Error | Could not reload streamlit files. Error: 092806 (P0002): The specified Streamlit was not found. |
|---|---|
Cause | The Snowflake WebSocket connection cannot reach the endpoint associated with the application. |
Solution | Add *.snowflake.app to the allowlist on the organization’s firewall configuration. |
You can’t see your data or change your database¶
You might not be able to see your data or change the database, warehouse, or role because Streamlit apps run with owner’s rights, which means that they run with the privileges of the owner, not the privileges of the caller. Streamlit apps use the database and schema that the Streamlit in Snowflake app was created in, not the database and schema that the caller is currently using.
For more information, see Understanding owner’s rights and Streamlit in Snowflake apps.
Streamlit library feature doesn’t work¶
Ensure that you use the Streamlit library version and a feature that are supported by Streamlit in Snowflake. For more information, see Supported versions of the Streamlit library and Unsupported Streamlit features.
To ask questions on features in the open-source Streamlit library, see Streamlit Community Forum.