New submission from Tim Hoffmann <tim.hoffm...@posteo.de>:

Path.home() may fail un
(https://github.com/matplotlib/matplotlib/issues/17707#issuecomment-647180252).

1. I think the raised key error is too low-level, and it should be something 
else; what exactly t.b.d.
2. The documentation 
(https://docs.python.org/3/library/pathlib.html#pathlib.Path.home) should 
specify what happens in case of failure.
3. The documentation links to 
https://docs.python.org/3/library/os.path.html#os.path.expanduser, but that's 
not correct. _PosixFlavor.gethomedir() implements it's own user lookup, which 
is slightly different from os.path.expanduser()

----------
components: Library (Lib)
messages: 372116
nosy: timhoffm
priority: normal
severity: normal
status: open
title: Error handling and documentation of Path.home()
type: behavior

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue41082>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to