Quite impressive!
The main wish of the people who tried it here was for it to handle mod dependencies, but looking at the commit history, it seems you already added that in the mean time.
Another observation was that the warnings don't take into account suppression files regarding unused databases, until they realised that this is a new feature in DE that you can't know about yet (or, in case you got early access, aren't allowed to talk about
).
In any case, it's not a big secret. Sometimes, the Osiris compiler did not catch typos in database names. For example:
IF
CharacterDied(_Player)
AND
DB_FreeResurrect(_Player)
AND
DB_Player(_Player)
THEN
// Free resurrect for players!
CharacterResurrect(_Player);
// Not twice in a row
NOT DB_FreeResurrected(_Player);
The DB_Player in the above fragment should read DB_IsPlayer, and the DB_FreeResurrected should be DB_FreeResurrect. Osiris did not notice anything wrong with this fragment because it can infer the type of the _Player variable from the CharacterDied event signature.
In order to catch such errors, the Osiris compiler now gives warnings (which are treated as errors; it previously has some similar warnings that only appeared in the log file but did not trigger errors and were not shown in the regular story editor) for all databases that either only checked or only defined in all story goals of the current mod and any mod it depends on. After all, such checks will always fail and such defines will never be used.
However, this can result in false positives. A common example is helpers in the Shared mod, which often check databases that will only be defined in other mods that actually make use of these helpers. To suppress these false positives, a new file can be added in the Story directory of a mod, with the name story_orphanqueries_ignore_local.txt. Every line of this file contains the name of a database followed by its arity (= number of fields/parameters).
When compiling a mod, the contents of all story_orphanqueries_ignore_local.txt files from the dependent mod and this mod are merged, so the ones defined in the Shared mod will also apply to your own mod.
In addition to the previous file, there are two more files you may now see in the Story directory of a Mod:
* story_orphanqueries_ignore.txt: this file is recreated by the story editor every time you compile story (so no need to restart after changing the story_orphanqueries_ignore_local.txt file). It simply contains the contents of all relevant story_orphanqueries_ignore_local.txt files: the one from the current mod and any mod it depends on. This is the file that is read by the Osiris compiler to determine which warnings it should not show. Since it gets overwritten every time, don’t make changes to it since they will get lost.
* story_orphanqueries_found.txt: this file is generated by the Osiris compiler every time you build story, and contains all of the databases for which it gave the aforementioned warning. These databases are in the same format as used by story_orphanqueries_ignore_local.txt, so you can just copy/paste its contents in case these are new false positives that should be suppressed.
One final note: the line number printed for these warnings is bogus, as no line number information is available anymore at the time it gets shown. In general ctrl-shift-f for the database name will be the easiest way to find the location(s) where it is used/defined.