Lawrence --

> > Petsc Development GIT revision: v3.4.2-20859-g7bfdb6492c  GIT Date: 2018-04-03 16:04:52 -0500
> This is 20859 commits after the 3.4.2 tag. It's from about three weeks ago.
> Dunno why the git describe our out [output?] is this. 

Odd, but I got it.  Wasn't reading the whole string.

> > Can you post the output of firedrake-status?
> > Both with the reinstalled firedrake, and the old, it crashes...
> Aha, it's a python script, so just run firedrake-status, rather than try to source it. 

Got it.  And firedrake-status tells me that PETSC_DIR is my own or "None" according to whether I do "unset PETSC_DIR" before running activate or not.  Makes sense!

> I have now reinstalled firedrake with PETSC_DIR unset ...  But if I run
> > activate later it seems to use the value of PETSC_DIR at that time.

> I'll reiterate that firedrake runs with (basically) petsc master. However,
> we had issues with changes not being made simultaneously in petsc
> and petsc4py. Hence we maintain a fork with known good branch pointers
> for both (and slepc and slepc4py). These are the "firedrake" branches
> you can see at github.com/firedrakeproject/petsc etc...
firedrake-install clones and builds these packages.

Understood.

> If you have
 PETSC_DIR set then it complains (or it should). 

It does not complain.  It probably should?  Would have saved me confusion.  Turns out my PETSC_DIR had almost the same master commit, but not quite .. thus truely weird seg faults when that petsc was silently linked.

By the way, gdb --args python3 script.py works for me.  In fact I tried it in my debugging earlier but the seg fault was so bad (... in PetscFinalize() or something ... can't reconstruct ...) that it did not help when I most needed it.

> You can run with your prebuilt petsc: run the install with --honour-petsc-dir.
> But we don't guarantee that you will get all the different bits matching. 

Actually now that I know it is v3.4.2 + 20,000 commits I'm good with firedrake's petsc choice!  ;-)

> So it looks like I should do
> > $ unset PETSC_DIR
> > $ source firedrake/bin/activate
> > every time I start firedrake?  Is this the correct action if one has
> > PETSC_DIR set?
> I think so yes. It's possible that this env variable interferes with the library
> that petsc4py loads, and if things have changed, maybe you get issues. 

firedrake-status confirms that "unset PETSC_DIR" action is really needed.  Should this be documented in the firedrake install instructions?  Maybe the fact that I already have PETSc on  my machine is a special case ... but probably not that special.

In any case, everything works now.  It is even true that all the hiccups have clear explanations!  Awesome!

Also my Stokes solver works as expected.  ;-)

Ed




--
Ed Bueler
Dept of Math and Stat and Geophysical Institute
University of Alaska Fairbanks
Fairbanks, AK 99775-6660
301C Chapman