Repository navigation
Skip the removed ECOS_BB solver in lp_portfolio - #768
xvruipeng-cyber wants to merge 2 commits into
Conversation
|
I tried to reproduce #626 on both sides of this change (Python 3.12, cvxpy 1.9.3, It would help a reviewer to name the versions that do fail (which cvxpy and which |
|
The failure in #626 is cvxpy 1.6.0 dropping ECOS, which raises On this machine (Python 3.14, cvxpy 1.9.3, |
|
Thanks for the details. I ran your no-ecos path (Python 3.12, cvxpy 1.9.3, So the new real-solve test passes without the patch in the environment I could build, and I still have not seen the failing combination. The case the guard changes is |
Summary
Fixes #626.
lp_portfoliostill selectsECOS_BBwhenever theecospackage imports. cvxpy 1.6 stopped registering that solver, so the default allocation raisesSolverError: The solver ECOS_BB is not installedeven though ecos itself is present. The 1.7.0 plan to drop this default stays in place:ECOS_BBis used only whencvxpy.installed_solvers()still lists it, and the existingFutureWarningis unchanged in that case. Otherwise the call leaves the solver asNoneand cvxpy picks an installed mixed-integer solver.Test plan
test_lp_portfolio_skips_ecos_bb_when_cvxpy_removed_it: ecos is treated as installed, butECOS_BBis absent, andProblem.solvereceivessolver=Nonetest_lp_portfolio_still_defaults_to_ecos_bb_when_installed: whenECOS_BBis listed, the solve still requests it and emits the existing future warningMade with Cursor