def METHOD_NAME(self, operation: str | None, timeout_occurred: bool = False):
    matching_items = []
    for item in self._data.values():
        if (operation is None or item["operation"] == operation) and item["timeout_occurred"] == timeout_occurred:
            matching_items.append(item)
    return matching_items