Different Python version causes conflicts with postprocessing?

Feel free to talk about anything and everything in this board.
Post Reply
qwerty967
Jr. Member
Jr. Member
Posts: 57
Joined: February 27th, 2008, 5:46 am

Different Python version causes conflicts with postprocessing?

Post by qwerty967 »

I just upgraded to Snow Leopard and tried to switch my postprocessing script from

Code: Select all

#!/usr/bin/python2.5
to

Code: Select all

#!/usr/bin/python2.6
and this error came up:

Code: Select all

    'import site' failed; use -v for traceback
Traceback (most recent call last):
  File "/Volumes/thor/scripts/postproc.sh", line 10, in <module>
    import glob
ImportError: No module named glob
Is this a bug?
User avatar
switch
Moderator
Moderator
Posts: 1380
Joined: January 17th, 2008, 3:55 pm
Location: UK

Re: Different Python version causes conflicts with postprocessing?

Post by switch »

Sounds like your install of python does not have glob installed. What is the contents and purpose of /Volumes/thor/scripts/postproc.sh ?

Moving to the general forum as this is not a sabnzbd bug.
qwerty967
Jr. Member
Jr. Member
Posts: 57
Joined: February 27th, 2008, 5:46 am

Re: Different Python version causes conflicts with postprocessing?

Post by qwerty967 »

I am using the default Python installations (2.5 and 2.6) that ship with the recently released Snow Leopard. I've switched all my miscellaneous Python scripts from using 2.5 to 2.6. The only thing that gives me an error is my custom post-processing script for SABnzbd. Running the script from the terminal does not yield this error, however, SABnzbd running it as post-processing does.

It's no big deal. Running it under 2.5 works, but 2.6 throws an error on the first import statement. glob, os, re, they all fail except for sys.
madd
Newbie
Newbie
Posts: 3
Joined: September 3rd, 2009, 2:13 pm

Re: Different Python version causes conflicts with postprocessing?

Post by madd »

I'm getting the same error using Snow Leopard.

The post-processing scripts run perfectly fine if executed from command-line using ie Terminal.
qwerty967 wrote: I just upgraded to Snow Leopard and tried to switch my postprocessing script from

Code: Select all

#!/usr/bin/python2.5
to

Code: Select all

#!/usr/bin/python2.6
and this error came up:

Code: Select all

    'import site' failed; use -v for traceback
Traceback (most recent call last):
  File "/Volumes/thor/scripts/postproc.sh", line 10, in <module>
    import glob
ImportError: No module named glob
Is this a bug?
qwerty967
Jr. Member
Jr. Member
Posts: 57
Joined: February 27th, 2008, 5:46 am

Re: Different Python version causes conflicts with postprocessing?

Post by qwerty967 »

A couple people are reporting errors with the default Python in Snow Leopard and this post-processing script: [Linux, MacOSX, Windows] Media Processing + XBMC Updater.
zakharm
Release Testers
Release Testers
Posts: 56
Joined: September 29th, 2008, 1:08 pm

Re: Different Python version causes conflicts with postprocessing?

Post by zakharm »

I'm also having problems when using Snow Leopard with my album art script

Code: Select all

    
'import site' failed; use -v for traceback
Traceback (most recent call last):
  File "write_album_art.py", line 26, in <module>
    import sys, os, fnmatch, re, urllib, eyeD3, shutil, string, ConfigParser
ImportError: No module named os
Write album art post processing script
Camelot
Jr. Member
Jr. Member
Posts: 64
Joined: August 18th, 2008, 6:23 am

Re: Different Python version causes conflicts with postprocessing?

Post by Camelot »

I am now having the same issue. Anyone find a fix? :)
User avatar
shypike
Administrator
Administrator
Posts: 19774
Joined: January 18th, 2008, 12:49 pm

Re: Different Python version causes conflicts with postprocessing?

Post by shypike »

It looks like Apple made a serious error with their Python version.
Raf (our OSX maintainer) is looking into the matter.
It also affects compiling SABnzbd for OSX.
Post Reply