-
-
Couldn't load subscription status.
- Fork 24
Make robust to deprecations removals #168
Conversation
|
Does this close SciML/OrdinaryDiffEq.jl#2639? |
|
That error you posted at leat looks very very similar to the one that we discussed on Slack and that lead to this PR – so, maybe (or probably) that solves it, yes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
JuliaFormatter
[JuliaFormatter] reported by reviewdog 🐶
SimpleNonlinearSolve.jl/src/termination_conditions_deprecated.jl
Lines 171 to 172 in 5ef1936
| patience_objective_multiplier = 3, | |
| min_max_factor = 1.3) where {T} |
[JuliaFormatter] reported by reviewdog 🐶
SimpleNonlinearSolve.jl/src/termination_conditions_deprecated.jl
Lines 187 to 189 in 5ef1936
| NLSolveSafeTerminationResult, | |
| Nothing | |
| }) |
[JuliaFormatter] reported by reviewdog 🐶
SimpleNonlinearSolve.jl/src/termination_conditions_deprecated.jl
Lines 195 to 196 in 5ef1936
| return _termination_condition_closure_basic(get_du(integrator), integrator.u, | |
| integrator.uprev, abstol, reltol) |
[JuliaFormatter] reported by reviewdog 🐶
SimpleNonlinearSolve.jl/src/termination_conditions_deprecated.jl
Lines 207 to 208 in 5ef1936
| return _termination_condition_closure_safe(get_du(integrator), integrator.u, | |
| integrator.uprev, abstol, reltol) |
[JuliaFormatter] reported by reviewdog 🐶
SimpleNonlinearSolve.jl/src/utils.jl
Lines 177 to 178 in 5ef1936
| return check_termination( | |
| tc_cache, fx, x, xo, prob, alg, get_termination_mode(tc_cache)) |
| export NLSolveTerminationMode, | ||
| NLSolveSafeTerminationOptions, NLSolveTerminationCondition, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[JuliaFormatter] reported by reviewdog 🐶
| export NLSolveTerminationMode, | |
| NLSolveSafeTerminationOptions, NLSolveTerminationCondition, | |
| export NLSolveTerminationMode, NLSolveSafeTerminationOptions, NLSolveTerminationCondition, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
JuliaFormatter
[JuliaFormatter] reported by reviewdog 🐶
SimpleNonlinearSolve.jl/src/termination_conditions_deprecated.jl
Lines 149 to 150 in 89e640c
| struct NLSolveTerminationCondition{mode, T, | |
| S <: Union{<:NLSolveSafeTerminationOptions, Nothing}} |
[JuliaFormatter] reported by reviewdog 🐶
SimpleNonlinearSolve.jl/src/termination_conditions_deprecated.jl
Lines 171 to 172 in 89e640c
| patience_objective_multiplier = 3, | |
| min_max_factor = 1.3) where {T} |
[JuliaFormatter] reported by reviewdog 🐶
SimpleNonlinearSolve.jl/src/termination_conditions_deprecated.jl
Lines 187 to 189 in 89e640c
| NLSolveSafeTerminationResult, | |
| Nothing | |
| }) |
[JuliaFormatter] reported by reviewdog 🐶
SimpleNonlinearSolve.jl/src/termination_conditions_deprecated.jl
Lines 195 to 196 in 89e640c
| return _termination_condition_closure_basic(get_du(integrator), integrator.u, | |
| integrator.uprev, abstol, reltol) |
[JuliaFormatter] reported by reviewdog 🐶
SimpleNonlinearSolve.jl/src/termination_conditions_deprecated.jl
Lines 207 to 208 in 89e640c
| return _termination_condition_closure_safe(get_du(integrator), integrator.u, | |
| integrator.uprev, abstol, reltol) |
[JuliaFormatter] reported by reviewdog 🐶
SimpleNonlinearSolve.jl/src/utils.jl
Lines 177 to 178 in 89e640c
| return check_termination( | |
| tc_cache, fx, x, xo, prob, alg, get_termination_mode(tc_cache)) |
| :AbsNorm => doc"``\| \Delta u \| \leq abstol``." | ||
| ) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[JuliaFormatter] reported by reviewdog 🐶
| :AbsNorm => doc"``\| \Delta u \| \leq abstol``." | |
| ) | |
| :AbsNorm => doc"``\| \Delta u \| \leq abstol``.") |
| return new{__norm_type(f), typeof(max_stalled_steps), F, | ||
| typeof(protective_threshold), typeof(patience_objective_multiplier), | ||
| typeof(min_max_factor)}(f, protective_threshold, patience_steps, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[JuliaFormatter] reported by reviewdog 🐶
| return new{__norm_type(f), typeof(max_stalled_steps), F, | |
| typeof(protective_threshold), typeof(patience_objective_multiplier), | |
| typeof(min_max_factor)}(f, protective_threshold, patience_steps, | |
| return new{__norm_type(f), typeof(max_stalled_steps), | |
| F, typeof(protective_threshold), | |
| typeof(patience_objective_multiplier), typeof(min_max_factor)}( | |
| f, protective_threshold, patience_steps, |
| @concrete mutable struct NonlinearTerminationModeCache{dep_retcode, | ||
| M <: AbstractNonlinearTerminationMode, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[JuliaFormatter] reported by reviewdog 🐶
| @concrete mutable struct NonlinearTerminationModeCache{dep_retcode, | |
| M <: AbstractNonlinearTerminationMode, | |
| @concrete mutable struct NonlinearTerminationModeCache{ | |
| dep_retcode, M <: AbstractNonlinearTerminationMode, |
| function SciMLBase.init(du::Union{AbstractArray{T}, T}, u::Union{AbstractArray{T}, T}, | ||
| mode::AbstractNonlinearTerminationMode, saved_value_prototype...; | ||
| use_deprecated_retcodes::Val{D} = Val(true), # Remove in v8, warn in v7 | ||
| abstol = nothing, reltol = nothing, kwargs...) where {D, T <: Number} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[JuliaFormatter] reported by reviewdog 🐶
| abstol = nothing, reltol = nothing, kwargs...) where {D, T <: Number} | |
| abstol = nothing, | |
| reltol = nothing, kwargs...) where {D, T <: Number} |
| Vector{TT}(undef, mode.max_stalled_steps) | ||
| best_value = initial_objective | ||
| max_stalled_steps = mode.max_stalled_steps | ||
| if ArrayInterface.can_setindex(u_) && !(u_ isa Number) && |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[JuliaFormatter] reported by reviewdog 🐶
| if ArrayInterface.can_setindex(u_) && !(u_ isa Number) && | |
| if ArrayInterface.can_setindex(u_) && | |
| !(u_ isa Number) && |
| function NLSolveSafeTerminationResult(u = nothing; best_objective_value = Inf64, | ||
| best_objective_value_iteration = 0, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[JuliaFormatter] reported by reviewdog 🐶
| function NLSolveSafeTerminationResult(u = nothing; best_objective_value = Inf64, | |
| best_objective_value_iteration = 0, | |
| function NLSolveSafeTerminationResult( | |
| u = nothing; best_objective_value = Inf64, best_objective_value_iteration = 0, |
| return NLSolveSafeTerminationResult{typeof(best_objective_value), typeof(u)}(u, | ||
| best_objective_value, best_objective_value_iteration, return_code) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[JuliaFormatter] reported by reviewdog 🐶
| return NLSolveSafeTerminationResult{typeof(best_objective_value), typeof(u)}(u, | |
| best_objective_value, best_objective_value_iteration, return_code) | |
| return NLSolveSafeTerminationResult{typeof(best_objective_value), typeof(u)}( | |
| u, best_objective_value, best_objective_value_iteration, return_code) |
| NLSolveTerminationMode.NLSolveDefault, | ||
| NLSolveTerminationMode.Norm, NLSolveTerminationMode.Rel, | ||
| NLSolveTerminationMode.RelNorm, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[JuliaFormatter] reported by reviewdog 🐶
| NLSolveTerminationMode.NLSolveDefault, | |
| NLSolveTerminationMode.Norm, NLSolveTerminationMode.Rel, | |
| NLSolveTerminationMode.RelNorm, | |
| NLSolveTerminationMode.NLSolveDefault, NLSolveTerminationMode.Norm, | |
| NLSolveTerminationMode.Rel, NLSolveTerminationMode.RelNorm, |
| const SAFE_TERMINATION_MODES = (NLSolveTerminationMode.RelSafe, | ||
| NLSolveTerminationMode.RelSafeBest, | ||
| NLSolveTerminationMode.AbsSafe, | ||
| NLSolveTerminationMode.AbsSafeBest) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[JuliaFormatter] reported by reviewdog 🐶
| const SAFE_TERMINATION_MODES = (NLSolveTerminationMode.RelSafe, | |
| NLSolveTerminationMode.RelSafeBest, | |
| NLSolveTerminationMode.AbsSafe, | |
| NLSolveTerminationMode.AbsSafeBest) | |
| const SAFE_TERMINATION_MODES = ( | |
| NLSolveTerminationMode.RelSafe, NLSolveTerminationMode.RelSafeBest, | |
| NLSolveTerminationMode.AbsSafe, NLSolveTerminationMode.AbsSafeBest) |
| const SAFE_BEST_TERMINATION_MODES = (NLSolveTerminationMode.RelSafeBest, | ||
| NLSolveTerminationMode.AbsSafeBest) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[JuliaFormatter] reported by reviewdog 🐶
| const SAFE_BEST_TERMINATION_MODES = (NLSolveTerminationMode.RelSafeBest, | |
| NLSolveTerminationMode.AbsSafeBest) | |
| const SAFE_BEST_TERMINATION_MODES = ( | |
| NLSolveTerminationMode.RelSafeBest, NLSolveTerminationMode.AbsSafeBest) |
No description provided.