Close the section and choose "No" when prompted to save changes.
Open the section: your "unsaved" edits are still there!
Yikes. The good news is that closing the project and reopening reverts to the correct, last-saved data in the underlying XML data file.
Already found the problem, which is described below for future reference:
When opening a section, we do a "preflight" open of the section to count its Section models so we can set the diagram to read-only if there are 2+ Sections. That section is then opened again in the DiagramController's open() method. This makes the reference count 2 for that section/container in AbstractProject. When the section is closed, the decremented reference count is 1 instead of 0, so the container is never set to null (see AbstractProject.closeContainer()). Thus the modified-but-unsaved container data is retained, and shows up when you open the section again.
Yikes. The good news is that closing the project and reopening reverts to the correct, last-saved data in the underlying XML data file.
Already found the problem, which is described below for future reference:
When opening a section, we do a "preflight" open of the section to count its Section models so we can set the diagram to read-only if there are 2+ Sections. That section is then opened again in the DiagramController's open() method. This makes the reference count 2 for that section/container in AbstractProject. When the section is closed, the decremented reference count is 1 instead of 0, so the container is never set to null (see AbstractProject.closeContainer()). Thus the modified-but-unsaved container data is retained, and shows up when you open the section again.