Hi Nate,
Your fix works for the scramble fine, but not for the run.sh which now
fails. On removing the -ES from run.sh, I get an error importing
simplejson (see below). simplejson.egg is in the
eggs/py2.5-noplatform dir so I dont' see why it doesn't pick this up
if it manages to pick up WebHelpers.
Traceback (most recent call last):
File "./scripts/paster.py", line 26, in <module>
command.run()
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/PasteScript-1.3.6-py2.5.egg/paste/script/command.py",
line 78, in run
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/PasteScript-1.3.6-py2.5.egg/paste/script/command.py",
line 117, in invoke
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/PasteScript-1.3.6-py2.5.egg/paste/script/command.py",
line 212, in run
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/PasteScript-1.3.6-py2.5.egg/paste/script/serve.py",
line 227, in command
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/PasteScript-1.3.6-py2.5.egg/paste/script/serve.py",
line 250, in loadapp
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/PasteDeploy-1.3.1-py2.5.egg/paste/deploy/loadwsgi.py",
line 193, in loadapp
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/PasteDeploy-1.3.1-py2.5.egg/paste/deploy/loadwsgi.py",
line 213, in loadobj
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/PasteDeploy-1.3.1-py2.5.egg/paste/deploy/loadwsgi.py",
line 237, in loadcontext
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/PasteDeploy-1.3.1-py2.5.egg/paste/deploy/loadwsgi.py",
line 267, in _loadconfig
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/PasteDeploy-1.3.1-py2.5.egg/paste/deploy/loadwsgi.py",
line 397, in get_context
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/PasteDeploy-1.3.1-py2.5.egg/paste/deploy/loadwsgi.py",
line 439, in _context_from_explicit
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/PasteDeploy-1.3.1-py2.5.egg/paste/deploy/loadwsgi.py",
line 18, in import_string
File "/Users/james/Src/galaxy_dist/lib/pkg_resources.py", line 1912, in load
entry = __import__(self.module_name, globals(),globals(), ['__name__'])
File "/Users/james/Src/galaxy_dist/lib/galaxy/web/__init__.py", line
5, in <module>
from framework import expose, json, require_login, url_for, error,
form, FormBuilder
File "/Users/james/Src/galaxy_dist/lib/galaxy/web/framework/__init__.py",
line 17, in <module>
import webhelpers
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/WebHelpers-0.2-py2.5.egg/webhelpers/__init__.py",
line 1, in <module>
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/WebHelpers-0.2-py2.5.egg/webhelpers/rails/__init__.py",
line 7, in <module>
File "/Users/james/Src/galaxy_dist/eggs/py2.5-noplatform/WebHelpers-0.2-py2.5.egg/webhelpers/rails/scriptaculous.py",
line 16, in <module>
ImportError: No module named simplejson
2008/9/12 Nate Coraor <nate(a)bx.psu.edu>:
> James Casbon wrote:
>
>> Here is the traceback. If you read hashlib, it tries to import
>> _hashlib and if that fails and so it tries to get _md5. The MacPorts
>> python should have _hashlib but not _md5 (as below). _hashlib cannot
>> be found with the path for some reason.
>>
>> Traceback (most recent call last):
>> File "scramble.py", line 11, in <module>
>> use_setuptools( download_delay=8, to_dir=scramble_lib )
>> File
>> "/Users/james/Src/galaxy_dist/scripts/scramble/build/py2.5-macosx-10.3-i386-ucs2/Cheetah/ez_setup.py",
>> line 91, in use_setuptools
>> return do_download()
>> File
>> "/Users/james/Src/galaxy_dist/scripts/scramble/build/py2.5-macosx-10.3-i386-ucs2/Cheetah/ez_setup.py",
>> line 85, in do_download
>> egg = download_setuptools(version, download_base, to_dir,
>> download_delay)
>> File
>> "/Users/james/Src/galaxy_dist/scripts/scramble/build/py2.5-macosx-10.3-i386-ucs2/Cheetah/ez_setup.py",
>> line 120, in download_setuptools
>> import urllib2, shutil
>> File
>> "/opt/local/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/urllib2.py",
>> line 91, in <module>
>> import hashlib
>> File
>> "/opt/local/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/hashlib.py",
>> line 133, in <module>
>> md5 = __get_builtin_constructor('md5')
>> File
>> "/opt/local/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/hashlib.py",
>> line 60, in __get_builtin_constructor
>> import _md5
>> ImportError: No module named _md5
>
> Okay, what's happening here is that in the egg's source directory, scramble
> creates a script which it then executes in a clean environment using python
> -ES. Since your hashlib/md5 isn't part of the base install, you'll need to
> remove the -ES from line 132 of lib/galaxy/eggs/__init__.py:
>
> cmd = "%s -ES %s" % ( self.python, "scramble.py" )
>
> becomes:
>
> cmd = "%s %s" % ( self.python, "scramble.py" )
>
> Try this out and let me know if it works.
>
> --nate
>