Command to identify matching regex
See original GitHub issueFrequently in the recent past, we have had some “wtf” moments when an innocuous-looking phrase in a post triggered a “bad keyword in answer” or similar. Troubleshooting these is slow and somewhat demanding. Couldn’t we have Smoke Detector simply tell us which regex matched?
This was explored in the past when Quartata (I think it was) looked into having this information available for every post, but it turned out to be too slow.
A much less imposing solution would be to only provide this information when it is explicitly demanded, perhaps through a dedicated command.
I propose !!/bisect
though it’s probably too obscure. “Why” is already taken and !!/wtf
is probably too easy to type in by mistake … Additional proposals welcome.
The implementation I am imagining would check the input against everything, then gradually discard more and more of the blacklists until it has identified a single regex which is responsible for the detection.
(Corner case: What if a phrase matches more than one?)
Issue Analytics
- State:
- Created 5 years ago
- Comments:6 (6 by maintainers)
Top GitHub Comments
Example: https://chat.stackexchange.com/transcript/message/48279574#48279574
Details: https://stackoverflow.com/c/charcoal/questions/505
@tripleee I’m thinking of only running the check against the blacklists and watchlists, not the fixed regexes in function-based checks.