clinton-hall / nzbToMedia

Provides NZB and Torrent postprocessing To CouchPotatoServer, SickBeard/SickRage, HeadPhones, Mylar and Gamez
GNU General Public License v3.0
673 stars 176 forks source link

Error after migration to Docker from Kubernetes #2003

Closed fadern closed 2 weeks ago

fadern commented 2 weeks ago

Describe the bug I have my nzbtomedia script in a separate folder that I mount into the SAB docker/pod. This have successfully worked in kubernetes but when truenas dropped the support for kubernetes I had to move to Docker. Now Sab runs in Docker.

Technical Specs

  1. Running on TrueNAS 24.10 (Docker)
  2. Python version 3.13
  3. Download Client SABnbzd
  4. Intended Media Management SickChill
  5. nzbToMedia 12.1.13

Expected behavior The script should run successfully.

Log Changing to directory: /mnt/nzbToMedia

-- Cleaning bytecode -- WARNING: Automatic cleanup could not be executed. If errors occur, manual cleanup may be required. REASON : Error: [Errno 2] No such file or directory: 'git'

Directory is not a git repository

Force cleaning folder: libs Skipping required subfolders ['common', 'custom', 'py2', 'win']

Force cleaning folder: core Skipping required subfolders ['auto_process', 'extractor', 'plugins', 'processor', 'utils'] Returning to directory: /app

-- Cleanup finished --

Traceback (most recent call last): File "/mnt/nzbToMedia/nzbToMedia.py", line 734, in import core File "/mnt/nzbToMedia/core/init.py", line 52, in from core import logger, main_db, version_check, databases, transcoder File "/mnt/nzbToMedia/core/databases.py", line 11, in from core.utils import backup_versioned_file File "/mnt/nzbToMedia/core/utils/init.py", line 13, in from core.utils.common import clean_dir, flatten, get_dirs, process_dir File "/mnt/nzbToMedia/core/utils/common.py", line 14, in from core.utils.files import list_media_files, move_file File "/mnt/nzbToMedia/core/utils/files.py", line 14, in import mediafile as mediafiletool File "/mnt/nzbToMedia/libs/common/mediafile.py", line 52, in import imghdr ModuleNotFoundError: No module named 'imghdr'

fadern commented 2 weeks ago

It might be related to python 3.13 and mediafile. https://github.com/beetbox/mediafile/issues/67

fadern commented 2 weeks ago

Solved by changing to another sabnzbd image (lscr.io/linuxserver/sabnzbd) with python 3.12.

clinton-hall commented 2 weeks ago

Thanks for confirming. I actually have Python 3.13 support in Nightly. Should be merging to Master soon.