So: can I just delete all of these snapshots? Can we make a sage
function that cleans out these snapshots if we decide we don't need them?
Thanks,
Jason
--
Jason Grout
Yes.
> Can we make a sage
> function that cleans out these snapshots if we decide we don't need them?
When the notebook is about to create a snapshot, it *should* clean up
old snapshots using some simple criterion, e.g., at most one per hour
after the first hour, then at most one per day up to a month, but
after a month just one per month, etc.
-- William
No, it didn't. I deleted my .sage/sage_notebook folder (well, moved it),
so Sage created a new notebook, and now things are back to being almost
instantaneous.
Thanks,
Jason
I would just forget about all that crap, and write
something so there can be at most say 30 snapshots for any given
worksheet. Full stop. How those 30 are divied out is a matter of
algorithms, but the simplest choice is just delete all but the 30 most
recent.
William
Hi,
Does anybody here ever use snapshots? This is what implements the
"Undo" button.
I never use it.
William
I use it on occasion when something happens with the notebook and I
would otherwise have lost code. I also like the confidence it gives me
to experiment, knowing there is a version history. I would definitely
keep it.
Jason
Wouldn't the history of the last 500 (say) commands serve roughly the
same purpose? That's the "Log" button at the top of the screen.
William
So with the current snapshot system you already lost a lot of work? Why?
William
Even with the patch we're discussing, the total number of snapshots
produced by people on sagenb.org in the last 20 hours is over 10,000:
sage@sagenb:~/sagenb$ ls -1 */worksheets/*/*/snapshots/*|wc -l
10395
So it really doesn't cut down on them very much. Of course a lot of
people use sagenb.org, e.g., well over 100 distinct uses just
*yesterday*, and over 7200 registered users.
I also like the idea to reduce the total max number of autosaved to
some fixed number, e.g., 30.
-- William
You shouldn't worry about that. I've hired Mike Hansen fulltime to
work fulltime
from now until at least the end of the summer, and I'm confident he
will fix the issues as part of a broader project he is working on.
This isn't going to just languish forever.
William
You could have just pressed reload and you would have had your
worksheet back entirely. It was still sitting there on the server in
RAM. Never use the back button with the sage notebook, unless you
immediately press refresh.
william
Tom or some other javascript ninja:
Isn't there some sort of javascript that disables the back button?
That's a common problem in web applications, and I'd be very surprised
if it isn't a solved problem already.
Jason
Not, there is no javascript to do that. Also, disabling the back
button is irrelevant to the above problem, which would only have been
prevented by disabling being able to leave the page by clicking on a
favorites. There is javascript to attempt to prevent users from
leaving pages -- lots of spam sites use it. Of course it doesn't work
well though, and is often extremely annoying.
William
I am using GMail. I hit reply. I typed this. Now I am going to hit the
browser's back button...
I'm still here. So Google can do it. It presented me with a warning:
Your draft has been modified.
Abandon changes?
See the attached screenshot.
Franco
--
--
Right, sorry. I misunderstood and didn't realize that the goal was to
disable the back button.
I think it might be a good idea to pop-up a dialog when one tries to
leave a worksheet if it hasn't been saved.
Franco
--