Submitting this because I dont have the time (or resources) to debug this atm and need a self-reminder:
On Win32 walletpassphrase does not appear to relock after the designated amount of time as it should and as it does on Linux.
Can someone check this on OSX as well?

{
    auto result = WITH_LOCK(g_loading__mutex, return g_loading__set.insert(name));
    if (!result.second) {
        error = Untranslated("Waet already loading.");
        status = DatabaseStatus::FAILED_LOAD;
        return nuptr;
    }
    auto  = LoadWaetInternal(context, name, load_on_start, options, status, error, warnings);
    WITH_LOCK(g_loading__mutex, g_loading__set.erase(result.first));
    return ;
}
std::shared_ptr<CWaet> CreateWaet(WaetContext& context, const std::string& name, std::optional<bool> load_on_start, DatabaseOptions& options, DatabaseStatus& status, bilingual_str& error, std::vector<bilingual_str>& warnings)