-
Notifications
You must be signed in to change notification settings - Fork 176
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
nzbToMedia error - No module named imghdr #1769
Comments
Thanks @clinton-hall. I am already running the Sherpa qpkg. I recently updated both SAB and sickchill to the latest via Sherpa and have since had the above error. I'll update again and see how it goes |
@OneCDOnly |
It looks like it's found one of QNAP's Python's again - probably the internal Python 2.7.5. 😞 I may be able to fix this by including the same Working on this now... |
OK, just pushed a new nzbToMedia QPKG (200831). It now exports However, I'm not sure this will fix it as I'm not exactly a Python guru. @captainhowie can you please check which Python is run? Your NAS should show something like mine:
|
Interesting I don't think pythonpath will have any impact (and happy to be proven wrong)... This will add the location for Python modules, but only for the nzbToMedia install which doesn't call Python, and this won't change which python interpreter is called... Since the script is called from SAB, I believe it is the SAB package that is finding the "other" Python in the PATH. (however SAB still starts fine since you define I believe the easiest way to change this would be to either:
|
I still haven't resolved the problems with this method. It seems that if we install all the I need to work out how to keep the OpenWRT modules as the first preference, but this is outside my area of knowledge, so I've set it aside for now. |
Oh wait, I misread your suggestion. Yes, we already export in ... although, the way I wrote the logic for it, it only gets prepended to $PATH if it doesn't already exist anywhere in $PATH. I should change that to an automatic remove and prepend. |
Ah.. I see... yes, make /opt/bin always sit at front of PATH... As far as the pip issues, These should not interfere with OpenWRT if it is done within venv... as these are only installed for, and called by, each App with its own separate environment. I might see if I get Sherpa going on my QNAP and test... I'll let you know what I find. |
First part is identical second part lrwxrwxrwx 1 admin administrators 16 2020-08-13 18:09 /opt/bin/python -> /opt/bin/python3* |
Hi everyone. Apologies I didn't get a chance to update the forum. I updated all three packages via sherpa yesterday morning prior to the conversation above (sabnzbd, nzbtomedia, sickchill). I ran a tv program through last night and it successfully post processed. It appears something updated between the update a few days ago, and the update available 36hrs ago. Thanks team |
Done: OneCDOnly/sherpa@b8dbebb I’ll mod the other apps shortly. 🤓 |
@OneCDOnly I have a working version of sab using venv... I sent you a PR (you don't have to merge this, as it does undo changes you are recently made) but I figured this may be helpful (seeing as Entware introduced some fun challenges). |
and a PR for SickChill.... test and use as you will.... Happy to answer any questions about it. |
@clinton-hall thank you. Glad to see it can be done via I hope to revisit the I'll work on adding those mods when I can. Cheers! |
All good.... I'll leave my fork there with the PRs so you can review when you are ready to look at this... I personally found this cleaned up my apkgs so much and has made the packages easier to maintain. FWIW, I think the entire
block would be better off sitting in the installation routine and only done/checked once.
then start the daemon with appropriate arguments. In the case of SickChill, just execute There is probably a lot more cleaning up that can be done too. i.e. remove the git checks (Still required for SAB but not SickChill). |
I have just noticed a new error in sabnzbd regarding the post processing. The error is as follows:
Traceback (most recent call last):
File "/share/Download/nzbToMedia/nzbToMedia.py", line 730, in
import core
File "/share/CACHEDEV1_DATA/.qpkg/nzbToMedia/nzbToMedia/core/init.py", line 52, in
from core import logger, main_db, version_check, databases, transcoder
File "/share/CACHEDEV1_DATA/.qpkg/nzbToMedia/nzbToMedia/core/databases.py", line 11, in
from core.utils import backup_versioned_file
File "/share/CACHEDEV1_DATA/.qpkg/nzbToMedia/nzbToMedia/core/utils/init.py", line 13, in
from core.utils.common import clean_dir, flatten, get_dirs, process_dir
File "/share/CACHEDEV1_DATA/.qpkg/nzbToMedia/nzbToMedia/core/utils/common.py", line 14, in
from core.utils.files import list_media_files, move_file
File "/share/CACHEDEV1_DATA/.qpkg/nzbToMedia/nzbToMedia/core/utils/files.py", line 14, in
import beets.mediafile
File "/share/CACHEDEV1_DATA/.qpkg/nzbToMedia/nzbToMedia/libs/common/beets/mediafile.py", line 51, in
import imghdr
ImportError: No module named imghdr
Any ideas what this issue relates to?
Running on a QNAP NAS.
Many thanks
Andrew
The text was updated successfully, but these errors were encountered: