Проверьте это проблемное изображение. Я импортировал
module in Python and tried running it. It is imported and it is running good as well, but VSCode is giving a yellow line warning and showing that it is overriding with the module in
. It is asking me to change the name of
to something else, which I can't change because it will give me errors in other libraries like pandas, numpy, matplotlib, and OpenCV. How can I remove this unwanted warning?
This is the error I'm getting:
Код: Выделить всё
"c:\Users\Syed M Tayyab\Desktop\VS Code ML\venv\Lib\random.py" is overriding the stdlib module "random"PylancereportShadowedImports
I tried changing random.py To something else but as I mentioned earlier that changing randon.py to something else may solve this problem but will generate more problems in other libraries as random.py is also imported in them.
Источник:
https://stackoverflow.com/questions/763 ... o-solve-it