This returns me a short path (DOS convention) (on Windows):
import tempfile
tempDir = tempfile.mkdtemp()
print tempDir
Output >>> c:\users\admini~1\appdata\local\temp\tmpf76unv
Notice the admini~1.
How can I get/convert this to a full path? e.g. C:\users\administrator\appdata…
Please try the following code (updated):
Hope this helps. Please refer to http://mail.python.org/pipermail/python-win32/2008-January/006642.html