Watching a script, and stopping one
- A script now appears in the Scripts pane while it is running, saying how long it has been going. Runs were written down only once they were over, so a script collecting two hundred papers looked exactly the same as one that had never started — and the only way to find out was to wait.
- And there is a Stop beside it. A script cannot be interrupted mid-calculation; what Stop does is refuse the next thing it asks MojoPad to do, which ends any run that is actually doing something. A script that only computes has to be waited out, and the manual says so.
- An event script that will not finish no longer silences the rest. Only one event script runs at a time, so one that hangs quietly stopped every other event page in that wiki until MojoPad was restarted — and the message saying why did not mention where to look. It names the pane now, where the run can be seen and stopped.
A script can put things away
- A plugin can now say which folder its pages and files belong in. Until now everything a script made arrived Unfiled. For one page that hardly matters; for a plugin that collects every paper a report cites, it is the difference between a library and a heap — and there was no way to sort it out afterwards except by hand, one file at a time. Both
createandaddFilenow take a folder, a slash nests one folder inside another, and folders that are not there yet are made. - Running it again does not leave you a second folder. The name is matched without regard to capitals or spacing, so a plugin that runs every morning files into the same folder every morning rather than adding one to the sidebar each day.
- A page that was already there is left where you put it. Asking to create a page that exists has always done nothing; it now also files nothing, because a call that makes no page should not quietly move one you had already put away.
- An option this version has never heard of now says so. A script written for a later MojoPad used to fail in complete silence — an unrecognized setting does nothing at all, so files went on landing in Unfiled with no error and nothing to search for, and the script looked correct because it was, for a different version.
- And the folder tree is documented at last. The call that reads it has existed for a while without appearing in the manual, so the only way to find out was to open the wiki’s own file and look.
Saving a page asks once, and asks about the right thing
- Saving a page no longer asks about its pictures at all. Clicking Save is the decision. An article’s photographs usually live on a handful of other sites, and MojoPad asked about each one — half a dozen questions for a single page, every page. They are simply saved now.
- Why that is safe, since it is a permission being removed. A plugin’s address can be built out of what it has read, which is why MojoPad asks about those. A saved page’s pictures are quite different: their addresses were written by the page you chose to keep, and your own browser fetched every one of them while you were reading it. Nothing of yours can travel out that way, so there was nothing for you to weigh — and a question with no decision in it only teaches people to dismiss the ones that have.
- A site the page did not name is still a question. MojoPad works out where the page keeps its pictures from the page itself, not from what asks for them, so this quiet only ever covers the page in front of you.
- When it does ask, it asks once, naming the sites. It used to ask per site — and refusing one abandoned every picture on the page, so yes was the only workable answer. A declined site now costs its own pictures and nothing else; they stay as links.
- Sites that are not secure are included in that question. Pictures served over an insecure connection were the one kind never mentioned, and they were fetched anyway.
- And that answer stays about pictures. It used to be written into the permission that says which sites a wiki’s plugins may reach — so allowing one photograph gave every plugin in that wiki standing access to that site, for ever. They are two separate answers now, and both are listed in Settings where you can take either back.
- Keeping a snapshot of a page now asks too. It reaches further than anything else here — every address the page names — and it was the one door that asked nothing at all.
- Bringing a page in by its address follows the same rule. The same page saved two ways behaved two ways: one asked about each site its pictures came from, the other fetched them all in silence.
- A site you allowed can no longer hand the request to a different one. Permission names a site; anything it forwards to is somewhere else, and is now checked rather than assumed.
A file that is not what it says it is
- MojoPad no longer calls a file a scan when it is not a PDF at all. A publisher that refuses automatic downloads usually answers with a web page saying so — and answers as though nothing were wrong. Kept under the name of the paper that was asked for, that page will not open, and MojoPad used to explain it by saying the file looked like a scan and suggesting text recognition. Two different problems with two different answers, and it was naming the wrong one. It now says what actually happened and that fetching the file again is what fixes it.
- And a plugin can no longer keep one by mistake. Anything a script fetches is checked against the name it is being saved under before it is kept, so a page that arrives where a paper was expected is refused there and then, while you are still watching — rather than months later, one file at a time.
What your settings carry, and what “forget” means
- An exported settings file no longer describes your wikis. Two of the permissions MojoPad remembers travelled when the rest did not: the sites a wiki’s plugins may reach, and the tools a model may use in a wiki without being asked each time. Both are recorded wiki by wiki, by each wiki’s full location on this Mac — so a file meant to carry your preferences to another computer also listed every wiki you had ever answered those questions for, where each one lives, and what each was allowed. Settings files are the kind of thing people keep in a synced folder. They stay on this Mac now, like every other permission always has.
- And a wiki can no longer see what other wikis are allowed to do. MojoPad hides your standing permissions from the wiki you have open, so a page’s own scripts cannot read them — but it recognized them by how they were named, and one was not named that way. It was readable: which wikis exist, where each one lives on this disk, and what each may already do without asking. That is the map you would want before trying anything, and it is closed.
- Taking back permission to reach a site now takes it back at once. Forgetting a site in Settings removed the standing answer but left the site allowed until MojoPad was next restarted — so a permission you had deliberately withdrawn went on working for the rest of the day. It is withdrawn immediately, and a no you gave earlier is cleared at the same time, because reopening a question means asking it again rather than making the refusal permanent.