Answer the question
In order to leave comments, you need to log in
Learning to make tg bots,Error FileNotFoundError: [Errno 2] No such file or directory: 'static/ky.jpg'?
import telebot
import config
bot = telebot.TeleBot(config.token)
@bot.message_handler(commands=['start'])
def welcome(message):
sti = open('static/ky.jpg', 'rb')
bot.send_sticker(message.chat.id, sti)
bot.send_message(message.chat.id, "Ку бро, {0.first_name}!\nЯ - <b> твой крол! ".format(message.from_user, bot.get_me()),
parse_mode='html')
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question