Haselnussbomber / HaselTweaks

A collection of quality of life tweaks and more.
GNU Affero General Public License v3.0
73 stars 9 forks source link

FPS DTR entry broken #123

Closed sersorrel closed 1 month ago

sersorrel commented 1 month ago

The FPS DTR entry is missing:

image

the following error looks relevant:

23:07:11.667 | ERR | [HaselTweaks] [DTR] Error while enabling tweak
    System.ArgumentException: An entry with the same title already exists.
       at Dalamud.Game.Gui.Dtr.DtrBar.Get(LocalPlugin plugin, String title, SeString text) in C:\goatsoft\companysecrets\dalamud\\Game\Gui\Dtr\DtrBar.cs:line 121
       at Dalamud.Game.Gui.Dtr.DtrBarPluginScoped.Get(String title, SeString text) in C:\goatsoft\companysecrets\dalamud\\Game\Gui\Dtr\DtrBar.cs:line 640
       at HaselTweaks.Tweaks.DTR.OnEnable() in /_/HaselTweaks/Tweaks/DTR.cs:line 45
       at HaselTweaks.TweakManager.Initialize() in /_/HaselTweaks/TweakManager.cs:line 36

This seems new after updating to v25.2.8?

Haselnussbomber commented 1 month ago

Not sure. I haven't encountered it yet and I also haven't touched any relevant parts. There were changes to the DtrBar service in Dalamud recently, maybe that's causing it. 🤷‍♂️ Maybe it was just after an update. Restarting the game should fix it.

sersorrel commented 1 month ago

indeed restarting the game fixed it.

sersorrel commented 1 month ago

happened again after the most recent update, fwiw

Haselnussbomber commented 1 month ago

Do you have logs of the plugin unloading and unregistering DtrBar entries?

sersorrel commented 1 month ago
18:53:44.994 | INF | [LOCALPLUGIN] Unloading "HaselTweaks"
18:53:45.014 | DBG | [HaselTweaks] [CommandService] Unregistering /gsg
18:53:45.021 | DBG | [HaselTweaks] [CommandService] Unregistering /itemlink
18:53:45.021 | DBG | [HaselTweaks] [CommandService] Unregistering /whatmount
18:53:45.021 | DBG | [HaselTweaks] [CommandService] Unregistering /whatbarding
18:53:45.021 | DBG | [HaselTweaks] [CommandService] Unregistering /glamourplate
18:53:45.023 | DBG | [HaselTweaks] [CommandService] Unregistering /haseltweaks
18:53:46.037 | INF | [LOCALPLUGIN] Finished unloading "HaselTweaks"
18:53:46.037 | DBG | [PLUGINM] Installing plugin HaselTweaks (testing=False, version=26.0.0, reason=Update)
18:53:46.038 | DBG | [PLUGINM] Extracting to "Z:\home\ash\.xlcore\installedPlugins\HaselTweaks\26.0.0"
18:53:46.098 | INF | [PLUGINM] Installed plugin HaselTweaks (testing=False)
18:53:46.098 | INF | [PLUGINM] Loading plugin HaselTweaks
18:53:46.098 | INF | [PLUGINM] "HaselTweaks" defaultState: True wantedByAnyProfile: True loadPlugin: True
18:53:46.104 | INF | [LOCALPLUGIN] Loading HaselTweaks.dll
18:53:46.652 | INF | [LOCALPLUGIN] Finished loading "HaselTweaks"
18:53:46.652 | DBG | [PLUGINM] Starting plugin update check...
18:53:46.654 | DBG | [PLUGINM] Update check found 0 available updates.
18:53:46.655 | DBG | [PLUGINM] Starting plugin update check...
18:53:46.657 | DBG | [PLUGINM] Update check found 0 available updates.
18:53:46.776 | DBG | [HaselTweaks] [CommandService] Registering /itemlink
18:53:46.777 | DBG | [HaselTweaks] [CommandService] Registering /whatmount
18:53:46.777 | DBG | [HaselTweaks] [CommandService] Registering /whatbarding
18:53:46.777 | DBG | [HaselTweaks] [CommandService] Registering /glamourplate
18:53:46.781 | ERR | [HaselTweaks] [DTR] Error while enabling tweak
    System.ArgumentException: An entry with the same title already exists.
       at Dalamud.Game.Gui.Dtr.DtrBar.Get(LocalPlugin plugin, String title, SeString text) in C:\goatsoft\companysecrets\dalamud\\Game\Gui\Dtr\DtrBar.cs:line 121
       at Dalamud.Game.Gui.Dtr.DtrBarPluginScoped.Get(String title, SeString text) in C:\goatsoft\companysecrets\dalamud\\Game\Gui\Dtr\DtrBar.cs:line 640
       at HaselTweaks.Tweaks.DTR.OnEnable() in /_/HaselTweaks/Tweaks/DTR.cs:line 45
       at HaselTweaks.TweakManager.Initialize() in /_/HaselTweaks/TweakManager.cs:line 36
18:53:46.799 | DBG | [HaselTweaks] [CommandService] Registering /gsg
18:53:46.822 | DBG | [HaselTweaks] [CommandService] Registering /haseltweaks
18:53:46.840 | WRN | [HITCH] Long "FrameworkUpdate" detected, 175.2417ms > 50ms - check in the plugin stats window.
18:53:59.911 | INF | [HaselTweaks] Configuration saved.
Haselnussbomber commented 1 month ago

Not sure if you've been reading #dalamud-dev, but this is a bug in Dalamuds ServiceScope, which doesn't wait for the disposal of the DtrBar service and continues to load the plugin before the entries are removed. So, I can't do anything here. You have to wait for a Dalamud update. 😅