>>> dir = u'\\\\nas\\cut\\'
>>> cutter = "seleção"
>>> ext = ".cf2"
>>> path = dir+cutter+ext
Traceback (most recent call last):
File "<pyshell#8>", line 1, in <module>
path = dir+cutter+ext
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe7 in position 4: ordinal not in range(128)
This is needed to use:
f = open(dir, 'r')
I don't know how I concatenate this well. The variable dir must be in unicode because I use configparser to parse te value from a .ini file and that comes with unicode encoding.