Installing obspy with mac ports

Hello all;

I am trying to install obspy with mac ports on a MacOsX version Yosemite. It does install fine, give no errors, but when trying to import I get the following error. I also uninstalled the obspy an installed it again, but keep getting the same error:

Python 2.7.10 (default, May 25 2015, 13:06:17)
[GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.56)] on darwin
Type “help”, “copyright”, “credits” or “license” for more information.

import obspy
Traceback (most recent call last):
File “”, line 1, in
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/obspy/init.py”, line 36, in
from obspy.core.utcdatetime import UTCDateTime # NOQA
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/obspy/core/init.py”, line 107, in
from obspy.core.util.attribdict import AttribDict
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/obspy/core/util/init.py”, line 27, in
from obspy.core.util.base import (ALL_MODULES, DEFAULT_MODULES,
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/obspy/core/util/base.py”, line 27, in
from pkg_resources import iter_entry_points, load_entry_point
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/init.py”, line 3074, in
@_call_aside
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/init.py”, line 3060, in _call_aside
f(*args, **kwargs)
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/init.py”, line 3099, in _initialize_master_working_set
add_activation_listener(lambda dist: dist.activate())
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/init.py”, line 959, in subscribe
callback(dist)
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/init.py”, line 3099, in
add_activation_listener(lambda dist: dist.activate())
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/init.py”, line 2616, in activate
for pkg in self._get_metadata(‘namespace_packages.txt’):
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/init.py”, line 2606, in _get_metadata
for line in self.get_metadata_lines(name):
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/init.py”, line 1615, in get_metadata_lines
return yield_lines(self.get_metadata(name))
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/init.py”, line 1607, in get_metadata
return self._get(self._fn(self.egg_info, name))
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/init.py”, line 1718, in _get
with open(path, ‘rb’) as stream:
IOError: [Errno 13] Permission denied: ‘/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/obspy-0.10.2-py2.7.egg-info/namespace_packages.txt’

Any clue as to what is wrong the installation ??

When importing obspy.core I also get the following error messages:

from obspy.core import read
Traceback (most recent call last):
File “”, line 1, in
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/obspy/init.py”, line 36, in
from obspy.core.utcdatetime import UTCDateTime # NOQA
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/obspy/core/init.py”, line 107, in
from obspy.core.util.attribdict import AttribDict
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/obspy/core/util/init.py”, line 27, in
from obspy.core.util.base import (ALL_MODULES, DEFAULT_MODULES,
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/obspy/core/util/base.py”, line 27, in
from pkg_resources import iter_entry_points, load_entry_point
File “/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/init.py”, line 84, in
packaging = pkg_resources._vendor.packaging
AttributeError: ‘module’ object has no attribute ‘_vendor’

Thank you in advance.