# Error handling Example to for handling protocol exceptions. The errors are described in the protobuf protocol definition of the errors. This example tries to set an invalid ScanPattern and a protocol exception will be raised and catched. ```.. literalinclude:: error_handling.py :language: python ```