NotImplementedError: Wrong number or type of arguments for overloaded function 'new_RoutingModel'

NotImplementedError: Wrong number or type of arguments for overloaded function 'new_RoutingModel'

我正在制作一个用 django 开发的 web 应用程序路由优化器,它运行良好,但由于一些变化,我想我搞砸了我的死记硬背代码 optimiser.It 向我显示以下错误:

File "/home/chirag/chirag/smartlogistics/lib/python3.7/site-packages/ortools/constraint_solver/pywrapcp.py", line 3191, in __init__
this = _pywrapcp.new_RoutingModel(*args)
NotImplementedError: Wrong number or type of arguments for overloaded 
function 'new_RoutingModel'.
 Possible C/C++ prototypes are:
operations_research::RoutingModel::RoutingModel(operations_research::RoutingIndexManager const &)
operations_research::RoutingModel::RoutingModel(operations_research::RoutingIndexManager const &,operations_research::RoutingModelParameters const &)

我无法解决问题,我是 django 的新手。任何帮助表示赞赏。 谢谢你。

不知何故,您选择了 7.0 beta 版本,它打破了 API。 看:

https://github.com/google/or-tools/tree/master/ortools/constraint_solver/doc

https://github.com/google/or-tools/releases/tag/v7.0-beta.1