class_docstr: A more secure dictionary for accessing plugin secrets in
  operators that will attempt to resolve missing plugin secrets upon access.
class_docstr_tok: ["A","more","secure","dictionary","for","accessing","plugin","secrets","in","operators","that","will","attempt","to","resolve","missing","plugin","secrets","upon","access","."]
code: def __setattr__(self, key, value):
      if not getattr(
          self, "_SecretsDictionary__frozen", False
      ) or not hasattr(self, key):
          super().__setattr__(key, value)
          return
  
      if key == "_SecretsDictionary__secrets" and value != {}:
          is_allowed = all(
              v in self.__required_keys for v in value.keys()
          )
          if not is_allowed:
              raise KeyError(
                  "Cannot access secrets not defined in the "
                  "plugin's definition"
              )
      elif key == "_SecretsDictionary__required_keys" and self.__frozen:
          raise AttributeError(
              "Cannot mutate plugin secrets requirement"
          )
      elif (
          key == "_SecretsDictionary__frozen"
          and len(self.__required_keys) > 0
      ):
          raise AttributeError(
              "Cannot mutate plugin secrets requirement"
          )
  
      elif hasattr(super(), key):
          super().__setattr__(key, value)
  
imports: import logging
  import traceback
  import typing
  from typing import Optional
  from ..internal import secrets
label_desc: Use image node_id 7 for calling the SecretsDictionary obj's underlying member method code with example usage: obj.__setattr__(key, value) without return types