Quantcast
Download
(118 Kb)
Download
Updated: 04/25/21 06:41 AM
Pictures
File Info
Compatibility:
Blackwood (7.0.5)
Flames of Ambition (6.3.5)
Updated:04/25/21 06:41 AM
Created:10/25/20 04:32 PM
Monthly downloads:9,636
Total downloads:257,176
Favorites:153
MD5:
Categories:Libraries, Data Mods
LibHistoire - Guild History  Popular! (More than 5000 hits)
Version: 1.2.2
by: sirinsidiator [More]
What is this library for?
Up until now, addons had to send guild history requests to the server individually, which in the past has lead to huge performance problems as more and more players started using these addons and ultimately forced ZOS to throttle how fast they are allowed to send automated requests for the guild history. In order to alleviate this problem and take a lot of the complexity away from individual addons, this library was born. Instead of having each addon send requests, it will all be taken care of by LibHistoire and they will simply become passive listeners.

The library will take care of loading missing history from the server in the background and store everything locally so it never has to request the same time range more than once.

Right now the game provides the history in an inverse order (future to past) of what addons actually try to use (past to future), so before the library passes any events to addons, it will attempt to load the full time range since you last played the game. During this time, it will keep them in a temporary "unlinked" state and only when it encounters the last stored event, it will save them and start sending events to listening addons. If you quit the game before that happens, all progress will be lost and it will have to start over from the beginning the next time you log in.

You can speed this process up by manually requesting missing history via the guild history menu, as this action won't be subject to the cooldown any addon has to deal with. Another option is to tell the library to force a link with what data it has got and create a hole in your history. You can always manually request more history events and trigger a rescan which will find any missing entries later.

Unlike other addons, the library won't request the full range of history provided by the server when you first use it. Instead it will immediately force a link and start collecting data from there. If you want to collect older history in that situation, you will need to manually request it and then hit the rescan button for that guild and category.

Dependencies
The following dependencies are required by LibHistoire:
  • LibAsync - to minimize fps loss while processing history events
  • LibCustomMenu - for the options menu of the status window
  • LibDebugLogger - for logging useful debug information in case something goes wrong

Some observations on what the server does
  • Requesting older history events via an addon starts a cooldown
  • The cooldown is separate for each guild and category, meaning an addon can send up to 20 requests at once
  • Simply put the interval between requests depends on how many players are currently online and is dynamically controlled by the server
  • Interval can be anything from a few seconds (on PTS) to several minutes during primetime EU. I've often seen values between 3 and 4 minutes while developing the library
  • New events are pushed automatically by the server with no way for addons to influence that process
  • The time between new events varies greatly and seems to depend on the how many players are online and how many events a guild produces
  • Sometimes the updates arrive almost instantly, sometimes they don't arrive for several hours - I've had to wait 2-3 hours quite often before any new guild history arrived
  • Ocassionally the updates never arrive (even after waiting for 5 hours) and restarting the game is the only way to force an update in that situation

User Interface

The status icon on the bottom right of the guild history symbolizes the link status of the currently viewed category in the selected guild. On hover it will show a tooltip that gives information about the stored history and unlinked events.


The new guild history status panel will provide an overview of what LibHistoire has stored and what is missing.

On the left side it will show each guild and the overall progress, on the right side it will show the categories for the currently selected guild.
Clicking on a guild or category will update the selection in both the status window and the guild history menu accordingly.
When you hover over any of the entries, a tooltip will show you the same information as the tooltip in the guild history menu.
The category entries also house the force link button (while the category is unlinked) and the rescan button (after it has linked up with stored events).
On the bottom of the panel you can see an icon which symbolizes the overall state and gives some general information about what is happening when you hover over it.
The cog button on the top right will open a context menu with an option to unlock the window so it can be moved and an option to hide it (same as the button on the bottom left of the guild history)

Special Thanks
FooWasHere who helped me test how the history behaves on rank and permission changes
ZOSDanBatson for answering my many questions about the history API
Everyone else who helped me test this and gave me feedback

For Developers
Why should you use it?
  • It minimizes the amount of requests sent by addons to the absolute minimum and if every addon starts using it, it will likely lower the cooldown the server chooses, so everyone gets their data faster.
  • It takes care of all the complexity that comes with requesting the history. There are many special cases you probably didn't even think about. The lib will handle them all for you.
  • It stores the history locally, so an addon can access time ranges that would be impossible via the game api
  • The data format minimizes impact on load time and disk space usage (compared to other addons like MM or ATT)

How does it work
The library listens to all incoming data and determines for each individual event if it has already been stored locally. It also takes care of sorting the events in the correct historic order and waits until the hole since the last login has been filled before saving them to disk and passing them to listeners.
When a listener starts, it will first iterate over available stored events, then wait for "unlinked" events to link before it iterates over those and finally start passing along newer events whenever they arrive. This is all done via LibAsync, so you will only get as many events per frame as you can safely process without affecting performance.
To avoid having to deserialize all stored events, it offers ways to select a starting point either by specifying an eventId or a timestamp*. It will do a binary search for the closest event and start from there instead of the beginning of the stored history.

*timestamps may not be 100% accurate as event times are returned from the game api as seconds since an event and manually converted to an absolute timestamp. This brings a certain inaccuracy with it and can lead to events being stored with timestamps that do not reflect their actual order. If precision is required it may be best to specify a timestamp a few seconds before the actual target time and use eventIds to identify an actual border for a time range.

If you find a problem, feel free to open an issue over on github, or leave a comment here on ESOUI.

API Reference
Callbacks
Can be accessed via the LibHistoire.callback table.

Code:
INITIALIZED()
Fired when Histy has finished initializing and is ready. Any call to the api (aside of RegisterCallback) should be done after it has fired.

Code:
HISTORY_RESCAN_STARTED(integer guildId, integer category)
Fired when the user or library triggered a rescan of the history.

Code:
HISTORY_RESCAN_ENDED(integer guildId, integer category, integer numEventsBefore, integer numEventsInside, integer numEventsAfter, boolean foundInvalidEvents)
Fired after a category rescan has finished. Invalid events are product of a bug where the game won't set the correct event time for a few seconds and the library will ignore them.

Library API
Code:
RegisterCallback(LibHistoire.callback type, function callback)
Register to a callback fired by the library. Usage is the same as with CALLBACK_MANAGER:RegisterCallback.

Code:
UnregisterCallback(LibHistoire.callback type, function callback)
Unregister from a callback. Usage is the same as with CALLBACK_MANAGER:UnregisterCallback.

Code:
LibHistoire.GuildHistoryEventListener listener = CreateGuildHistoryListener(integer guildId, integer category)
Creates a GuildHistoryEventListener object which can be configured before it starts listening to history events, or nil if guildId or category are not valid.
WARNING: Make sure you only call it after the INITIALIZED callback has fired, otherwise it may return nil.

GuildHistoryEventListener
Code:
string key = GetKey()
Returns a key consisting of server, guild id and history category, which can be used to store the last received eventId.

Code:
integer guildId = GetGuildId()
Returns the guild id of the listener.

Code:
integer category = GetCategory()
Returns the category of the listener.

Code:
integer eventCount, number processingSpeed, number timeLeft = GetPendingEventMetrics()
Returns information about history events that need to be sent to the listener.
  • eventCount - the amount of stored or unlinked events that are currently waiting to be processed by the listener
  • processingSpeed - the average processing speed in events per second or -1 if not enough data is yet available
  • timeLeft - the estimated time in seconds it takes to process the remaining events or -1 if no estimate is possible

Code:
boolean success = SetAfterEventId(id64 eventId)
Accepts an eventId (id64). The nextEventCallback will only return events which have a higher eventId when it is set. Will return true if it was called while the listener is not running, or false otherwise.

Code:
boolean success = SetAfterEventTime(integer eventTime)
If no afterEventId has been specified, the nextEventCallback will only receive events after the specified timestamp. Will return true if it was called while the listener is not running, or false otherwise.

Code:
boolean success = SetBeforeEventId(id64 eventId)
Accepts an eventId (id64). The nextEventCallback will only return events which have a lower or equal eventId when it is set. Once the specified eventId has been passed, the listener will automatically stop and call the function specified with SetIterationCompletedCallback. Will return true if it was called while the listener is not running, or false otherwise.

Code:
boolean success = SetBeforeEventTime(integer eventTime)
If no beforeEventId has been specified, the nextEventCallback will only receive events before (including) the specified timestamp. Like with beforeEventId, the listener will stop and call the iteration completed function when the specified eventTime has been reached. Will return true if it was called while the listener is not running, or false otherwise.

Code:
boolean success = SetIterationCompletedCallback(function callback)
When an end criteria is set, this callback will fire when the listener has stopped automatically.

Code:
boolean success = SetTimeFrame(integer startTime, integer endTime)
A convenience method to specify a time range which includes the startTime and excludes the endTime. See SetAfterEventTime and SetBeforeEventTime.

Code:
boolean success = SetNextEventCallback(function callback)
Sets a callback which is passed stored and received events in the correct historic order (sorted by eventId). Will return true if it was called while the listener is not running, or false otherwise.
The callback has the following signature:
Code:
function(GuildEventType eventType, id64 eventId, integer eventTime, variable param1, variable param2, variable param3, variable param4, variable param5, variable param6)
More details about param1-6 can be found in guildhistory_shared.lua in the UI source code.

Code:
boolean success = SetMissedEventCallback(function callback)
Sets a callback which is passed missed events that are discovered during a rescan, ignoring any afterEventId or afterEventTime values. See SetNextEventCallback for details on the callback. Will return true if it was called while the listener is not running, or false otherwise.

Code:
boolean success = SetEventCallback(function callback)
A convenience function which will set both callback types in one go. See SetNextEventCallback for details on the callback. Will return true if it was called while the listener is not running, or false otherwise.

Code:
boolean success = Start()
Signals that the listener can start sending data to the addon. Will return true if it was called while the listener is not running, or false otherwise.

Code:
boolean success = Stop()
Signals that the listener to stop sending data to the addon. Will return true if it was called while the listener is running and has been stopped, or false otherwise.

Code:
boolean success = IsRunning()
Returns the current state of the listener.

Examples
Iterate over all stored events
Lua Code:
  1. LibHistoire:RegisterCallback(LibHistoire.callback.INITIALIZED, function()
  2.     local listener = LibHistoire:CreateGuildHistoryListener(guildId, category)
  3.     listener:SetEventCallback(function(eventType, eventId, eventTime, param1, param2, param3, param4, param5, param6)
  4.         -- do something with the event data
  5.     end)
  6.     listener:Start()
  7. end)
This will simply iterate over all stored events and then listen to any newly received data, including anything that will be found on a rescan.

Retrieve a time range
Lua Code:
  1. LibHistoire:RegisterCallback(LibHistoire.callback.INITIALIZED, function()
  2.     local listener = LibHistoire:CreateGuildHistoryListener(guildId, category)
  3.     listener:SetTimeFrame(startTime, endTime)
  4.     listener:SetNextEventCallback(function(eventType, eventId, eventTime, param1, param2, param3, param4, param5, param6)
  5.          -- do something with the event data
  6.     end)
  7.     listener:Start()
  8. end)
This example shows how to iterate over a specific time frame and then stop. SetTimeFrame is preferable over just checking the eventTime in the callback, as it will be faster than just iterating everything.

Retrieve sales for different guilds and continue from last event
Lua Code:
  1. LibHistoire:RegisterCallback(LibHistoire.callback.INITIALIZED, function()
  2.     local function SetUpListener(guildId, category)
  3.         local listener = LibHistoire:CreateGuildHistoryListener(guildId, category)
  4.         local key = listener:GetKey()
  5.         listener:SetAfterEventId(StringToId64(saveData.lastEventId[key]))
  6.  
  7.         listener:SetNextEventCallback(function(eventType, eventId, eventTime, param1, param2, param3, param4, param5, param6)
  8.             -- the events received by this callback are in the correct historic order
  9.             saveData.lastEventId[key] = Id64ToString(eventId)
  10.         end)
  11.  
  12.         listener:SetMissedEventCallback(function(eventType, eventId, eventTime, param1, param2, param3, param4, param5, param6)
  13.             -- events in this callback are out of order compared to what has been received by the next event callback and can even have an eventId smaller than what has been specified via SetAfterEventId.
  14.         end)
  15.         listener:Start()
  16.     end
  17.  
  18.     for i = 1, GetNumGuilds() do
  19.         SetUpListener(GetGuildId(i), category)
  20.     end
  21. end)
This example will register listeners for all guilds and keep track of the last event id that has been processed by the addon. That way the library will pass every event to the listener only once. It will also handle events that have been found later during a manual rescan.
v1.2.2
- fixed error when serializing unexpected event types

v1.2.1
- fixed an error preventing events from getting stored for new users or when joining a new guild
- fixed progress bars flickering yellow on initial load
- fixed event listener getting stuck in a loop in some cases
- fixed game freezing when storing missing events during a rescan in categories with lots of stored events
- fixed typo in logout warning dialog

v1.2.0
- fixed an issue that would cause some players to get kicked from the PTS (public test server)
- fixed progress bar not immediately filling to 100% when the last batch of missing events are received in a category
- fixed a rare error that could occur when stored data is deserialized and added some assertions to find the underlying reason
- changed progress bars on status window to show in a red color while events are missing and yellow while events are being processed
- added a confirmation dialog when trying to logout or quit the game while history events are not yet linked, which will send players to the history menu
- updated api version

v1.1.3 (dedicated to Sharlikran who found all these problems)
- fixed codec storing item links in an uncompressed form
- fixed several codec bugs that caused item links to get decoded into invalid links
NOTE: No data was lost and I believe I've found and fixed all incorrect cases and added unit tests to guard against regressions. As an additional measure the lib will now also throw an assertion error if it encounters links that cannot be decoded. Please make sure to report these so I can add them to the test cases and fix them!

- fixed several more bugs in the new GetPendingEventMetrics function

v1.1.2
- fixed error when rescanning a category

v1.1.1
- fixed error in new GetPendingEventMetrics function

v1.1.0
- improved event decoding speed
- changed some logging to reduce log spam
- fixed afterEventTime not returning the correct event when multiple events have the same timestamp
- fixed status tooltip not updating when linking process begins
- added progress info to tooltip while linking
- added log warning when trying to start a listener without an event callback
- added new functions to EventListener API
- GetKey - returns an identifier which can be used to store the last seen eventId for a listener
- GetGuildId - returns the guildId of a listener
- GetCategory - returns the category of a listener
- GetPendingEventMetrics - returns
the amount of stored or unlinked events that are currently waiting to be processed by the listener
the average processing speed in events per second or -1 if not enough data is yet available
the estimated time in seconds it takes to process the remaining events or -1 if no estimate is possible
- SetBeforeEventId, SetBeforeEventTime
these can be used to limit the iteration range and automatically stop the listener when they are passed
they will also ensure the correct data is returned by the GetPendingEventMetrics function when only a subset of the data is requested (otherwise it will consider all available events)
- SetIterationCompletedCallback
when an end criteria is set, this callback will fire when the listener has stopped automatically
- SetTimeFrame(startTime, endTime)
a convenience method to specify a range which includes the startTime and excludes the endTime
v1.0.2
- added new callback for when Histy is ready

v1.0.1 - initial release
Optional Files (0)


Archived Files (8)
File Name
Version
Size
Uploader
Date
1.2.1
118kB
sirinsidiator
04/24/21 03:01 PM
1.2.0
118kB
sirinsidiator
04/22/21 01:22 PM
1.1.3
119kB
sirinsidiator
12/12/20 11:12 AM
1.1.2
118kB
sirinsidiator
12/05/20 02:33 PM
1.1.1
118kB
sirinsidiator
12/05/20 09:47 AM
1.1.0
118kB
sirinsidiator
12/04/20 07:01 AM
1.0.2
115kB
sirinsidiator
10/31/20 05:32 AM
1.0.1
115kB
sirinsidiator
10/25/20 04:32 PM


Post A Reply Comment Options
Unread Yesterday, 12:54 PM  
Thrasher

Forum posts: 6
File comments: 130
Uploads: 0
Hi Sharlikran!

Would it be possible to add a message to the chat window when a rescan is complete?

Please let me know,
Thrasher
Last edited by Thrasher : 09/25/21 at 12:55 PM.
Report comment to moderator  
Reply With Quote
Unread 09/13/21, 11:03 AM  
Sharlikran
 
Sharlikran's Avatar
AddOn Author - Click to view AddOns

Forum posts: 298
File comments: 1284
Uploads: 11
Re: Doc Feature Request

Originally Posted by Techwolf
So far, I only found that MM uses this AddOn. Would like to find an addon that display other history data that this libaddon saves.

So the feature request is a list of AddOns that use this one. Can be posted anywhere, just a place where one can find the list.
The only ones I know of are

Advanced Member Tooltip - LibHistoire
Guild Tools By Fen
__________________
Admin for TES5Edit, occasional LOOT masterlist contributor, and Wrye Bash contributor. I also maintain special Fallout 3 and Fallout NV versions of Wrye Flash.
Last edited by Sharlikran : 09/14/21 at 11:50 PM.
Report comment to moderator  
Reply With Quote
Unread 09/13/21, 10:22 AM  
Sharlikran
 
Sharlikran's Avatar
AddOn Author - Click to view AddOns

Forum posts: 298
File comments: 1284
Uploads: 11
Originally Posted by ClevaTreva
If I get "holes in my data" does it matter?
In what sense?

Have you looked at the documentation?
__________________
Admin for TES5Edit, occasional LOOT masterlist contributor, and Wrye Bash contributor. I also maintain special Fallout 3 and Fallout NV versions of Wrye Flash.
Report comment to moderator  
Reply With Quote
Unread 09/12/21, 06:08 PM  
ClevaTreva

Forum posts: 0
File comments: 28
Uploads: 0
If I get "holes in my data" does it matter?
Report comment to moderator  
Reply With Quote
Unread 09/11/21, 07:32 PM  
Techwolf
 
Techwolf's Avatar

Forum posts: 5
File comments: 66
Uploads: 0
Doc Feature Request

So far, I only found that MM uses this AddOn. Would like to find an addon that display other history data that this libaddon saves.

So the feature request is a list of AddOns that use this one. Can be posted anywhere, just a place where one can find the list.
Report comment to moderator  
Reply With Quote
Unread 08/14/21, 08:33 AM  
Akbar

Forum posts: 0
File comments: 2
Uploads: 0
Originally Posted by Sharlikran

The specific section you need is Update Your Guild History Each Day. However, you should probably take the time maybe on the weekend when you have more then 40 minutes to play and do a Ten Day scan so you have no gaps for at least that amount of time. The server only stores 10 days.

If you do a Ten Day Scan and then keep the data up to date you won't have to do another Ten Day scan because MM and LH would just be examining sales and then skipping them because they would be duplicates of what is already stored in the data files.
Oh, I never found your documentation! This is perfect and solves every problem I currently have. Thanks so much for the hard work, Sharlikran & sirinsidiator, I really do appreciate how much heavy lifting this library does for all of the add-ons I rely on.

I'll read over all of the docs just to familiarize myself with everything else, but my daily chore of waiting for the sales to update is fixed which was my biggest issue. (and my inability to see the "E Show More" apparently. {shrug})
Last edited by Akbar : 08/14/21 at 08:35 AM.
Report comment to moderator  
Reply With Quote
Unread 07/22/21, 06:05 AM  
sirinsidiator
 
sirinsidiator's Avatar
AddOn Author - Click to view AddOns

Forum posts: 1489
File comments: 1049
Uploads: 38
Re: Please clarify the Logout Notification

Originally Posted by Shadowshire
(1) What does the message signify by close the game now?
It means either you completely close the client to go back to the desktop, or you log out to the title screen. Character select is actually fine, but I don't have a way to show the message there in case you were to log out or quit and at the time I added the dialog it seemed more reasonable to show it on log out instead of having people who close the game from the character select screen complain why their data is missing.

Originally Posted by Shadowshire
(2) If a player does not cancel the log-out, then will Guild Store sales data be irretrievably lost, or corrupted?
As stated above switching characters is fine, although it will waste some CPU power to re-scan the already loaded data once you log in on a character.

Originally Posted by Shadowshire
(3) What happens when a player Reloads the UI while playing a character, for example, after a UI Error occurs? It seems to me that the outcome should be the same as when a player logs-out of a character, then chooses to play the same character again from the Select Character dialog screen.
Exactly. There is basically no difference in regard to LibHistoire.

Originally Posted by Shadowshire
In the first sentence above, it appears to me that "(future to past)" should be "(present to past)" instead, and that "(past to future)" should be "(past to present)". It does not seem likely that data about future Sales are provided by the mega-server. But I could be wrong.
Never underestimate the powers of a mega-server. In reality ESO is a single player game and everyone else is just simulated, thus it already knows what happens next. :P (Jokes aside, English is not my first language, so you'll have to excuse mistakes like that )

So to reiterate, logging out of one character and into the next is fine, logging out to character select and then quit or log out of the account from there is not fine.
Regarding your suggestion, I still have some reservations about it, but I may just try it in the next version to see how it works out. Should the amount of people who complain about missing data rise again, I'll add it back though.

Also keep in mind that there are several easy ways how power users can relog chars without triggering the dialog mentioned in the comments below.
__________________
https://www.imperialtradingcompany.eu/ - My Addons - The Vault (Early updates and experimental projects) - My patreon - My blog
>siri.exe MyAddon
Does your addon work? [y/n] n
There is a typo in there.
Report comment to moderator  
Reply With Quote
Unread 07/21/21, 10:19 PM  
Sharlikran
 
Sharlikran's Avatar
AddOn Author - Click to view AddOns

Forum posts: 298
File comments: 1284
Uploads: 11
Re: (Reply to sharlikran)

Originally Posted by Shadowshire
LibHistoire cannot always accomplish its work without player participation.
This is the part I have the hardest time getting users to understand. People see it as an inconvenience when it has nothing to do with sirinsidiator or myself. Nor does LibHistoire lack functionality.

I understand users want an answer I really do. However, I see it as an act of futility to ask mod authors why things are the way they are. Because it is ZOS users should be asking because only they can provide the answer or make any changes.

I do hope you get a response other then mine but in the event you don't, I hope the functionality sirinsidiator has created helps you maintain your sales information as it really is the best approach given the circumstances.
__________________
Admin for TES5Edit, occasional LOOT masterlist contributor, and Wrye Bash contributor. I also maintain special Fallout 3 and Fallout NV versions of Wrye Flash.
Last edited by Sharlikran : 07/21/21 at 10:26 PM.
Report comment to moderator  
Reply With Quote
Unread 07/21/21, 08:41 PM  
Shadowshire

Forum posts: 1
File comments: 378
Uploads: 0
(Reply to sharlikran)

Originally Posted by Sharlikran
@Shadowshire Thank you for taking the time to share your thoughts with the author so that after he reads everything if he could clarify anything, he can do so in a future version.

....

.... Don't consider LibHistoire to be lacking functionality. The game itself must have the sales (know as Events) loaded into memory before they can be scanned by LibHistoire or any other sales related software.

Anything you do to interrupt LibHistoire such as reloding the UI or logging out to log into another character, (don't get nitpicky about wording) means that progress will be lost. Unless ZOS changes how guild history functions, the circumstances are not within the control of the mod author.
You are welcome, and I look forward to sirinsidiator's response.

In my experience and observation, after I use the Show More key on the Guild History > Sales > All page, for each guild for which events are pending, LibHistoire has acquired all of them from whatever source it does so. Then I can log-out of the character which I am playing (or reload the UI) and LibHistoire will not be affected. The Notification warning will not be displayed. When execution of LibHistoire resumes, ordinarily it will proceed with any events which remain to be "linked".

For what they may be worth, I have made sequences of screenshots which show LibHistoire's progress as it occurred over the span of playing each of six characters in the course of several hours.

As far as I can determine, there has not been any loss of data. For example, there are no gaps on the MM tooltip Histogram shown for items for which there are dozens of sales per day. Also, the number of Sales which Master Merchant currently retains continues to increase, until the criteria for deleting records take effect.

Nonetheless, sometimes I have reasons to suspect that LibHistoire might have one or more bugs. Collecting evidence can be difficult and time-consuming. But I've set myself the task of doing what I can to see whether I can obtain information which the developer will need to correct any evident error.

As to being "nit-picky about wording", at present, the LibHistoire Notification lacks clarity in the context in which it is displayed. The confusion it creates inspires the complaints and "rants" which players post. The ZOS design characteristics aside, unfortunately, given the performance problems of the game client and mega-server system -- among other potential sources of problems -- LibHistoire cannot always accomplish its work without player participation.

Again, in my experience, after I use the keybind for Show More until there are no more events to "show", the LibHistoire Notification will not be displayed thereafter. Sometimes I play the first character that I chose long enough that apparently LibHistoire acquires all "events" which would be obtained if I used the Show More feature on each of the respective Guild UI Sales History pages. Which is to say, when I log-out of the character, its Notification warning is not displayed. But when it is displayed, I Cancel the log-out and access the Guild UI to effect the process of retrieving all past unlinked events.
__________________
---- Shadowshire ..... nil carborundum illegitimi
Report comment to moderator  
Reply With Quote
Unread 07/20/21, 04:05 PM  
Sharlikran
 
Sharlikran's Avatar
AddOn Author - Click to view AddOns

Forum posts: 298
File comments: 1284
Uploads: 11
@Shadowshire Thank you for taking the time to share your thoughts with the author so that after he reads everything if he could clarify anything, he can do so in a future version.

I did delete the comments you left in the MM comments section because I felt they were asked and answered and really only pertained to what you wanted to know.

The section What is being scanned is not very verbose and I don't feel it needs to be. The first sentence states that LibHistoire only has access to what is loaded into memory. As you know from reading my previous comments, that happens either by automatic requests or because you manually press E.

I won't comment more and wait for sirinsidiator because he will probably be more concise. However I did want to reiterate the theme of my responses to your concerns. Don't consider LibHistoire to be lacking functionality. The game itself must have the sales (know as Events) loaded into memory before they can be scanned by LibHistoire or any other sales related software.

Anything you do to interrupt LibHistoire such as reloding the UI or logging out to log into another character, (don't get nitpicky about wording) means that progress will be lost. Unless ZOS changes how guild history functions, the circumstances are not within the control of the mod author.
__________________
Admin for TES5Edit, occasional LOOT masterlist contributor, and Wrye Bash contributor. I also maintain special Fallout 3 and Fallout NV versions of Wrye Flash.
Last edited by Sharlikran : 07/20/21 at 11:01 PM.
Report comment to moderator  
Reply With Quote
Unread 07/20/21, 06:55 AM  
Shadowshire

Forum posts: 1
File comments: 378
Uploads: 0
Question Please clarify the Logout Notification

The following dialog message is displayed almost every time when I log-out of the first character which I have chosen to play:

LibHistoire has not linked your history yet! If you close the game now, you will lose any progress and have to start over the next time.

(1) What does the message signify by close the game now?

The context is that I am logging-out of a character with which I have been playing TESO. Doing so displays the Select Character dialog screen afterward, and the game client continues running. Does simply logging-out of playing a character cause LibHistoire to lose any progress, so that it must "start over next time"?

(2) If a player does not cancel the log-out, then will Guild Store sales data be irretrievably lost, or corrupted?

(3) What happens when a player Reloads the UI while playing a character, for example, after a UI Error occurs? It seems to me that the outcome should be the same as when a player logs-out of a character, then chooses to play the same character again from the Select Character dialog screen.


On the ESOUI LibHistoire Addon Info tab:
Right now the game provides the history in an inverse order (future to past) of what addons actually try to use (past to future), so before the library passes any events to addons, it will attempt to load the full time range since you last played the game. During this time, it will keep them in a temporary "unlinked" state and only when it encounters the last stored event, it will save them and start sending events to listening addons. If you quit the game before that happens, all progress will be lost and it will have to start over from the beginning the next time you log in.
In the first sentence above, it appears to me that "(future to past)" should be "(present to past)" instead, and that "(past to future)" should be "(past to present)". It does not seem likely that data about future Sales are provided by the mega-server. But I could be wrong.

The last sentence states "If you quit the game before that happens, ..." But ordinarily I am not quitting the game before LibHistoire completes its task. Rather, the Notification is displayed after I chose the ESC menu Log Out option to return to the Select Character dialog screen. That said, if a player does choose the Quit option from the ESC menu while logged-in to play a selected character, then displaying the Notification certainly appears justified.

So: I suggest that you change the LibHistoire design -- if that is possible -- so that the Notification will be displayed only when it has not completed linking the Sales events and the player has chosen to Quit the game. That is, if logging-out of a character to the Select Character dialog screen does not disrupt the operation of LibHistoire, which can resume after the same or another character is subsequently selected.

There are two optons on the UI which a player can use to stop playing the game. As noted above, one is the Quit option on the ESC menu, shown while the player is currently logged-in to a character. The other is by using the Back option on the Select Character dialog to return to the primary account/game log-in dialog screen. The game client continues to run while that dialog is shown, until and unless the player chooses the Quit option shown in the upper right-hand corner of its display.

However, no add-ons remain loaded. They are loaded only after a player selects which character to play, and they are unloaded when the player chooses to log-out of that character (or to Quit the game while logged-in to a character). On the face of it, LibHistoire must start afresh if the player does go Back to the primary account/game log-in dialog, then subsequently logs-in to resume playing TESO. So, displaying the Notification is justified after the player uses the Back option on the Select Character dialog screen.

Thank-you for your time and attention to this matter. Thank-you also for all of the time and effort which you have applied to developing LibHistoire. May peace be with you.

__________________
---- Shadowshire ..... nil carborundum illegitimi
Report comment to moderator  
Reply With Quote
Unread 07/18/21, 12:38 PM  
tralce
AddOn Author - Click to view AddOns

Forum posts: 0
File comments: 33
Uploads: 1
Any way to purge out data older than x days, or purge out data from guilds I'm no longer in?
Last edited by tralce : 07/20/21 at 09:35 AM.
Report comment to moderator  
Reply With Quote
Unread 07/15/21, 12:51 AM  
fredd

Forum posts: 0
File comments: 2
Uploads: 0
Originally Posted by jayman10000
Originally Posted by lnfinity
whats your solution? i do crafting writs daily on 11 chars and this is so annoying
.
Yeah me too the solution was I found a solution through an addon that offers a keybind for quitting, when using that the quit feature from libhistoire wont trigger. I found out you can actually also just type /logout (or /quit) in the chat field, as that is what the addons do, and then libhistoire wont complain.

This is a nice solution I think, that way both features can work for us; if you use the menu to quit/logout you get warning from lihistoire which is actually a good feature. But if you deliberately use /logout or /quit then you KNOW what you are doing it doesnt have to bug you with the message about missing history data getting lost (and you can also copy/paste those commands it so it will be almost more easy than using menu).


If you need an addon for it I know T.O.M. has keybinds for quitting.

Originally Posted by Sharlikran
That makes no sense. The nag as you and others call it isn't so that you leave the game running. You press one single (but yes additional) key to log out, or request your data. Because again, the server won't give you sales any faster then the server wants to. If you want to maintain you sales later that's fine press alt and log out.
Thank you Sharlikran for your wonderful work; my personal wish is that the above functionality can be left as it is now to support both, so we still get warning when using menu to logout or quit, but when using /logout or /quit from chat there will be no warning!
Hi what is T.O.M please I can't find this on ESOUI what does it stand for? thx
Report comment to moderator  
Reply With Quote
Unread 06/27/21, 02:32 AM  
Sharlikran
 
Sharlikran's Avatar
AddOn Author - Click to view AddOns

Forum posts: 298
File comments: 1284
Uploads: 11
Originally Posted by assoui
Thank you for this addon. Just one query, is this addon required by any other addon other that Master Merchant?

Because I have alot of addons and this addon seems to want to scan my guild history even when I disabled Master Merchant so I am checking if any other addon could be invoking it. I usually leave library addons alone in my Cyro addon profile as they don't [usually] do any activity unless used by another non-library addon.

If it does do something on its own without invoking from a main addon, I would suggest removing the lib from the addon name as it may cause confusion when optimizing addon loading.
Version 3.1.0 of MM would have done the same thing. The server decides how often to send new events but it does not disable that if you are in Cyrodiil. The Library is responding to the server not that the library has a fault to it.

So if you are in Cyrodiil and you want to disable MM (which makes sense) then disable LibHistoire as well.

Caution though. Many people dislike that the server does not send events quickly enough. If you disable LibHistoire when you have unlinked events it will interrupt that. So I suggest fully linking all events before you disable LibHistoire.

Once you enable LibHistoire and MM again then it will pick up where you left off as if you had been logged out for the day.
__________________
Admin for TES5Edit, occasional LOOT masterlist contributor, and Wrye Bash contributor. I also maintain special Fallout 3 and Fallout NV versions of Wrye Flash.
Last edited by Sharlikran : 06/27/21 at 02:47 AM.
Report comment to moderator  
Reply With Quote
Unread 06/27/21, 01:28 AM  
assoui

Forum posts: 0
File comments: 21
Uploads: 0
Thank you for this addon. Just one query, is this addon required by any other addon other that Master Merchant?

Because I have alot of addons and this addon seems to want to scan my guild history even when I disabled Master Merchant so I am checking if any other addon could be invoking it. I usually leave library addons alone in my Cyro addon profile as they don't [usually] do any activity unless used by another non-library addon.

If it does do something on its own without invoking from a main addon, I would suggest removing the lib from the addon name as it may cause confusion when optimizing addon loading.
Report comment to moderator  
Reply With Quote
Post A Reply



Category Jump:

Support AddOn Development!

You have just downloaded by the author . If you like this AddOn why not consider supporting the author? This author has set up a donation account. Donations ensure that authors can continue to develop useful tools for everyone.