[Python-ideas] pathlib.Path should handle Pythonpath or package root

Nick Coghlan ncoghlan at gmail.com
Tue Jul 18 09:56:07 EDT 2017


On 18 July 2017 at 22:08, George Fischhof <george at fischhof.hu> wrote:
> Hi there,
>
> I created a program which uses plugins (import them). I started to test it,
> and found that I need two types of paths: one for file system and another
> one which is package relative.
>
> So I thing this is a good idea, to enhance pathlib to handle package roots.

Is there a specific behaviour you're looking for that isn't already
addressed by "pathlib.Path(module.__file__).parent"?

Cheers,
Nick.

-- 
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia


More information about the Python-ideas mailing list