Added "run until valid" feature#56
Added "run until valid" feature#56akayy-dev wants to merge 2 commits intologicguy1:mainfrom akayy-dev:feature/run_until_valid
Conversation
|
Can someone add colors to it |
idk if the maintainer of this project abandoned it or something but there is already an open pull request with this exact feature and more. |
|
No deffenately not just busy with exams etc lately |
| time.sleep(1) # Wait a little more | ||
| self.slowType("\nInput How Many Codes to Generate and Check: ", .02, newLine = False) # Print the first question | ||
| self.slowType("\nRun until valid code is found? y/n ", .02, newLine = False) | ||
| infinite_choice = input('') |
There was a problem hiding this comment.
elif infinite_choice == "n" or infinite_choice == "N":
if infinite_choice == "y" or infinite_choice == "Y":
Those "or" in the beginning are unnecessary.
You could just use:
infinite_choice = input('').lower()
and then all of those wouldn't be necessary.
There was a problem hiding this comment.
You could add a .strip() to infinite choice too.
infinite_choice = input('').lower().strip()
making the user life easier.
There was a problem hiding this comment.
Or just use a check if it is in like if "y" in input.lower()
Current Functionality
As of right now, the only option for generation of codes is to input the amount of codes you want the program to check for, this can get quite annoying long-term to have to check each periodically to restart the program.
Issue #34
Run Until Valid
My PR lets the user run the program for an indefinite amount of time until a valid code is found.
New behavior
Upon starting of the program, the user will be asked if he/she wants to run the program until a valid code is found or generate a specified amount of codes.