diff --git a/src/feasibility-residual.jl b/src/feasibility-residual.jl index c3568b9..090d676 100644 --- a/src/feasibility-residual.jl +++ b/src/feasibility-residual.jl @@ -48,7 +48,7 @@ function FeasibilityResidual( name = "$(nlp.meta.name)-feasres", ) where {T, S} if !equality_constrained(nlp) - if unconstrained(nlp) + if unconstrained(nlp) || bound_constrained(nlp) throw(ErrorException("Can't handle unconstrained problem")) elseif nlp isa AbstractNLSModel return FeasibilityResidual(SlackNLSModel(nlp), name = name) diff --git a/test/allocs_test.jl b/test/allocs_test.jl index 0efc82b..26c8f46 100644 --- a/test/allocs_test.jl +++ b/test/allocs_test.jl @@ -49,7 +49,7 @@ end ), map( x -> FeasibilityResidual(eval(Symbol(x))(), name = x * "feas"), - setdiff(problems, ["MGH01"]), + setdiff(problems, ["MGH01", "BNDROSENBROCK"]), ), ) # jtprod! https://github.com/JuliaSmoothOptimizers/NLPModelsModifiers.jl/issues/77