title: Getting error while changing the logging file directory in Python
body: <p><strong>Objective</strong>
  Need to change logging file path under '/users/logs' directory when everytime my python tests executes on Windows machine</p>
  <p><strong>Steps</strong>
  I have <em>logging.conf</em> file with settings as below. This configuration file exists under path '{ProjectRoot}/logs'</p>
  <pre><code>[loggers]
  keys=root,simpleExample
  
  [handlers]
  keys=consoleHandler,fileHandler
  
  [formatters]
  keys=simpleFormatter
  
  [logger_root]
  level=INFO
  handlers=consoleHandler,fileHandler
  
  [logger_simpleExample]
  level=DEBUG
  handlers=consoleHandler,fileHandler
  qualname=simpleExample
  propagate=0
  
  [handler_consoleHandler]
  class=StreamHandler
  level=DEBUG
  formatter=simpleFormatter
  args=(sys.stdout,)
  
  [handler_fileHandler]
  class=FileHandler
  level=DEBUG
  formatter=simpleFormatter
  args=('%(logfilename)s', 'a', 'utf8')
  
  [formatter_simpleFormatter]
  format= %(levelname)s:%(asctime)s:%(module)s:%(funcName)s:%(lineno)d:%(message)s
  </code></pre>
  <p>And I have initialized logger as below</p>
  <pre><code>projectRoot = Path(__file__).parent
  loggingConfigFile = f'{projectRoot}\\logs\\logging.conf'
  logging.config.fileConfig(loggingConfigFile, defaults={'logfilename': &quot;C:\\Users\\user1\logs\\bp1.log&quot;}, disable_existing_loggers=False)
  </code></pre>
  <p>When I execute this I get error as</p>
  <p><em>File &quot;&quot;, line 1
  ('C:\Users\innabal1\logs\bp1.log', 'a', 'utf8')
  ^
  SyntaxError: (unicode error) 'unicodeescape' codec can't decode bytes in position 2-3: truncated \UXXXXXXXX escape</em></p>
  <p>When I just give only the file name alone it works fine. But logs are created under the current execution directory.</p>
  <pre><code>logging.config.fileConfig(loggingConfigFile, defaults={'logfilename': &quot;bp1.log&quot;}, disable_existing_loggers=False)
  </code></pre>