Method: rich.prompt.PromptBase.check_choice
Calls: 2, Exceptions: 0, Paths: 1Back
Path 1: 2 calls (1.0)
'egg' (1) 'foo' (1)
False (1) True (1)
1def check_choice(self, value: str) -> bool:
2 """Check value is in the list of valid choices.
3
4 Args:
5 value (str): Value entered by user.
6
7 Returns:
8 bool: True if choice was valid, otherwise False.
9 """
10 assert self.choices is not None
11 return value.strip() in self.choices