Answer the question
In order to leave comments, you need to log in
A joint with a QR code made in Python when sent to Telegram. How to fix?
The task is to create a QR code and send a picture to telegram.
There is such a code, it is working, but with a nuance
import pyqrcode
qr_obj = pyqrcode.create('QR ТЕКСТ')
buffer = BytesIO()
qr_obj.png(buffer)
bot.send_photo(chat_id=some_chat_id, photo=buffer.getvalue())
Answer the question
In order to leave comments, you need to log in
have you read the documentation ?
import pyqrcode
qr_obj = pyqrcode.create('QR ТЕКСТ')
buffer = BytesIO()
qr_obj.png(buffer, scale=10)
bot.send_photo(chat_id=some_chat_id, photo=buffer.getvalue())
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question