[Python-bugs-list] [ python-Bugs-810408 ] mkstemp doesn't return
abspath
SourceForge.net
noreply at sourceforge.net
Mon Sep 22 01:26:04 EDT 2003
Bugs item #810408, was opened at 2003-09-22 14:26
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=810408&group_id=5470
Category: Python Library
Group: Python 2.3
Status: Open
Resolution: None
Priority: 5
Submitted By: George Yoshida (quiver)
Assigned to: Nobody/Anonymous (nobody)
Summary: mkstemp doesn't return abspath
Initial Comment:
The document of tempfile.mkstemp says that,
"mkstemp() returns a tuple containing an OS-level
handle to an open file (as would be returned by
os.open()) and the absolute pathname of that file,
in that order."
However, if you specify the directory a relative path,
it doesn't return an absolute pathname.
>>> import tempfile
>>> tempfile.mkstemp()
(5, '/tmp/tmpHBq8rz')
>>> tempfile.mkstemp(dir='.')
(3, './tmpvK7BEr')
>>> tempfile.mkstemp(dir='./test')
(4, './test/tmplB7GZF')
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=810408&group_id=5470
More information about the Python-bugs-list
mailing list