WeakAuras

WeakAuras

206M Downloads

Shadowlands Beta: Divide by zero error in groupCountFunc when dead

jf647 opened this issue ยท 3 comments

commented

Describe the bug

Died on Shadowlands beta. I have an aura that triggers on <= 0.8 of the group missing Battle Shout.

Expected nothing special.

Instead, WA started throwing this errors repeatedly (up to 8k as I write this, ~3m since dying)

Do you have an error log of what happened?

Message: [string "--[==[ Error in 'Unknown' ]==]     return f..."]:2: Division by zero
Time: Sun Aug  2 21:30:58 2020
Count: 10071
Stack: [string "--[==[ Error in 'Unknown' ]==]     return f..."]:2: Division by zero
[string "--[==[ Error in 'Unknown' ]==]     return function(count, max)
      local fraction = count/max
      if(fraction <= 0.8) then
        return true
      else
        return false
      end
    end
  "]:2: in function `groupCountFunc'
[string "@Interface\AddOns\WeakAuras\BuffTrigger2.lua"]:989: in function <Interface\AddOns\WeakAuras\BuffTrigger2.lua:988>
[string "@Interface\AddOns\WeakAuras\BuffTrigger2.lua"]:1031: in function <Interface\AddOns\WeakAuras\BuffTrigger2.lua:1009>
[string "@Interface\AddOns\WeakAuras\BuffTrigger2.lua"]:1355: in function <Interface\AddOns\WeakAuras\BuffTrigger2.lua:1350>
[string "@Interface\AddOns\WeakAuras\BuffTrigger2.lua"]:1674: in function <Interface\AddOns\WeakAuras\BuffTrigger2.lua:1667>

Locals: count = 0
max = 0
(*temporary) = nil
(*temporary) = nil
(*temporary) = "Division by zero"

To Reproduce

Died. The errors are raised while waiting to release and while a ghost. They stop the moment you resurrect.

Steps to reproduce the behavior:

  1. Install aura from the linked gist below.
  2. Die
  3. Profit?

Which version of WeakAuras are you using?

3.0.0-alpha4

Are you on World of Warcraft Classic or Retail?

  • [] Classic
  • [] Retail
  • Shadowlands beta

Was it working in a previous version? If yes, which was the last good one?

The aura is unchanged from the one I use on retail, where this does not happen.

Additional Info

Export string for the aura: https://gist.github.com/jf647/813013aab273cabbf5100ff739409bee

commented

On non release build like ptr and beta, more things throw error.
The error is due to your custom code.

commented

No, this is a actual bug in the grow function.

Though you are right that it only occurs due to the beta behaving differently from live.

commented

Fixed.