BetterBags

BetterBags

1M Downloads

Unknown operator lua error when using search

rwrose02 opened this issue ยท 2 comments

commented

Addon Version

v0.3.10

World of Warcraft Version

Retail

Describe the bug

When using search feature to create a custom category if you are trying to search "exp != TWW" but mistype the char following "!", such as "exp !+ TWW" a lua error is triggered on "+" being typed in. The error is correctly reported as an invalid operator, but the error isn't handled internally and is instead reported to the user via bugsack. I'm not super familiar with the standard error handling process used for wow addons but this error is caught by bugsack not by the addon itself. This might be an irrelevant report but I figured I'd report it since I only get a lua error on mistyping when using this specific operator in a search query and not when mistyping other search queries.

Bugsack Report:
8x BetterBags/data/search.lua:566: Unknown operator: !
[string "=[C]"]: in function error' [string "@BetterBags/data/search.lua"]:566: in function <BetterBags/data/search.lua:544> [string "=(tail call)"]: ? [string "@BetterBags/data/search.lua"]:659: in function EvaluateQuery'
[string "@BetterBags/data/search.lua"]:383: in function Search' [string "@BetterBags/frames/search.lua"]:136: in function UpdateSearch'
[string "@BetterBags/frames/search.lua"]:258: in function <BetterBags/frames/search.lua:257>
[string "@BetterBags/core/context.lua"]:164: in function <BetterBags/core/context.lua:162>

Locals:
(*temporary) = "Unknown operator: !"

Steps to reproduce

open bag and start typing any search term followed by does not equal such as "exp !+". The lua error is repeatedly triggered upon entering any char immediately after the "!" that doesn't result in a valid operator.

commented

was fixed in v0.3.12

commented

This is a very good bug catch, and yes, this should not be exposed -- this is by accident and a real bug. I'll fix this in the next release.