0

我正在用 pyrogram 制作一个机器人,将照片发送给一个人,但出现以下错误

local variable 'photographer' referenced before assignment

我的代码是

m = await client.send_photo(
        chat_id=message.chat.id,
        caption=f"Photo generated by @{user}...\n\n**Details**:\nOrigin Time:`{time}`\n**Width**: `{width}`\n**Height**: `{height}`\n_Description_: `{description}`\n**Photographer**: `{photographer}`\nGenerated by .....,..",
        photo=url,
        reply_markup=InlineKeyboardMarkup(
            [[InlineKeyboardButton("❌ Close ❌", callback_data = "close")]]
        ),
        parse_mode="markdown",
    )

如果你能帮助我,我将非常感激

4

0 回答 0