[Python-ideas] chdir context manager (original) (raw)
Nick Coghlan ncoghlan at gmail.com
Sat Jan 19 15:57:47 CET 2013
- Previous message: [Python-ideas] chdir context manager
- Next message: [Python-ideas] chdir context manager
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
-1 from me
I consider caring about the current directory to be an anti-pattern - paths should be converted to absolute ASAP, and for invocation of other tools that care about the current directory, that's why the subprocess APIs accept a "cwd" argument. I certainly don't want to encourage people to unnecessarily rely on global state by providing a standard library context manager that makes it easier to do so.
Regards, Nick.
-- Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia
- Previous message: [Python-ideas] chdir context manager
- Next message: [Python-ideas] chdir context manager
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]