def button(self, bot, update):
query = update.callback_query
bot.editMessageText(text="Capturing image of topic: %s" % query.data,
chat_id=query.message.chat_id,
message_id=query.message.message_id)
img_file_path = self.get_image(image_topic=query.data)
bot.editMessageText(text="Uploading captured image of topic: %s" % query.data,
chat_id=query.message.chat_id,
message_id=query.message.message_id)
bot.send_photo(chat_id=query.message.chat_id,
photo=open(img_file_path, 'rb'),
caption="This is what I see on topic " +
query.data)
# update.message.reply_photo(photo=open(img_file_path, 'rb'),
# caption="This is what I see on topic " +
# query.data)
choose_topic_image_reply.py 文件源码
python
阅读 17
收藏 0
点赞 0
评论 0
评论列表
文章目录