On Wed, Mar 12, 2014 at 1:49 AM, Mike Sussman <[email protected]> wrote: > This is a follow-up to my recent post. In that post, I reported the error > ImportError: No module named petsc4py.PETSc > when attempting to run demo_poisson.py. > > Looking through a transcript of what I was doing, I realized that I had > successfully run one of the tutorial scripts: d1_p2D.py earlier in the > afternoon and it ran successfully. But then I upgraded my system using > synaptic and I noticed that I am now running fenics 1:1.3.0.2. After that > upgrade d1_p2D.py doesn't work. In fact, the single command "from dolfin > import *" fails with the message: >>>> from dolfin import * > Traceback (most recent call last): > File "<stdin>", line 1, in <module> > File "/usr/lib/python2.7/dist-packages/dolfin/__init__.py", line 16, in > <module> > import cpp > File "/usr/lib/python2.7/dist-packages/dolfin/cpp/__init__.py", line 42, > in <module> > exec("import %s" % module_name) > File "<string>", line 1, in <module> > File "/usr/lib/python2.7/dist-packages/dolfin/cpp/la.py", line 30, in > <module> > _la = swig_import_helper() > File "/usr/lib/python2.7/dist-packages/dolfin/cpp/la.py", line 26, in > swig_import_helper > _mod = imp.load_module('_la', fp, pathname, description) > ImportError: No module named petsc4py.PETSc >> > > Is it possible that something is wrong with the upgrade?
Yes. This works fine for me in a clean Ubuntu 13.04 machine. Make sure you upgrade all packages by running: sudo apt-get update sudo apt-get dist-upgrade Let us know if that doesn't resolve your problem. BTW, Ubuntu 13.04 is no longer supported by Ubuntu, so you should consider upgrading to 13.10. Johannes _______________________________________________ fenics-support mailing list [email protected] http://fenicsproject.org/mailman/listinfo/fenics-support
