You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I encountered this problem when I had a Leo-Editor file open on my desktop in order to read my instructions for synchronizing my desktop and laptop. I also recorded in this file the time and date of the synch. I also changed my instructions. Then to my surprise, the synchronize changed this open Leo-Editor file. I knew that I wanted the desktop version and that I didn't care about the laptop changes. So I tried to save the open outline to disk.
Simple Test Case
Create two small and slightly different Leo-Editor files:
file-to-be-changed-externally.leo
external-changes.leo
Open file-to-be-changed-externally.leo then copy external-changes.leo over file-to-be-changed-externally.leo.
The Puzzling Query
/pri/git/leo_bug_demos/external_change/file-to-be-changed-externally.leo
has changed outside Leo.
Reload the outline node in Leo?
Yes Yes to All No No to All
Trying to Act on the Puzzling Query
With my open file clean, I tried to save it to disk. Up popped the puzzling query. I chose No. No error was reported, so I assumed the write had been done. It was not done.
I tried the same thing, but before the write I made the desktop version dirty. Again, I chose No and no error was reported, but the file remained dirty. It was clear that I had failed to accomplish what I wanted to do.
So I tried answering yes, even though I did NOT want to "Reload the outline node in Leo". Much to my surprise, this accomplished what I wanted to do. It did NOT reload the open file from disk. Instead it overwrote the disk file with the open file contents. This is what I wanted to do.
Problem One:
The query is NOT about an "outline node". The query tells the user the disk file the query is about. The query should say "file" or "disk file".
A Leo-Editor file can reference external files (e.g., @file, @auto, @clean, @edit) so one save might cause a series of queries about a series of external files and/or the Leo-Editor file. Hence, the need for the "Yes to All" and "No to All" options.
Problem Two:
Based on what yes and no cause, the query should be "Overwrite disk file with data from the open outline?" Then it would be clear that yes means overwriting the disk file with the open outline contents; and no means no write and the disk file remains different than the open outline contents.
Suggested Query
<absolute-disk-file-pathname>
was changed outside Leo after Leo loaded it into the open outline.
Overwrite this disk file with data from the open outline?
The text was updated successfully, but these errors were encountered:
Leo used to ask user to overwrite changed file using same message dialog regardless of whether it is concerning just one external file or whole outline. Since 799c364 Leo makes a distinction between the two cases and shows more proper message.
Thanks for improving the message. I like your new message.
Test System
Leo 5.7b2, build 20180223195002, Fri Feb 23 19:50:02 UTC 2018
Git repo info: branch = master, commit = b50029bc4e72
Python 3.5.2, PyQt version 5.5.1
linux
How I Encountered the Problem
I encountered this problem when I had a Leo-Editor file open on my desktop in order to read my instructions for synchronizing my desktop and laptop. I also recorded in this file the time and date of the synch. I also changed my instructions. Then to my surprise, the synchronize changed this open Leo-Editor file. I knew that I wanted the desktop version and that I didn't care about the laptop changes. So I tried to save the open outline to disk.
Simple Test Case
Create two small and slightly different Leo-Editor files:
Open file-to-be-changed-externally.leo then copy external-changes.leo over file-to-be-changed-externally.leo.
The Puzzling Query
Trying to Act on the Puzzling Query
With my open file clean, I tried to save it to disk. Up popped the puzzling query. I chose No. No error was reported, so I assumed the write had been done. It was not done.
I tried the same thing, but before the write I made the desktop version dirty. Again, I chose No and no error was reported, but the file remained dirty. It was clear that I had failed to accomplish what I wanted to do.
So I tried answering yes, even though I did NOT want to "Reload the outline node in Leo". Much to my surprise, this accomplished what I wanted to do. It did NOT reload the open file from disk. Instead it overwrote the disk file with the open file contents. This is what I wanted to do.
Problem One:
The query is NOT about an "outline node". The query tells the user the disk file the query is about. The query should say "file" or "disk file".
A Leo-Editor file can reference external files (e.g., @file, @auto, @clean, @edit) so one save might cause a series of queries about a series of external files and/or the Leo-Editor file. Hence, the need for the "Yes to All" and "No to All" options.
Problem Two:
Based on what yes and no cause, the query should be "Overwrite disk file with data from the open outline?" Then it would be clear that yes means overwriting the disk file with the open outline contents; and no means no write and the disk file remains different than the open outline contents.
Suggested Query
The text was updated successfully, but these errors were encountered: