[BUG] set_cover Python: 整数焦点超载无法访问,且 bool in_focus 标志在新的不变量上导致 GreedySolutionGenerator 发生崩溃
作者: jg-codes创建于 2026年8月1日更新于 2026年9月15日
标签Lang: Python
inv.compute_coverage_in_focus([0, 1, 2]) TypeError: compute_coverage_in_focus(): incompatible function arguments. The following argument types are supported:
- (self: ...SetCoverInvariant, focus: absl::lts_20250814::Span) -> list[int]
pybind11 falling back to the raw C++ type name in the signature is the tell: nothing is registered for
absl::Span, so no Python object can satisfy the parameter.set_cover.ccincludespybind11/stl.handpybind11_protobuf/native_proto_caster.h, neither of which provides abseil casters.
内容来源: google/or-tools