docs: def warn(code, message, **kwargs):
          """
          Call this to store a warning in the journal.
  
          Will raise if `Logger.fatal_warnings` is set to True.
          """
  
          if code in Logger._ignored_codes:
              return
  
          assert code in Logger._warning_code_to_exception
          exc_type, domain = Logger._warning_code_to_exception[code]
  
          if domain in Logger._ignored_domains:
              return
  
          level = WARNING
          if Logger.fatal_warnings:
              level = ERROR
  
          exc = exc_type(message, **kwargs)
  
          Logger._log(code, exc.message, level, domain)
  
          if Logger.fatal_warnings:
              raise exc