Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Get SCIP solving time considering float number with some text #3234

Merged
merged 2 commits into from
Apr 19, 2024

Conversation

henriquejsfj
Copy link
Contributor

@henriquejsfj henriquejsfj commented Apr 14, 2024

This fix does not change previous behavior and handles the case of a string with a float number plus some text.
Fix #3233

Legal Acknowledgement

By contributing to this software project, I have read the contribution guide and agree to the following terms and conditions for my contribution:

  1. I agree my contributions are submitted under the BSD license.
  2. I represent I am authorized to make the contributions and grant the license. If my employer has rights to intellectual property that includes these contributions, I represent that I have received permission to make contributions and grant the required license on behalf of that employer.

Copy link

codecov bot commented Apr 16, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 88.40%. Comparing base (8561f48) to head (3ce7416).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3234   +/-   ##
=======================================
  Coverage   88.39%   88.40%           
=======================================
  Files         848      848           
  Lines       95322    95322           
=======================================
+ Hits        84259    84267    +8     
+ Misses      11063    11055    -8     
Flag Coverage Δ
linux 86.34% <ø> (ø)
osx 76.19% <ø> (ø)
other 86.54% <ø> (+<0.01%) ⬆️
win 83.84% <ø> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mrmundt
Copy link
Contributor

mrmundt commented Apr 16, 2024

@henriquejsfj - Thanks for this PR! We think this looks fine. We test against SCIP 8.0 on our Jenkins, not 9.0, so we don't have a test to verify this behavior. Is it possible for you to add a small test for this edge case?

Unrelated: can you please edit the PR description to add back in the template? The legal acknowledgement is a requirement.

As for the failing test, that is unrelated. I have a different PR up to fix that.

@henriquejsfj
Copy link
Contributor Author

henriquejsfj commented Apr 18, 2024

@mrmundt Thanks for your reply.

I tested an example from docs and it was working, so I investigated and found the edge case:

solver = SolverFactory("scip")
solver.options['reoptimization/enable'] = True

By adding this option both SCIP 8 and 9 will return that bigger string breaking the code.

Previously, when I used SCIP 7 with Pyomo 6.3 I had no issues.

@mrmundt
Copy link
Contributor

mrmundt commented Apr 18, 2024

@henriquejsfj - I stand corrected! We do have SCIP 9.0 available on one test suite in GHA - linux/3.11/conda. Could you please add a test case to the test_scip.py file? (It can be a bit hard to find: https://github.com/Pyomo/pyomo/blob/main/pyomo/solvers/tests/mip/test_scip.py )

This fix does not change previous behavior and handles the case of a string with a float number plus some text.
@henriquejsfj
Copy link
Contributor Author

@mrmundt - Sure, just added it. It is always a good idea to add a test case to a bug that was not caught before!

@jsiirola jsiirola merged commit bd640f8 into Pyomo:main Apr 19, 2024
33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

SCIPAMPL failing to read solving time from log file
4 participants