- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我在 python 中尝试了以下代码:
from newspaper import Article
#A new article from BBC
url = "http://www.bbc.com/news/magazine-26935867"
#For different language newspaper refer above table
BBC_article = Article(url, language="en") # en for English
我收到以下错误:
Traceback (most recent call last): File "news_paper_article.py", line 3, in from newspaper import Article
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/newspaper/init.py", line 10, in from .article import Article, ArticleException
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/newspaper/article.py", line 12, in from . import images File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/newspaper/images.py", line 21, in from . import urls
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/newspaper/urls.py", line 16, in from tldextract import tldextract ImportError: No module named tldextract
这可能是一些简单的问题,但我才刚刚开始,我们将不胜感激。
最佳答案
尝试:
pip install tldextract
关于python - "No module named tldextract",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46158754/
我是一名优秀的程序员,十分优秀!