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.

Author shura_zam
Recipients ezio.melotti, shura_zam
Date 2009-09-01.08:33:59
SpamBayes Score 2.9827931e-09
Marked as misclassified No
Message-id <>
All code:
# -*- coding: cp1251 -*-
import os.path

var = r'${APPDATA}\Microsoft\Windows\Start Menu'
print os.path.expandvars(var)
print os.path.expandvars(unicode(var, 'cp1251'))
Console session:
C:\Users\Леново\AppData\Roaming\Microsoft\Windows\Start Menu
Traceback (most recent call last):
  File "C:\Lang\test\python\", line 6, in <module>
    print os.path.expandvars(unicode(var, 'cp1251'))
  File "C:\Lang\Python\26\lib\", line 388, in expandvars
    res = res + c
UnicodeDecodeError: 'ascii' codec can't decode byte 0xcb in position 9:
ordinal not in range(128)
Date User Action Args
2009-09-01 08:34:01shura_zamsetrecipients: + shura_zam, ezio.melotti
2009-09-01 08:34:01shura_zamsetmessageid: <>
2009-09-01 08:34:00shura_zamlinkissue6815 messages
2009-09-01 08:33:59shura_zamcreate