Skip to content

Conversation

@XPRSc4v4
Copy link

@XPRSc4v4 XPRSc4v4 commented Dec 5, 2025

Hi!

Fixes

  • Deprecated function names in Xpress 9.8+ (Python API v46)
  • Removed enums in Xpress 9.8+
  • Compatibility with both pre-9.8 and post-9.8 Xpress versions

Summary/Motivation:

Starting with Xpress 9.8 (Python API version 46), FICO deprecated lowercase function names in favor of camelCase (e.g., lpoptimizelpOptimize) and removed several enum types. The old functions are still available but deprecated, and will be removed in future releases. This PR adds runtime version detection to dispatch to the correct functions and enums based on the installed Xpress version, eliminating deprecation warnings while maintaining backward compatibility.

Changes proposed in this PR:

  • Extended version detection logic that checks Xpress Python API version at runtime
  • Created compatibility wrappers that dispatch to correct function names (lowercase for v45-, camelCase for v46+)
  • Updated enum handling to use new attribute access pattern for v46+ while maintaining old enum values for earlier versions
  • Modified tests to use XpressDirect interface instead of calling Xpress Python APIs directly
  • All changes maintain full backward compatibility with Xpress versions prior to 9.8

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.

* TXP-7757: removed most deprecation warnings up to current unpublished release

* Fixed more warnings

* Missing version agnostic functions

* Fixed version specific LPStatus enums + renamed get-lb/ub methods

* Suggested improvements
@XPRSc4v4 XPRSc4v4 changed the title Remove deprecation warnings (#1) [Xpress] Remove deprecation warnings (#1) Dec 5, 2025
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.

1 participant