New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make the PETSc TS interfaces conform to callback conventions. #15269
Conversation
For reference, this is the |
The error appears to be a problem on the system on which I ran this. The tester is ok, and so is my laptop. In other words, this is good to review. |
I verified that this must be an issue with the rather old PETSc version on that machine, and that the failure predates the patch. I've also pushed more commits that add tests, including one that verifies that, unlike SUNDIALS, PETSc TS is unable to deal with recoverable errors in user callbacks. |
I can extend the code to support recoverable errors. Regarding the failures, deal.ii now requires petsc 3.8 or later |
I have modified the call_and_possibly function to eat the exception as for the sundials case. On second thought, I think it is better to return and re-raise it so that the outer try and catch around SNESSolve will deal with it. Your call |
Same here: Can I ask for this patch to be merged without @stefanozampini 's addition? It tests cleanly and is self-contained. I will take care of the changes @stefanozampini suggests in a separate patch. |
Fine with me. It appears TS errors are not recoverable yet (I will try to look at this in PETSc) but SNES are (at least in function evaluation). See here #15276 |
For the unity build of deal.II, this PR (or the companion #15271) lead to build errors, see e.g. https://cdash.dealii.org/viewBuildError.php?buildid=1027 because we have the two functions with the same name and arguments dealii/include/deal.II/lac/petsc_snes.templates.h Lines 54 to 59 in b065060
dealii/include/deal.II/lac/petsc_ts.templates.h Lines 54 to 59 in b065060
|
@kronbichler #15284 provides a quick fix. |
Yes, I saw it only now. Thank you. |
@stefanozampini I would love it if you could take a look over this.
On my workstation, this currently fails with an exception of this form:
I have to run, and so have not investigated what may be going wrong. I also don't know whether I have run these tests on this machine before, so am only half-certain that this is caused by the current patch.
In reference to #15112.