New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
UnicodeDecodeError: 'ascii' codec can't decode byte #170
Comments
I encountered this problem as well, on a Win10 in Czech locale. On my Win10 in English locale it works fine. |
In my computer, it is russial locale. (I think, it is worth mentioning here.) |
@mikiqex @tolik89u does your windows user account name have non-ASCII characters in it? (accentuated characters, Cyrillic characters?) It would make sense since youtube-dl-gui tries to access @MrS0m30n3 maybe using |
I don't know where in the code the error is, but yes, my username is Толик, i. e. consists of cyrillic characters. BTW, YouTube-DLG is not the only program that had such an issue. I remember, in university I also had to install some programs from the user account that I've created espesially for that purpose and who's login doesn't contain cyrillic — because those programs couldn't install in Толик user account and displayed error. It is interesting: when the problem with cyrillic login will be fixed, will the program work correctly, or it will throw an error — this time because of cyrillic file paths? :D |
@tolik89u proper unicode handling is a pain in python2, so that other program may have been python2 too :). Your login name is used in your personal directory path
The problem here is all about unicode file paths, in this case the unicode part is your username. But once it is fixed it would be interesting to know if saving a file in, for example By the way I looked in the |
In fact, Windows substitutes standard directories names. Special Windows user directories have two names: one name is the real folder name, which is used by filesystem, such as Downloads or Pictures. The other is the displayed name, which is displayed in Explorer windows. It is somehow stored in destkop.ini file inside given special folder. Therefore, by default the Downloads folder in russian Windows is |
I dont have the time to read every bullshit everyone writes if you dont like the program dont use it end of story. I wont spend my time reading an issue when you cant take 5 minutes to file a proper report. P.S. |
@MrS0m30n3, (or at least someone else, could you please help me? (in case if the author doesn't have much time for my "bullshit"))
|
I just found that current version is 0.3.8: |
@MrS0m30n3 I think this bug report was filed correctly. To summarize: youtube-dl-gui 0.3.8 crashes on launch when the user's home directory contains non-ascii characters. Edit: indeed this seems to be a windows-specific problem. Linux (Debian) does not even let me create an user with such an username:
@tolik89u a workaround would be creating a user account without cyrillic characters. It will spare you many bugs in other programs, and I understand @MrS0m30n3 is not inclined to fix a windows-specific and rare bug since he doesn't use that operating system. Closing as wontfix then |
FYI, I just tried to run it from non-ASCII login -- it works fine. Moreover, it even correctly handles cyrillic file paths: both "save path" specified in options and the filename itself when title contains cyrillic chars and filename template contains %(title). Though there's still error message in log:
but it downloads files correctly -- therefore I don't care about the error.
BTW, @MrS0m30n3 , why do you think I don't like it? As I wrote above, only now I finally managed to make it not to crash immediately after start, and I was lucky to see it working. And only now I can decide whether I like it or not. And I definitely do like it! Thank you and all contributors to this program for your time spending on creating it! I definitely will use it because I know no other alternatives to download from 1tv.ru list of multiple files at a time (earlier I had to download files manually one by one, it took a couple of minutes to start the download job manually for 10 -- 20 files). I'll run it under my surrogate non-cyrillic login -- thank you to @nodiscc for your tip! |
See i'm a magician, download this and i am sure it will work with the weird username, if yes i dont get why @nodiscc marked this as wontfix since its clearly a duplicate. @tolik89u i love how you found issue #57 but you probably did not took the time to read through the issue. If the above download does not work you can blame me 100% but i'm sure it will work. |
@tolik89u wrote
I think it's mentioned clearly in the issue template
So no this report is still invalid and thats not the only reason... |
Now I see that. Yes, for some reason I thought that issue marked as closed is already implemented in current version, but now I see that it isn't — that's why I didn't read the issue to the end. Yes, the file you gave works fine with non-ASCII chars in login. Thank you, now I even don't have to "runas" it as ASCII login! I just run it from my account. Cool! I still don't get how I could know which version of youtube-dl is used by my version of youtube-dlg if youtube-dlg crashed at start. I've clicked "Update" button yesterday when I ran youtube-dlg as ASCII login, but this didn't solve the crash. Only your patch from #57 did. Again, thanks a lot for your help and time! |
Please follow the guide below
x
into all the boxes [ ] relevant to your issue (like that [x])WARNING
All the invalid issues will be rejected!!
Before going further
If your problem is a bug with the youtube-dl program or a request for new site support please report it here
Make sure you are using the latest youtube-dl-gui version:
Options > About
tab. If it's not please download & install the latest version for your OS and check if your issue still persistsMake sure you are using the latest youtube-dl version: Click the
Update
button on the main screen and check if your issue still persistsMake sure you searched the bugtracker for similar issues including closed ones
how can I know, if it is youtube-dl, or it's youtube-dl-gui problem?
Probably, yes, that's not youtube-dl problem 'cause I haven't even seen the GUI window and haven't press Download button.
I've just installed youtube-dl-gui from https://mrs0m30n3.github.io/youtube-dl-gui/
How can I know, which verstion of youtube-dl I use?
Probably, yes, the latest version of youtube-dl-gui probably should use the latest version of youtube-dl, shouldn't it?
the similar issue is marked as solved
Unicode decode error #57
but my problem sure is not solved!
What is the purpose of your issue?
Please remove the following section between the (---) if your problem does not belong to the first two categories (bug report)
What operating system do you use ?
Windows 7 x64 SP 1, russian locale
List of actions to perform to reproduce the problem:
What is the expected behaviour ?
the gui window opens
What happens instead ?
window opens and says «see the log file for details», and OK button. Nothing else, no GUI. After hitting OK, the window closes and that's all.
Description of your issue, suggested solution and other information. Please make sure the description is worded well enough to be understood.
the log file states:
Traceback (most recent call last):
File "youtube-dl-gui", line 35, in
File "youtube_dl_gui_init_.pyc", line 52, in
File "youtube_dl_gui\utils.pyc", line 94, in get_config_path
File "ntpath.pyc", line 84, in join
UnicodeDecodeError: 'ascii' codec can't decode byte 0xd2 in position 7: ordinal not in range(128)
I've installed
Python 2.7.3+
wxPython 3
followed by links from here https://mrs0m30n3.github.io/youtube-dl-gui/ but that didn't help.
The text was updated successfully, but these errors were encountered: