ModuleNotFoundError: No module named 'queue'
#1
Hi,

I try to port my addon to Kodi 19.4 and it fails to load with message ModuleNotFoundError: No module named 'queue'. The error referred to following line
Quote:import requests

A quick Google search for the error did not provide sufficient information to develop a fix for the issue. 

A snippet from log file is accessible at following link

ModuleNotFoundError: No module named 'queue'

What would be a solution to this issue?

Polar Bear
Reply
#2
(2022-07-04, 09:22)Polar Bear Wrote: Hi,

I try to port my addon to Kodi 19.4 and it fails to load with message ModuleNotFoundError: No module named 'queue'. The error referred to following line
Quote:import requests

A quick Google search for the error did not provide sufficient information to develop a fix for the issue. 

A snippet from log file is accessible at following link

ModuleNotFoundError: No module named 'queue'

What would be a solution to this issue?

Polar Bear

You might look here and the differences between Python 2 and 3.   It might be the cause.

"It's because of the Python version. In Python 2.x it's import Queue as queue; on the contrary in Python 3 it's import queue"

Beyond this we'll need to see your code.


Jeff
Running with the Mezzmo Kodi addon.  The easier way to share your media with multiple Kodi clients.
Service.autostop , CBC Sports, Kodi Selective Cleaner and Mezzmo Kodi addon author.
Reply
#3
looks to me like exception is in script.module.urllib3 so assuming 1.26.9+matrix.1 is installed, then there seems to be a problem in the python for Kodi, which is platform dependent (python 3.8 is supplied with kodi on windows and queue.py is a std module in the kodi folder tree.  Don't know about other platforms).

scott s.
.
Reply
#4
Hello,

thank your for your reply.

Perhaps additional information will be helpful in problem resolution.

OS: Windows 10
Kodi 19.4 Dev Test 1: downloaded from here (direct link)

The plugin was stripped to bare bone to demonstrate the issue and available at following location (for next 14 days).

Your assistance is greatly appreciated.

PolarBear
Reply
#5
That portable build is made by someone copy and pasting old versions over each other and due to Windows filesystems being case-insensitive on collisions includes files like:
Code:
2021-02-11 17:45:24 ..... 54374 App/Kodi/system/Python/Lib/ConfigParser.py
2021-02-11 17:45:24 ..... 11356 App/Kodi/system/Python/Lib/Queue.py
2021-02-11 17:45:24 ..... 26923 App/Kodi/system/Python/Lib/SocketServer.py

TLDR: it's broken, delete it and use official build.
Reply
#6
Hello,

indeed, once the official version of Kodi 19.4 was installed a few small issues emerged which was successfully fixed in very short period of time.

As of this moment the plugin works both in Windows 10 and on Android TV box (Kodi 19.2).

Note: I was bought by 'portable' Kodi test version which as was indicated has some issues.

Thank you for your assistance in resolution of the problem.

Polar Bear
Reply

Logout Mark Read Team Forum Stats Members Help
ModuleNotFoundError: No module named 'queue'0