Sport
SportUseCase
Bases: AbstractUseCase
Use case for sports
check_proactivity()
Check if there is a proactivity to be triggered
- TODO: Why is it necessary to check if valid_teams is None twice?
choose_league(leagues)
Returns the league the users chooses.
- TODO: Refactor by using
print_options
andget_int
Returns:
Type | Description |
---|---|
str
|
The league the user chooses. |
choose_team(teams)
Returns the team the users chooses.
- TODO: Refactor by using
print_options
andget_int
Returns:
Type | Description |
---|---|
str
|
The team the user chooses. |
get_matchday_num(max_num)
trigger_assistant(best_match)
UseCase for sport
- TODO: Implement
quotes_key
- TODO: Fix typing (remove type ignore)
- TODO: Refactor try except blocks to only include the api call
Parameters:
Name | Type | Description | Default |
---|---|---|---|
best_match |
BestMatch
|
An object containing the best match for the user input. |
required |
Raises:
Type | Description |
---|---|
NotImplementedError
|
If the given key was not found in the match case statement for implemented functions, or if the function is not implemented yet. |