update_vasp_custodian_handlers¶
- atomate2.vasp.powerups.update_vasp_custodian_handlers(flow, custom_handlers, class_filter=BaseVaspMaker)[source]¶
Update custodian error handlers for VASP jobs in a flow.
Replaces the default custodian error handlers with custom handlers, allowing users to customize error handling and recovery behavior or disable error handling entirely.
- Parameters:
flow (Flow) – The flow whose custodian handlers will be updated.
custom_handlers (tuple) – Tuple of custodian handler objects to use for error handling. Pass an empty tuple () to disable error handling.
class_filter (Maker, optional) – The maker class for which handlers will be updated. Only jobs created by this maker class or its subclasses will have their handlers modified. Default is BaseVaspMaker.
- Returns:
A copy of the flow with updated custodian handlers.
- Return type:
Flow
Notes
Custodian handlers are executed in the order they appear in the tuple. Common handlers include VaspErrorHandler, MeshSymmetryErrorHandler, etc.
Examples
>>> from custodian.vasp.handlers import VaspErrorHandler >>> handlers = (VaspErrorHandler(),) >>> flow = update_vasp_custodian_handlers(flow, handlers)