On slow save, turn save button yellow while saving

Intro: I have TW 5.2.2 saved on a secure network drive so I can access it from 2 remote desktops and from my work laptop. I use it to save all my notes for all my various responsibilities. I have 200 500+ tiddlers in this one and the file is about 4.5MB in size. No images in this TW. TW plugins are the Todo list and Markdown.

Preferred solution would be using a plain browser and maybe a browser addon. Which means I would have to install any addon in 3 different browsers: my laptop browser and the browser on each remote desktop.

  1. Browser: I use the latest Brave browser to view, edit and save the TW file. Edit: I was unable to use the Firefox v121 browser because on saving it would pop up a Save dialog every time.
  2. The TW file cannot be stored in the browser Downloads folder, it is stored on a network drive already, accessible by all desktops I use.
  3. Ublock Origins is off for the TW file for Brave and Firefox.
  4. OS on laptop: Windows 10 Pro. OS on remote desktops varies but they are all Windows.
  5. This is for work so I cannot use Tiddlyhost as Tiddlyhost is blocked, it appears by a third party block list.
  6. This is the only network drive that I can save this on which is mapped to my other Remote Desktop machines.
  7. Network security is high.
  8. I don’t want to install other software at the OS level to make this work. I’d like to just use the browser to edit and make one-click saves to the Tiddlywiki.
  9. I do not control security/malware options on my PC so I cannot whitelist Tiddlyhost. Tiddlyhost seems to be blocked at our router level by a third-party block list.

Whenever I save this file it takes about 60 seconds. This is a message related to this problem: Can we get "Starting to save" message on save? - #17 by C_Bacca We have security software which may scan the file upon each save, because TW is a self-modifying HTML file. Why it takes so long to scan just a small text/HTML file is beyond me. When a file needs saving the save button turns red, this is good!

Question: When the save process starts can we change the save button to yellow to indicate it is in the saving process? Then when the save process is done the save button turns gray again like normal.

I don’t know anyone else who has this problem but this is a non-stop problem for me. I don’t want to accidentally click the save button again in the middle of a save because, in the past, TW has given me an error.

Thank you! You have all been very helpful. I’m just a regular user of TW, I don’t program any of it or make macros or anything fancy. Feel free to explain like I’m 5 so I can learn more.

When there is an issue like this it is usually a good idea to try changing something and seeing if there is any change in behaviour, if you can find something that alters the behaviour then you have some hope of finding out what is wrong.

You mention a few “things” which could be considered for playing around with, the network, the machine, the operating system and the browser. It seems you are already using different machines so if saving is slow on all of them then that is probably already tested.

An easy candidate to look at next would be the browser - is it still slow when you try with a different browser?

Operating system you say is Windows 10 Pro - obviously many people will already be using that which is not always a re-assurance that nothing is wrong since forums are full of issues that do not affect only a fraction of windows users but since you are using different machines then that may not be a high priority.

I was unable to use the Firefox v121 browser because on saving it would pop up a Save dialog every time. And the Save dialog was in the wrong directory each time.

Under TW Control Panel, Saving, HTML Native File System Saver, Enable Saver is checked.

The link to Tiddlyfox from this page https://tiddlywiki.com/#Saving%20with%20TiddlyFox is invalid. I get a 404 error. Oh I see Tiddlyfox is obsolete from this page: https://tiddlywiki.com/static/TiddlyFox.html

I agree that some visual indication that saving has been started, but not completed, would be useful. Another case where saving may take longer is e.g. with Tiddlyhost on slower connections.

The problems with indicating this by color are:

  • It would have to be a color from palette. I don’t know if there is any color that’s consistently different from “saved” and “dirty” save button colors in core palettes.
  • It is useless for color-blind or those with other visual impairments.

For these reasons the different shape of the “dirty” indicator was introduced a couple of versions ago (before it used to be just differently colored tick).

Maybe we could further modify the dynamic save button icon to also reflect this third, “saving in progress” state? If there is no color that would do as the intermediate “yellow” in the current palettes, we could just give it the “dirty” color – because it is also an “unsaved” state after all.

I would expect on standard firefox you to be given a requestor that allows you to change the save location, even if not as long as you know where the file will be saved can you not do the experiment and simply delete the unwanted file from wherever it is saved by default?

The objective here is not to move over to using Firefox permanently but merely to compare the save time on Firefox with the save time with your current browser to give an indication of whether the issue is browser specific. It could be for instance that settings inhibit your current browser from using more than a specified amount of memory resource etc.

Maybe a spinning gif ??

Hi @C_Bacca I agree that it would be useful to be able to have an indicator that a save is in progress. I looked briefly at the code for $:/core/modules/saver-handler.js and it looks feasible to set an additional class on the root element while a save is in progress, which would allow us to colour the icon orange during the save. Perhaps somebody could create a GitHub ticket to keep track of the idea?

3 Likes

Thanks Jeremy, if it’s not too hard to do. I think I’m the only one with this problem and my solutions are limited, one reason is Tiddlyhost is blocked from my work network. I really appreciate it.

Possibly if you externalised the core the save times would be reduced.

Thank you @Mark_S much appreciated.

This is normal browser behaviour unless you have a save mechanism. I use Timimi as the saver in FireFox and Chrome. It needs a locally installed component plus browser extension.

  • Most browsers have an option to save to the download folder, or select where to save. In the latter option the folder may open in a recently used folder, which changes.

I could see a tiddlywiki file being scanned for URL’s and JavaScript by a sophisticated malware protection process and possibly slowing saves. I have also found HTML files treated as threats.

  • The external core suggestion is a good one as you reduce save but particularly the core which may trigger the malware scan.
  • If your save problem persists perhaps try saving a copy of your wiki as another file extension. eg wikiname.tw if you then try and open this file most browsers see the internal html header/meta and still treat it as html. Most savers can still save back as a .tw file.
    • Perhaps the malware protection will not be so concerned about a non-html file.

You may be one of only a few with your particular version of the problem. Still, I do find it inconvenient that the starting to save wiki... indicator is on a short timer, and can (if I recall correctly) disappear from view even when the save is not successful. (This is hard to reproduce, since tiddlyhost is usually responsive either with a save confirmation or with an alert indicating a problem — such as a more recent edit from another tab/session, or not currently being logged-in.)

Some visual cue that we’re hanging out in this unresolved attempting-to-save state would be very helpful.

Actually, I’d love for that cue NOT to be stuck within the save-status-icon area (even while the thought put into that status icon has been much appreciated). Having the “starting to save…” notification remain prominent until the save is complete would help even in cases where the status icon is not in view (sidebar is collapsed, etc.).

-Springer

I agree that the notification also deserves some improvements.

If I may add to the list of wishes/ideas for consideration, I’d propose this look:

  • “Appear” animation.
  • Notification with text “Saving wiki…”, stays as long as the saving process takes place.
  • Change color and change text to “Saved wiki”. Maybe rearrange it to “Wiki saved”, so that it stands out from the previous message. I think it also sounds more indicative and reads more like wiki is saved rather than saving is now complete, but let the native English speakers be the judges of that.
  • “Disappear” animation after save completion + notification timeout.

The current situation is, independently for both “Starting to save” and “Saved” notificaitons:

  • “Appear” animation
  • Is visible during the timeout, unless covered by the next notification
  • “Disappear” animation

This leads to two problematic situations:

  • If saving is quick, both notifications are overlaid, and the first one slides away from the second one in a weird way. I think there is no need for the “Starting to save” notification to be there at all, even covered, after the wiki has been saved.
  • If saving is long, there is a gap where no notification is present.

And now a wise, relevant quote:

Everything not saved will be lost.
— Nintendo quit screen

1 Like

This is caused by a setting in the browser configuration.

  • If you open your FF browser settings
  • General
  • Scroll down to “Files and Applications” → Downloads
  • You probably have “Always as your where to save files” option checked.

If you disable this option, you will be not asked again but everytime you save a wiki, it will get a new name by the browser. …

So if you want to use the browser native save option, you probably keep this option checked and always overwite your current wiki. Or you create a new “milestone” wiki as a backup.


As Tony wrote, you can use the Timimi browser addOn plus the Timimi tw-pluigin, or you can also try my FileBackups plugin, which only needs a FireFox AddOn, but only allows you to save back to the browser downloads directory or a subdirectory. This is a limitation introduced by modern browsers

See: File Backups – Get this Extension for 🦊 Firefox (en-US) which also contains a link to a video, that shows how to use the plugin and the backups function

In my first response I did not see, that you save to a network drive and in a locked down “enterprise” environment you are probably also not able to install browser addOns?

So Timimi and FileBackups addOns are probably not possible. … So are you able to install browser addOn’s?

I am a bit curious about the size of your wiki. The TW core needs a bit more than 2MB. So for 200 tiddlers an other 2MB seems to be a bit high. Except if you store images or other binary data in your wiki.

This should be avoided, because the wiki size “explodes” that way and if saved over a slow connection it will need a long time to be saved.

TW has a possibility to “link” to external binary files like imgages and PDFs using a special tiddler field called _cannonical_uri, which may be an option. But to work with “mapped network” drives you have to take care about your path settings.

Just a thought.

  1. Yes please! I just need some indicator that it’s still saving since it takes a long time for me.
  2. Also I can install browser addons. But when I installed the Timimi addon in Firefox yesterday it didn’t seem to do anything at all. It saved no files in the backup directory I specified in the Timimi browser addon options.
  3. I want to keep this a generic installation so I only need the browser to make this all work. I don’t want to install servers of any kind on my work PC. That could trigger all kinds of security problems for me which I don’t have the ability to fix. I do not control security (malware scanners) on my PC so I cannot whitelist any apps.
  4. Getting IT to whitelist tiddlyhost won’t happen. IT won’t take the risk. Network incursions and security events become part of their employee review. Whether those detract from their employee review score I don’t know.
  5. Part of our services is to provide website services to our customers and we already have contracts with them that have security requirements, etc. (That’s not my department though.) That’s why network security is high.

Ok I checked. I have 552 tiddlers, no images in this TW. There are many tiddlers which are notes for tutorials so each tiddler can be large and might be a full 8.5x11 inch printed page if printed out. Some tutorials span 22+ tiddlers, and that particular tutorial is only 33% done. (It’s a 46 hour tutorial for a technical topic.)

OK. So which TW plugins do you use?