pyrit.exceptions.pyrit_placeholder_retry#
- pyrit_placeholder_retry(func: Callable) Callable [source]#
A decorator to apply retry logic.
Retries the function if it raises MissingPromptPlaceholderException. Logs retry attempts at the INFO level and stops after a maximum number of attempts.
- Parameters:
func (Callable) – The function to be decorated.
- Returns:
The decorated function with retry logic applied.
- Return type:
Callable