This issue tracker has been migrated to GitHub ,
and is currently read-only.
For more information,
see the GitHub FAQs in the Python's Developer Guide.
Created on 2012年04月06日 02:07 by r.david.murray, last changed 2022年04月11日 14:57 by admin. This issue is now closed.
| Files | ||||
|---|---|---|---|---|
| File name | Uploaded | Description | Edit | |
| tempdir-doc.patch | r.david.murray, 2012年04月11日 17:48 | review | ||
| Messages (9) | |||
|---|---|---|---|
| msg157635 - (view) | Author: R. David Murray (r.david.murray) * (Python committer) | Date: 2012年04月06日 02:07 | |
The title pretty much says it all. I believe the behavior is correct (more useful than returning an object that is only useful for obtaining the name) even though it is unusual for context managers. In any case there is plenty of code using the existing behavior, so I think this is a doc bug. |
|||
| msg158063 - (view) | Author: R. David Murray (r.david.murray) * (Python committer) | Date: 2012年04月11日 17:48 | |
I misread the docs. They aren't wrong, but it is still the case that they don't mention that the directory name is what you get on entry to the context, which is what led to my confusion. Here's a patch. |
|||
| msg158100 - (view) | Author: Alyssa Coghlan (ncoghlan) * (Python committer) | Date: 2012年04月12日 02:09 | |
Change looks fine to me - go ahead and commit it :) |
|||
| msg182117 - (view) | Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) | Date: 2013年02月14日 19:16 | |
I don't understand a phrase "and is assigned to the target of the as clause on entry to a context". Typo? |
|||
| msg182121 - (view) | Author: R. David Murray (r.david.murray) * (Python committer) | Date: 2013年02月14日 21:18 | |
The patch is missing the markup for the 'as' keyword (it should read :keyword:`as`). If that were added, would the sentence make sense to you? Would it be clearer to say that the directory name is returned by the __enter__ method? |
|||
| msg182122 - (view) | Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) | Date: 2013年02月14日 21:29 | |
Aha, now it makes a sense to me. I don't know which variant will be clear. |
|||
| msg209840 - (view) | Author: Yury Selivanov (yselivanov) * (Python committer) | Date: 2014年01月31日 22:26 | |
bump? |
|||
| msg210344 - (view) | Author: Roundup Robot (python-dev) (Python triager) | Date: 2014年02月05日 19:56 | |
New changeset b5fe07d39e16 by R David Murray in branch '3.3': #14515: clarify that TemporaryDirectory's __enter__ returns the name. http://hg.python.org/cpython/rev/b5fe07d39e16 New changeset 7b7e17723787 by R David Murray in branch 'default': #14515: clarify that TemporaryDirectory's __enter__ returns the name. http://hg.python.org/cpython/rev/7b7e17723787 |
|||
| msg210345 - (view) | Author: R. David Murray (r.david.murray) * (Python committer) | Date: 2014年02月05日 19:58 | |
Just ran into this again :). Committed a patch with wording clarified based on Serhiy's feedback (I say 'target of the as clause of the with statement'.) |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:57:28 | admin | set | github: 58720 |
| 2014年02月05日 19:58:09 | r.david.murray | set | status: open -> closed messages: + msg210345 stage: patch review -> resolved |
| 2014年02月05日 19:56:52 | python-dev | set | nosy:
+ python-dev messages: + msg210344 |
| 2014年01月31日 22:26:19 | yselivanov | set | nosy:
+ yselivanov messages: + msg209840 |
| 2013年03月14日 08:17:45 | ezio.melotti | set | nosy:
+ terry.reedy, ezio.melotti stage: needs patch -> patch review versions: + Python 3.4 |
| 2013年02月14日 21:29:32 | serhiy.storchaka | set | messages: + msg182122 |
| 2013年02月14日 21:18:05 | r.david.murray | set | messages: + msg182121 |
| 2013年02月14日 19:16:10 | serhiy.storchaka | set | nosy:
+ serhiy.storchaka messages: + msg182117 |
| 2012年04月12日 02:09:55 | ncoghlan | set | messages: + msg158100 |
| 2012年04月11日 17:48:06 | r.david.murray | set | files:
+ tempdir-doc.patch nosy: + ncoghlan messages: + msg158063 keywords: + patch |
| 2012年04月06日 02:07:47 | r.david.murray | create | |