首页
学习
活动
专区
工具
TVP
发布
社区首页 >问答首页 >python电报机器人模块(telebot)

python电报机器人模块(telebot)
EN

Stack Overflow用户
提问于 2018-09-17 00:15:05
回答 1查看 211关注 0票数 -2

我已经写了一个简单的示例机器人与远程机器人模块,但我不知道我应该如何解决这个问题。我的代码是:

代码语言:javascript
复制
import telebot

bot = telebot.testBot("699870969:AAHth6QQWI8GR2CuCyW9V98F3CXUIA2siAw")

@bot.message_handler(commands = ['start', 'help'])
def send_welcome(message):
   bot.reply_to(message, "hesam, how are you ?")


@bot.message_handler(func=lambda message: True)
def echo_all(message):
   bot.reply_to(message, message.text)

bot.polling()

错误:远程机器人模块没有测试机器人

的属性

EN

回答 1

Stack Overflow用户

发布于 2018-09-17 01:50:07

看起来您拼写错了TeleBot类名。参见the example

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/52356024

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档