Category : modulenotfounderror

I have a working python script that calls data using elasticsearch python api client. The script was developed for unix/ubuntu environment and works. The script however does not work in windows environment, because some of the modules/functions used in python script (developed in ubuntu environment) are not available. I am not able to get equivalent ..

Read more

I have issues with path settings with pytest. Whenever I use pytest within a project, I run into problems how to correctly import stuff. To my setup, I am using Python 3.9 with pytest 6.2. Folder Structure My folder structure looks like this: project_folder/ app_folder/ libs/ __init__.py config.py class_file_1.py class_file_2.py main.py tests/ __init__.py test_class_file_1.py Problem ..

Read more

I’m trying to create a discord bot, but i have basic problem… I have this on start of code: import discord.py from discord.ext import commands Im gettin that error: PS C:Userstrnka> & "C:/Program Files/Inkscape/bin/python.exe" c:/Python_projects/Discord_Bots/RCN_bot/RCN.py Traceback (most recent call last): File "c:Python_projectsDiscord_BotsRCN_botRCN.py", line 1, in import discord.py ModuleNotFoundError: No module named ‘discord’ But I have ..

Read more

First of all I ran "poetry update" which seemed to work. To verify if it actually updated my poetry version I ran "poetry –version" which resulted in the following error: Traceback (most recent call last): File "C:UsersXXX.poetrybinpoetry", line 17, in <module> from poetry.console import main ModuleNotFoundError: No module named ‘poetry.console’ To solve this error, uninstalling ..

Read more

I want to run the 3 code snippets from this webpage. I’ve made all 3 one post, as I am assuming it all stems from the same problem of optimum not having been imported correctly? Kernel: conda_pytorch_p36 Installations: pip install optimum OR ! pip install datasets transformers optimum[intel] Both provide same Traceback: Requirement already satisfied: ..

Read more

I’m running into problems installing a Python package locally for development on Linux. There is only one Python available, at this location: $ which python3 /home/USERNAME/software/python/Python-3.9.1/bin/python3 For reproducibility, I’ve added the forked python package I’m working with here: https://github.com/evanbiederstedt/edlibtest/tree/main/bindings/python My problem is the following: When I try to locally install the package with pip install ..

Read more