Thank you for your answers!

You were right Brandon, I had two port versions of python. I uninstalled the 
older and inactive version. I made sure I was running the remaining python from 
macports, not the MacOSX one by "which python", which points at 
/opt/local/bin/python. Then I reinstalled vtk:

>  sudo port uninstall vtk-devel
>  sudo port clean --all vtk-devel
>  sudo port -v install vtk-devel +py26

However, I still get no module named vtk-devel. Other ideas?

Thanks, 

Aron

On 4 Mar, 2010, at 22:51, Brandon Allbery wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> On Mar 3, 2010, at 07:07 , Aron Wahlberg wrote:
>> I get the following error when I try to import vtk
>> 
>> Aron-Wahlbergs-MacBook-Pro:vtk-5.4 aron$ python -c 'import vtk'
>> Traceback (most recent call last):
>> File "<string>", line 1, in <module>
>> ImportError: No module named vtk
>> 
>> I have installed vtk via macports and have the following version:
>> 
>> port installed vtk-devel
>> The following ports are currently installed:
>> vtk-devel @5.4.2_1+cocoa+data+doc+examples+shared+testing (active)
> 
> 
> You have multiple versions of python installed.  At minimum, MacPorts will 
> only install Python packages into its own copy of Python, because messing 
> with the Apple-supplied one risks both compatibility issues and breakage due 
> to system updates; you may also have multiple Python versions installed by 
> MacPorts.
> 
> Use "port contents vtk-devel" to find out where the vtk files got installed, 
> then make sure you run that python.
> 
> - --
> brandon s. allbery [solaris,freebsd,perl,pugs,haskell] [email protected]
> system administrator [openafs,heimdal,too many hats] [email protected]
> electrical and computer engineering, carnegie mellon university    KF8NH
> 
> 
> 
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v2.0.10 (Darwin)
> 
> iEYEARECAAYFAkuQK3AACgkQIn7hlCsL25VtCwCgwOUxCALvtBy1roghGb56Ii26
> fBMAoJ+vcLZf8And8SHgNcm//pMeVs9P
> =jq7r
> -----END PGP SIGNATURE-----

_______________________________________________
macports-users mailing list
[email protected]
http://lists.macosforge.org/mailman/listinfo.cgi/macports-users

Reply via email to