config_error.py 770 B

123456789101112131415161718192021
  1. # This Python file uses the following encoding: utf-8
  2. # @author runhey
  3. # github https://github.com/runhey
  4. from pydantic import BaseModel, ValidationError, validator, Field
  5. from tasks.Component.config_base import MultiLine
  6. from module.logger import logger
  7. class Error(BaseModel):
  8. handle_error: bool = Field(default=True,
  9. description='handle_error_help')
  10. save_error: bool = Field(default=True,
  11. description='')
  12. screenshot_length: int = Field(default=1,
  13. description='')
  14. notify_enable: bool = Field(default=False,
  15. description='')
  16. notify_config: MultiLine = Field(default='provider: null', description='notify_config_help')