img_1 Img_2 I'm trying to build an application that will summarize moderately long texts in 60 words or less. But 'flask', 'requests', and 'transformers' are underlined with a wave line. I've tried import the packages but an error keeps popping up.
from flask import Flask, jsonify, request
import requests
from transformers import pipeline
- the error that keeps popping up.
A Import "flask" could not be resolved Pylance (reportMissing|mports) [Ln 1, Col 6]
A Import "requests" could not be resolved from source Pylance (reportMissingModuleSource) [Ln 2, Col 8]
A Import "transformers" could not be resolved Pylance (reportMissinglmports) [Ln 3, Col 6]
img_1 Img_2 I'm trying to build an application that will summarize moderately long texts in 60 words or less. But 'flask', 'requests', and 'transformers' are underlined with a wave line. I've tried import the packages but an error keeps popping up.
from flask import Flask, jsonify, request
import requests
from transformers import pipeline
- the error that keeps popping up.
A Import "flask" could not be resolved Pylance (reportMissing|mports) [Ln 1, Col 6]
A Import "requests" could not be resolved from source Pylance (reportMissingModuleSource) [Ln 2, Col 8]
A Import "transformers" could not be resolved Pylance (reportMissinglmports) [Ln 3, Col 6]
Share
Improve this question
edited Jan 29 at 6:49
Chip Chop
asked Jan 29 at 6:45
Chip ChopChip Chop
11 bronze badge
4
|
1 Answer
Reset to default 0To use the packages you would need to install them. Depending on your setup this can vary. Based on your tags, I am assuming you're pip-installing packages. You need to run the following commands to install the packages:
- pip install Flask (https://pypi./project/Flask/)
- pip install requests (https://pypi./project/requests/)
- pip install transformers (https://pypi./project/transformers/)
Once you install these packages, ideally your errors should be resolved.
pip
, but have you used it? – Tim Roberts Commented Jan 29 at 6:52python
is not found, so the system doesn;t recognize what python is. – Cincinnatus Commented Jan 29 at 9:07