You should just be able to fix your bat file to change to cp65001 on the same line you invoke kindleunpack.py
Something similar to the following should work in your bat file
chcp 65001 > nul && start /min python kindleunpack.py %*
The problem is without the chcp 65001, python will default to mbcs codec that can not represent all chars from every language and some chars then get mangled inside the python interpreter before ever reaching this program.
Changing to utf-8 (cp-65001) first allows all chars from every language to be represented and properly passed to Windows so hat Windows wide calls can be made to get all arguments.
Please give something similar to this a try and you should be able to get the command line to work properly on Windows. If not, enable debug mode from the command line and post a full debug output here in case the problem is occurring someplace other than right at the command line interface.
Please let me know the result.
Originally Posted by dimasic
The command line codepage is cp866, the shell is cmd.exe. As I said, when invoking from command line / bat file, it gets the error. Even if the directory path of the MOBI file contains cyrillic, but the filename itself in latin chars, then it's all OK. Is it necessary to convert filename? For example, the kindlestrip tool, written on python too, works well. Without conversion or something like that.