Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some recipes throw an error in StatweightCalculation.lua:93 #2

Closed
Znuff opened this issue Dec 22, 2022 · 2 comments
Closed

Some recipes throw an error in StatweightCalculation.lua:93 #2

Znuff opened this issue Dec 22, 2022 · 2 comments

Comments

@Znuff
Copy link

Znuff commented Dec 22, 2022

Trace:

1x CraftSim/StatweightCalculation.lua:93: bad argument #1 to 'pairs' (table expected, got nil)
[string "=[C]"]: in function `pairs'
[string "@CraftSim/StatweightCalculation.lua"]:93: in function `GetExpectedQualityBySkill'
[string "@CraftSim/Frames.lua"]:1345: in function `UpdateSimModeStatDetails'
[string "@CraftSim/SimMode.lua"]:95: in function `InitSimModeData'
[string "@CraftSim/CraftSim.lua"]:343: in function `TriggerModulesByRecipeType'
[string "@CraftSim/CraftSim.lua"]:100: in function <CraftSim/CraftSim.lua:99>

Recipe: https://www.wowhead.com/spell=376564/fiddle-with-khazgorite-fabric-cutters

Checking for thresholds before should fix it:

    if thresholds then
        for _, threshold in pairs(thresholds) do
            if skill > threshold then
                expectedQuality = expectedQuality + 1
            end
        end
    end
@derfloh205
Copy link
Owner

Also not able to reproduce in 1.7.7

@derfloh205
Copy link
Owner

As I was not able to reproduce it in the newest version and had no other people report that I am closing this for now
If this occurs again feel free to open another issue!
Have a nice day :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants