Changes by Ugra Dániel daniel.u...@gmail.com:
--
nosy: +daniel.ugra
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5178
___
___
Python-bugs-list
Nick Coghlan ncogh...@gmail.com added the comment:
Merging the interfaces for mkdtemp and TemporaryDirectory isn't going to happen.
mkstemp/mkdtemp are for when the user wants to control the lifecycle of the
filesystem entries themselves. (Note that context management on a regular
file-like
Giampaolo Rodola' g.rod...@gmail.com added the comment:
Nick, could you comment about my last proposal?
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5178
___
Changes by Nick Coghlan ncogh...@gmail.com:
--
assignee: - ncoghlan
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5178
___
___
Python-bugs-list
Nick Coghlan ncogh...@gmail.com added the comment:
Committed (with enhanced tests and a few fixes) in r85818
And credit where it's due to test___all__ for picking up a typo in my
adjustment to tempfile.__all__ :)
I created issue #10188 to track the shutdown problem. I'm considering taking
Changes by Nick Coghlan ncogh...@gmail.com:
--
resolution: - accepted
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5178
___
Georg Brandl ge...@python.org added the comment:
Ping... soon it's too late for 3.2 too :)
--
nosy: +georg.brandl
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5178
___
Giampaolo Rodola' g.rod...@gmail.com added the comment:
Personally I would like to have a unique tempfile.mkdtemp which can be used as
both a function and a context manager, as it happens for open() and others.
Not sure how to do that though, unless tempfile.mkdtemp gets turned into a
class.
Nick Coghlan ncogh...@gmail.com added the comment:
Missed the boat for 2.7 I'm afraid. Definitely one to take another look at for
3.2 though.
--
assignee: ncoghlan -
versions: -Python 2.7
___
Python tracker rep...@bugs.python.org
Changes by Giampaolo Rodola' g.rod...@gmail.com:
--
nosy: +giampaolo.rodola
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5178
___
___
Nick Coghlan ncogh...@gmail.com added the comment:
Building a collection of issues I want to take a look at for 2.7
--
assignee: - ncoghlan
versions: +Python 3.2 -Python 3.1
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5178
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
nosy: +ezio.melotti
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5178
___
___
Python-bugs-list
Nick Coghlan ncogh...@gmail.com added the comment:
Unassigning for the moment - I'm still interested in the idea, but the
referencing-globals-at-shutdown problem means it isn't going to be the
straightforward review-and-commit that I original thought this patch was
going to be.
I'll still try
Antoine Pitrou pit...@free.fr added the comment:
If you look at the code for os.path.isdir, it uses other globals such as
os.stat, so you might want to reinject them in your class as well...
--
nosy: +pitrou
___
Python tracker rep...@bugs.python.org
Neil Schemenauer nas-pyt...@arctrix.com added the comment:
Argh, it's like pulling a sweater thread. The stat.S_ISDIR function
uses the S_IFDIR global so I would have write my own. This does not
look like good maintainable code, IMO.
Maybe there should be a special flag modules can set to
Antoine Pitrou pit...@free.fr added the comment:
Maybe there should be a special flag modules can set to make them get
cleared later in the interpreter cleanup procedure. Modules could set
it if they don't create reference cycles themselves and don't hold
references to user objects.
Or,
Neil Schemenauer nas-pyt...@arctrix.com added the comment:
New version of the patch. Added a __del__ method that hopefully works
reliably. Added NEWS and an example of TemporaryFile as a context
manager. I did not change more tests to use TemporaryDirectory since I
understand hit-and-run
Changes by Nick Coghlan ncogh...@gmail.com:
--
title: Add content manager for temporary directory - Add context manager for
temporary directory
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5178
18 matches
Mail list logo