WheatonCS / Lexos

Python/Flask-based website for text analysis workflow. Previous (stable) release is live at:
http://lexos.wheatoncollege.edu
MIT License
120 stars 20 forks source link

Analyze and Tokenize: negative numbers are currently accepted input #877

Closed mlimoges closed 5 years ago

mlimoges commented 5 years ago

I found this while attempting to activate error modals in similarity query Most Analyze functions will complete even if given negative input in the Tokenize box the html warns against this input but running the analysis usually will still generate results

mleblanc321 commented 5 years ago

can we deactivate the "Submit" buttons if invalid input detected, to prevent any hit to back end?

also, @mlimoges -- i'm using Chrome (on lexos3) and i cannot enter (any) values from the keyboard, only the arrows up/down work for changing input; thus i can't seem to enter negative values on Chrome ... but (aha) Firefox let's me manually enter from keyboard; e.g., -4 can be entered, the input field turns RED, but the -4 is sent to the back end :(

czhang03 commented 5 years ago

If you guys decided to check on the frontend, remember also check it on the relavent function on the backend for robustness.