简体   繁体   English

安装了 python-telegram-bot 但仍然显示“没有名为'telegram'的模块”

[英]Installed python-telegram-bot but still showing "No module named 'telegram'"

Hi I already installed Python-telegram-bot using pip install python-telegram-bot.嗨,我已经使用 pip install python-telegram-bot 安装了 Python-telegram-bot。 However, when i run my python file in VS, it shows "No module named 'telegram'. I confirmed that i only have 1 version of python installed 3.8.3 and still unable to find any solution.但是,当我在 VS 中运行我的 python 文件时,它显示“没有名为‘telegram’的模块。我确认我只有一个版本的 python 安装了 3.8.3 并且仍然找不到任何解决方案。

I have anaconda installed as well, and i am not sure if it is the cause to this issue.我也安装了 anaconda,我不确定这是否是导致此问题的原因。

The error is prompted in the line below:错误提示在下面一行:

from telegram.ext import Updater, CommandHandler, MessageHandler, Filters

Just do this pip install python-telegram-bot只需执行此操作 pip 安装 python-telegram-bot

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM