tidy3d.set_logging_file

Contents

tidy3d.set_logging_file#

class set_logging_file[source]#

Bases:

Set a file to write log to, independently from the stdout and stderr output chosen using set_logging_level().

Parameters:
  • fname (str) – Path to file to direct the output to. If empty string, a previously set logging file will be closed, if any, but nothing else happens.

  • filemode (str) – β€˜w’ or β€˜a’, defining if the file should be overwritten or appended.

  • level (str) – One of {'DEBUG', 'SUPPORT', 'USER', 'INFO', 'WARNING', 'ERROR', 'CRITICAL'}. This is set for the file independently of the console output level set by set_logging_level().

  • log_path (bool = False) – Whether to log the path to the file that issued the message.