Utilities¶
-
openstack.utils.enable_logging(debug=False, path=None, stream=None)¶ Enable logging to a file at path and/or a console stream.
This function is available for debugging purposes. If you wish to log this package’s message in your application, the standard library
loggingpackage will receive these messages in any handlers you create.Parameters: - debug (bool) – Set this to
Trueto receive debug messages, which includes HTTP requests and responses, orFalsefor warning messages. - path (str) – If a path is specified, logging output will written to that file in addition to sys.stderr. The path is passed to logging.FileHandler, which will append messages the file (and create it if needed).
- stream – One of
None `` or ``sys.stdoutorsys.stderr. If it isNone, nothing is logged to a stream. If it isn’tNone, console output is logged to this stream.
Return type: None
- debug (bool) – Set this to