logme icon indicating copy to clipboard operation
logme copied to clipboard

TypeError: 'PosixPath' object is not iterable

Open valicika-e opened this issue 6 years ago • 1 comments

I get this error "TypeError: 'PosixPath' object is not iterable" The file logme.ini is added into the root folder of the project. Here is the error trace:

File "/opt/app/pip/logme/__init__.py", line 34, in log
  return _get_logger_decorator(scope, config=config, name=name)
File "/opt/app/pip/logme/__init__.py", line 63, in _get_logger_decorator
  provider = LogProvider(callable_, config=config, name=name)
File "/opt/app/pip/logme/providers.py", line 40, in __init__
  config_dict = get_logger_config(module_obj.__file__, name=config)
File "/opt/app/pip/logme/utils.py", line 67, in get_logger_config
  return get_config_content(caller_file_path, name=name)
File "/opt/app/pip/logme/utils.py", line 94, in get_config_content
  config = ConfigParser.from_files(init_file_path)
File "/opt/app/pip/bnmutils/configparser.py", line 29, in from_files
  obj.read(filenames, encoding)
File "/opt/app/pip/backports/configparser/__init__.py", line 702, in read
  for filename in filenames:
TypeError: 'PosixPath' object is not iterable

valicika-e avatar Jan 30 '19 13:01 valicika-e

Hi there, sorry for the late response. This seems to be a problem with python versioning. Since in anything below python3.6.2 does not seem to check if the filename passed is a os.PathLike. May I ask which version of python you are using? :)

BNMetrics avatar Apr 20 '19 09:04 BNMetrics