metoya
metoya

Reputation: 1

VSccode can't recognize html5lib (I installed it)

Visual Studio Code not reading html5lib

I am using bs4 in VS Code, along with html5lib, but VS Code is indicating that it does not exist (I installed it using the command prompt).

import requests 
from bs4 import BeautifulSoup

URL = " "
r = requests.get(URL) 

soup = BeautifulSoup(r.content, 'html5lib')
print(soup.prettify())

Upvotes: 0

Views: 67

Answers (1)

MingJie-MSFT
MingJie-MSFT

Reputation: 9229

Usually, ModuleNotFound error was caused by incorrect python interpreter if you have installed the package.

You can use shortcuts Ctrl+Shift+P and search for "Python: Select Interpreter" to choose the python interpreter which you install your python package in.

Upvotes: 0

Related Questions