vrp icon indicating copy to clipboard operation
vrp copied to clipboard

Adjusted python-example to work with pydayntic 2 and fixed problem dataclass to expect a list of options

Open Sagmedjo opened this issue 1 month ago • 0 comments

Fixes: #153

This pull request primarily cleans up the Python interop type definition files by removing all calls to __pydantic_model__.update_forward_refs() and fixes the structure of the objectives field in the Problem class.

Codebase cleanup and simplification:

  • Removed all calls to __pydantic_model__.update_forward_refs() from config_types.py and pragmatic_types.py, to comply with pydantic 2 and above

Type definition update:

  • Changed the type of the objectives field in the Problem class from Optional[List[List[Objective]]] to Optional[List[Objective]], fixing the data structure for objectives to work with the vrp_cli.solve_pragmatic method.

Sagmedjo avatar Nov 15 '25 14:11 Sagmedjo