Conversation
| case _: | ||
| raise ValueError('Unhandled result type') | ||
|
|
||
| if not username: |
There was a problem hiding this comment.
It looks like _check_for_correct_username is supposed to ensure that the username starts with a lowercase letter or underscore (but it's not doing so).
There was a problem hiding this comment.
I can trigger the message The username you entered is invalid to appear below the input field by starting a username without a lowercase letter or underscore. I am not sure why it is not working for you.
Seems like skip would be the intended outcome when pressing enter at an empty input field.
There was a problem hiding this comment.
Did you mean, why is an empty string not triggering the validator? The validator will not be used when text is an empty string.
archinstall/archinstall/tui/curses_menu.py
Lines 562 to 563 in b2b36a2
There was a problem hiding this comment.
Ah, yes, that was the confusing part. I assumed the validator function would run on all inputs :).
There was a problem hiding this comment.
An empty string is essentially no input, so there is nothing to validate. Makes sense to me anyway.
Fixes #3532