tvlfrosty / Reputation_Guide

A World of Warcraft addon to help you manage your reputation and Factions.
GNU General Public License v3.0
3 stars 6 forks source link

Script running too long #79

Closed Peregran closed 2 months ago

Peregran commented 2 months ago

Newest release 1.2.3:

2x ReputationGuide/ReputationGuide.lua:606: script ran too long [string "@ReputationGuide/ReputationGuide.lua"]:606: in function Init' [string "@ReputationGuide/ReputationGuide.lua"]:453: in functionREP_OnEvent'

Locals: self =

{ IsClassicPhaseFour = false LIMIT_TYPE_Incr = 12 AfterCata = true ShowDragonflightPhaseThree = true ShowClassicPhaseFour = true AfterClassic = true Version = "11.0.0-release" ShowClassicSOMPhaseFour = false IsDragonflightPhaseOne = false IsTheLastTitan = false LIMIT_TYPE_Ench = 10 Tools =
{ } IsClassicSOD = false

Starlynk1 commented 2 months ago

This is a killer for the game, locks up the whole window until that script times out and wow proceeds. Nearly game breaking bug.

tvlfrosty commented 2 months ago

I will have a look at it right away, if you have any more details on what you were doing when you got the error that would be very helpful

TomNookman commented 2 months ago

I was able to replicate this issue multiple times when gaining reputation by turning in the faction items to NPCs in the Dragon isles Titan Relic is one and Dragon Isles Artifact was another

Peregran commented 2 months ago

I was just logging into my character and the system hung at the screen after selecting my toon and before the game screen appeared.

Starlynk1 commented 2 months ago

I was turning in the daily quest for the echoes event

tvlfrosty commented 2 months ago

Hmm alright, so the main script that is causing it is only loaded once which should indeed be upon login. But it would affect further reputation turn ins / quests based on how many factions you have unlocked...

I am trying to find a different way to do this at the moment because I really don't want to force people to have all reputation headers expanded to see the reputation values printed...

11.0.0 somehow changed the behaviour of GetNumFactions() and it only returns visible factions now.

tvlfrosty commented 2 months ago

I reverted some of the changes in the 1.2.4-release that is currently being uploaded to Curseforge, this should fix the long load times that the previous update caused.

However this will break the reputation messages again if a faction is not visible in the ReputationFrame due to collapsed headers and the option "Replace original faction gain messages with a more detailed version" is turned on.

I will keep looking for a fix for that specific issue which was mentioned in the #63. But in the meantime hopefully this will affect less people.

And for the people that are affected by the issue where the chat message are not shown, please either turn of the option mentioned above or make sure the faction you are gaining reputation with is visible in the ReputationFrame until I can come up with a better fix for the changes to C_Reputation.GetNumFactions().

Starlynk1 commented 2 months ago

Very strange that this would be an issue. According to the 11.0.2.56162 API, C_Reputation.GetNumFactions has not been deprecated and is still available to call upon. I'm not an expert of coding, so unfortunately, I can't help with a reason why it failed now.


From: tvlfrosty @.> Sent: Monday, August 19, 2024 12:22 PM To: tvlfrosty/Reputation_Guide @.> Cc: Chad Rice @.>; Comment @.> Subject: Re: [tvlfrosty/Reputation_Guide] Script running too long (Issue #79)

I reverted some of the changes in the 1.2.4-release that is currently being uploaded to Curseforge, this should fix the long load times that the previous update caused.

But will break the reputation messages again if a faction is not visible in the ReputationFrame due to collapsed headers and the option "Replace original faction gain messages with a more detailed version" is turned on.

I will keep looking for a fix for that specific issue which was mentioned in the #63https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_tvlfrosty_Reputation-5FGuide_issues_63&d=DwMCaQ&c=euGZstcaTDllvimEN8b7jXrwqOf-v5A_CdpgnVfiiMM&r=XodWtLBkFpvdbc-aEppP_ibPteZq0Cpnye3A6MMh-wk&m=uG54OXL6bb5JHg9KiRp7iQ94Q4b7AW_Nsi1j-7B-khc9jgMTM8WgKb2EH8G4DRG5&s=kKGTO8FtoY4nCgZeVa29xg_H0JjPLXdW5T2q-P8kNXk&e=. But in the meantime hopefully this will affect less people.

And for the people that are affected by the issue where the chat message are not shown, please either turn of the option mentioned above or make sure the faction you are gaining reputation with is visible in the ReputationFrame until I can come up with a better fix for the changes to C_Reputation.GetNumFactions().

— Reply to this email directly, view it on GitHubhttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_tvlfrosty_Reputation-5FGuide_issues_79-23issuecomment-2D2297279179&d=DwMCaQ&c=euGZstcaTDllvimEN8b7jXrwqOf-v5A_CdpgnVfiiMM&r=XodWtLBkFpvdbc-aEppP_ibPteZq0Cpnye3A6MMh-wk&m=uG54OXL6bb5JHg9KiRp7iQ94Q4b7AW_Nsi1j-7B-khc9jgMTM8WgKb2EH8G4DRG5&s=E3-85DoSUs-NUDwSXQGUF4F86yqDNLxMnNIhCdewfWA&e=, or unsubscribehttps://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_AVZVK5BTNULAXA4WGJUH3XDZSJAY5AVCNFSM6AAAAABMWY56J2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEOJXGI3TSMJXHE&d=DwMCaQ&c=euGZstcaTDllvimEN8b7jXrwqOf-v5A_CdpgnVfiiMM&r=XodWtLBkFpvdbc-aEppP_ibPteZq0Cpnye3A6MMh-wk&m=uG54OXL6bb5JHg9KiRp7iQ94Q4b7AW_Nsi1j-7B-khc9jgMTM8WgKb2EH8G4DRG5&s=sI1AYoy1fdlALqvJIPwx0qpPdPxtjkreOxQAQ0uGjSk&e=. You are receiving this because you commented.Message ID: @.***>

tvlfrosty commented 2 months ago

Hey @Starlynk1, it is indeed still available, but before 11.0.0 it was just GetNumFactions(), it's now moved to the namespace C_Reputation.GetNumFactions(). And with that it seems it's now only returning the visible factions. So if one of the expansion headers is collapsed it no longer returns those 'hidden' factions.

It used to work fine before 11.0.0, so I am assuming those new expansion/faction headers are somehow causing the hidden factions not to be returned with C_Reputation.GetNumFactions() which is a massive issue for the addon at the moment.

I personally don't have that many factions unlocked on my retail character so all my headers were expanded and It was showing the reputation values in chat as expected, so I didn't notice the problem during the 11.0.0 patch, untill someone mentioned it after the 11.0.2 patch.