Skip to content

missing log directory when using -l #537

Open
@dutangp

Description

Hello,

Version tested 1.17.0 in docker

Running the application

python3 launcher.py -l /tmp/logs

output error

Traceback (most recent call last):
  File "/usr/lib64/python3.6/logging/config.py", line 565, in configure
    handler = self.configure_handler(handlers[name])
  File "/usr/lib64/python3.6/logging/config.py", line 738, in configure_handler
    result = factory(**kwargs)
  File "/usr/lib64/python3.6/logging/__init__.py", line 1032, in __init__
    StreamHandler.__init__(self, self._open())
  File "/usr/lib64/python3.6/logging/__init__.py", line 1061, in _open
    return open(self.baseFilename, self.mode, encoding=self.encoding)
FileNotFoundError: [Errno 2] No such file or directory: '/app/logs/server.log'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "launcher.py", line 11, in <module>
    main.main()
  File "src/main.py", line 71, in main
    logging.config.dictConfig(log_config)
  File "/usr/lib64/python3.6/logging/config.py", line 802, in dictConfig
    dictConfigClass(config).configure()
  File "/usr/lib64/python3.6/logging/config.py", line 573, in configure
    '%r: %s' % (name, e))
ValueError: Unable to configure handler 'file': [Errno 2] No such file or directory: '/app/logs/server.log'

I guess there is a missing configuration in the src/main.py to setup server.log file in the directory taken from the arg.

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions