Skip to content

Conversation

@rgsl888prabhu
Copy link
Collaborator

@rgsl888prabhu rgsl888prabhu commented Jun 10, 2025

Termination status is being pulled from cuOpt which makes cuopt main library a dependency for cuopt thin client.

This PR converts termination status and problem category to string just for server and also adds a new solution class specific to thin client and detaches need to connect with enums from main cuOpt library.

closes #90

@rgsl888prabhu rgsl888prabhu requested a review from a team as a code owner June 10, 2025 20:57
@rgsl888prabhu rgsl888prabhu requested a review from Iroy30 June 10, 2025 20:57
@rgsl888prabhu rgsl888prabhu self-assigned this Jun 10, 2025
@rgsl888prabhu rgsl888prabhu added bug Something isn't working non-breaking Introduces a non-breaking change labels Jun 10, 2025
@rgsl888prabhu rgsl888prabhu requested review from chris-maes and rg20 June 10, 2025 21:08
Copy link
Contributor

@chris-maes chris-maes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we should merge separate hard code status codes in the thin client. There should really only be one source of truth for these status values and that should be the C++ code.

@rgsl888prabhu rgsl888prabhu requested a review from a team as a code owner June 11, 2025 12:37
@rgsl888prabhu
Copy link
Collaborator Author

@jameslamb May I get review on this PR

@rgsl888prabhu rgsl888prabhu requested a review from jameslamb June 11, 2025 15:29
Copy link
Contributor

@chris-maes chris-maes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This changes the entire Python API to use strings instead of status codes for termination status. I don't think that is what we want. We should just change the thin client to use strings. No changes need to be made in solution.py, solver_wrapper.pyx, or the tests of the Python API.

@rgsl888prabhu
Copy link
Collaborator Author

This changes the entire Python API to use strings instead of status codes for termination status. I don't think that is what we want. We should just change the thin client to use strings. No changes need to be made in solution.py, solver_wrapper.pyx, or the tests of the Python API.

solution.py is packaged with thin client as well, so it would affect thin client if we keep it as it is.

@rgsl888prabhu
Copy link
Collaborator Author

@chris-maes @rg20 Created new solution module for thin client and only server converts the termination status to string

@rgsl888prabhu rgsl888prabhu requested review from chris-maes and rg20 June 11, 2025 21:36
Copy link
Member

@jameslamb jameslamb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving from a ci-codeowners perspective, will defer to other reviewers on the substance of the code changes.

Copy link
Contributor

@chris-maes chris-maes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. One minor question. I see the addition of .name to the ProblemCategaory and the LPTermination status. Why is this needed?

@rgsl888prabhu
Copy link
Collaborator Author

rgsl888prabhu commented Jun 12, 2025

It just changes enum value to it's corresponding string

LGTM. One minor question. I see the addition of .name to the ProblemCategaory and the LPTermination status. Why is this needed?

It just changes enum value to it's corresponding string, instead of us manually doing it.

@rgsl888prabhu rgsl888prabhu merged commit cfc22c9 into NVIDIA:branch-25.05 Jun 12, 2025
56 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working non-breaking Introduces a non-breaking change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Unable to run cuopt-sh-client without installing cuopt-server-cux library

4 participants