$def with(book, size="M") $ title = book.title $ author_names = ", ".join(a.get("name", "Name missing") for a in book.get_authors()) or book.get('by_statement','') $ cover_url = book.get_cover_url(size) $ cover_lg = book.get_cover_url("L") $if size == "M":
$_('Cover of: %(title)s by %(authors)s', title=title, authors=author_names)
$_('We need a book cover for: %(title)s', title=title)
$else: $_('We need a book cover for: %(title)s', title=title)