ye-yechen / v2ex-terminal Goto Github PK
View Code? Open in Web Editor NEWbrowse v2ex by a terminal
browse v2ex by a terminal
Traceback (most recent call last):
File "v2ex.py", line 92, in <module>
main()
File "v2ex.py", line 60, in main
resp = login()
File "~/v2ex-terminal/login.py", line 100, in login
username = raw_input(termcolor.colored(u'输入用户名: ', 'cyan'))
UnicodeEncodeError: 'ascii' codec can't encode characters in position 5-9: ordinal not in range(128)
For this one, I just turn
username = raw_input(termcolor.colored(u'输入用户名: ', 'cyan'))
password = raw_input(termcolor.colored(u'输入密码: ', 'cyan'))
into
username = raw_input(termcolor.colored('输入用户名: ', 'cyan'))
password = raw_input(termcolor.colored('输入密码: ', 'cyan'))
and it worked.
Traceback (most recent call last):
File "v2ex.py", line 92, in <module>
main()
File "v2ex.py", line 73, in main
work()
File "~/v2ex-terminal/operate.py", line 188, in work
welcome()
File "~/v2ex-terminal/operate.py", line 144, in welcome
get_my_time()
File "~/v2ex-terminal/operate.py", line 100, in get_my_time
url = home_page_url + "/api/members/show.json?username=" + globlevalue.username
TypeError: cannot concatenate 'str' and 'NoneType' objects
For this one, I turn url = home_page_url + "/api/members/show.json?username=" + globlevalue.username
into url = str(home_page_url) + "/api/members/show.json?username=" + str(globlevalue.username)
and it worked.
Besides, the order clear
didn't work.
hi, do you have any plans to replace selenium calls with requests? I reckon that as a terminal program you should use as little requirements as possible just as the terminal does. Anyway it's a nice project!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.