Defines how the solver should handle the request. In all modes but
VALIDATE_ONLY, if the request is invalid, you will receive an
INVALID_REQUEST error. See
max_validation_errors
to cap the number of errors returned.
*IMPORTANT*: not all infeasible shipments are returned here,
but only the ones that are detected as infeasible during
preprocessing.
Enums
Name
Description
DEFAULT_SOLVE
Solve the model.
VALIDATE_ONLY
Only validates the model without solving it: populates as many OptimizeToursResponse.validation_errors as possible.
DETECT_SOME_INFEASIBLE_SHIPMENTS
Only populates OptimizeToursResponse.validation_errors or OptimizeToursResponse.skipped_shipments, and doesn't actually solve the rest of the request (`status` and `routes` are unset in the response). If infeasibilities in `injected_solution_constraint` routes are detected they are populated in the OptimizeToursResponse.validation_errors field and OptimizeToursResponse.skipped_shipments is left empty.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[],[],null,["# Class SolvingMode (1.11.2)\n\nVersion latestkeyboard_arrow_down\n\n- [1.11.2 (latest)](/python/docs/reference/optimization/latest/google.cloud.optimization_v1.types.OptimizeToursRequest.SolvingMode)\n- [1.11.0](/python/docs/reference/optimization/1.11.0/google.cloud.optimization_v1.types.OptimizeToursRequest.SolvingMode)\n- [1.10.0](/python/docs/reference/optimization/1.10.0/google.cloud.optimization_v1.types.OptimizeToursRequest.SolvingMode)\n- [1.9.1](/python/docs/reference/optimization/1.9.1/google.cloud.optimization_v1.types.OptimizeToursRequest.SolvingMode)\n- [1.8.5](/python/docs/reference/optimization/1.8.5/google.cloud.optimization_v1.types.OptimizeToursRequest.SolvingMode)\n- [1.7.0](/python/docs/reference/optimization/1.7.0/google.cloud.optimization_v1.types.OptimizeToursRequest.SolvingMode)\n- [1.6.0](/python/docs/reference/optimization/1.6.0/google.cloud.optimization_v1.types.OptimizeToursRequest.SolvingMode)\n- [1.5.0](/python/docs/reference/optimization/1.5.0/google.cloud.optimization_v1.types.OptimizeToursRequest.SolvingMode)\n- [1.4.3](/python/docs/reference/optimization/1.4.3/google.cloud.optimization_v1.types.OptimizeToursRequest.SolvingMode)\n- [1.3.2](/python/docs/reference/optimization/1.3.2/google.cloud.optimization_v1.types.OptimizeToursRequest.SolvingMode)\n- [1.2.0](/python/docs/reference/optimization/1.2.0/google.cloud.optimization_v1.types.OptimizeToursRequest.SolvingMode)\n- [1.1.3](/python/docs/reference/optimization/1.1.3/google.cloud.optimization_v1.types.OptimizeToursRequest.SolvingMode)\n- [1.0.1](/python/docs/reference/optimization/1.0.1/google.cloud.optimization_v1.types.OptimizeToursRequest.SolvingMode)\n- [0.1.1](/python/docs/reference/optimization/0.1.1/google.cloud.optimization_v1.types.OptimizeToursRequest.SolvingMode) \n\n SolvingMode(value)\n\nDefines how the solver should handle the request. In all modes but\n`VALIDATE_ONLY`, if the request is invalid, you will receive an\n`INVALID_REQUEST` error. See\nmax_validation_errors\nto cap the number of errors returned. \n\n *IMPORTANT*: not all infeasible shipments are returned here,\n but only the ones that are detected as infeasible during\n preprocessing."]]