Skip to content

Commit 3511dc8

Browse files
feat: run initialiation on solve!
1 parent 31525cc commit 3511dc8

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

lib/NonlinearSolveBase/src/solve.jl

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,13 @@ function SciMLBase.__solve(
77
end
88

99
function CommonSolve.solve!(cache::AbstractNonlinearSolveCache)
10+
if cache.retcode == ReturnCode.InitialFailure
11+
return SciMLBase.build_solution(
12+
cache.prob, cache.alg, get_u(cache), get_fu(cache);
13+
cache.retcode, cache.stats, cache.trace
14+
)
15+
end
16+
1017
while not_terminated(cache)
1118
CommonSolve.step!(cache)
1219
end

0 commit comments

Comments
 (0)