On Wed, Nov 13 2024 at 07:36:04 PM, dieter.mau...@online.de wrote:
> Loris Bennett wrote at 2024-11-12 10:00 +0100:
>> ...
>>However, it strikes me as not immediately obvious that the logging file
>>must exist at this point.  I can imagine a situation in which I want to
>>configure a default log file and create it if it missing.
>
> This is what happens usually:
> if you open a file with mode `a` or `w`, the file is created
> if it does not yet exist.
>
> Thus, a missing log file should not give you the `FileNotFound`
> exception.
> Look at the exception details: they should tell you what really
> was not found (maybe the directory for the logfile).

It is possible a directory along the path does not exist.

-- 
regards,
kushal
-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to