kqcircuits.util.log_router.route_log(lowest_visible_level='INFO', remove_old_handlers=True, filename='', stdout=True)[source]

Routes the log output to stdout and/or the specified logfile.

Enables monitoring the log in KLayout console. If requested it also appends logs to the specified file. By default removes old handlers from root logger to avoid output to other places than defined here.

  • lowest_visible_level (String) – one of DEBUG, INFO, WARNING, ERROR, CRITICAL

  • remove_old_handlers (Boolean) – determines if old handlers are removed from the root logger

  • filename – name of the file to append logs to

  • stdout – enable printing logs to standard output