title: Python get windows temp directory full path
body: <p>This is relatively simple matter but for some reason I cannot find a way to get the full path of the windows temp directory via python or to find similar request already posted in stack overflow community.</p>
  <p>I'm using tempfile.gettempdir() command but it seems there is no way to capture the full path and it returns the short version:</p>
  <blockquote>
  <p>'C:\Users\SVETLO~1\AppData\Local\Temp'</p>
  </blockquote>
  <p>This overall works but there is an important part of the script later on which doesn't and it requires the full temp dir path, which is:</p>
  <blockquote>
  <p>C:\Users\SvetlozarDraganov\AppData\Local\Temp\</p>
  </blockquote>
  <p>Does anyone knows how to get the full absolute path to windows-temp folder with python?</p>
  <p>Thanks in advance.
  Svet</p>
  <p>Edit-1:</p>
  <p>I'm testing the %fA suggestion from CMD but for some reason, it doesn't work. If I'm using %sA attribute it actually returns the short path version:</p>
  <p>CMD: <code>for %A in (&quot;C:\Users\SvetlozarDraganov\AppData\Local\Temp&quot;) do @echo %~sA</code></p>
  <p>OUTPUT: <code>C:\Users\SVETLO~1\AppData\Local\Temp</code></p>
  <p>The %fA attribute however doesn't return the full path:</p>
  <p>CMD: <code>for %A in (&quot;C:\Users\SVETLO~1\AppData\Local\Temp&quot;) do @echo %~fA</code></p>
  <p>OUTPUT: <code>C:\Users\SVETLO~1\AppData\Local\Temp</code></p>