-
Notifications
You must be signed in to change notification settings - Fork 725
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
v1.0.0 hangs autocompleting haxor-news view command on running Windows #308
Comments
Thanks for reporting. I'll look into this asap. (A few hours ago, I tried to reproduce it, but actually, I was unable.) |
Thanks Jonathan. One other thing I forgot to mention, not sure if it makes a difference: I'm running Windows 10 on VirtualBox (edited issue description above). I'll try again tomorrow and try to create a gif of a screen capture of what I'm seeing. |
Here's a video of what I'm seeing on https://www.dropbox.com/s/du8v67rzaw4l99e/haxor-news-bug.mov?dl=0 Video is a little choppy because I'm running QuickTime screen record + Windows 10 on a VM with limited resources allocated to it. |
Trying to reproduce: I can reproduce it, but at some point, I got the exception below: File "c:\users\jonat\documents\github\haxor-news\haxor_news\hacker_news_cli.py", line 367, in view
browser)
File "c:\users\jonat\documents\github\haxor-news\haxor_news\hacker_news.py", line 638, in view_setup
browser)
File "c:\users\jonat\documents\github\haxor-news\haxor_news\hacker_news.py", line 553, in view
comments_hide_non_matching=comments_hide_non_matching)
File "c:\users\jonat\documents\github\haxor-news\haxor_news\hacker_news.py", line 255, in print_comments
depth=depth)
File "c:\users\jonat\documents\github\haxor-news\haxor_news\hacker_news.py", line 243, in print_comments
self.print_comment(item, regex_query, comments_hide_non_matching, depth)
File "c:\users\jonat\documents\github\haxor-news\haxor_news\hacker_news.py", line 216, in print_comment
click.echo(formatted_comment, color=True)
File "C:\Users\jonat\AppData\Local\Programs\Python\Python35\lib\site-packages\click-6.6-py3.5.egg\click\utils.py", line 259, in echo
file.write(message)
File "C:\Users\jonat\AppData\Local\Programs\Python\Python35\lib\site-packages\click-6.6-py3.5.egg\click\_compat.py", line 571, in _safe_write
return _write(s)
File "C:\Users\jonat\AppData\Local\Programs\Python\Python35\lib\site-packages\colorama-0.3.7-py3.5.egg\colorama\ansitowin32.py", line 40, in write
File "C:\Users\jonat\AppData\Local\Programs\Python\Python35\lib\site-packages\colorama-0.3.7-py3.5.egg\colorama\ansitowin32.py", line 141, in write
File "C:\Users\jonat\AppData\Local\Programs\Python\Python35\lib\site-packages\colorama-0.3.7-py3.5.egg\colorama\ansitowin32.py", line 166, in write_and_convert
File "C:\Users\jonat\AppData\Local\Programs\Python\Python35\lib\site-packages\colorama-0.3.7-py3.5.egg\colorama\ansitowin32.py", line 174, in write_plain_text
File "C:\Users\jonat\AppData\Local\Programs\Python\Python35\lib\encodings\cp1252.py", line 19, in encode
return codecs.charmap_encode(input,self.errors,encoding_table)[0]
UnicodeEncodeError: 'charmap' codec can't encode character '\u25ce' in position 2: character maps to <undefined> |
Hi @donnemartin, The bug is actually at this line:
By changing the Anyway, just don't assign to Edit: there are a few small things in the completer code that I'm going to improve as well. Not sure how this all plays together, but I guess the above change should be sufficient. Jonathan |
Here I made |
Thanks for the quick investigation @jonathanslenders! I'll try to check this out tomorrow and report back. |
@jonathanslenders that did the trick, thank you!
Hmm, curious if you see this error for all posts or just a few? And if it's not all posts, please let me know which one and I can try to get a fix. I'm not able to reproduce it on my end, I think it should have been fixed by donnemartin/haxor-news#36. |
If you don't mind, I'm closing this issue. The bug, related to modifying a About the bug that I generated, I was not able to reproduce it. |
No problem thanks for the support Jonathan! |
Hi Jonathan,
I ran into this issue updating
prompt-toolkit
to v1.0.0 onhaxor-news
v0.4.0:Build
haxor-news
v0.4.0, runningprompt-toolkit
v1.0.0:https://github.com/donnemartin/haxor-news/releases/tag/0.4.0
Environment
Windows 10 (on VirtualBox 5.0.20)
Python 3.5.1
Steps to reproduce
*Hangs for awhile but eventually comes back, I'm attempting to type
hn view 1 -c
.Previous version of
prompt-toolkit
v0.52 doesn't have the same issue. I've reverted back to v0.52 for now.-Donne
The text was updated successfully, but these errors were encountered: