Limit multiple-digit numbers in Inequality #1214
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Forming a multiple-digit
numberInputValue
in the Inequality Modal was unlimited, which led to bad behaviour (e.g. overflowing from its menu container, large numbers facing integer limit issues, larger numbers being converted to scientific notation).I've run a script to check all symbolic questions on the site and found 10 total questions with answers containing 4 or more digits:
4 characters is also the amount that fit cleanly in the menu hexagon, so 4 positive digits / 3 negative digits is the safest answer.
Also to get in simultaneously for the Chemistry Checker, the
hasMetaSymbols
check now also tests for empty lists. This has already been tested by Content so shouldn't need too much checking.