Commit 04b8dc2
authored
cuopt service correct definition for status value in lp result spec (#671)
The openapi spec for the status value in lp/mip results says "int" but it is actually a string. This change corrects that.
Unfortunately, the enums defining the values cannot be directly imported because the import causes early cuda initialization which leads to rmm errors.
So, this change uses local copies and then adds a unit test to make sure they don't drift.
## Summary by CodeRabbit
## Release Notes
* **New Features**
* Termination status values in API responses are now human-readable strings (e.g., "Optimal", "Infeasible") instead of numeric codes.
* Added validation to ensure termination status values are valid.
* **Tests**
* Added verification test for termination status enumerations synchronization.
<sub>✏️ Tip: You can customize this high-level summary in your review settings.</sub>
Authors:
- Trevor McKay (https://github.com/tmckayus)
Approvers:
- Ramakrishnap (https://github.com/rgsl888prabhu)
URL: #6711 parent 465f89f commit 04b8dc2
File tree
2 files changed
+101
-23
lines changed- python/cuopt_server/cuopt_server
- tests
- utils/linear_programming
2 files changed
+101
-23
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
211 | 211 | | |
212 | 212 | | |
213 | 213 | | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
Lines changed: 73 additions & 23 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
810 | 810 | | |
811 | 811 | | |
812 | 812 | | |
| 813 | + | |
| 814 | + | |
| 815 | + | |
| 816 | + | |
| 817 | + | |
| 818 | + | |
| 819 | + | |
| 820 | + | |
| 821 | + | |
| 822 | + | |
| 823 | + | |
| 824 | + | |
| 825 | + | |
| 826 | + | |
| 827 | + | |
| 828 | + | |
| 829 | + | |
| 830 | + | |
| 831 | + | |
| 832 | + | |
| 833 | + | |
| 834 | + | |
| 835 | + | |
| 836 | + | |
| 837 | + | |
| 838 | + | |
| 839 | + | |
| 840 | + | |
| 841 | + | |
| 842 | + | |
| 843 | + | |
| 844 | + | |
| 845 | + | |
| 846 | + | |
| 847 | + | |
| 848 | + | |
| 849 | + | |
| 850 | + | |
| 851 | + | |
| 852 | + | |
| 853 | + | |
| 854 | + | |
| 855 | + | |
| 856 | + | |
| 857 | + | |
| 858 | + | |
813 | 859 | | |
814 | | - | |
815 | | - | |
816 | | - | |
817 | | - | |
818 | | - | |
819 | | - | |
820 | | - | |
821 | | - | |
822 | | - | |
823 | | - | |
824 | | - | |
825 | | - | |
826 | | - | |
827 | | - | |
828 | | - | |
829 | | - | |
830 | | - | |
831 | | - | |
832 | | - | |
833 | | - | |
| 860 | + | |
| 861 | + | |
| 862 | + | |
| 863 | + | |
| 864 | + | |
| 865 | + | |
| 866 | + | |
| 867 | + | |
| 868 | + | |
| 869 | + | |
| 870 | + | |
| 871 | + | |
| 872 | + | |
| 873 | + | |
| 874 | + | |
| 875 | + | |
| 876 | + | |
| 877 | + | |
| 878 | + | |
| 879 | + | |
| 880 | + | |
| 881 | + | |
| 882 | + | |
| 883 | + | |
834 | 884 | | |
835 | 885 | | |
836 | 886 | | |
| |||
896 | 946 | | |
897 | 947 | | |
898 | 948 | | |
899 | | - | |
| 949 | + | |
900 | 950 | | |
901 | 951 | | |
902 | 952 | | |
| |||
925 | 975 | | |
926 | 976 | | |
927 | 977 | | |
928 | | - | |
| 978 | + | |
929 | 979 | | |
930 | 980 | | |
931 | 981 | | |
| |||
956 | 1006 | | |
957 | 1007 | | |
958 | 1008 | | |
959 | | - | |
| 1009 | + | |
960 | 1010 | | |
961 | 1011 | | |
962 | 1012 | | |
| |||
0 commit comments