Details for the issue
What did you do?
I called
pulp.LpProblem.fromMPS("problem.mps")
with this problem
problem.zip
What did you expect to see?
I expected the problem to be loaded without errors.
What did you see instead?
This error (output truncated)
File "/home/runner/work/Antares_Simulator/Antares_Simulator/src/tests/cucumber/features/steps/common_steps/mps_utils.py", line 4, in load_problem
return pulp.LpProblem.fromMPS(path)[1]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/hostedtoolcache/Python/3.12.12/x64/lib/python3.12/site-packages/pulp/pulp.py", line 1702, in fromMPS
data = mpslp.readMPS(filename, sense=sense, dropConsNames=dropConsNames)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/hostedtoolcache/Python/3.12.12/x64/lib/python3.12/site-packages/pulp/mps_lp.py", line 244, in readMPS
readMPSSetBounds(line, variable_info) # type: ignore[arg-type]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/hostedtoolcache/Python/3.12.12/x64/lib/python3.12/site-packages/pulp/mps_lp.py", line 289, in readMPSSetBounds
raise const.PulpError(f"Unknown bound {bound}")
pulp.constants.PulpError: Unknown bound UI
Useful extra information
It looks like this line was added between 3.0.2 and 3.3.0
else:
raise const.PulpError(f"Unknown bound {bound}")
in the last nested if..else case, making fromMPS less tolerant to unknown bound types such as "UI".
According to this page, UI should be a valid bound qualifier
UI integer variable (0 <=) x <= b
What operating system are you using?
I have been able to reproduce in these environments
I'm using python version:
I installed PuLP via:
Did you also
Details for the issue
What did you do?
I called
with this problem
problem.zip
What did you expect to see?
I expected the problem to be loaded without errors.
What did you see instead?
This error (output truncated)
Useful extra information
It looks like this line was added between 3.0.2 and 3.3.0
in the last nested if..else case, making
fromMPSless tolerant to unknown bound types such as "UI".According to this page, UI should be a valid bound qualifier
What operating system are you using?
I have been able to reproduce in these environments
I'm using python version:
I installed PuLP via:
Did you also