interactive
interactive copied to clipboard
Cell collapsed state not persisted
Describe the bug
The collapsed state of cell input/output is not saved with the notebook to disk.
- Create a new notebook in VS Code insiders - enter and evaluate a cell
- From the cell context menu (see screenshot) select Collapse Cell Input - observe the input is collapsed.
- Save the notebook to disk and close it
- Load the notebook - observe the cell input is visible again.
This may be caused by the toVsCodeNotebookCellData function in the DotNetInteractiveNotebookContentProvider class, where the metadata field is always set to an empty object. This implies that other metadata is not persisted correctly, but I have not confirmed this.
Please complete the following:
Which version of .NET Interactive are you using? 1.0.160901+a5db2e2c034eb03ecb446220826ca6aacaa4cb84
- OS
- [ x] Windows 10
- [ ] macOS
- [ ] Linux (Please specify distro)
- [ ] iOS
- [ ] Android
- Browser
- [ ] Chrome
- [ ] Edge
- [ ] Firefox
- [ ] Safari
- Frontend
- [ ] Jupyter Notebook
- [ ] Jupyter Lab
- [ ] nteract
- [x] Visual Studio Code
- [ ] Other (please specify)
Screenshots

We now save the collapse state for cells in VS Code.