Migrating legacy notebooks to Workspaces¶
This topic describes how to move your legacy Snowflake Notebooks and dependent files to the Workspaces environment.
Migration steps¶
In the navigation menu, select Projects » Notebooks to open your legacy notebook.
Navigate to the Files section to view your
.ipynbnotebooks and any dependent files.Download all necessary files to your local machine.
In the navigation menu, select Projects » Workspaces.
Select a workspace.
Open an existing workspace or create a new one.
Choose a private workspace for individual use or a shared workspace if the notebooks need to be accessed by multiple users. For more information, see Workspaces.
Select + Add new.
Upload your downloaded files into the workspace.
Key differences between legacy and new notebooks¶
Note
Not all legacy notebook files will run successfully and may require updates to align with the new environment. The table below outlines the updates available in Notebooks in Workspaces.
Area |
Legacy notebooks |
New notebooks |
|---|---|---|
Compute |
Users must choose between Warehouse and Container Runtime. |
Simplified user experience with Container Runtime only.
|
File system / IDE environment |
Partially supported. |
Full IDE environment with:
|
Package management |
|
More flexible package management options:
|
Support for Streamlit |
Supported. |
Not supported. Use libraries such as |
Jupyter compatibility |
Some Jupyter magics are supported. |
Full support. Use Jupyter magics such as |
If you have questions about availability timelines for specific features, ask your account representative to contact the Notebooks product team.
Technical requirements and compatibility¶
Review the following constraints before running your notebooks in the new environment:
Python and Runtime: Workspaces support Python 3.10 to 3.12 and Container Runtime 2.2.
Note
Python 3.9 and Container Runtime 2.0 are not supported in Workspaces.
Compute types: Notebooks in Workspaces run on CPU or GPU compute types.
Visualizations: Streamlit is not supported. For data visualization, use Matplotlib, Seaborn, Plotly, or Altair.
Managing dependencies¶
Workspaces do not have integration support with the Snowflake Anaconda package repository. If your project requires packages not included in the pre-installed packages, you can install them using the following methods:
Interactive workflow: Use
pip installwithin the notebook. For more information, see Managing packages and runtime.Automated setup: Define your dependencies in a
requirements.txtfile. For detailed instructions, see Managing packages and runtime. For scheduled notebooks, specify the file using theREQUIREMENTS_FILEparameter in EXECUTE NOTEBOOK PROJECT.
Scheduled tasks¶
If you have tasks scheduled on your legacy notebooks, they will continue to run with legacy notebooks and are not impacted.
If you want existing tasks to use new notebooks, update your tasks to reference the new Notebook Project Object (NPO). For more information, see Run and schedule Notebooks in Workspaces.