python scikits.audiolab Sndfile special chars in file name
Furqan wasi
furqan at avpreserve.com
Tue Aug 19 08:14:11 EDT 2014
Getting this
file = ur"C:\Users\Furqan\Desktop\查找問題Reference\1.wav"
SyntaxError: (unicode error) 'rawunicodeescape' codec can't decode bytes in
position 2-3: truncated \uXXXX
On Tue, Aug 19, 2014 at 4:05 PM, MRAB <python at mrabarnett.plus.com> wrote:
> On 2014-08-19 09:05, Furqan wasi wrote:
>
>> *Hi Mark and all, *
>>
>>
>> Thanks for the replay i appreciate your help but the problem i
>> have is not with the FileNotFoundError exception handling because the
>> file exists but the problem is that the library libsndfile/Sndfile
>> (python third party) which is child class/module of scikits.audiolab
>> (python third party) is not reading file with special character in its
>> path and name , i need some help to in how to make library
>> libsndfile/Sndfile to read file with special character in it i.e
>> C:\Users\Furqan\Desktop\test\查找問題daw\查找問題d.wav, as i mentioned
>> in my first email
>>
>> I recommend that you use Unicode strings instead of bytestrings:
>
> track1 = ur'C:\Users\Furqan\Desktop\test\查找問題daw\查找問題d.wav'
>
> --
> https://mail.python.org/mailman/listinfo/python-list
>
--
*Best Regards*
Furqan Wasi
*AVPreserve *
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20140819/d280ed22/attachment.html>
More information about the Python-list
mailing list