Skip to content
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

proxy support? #8

Open
wxg4net opened this issue Dec 13, 2014 · 5 comments
Open

proxy support? #8

wxg4net opened this issue Dec 13, 2014 · 5 comments

Comments

@wxg4net
Copy link

wxg4net commented Dec 13, 2014

how to use weechat's proxy? thx

@DarkDefender
Copy link
Owner

There isn't any proxy support in weetweet yet. I'm quite busy right now, but I'll take a look at it later.

@DarkDefender
Copy link
Owner

Sorry for the delay...

I've looked into it. It seems like the twitter lib I use doesn't have proxy support yet. However, it's possible to use an other lib to force the twitter lib to use a proxy.

This is the third party lib:
https://github.com/Anorov/PySocks

However it says that it's not recommended to force a proxy this way. So I guess I might run into problems if I do so.

I could create a branch for you to test it on. I guess you can't use twitter without a proxy?

@wxg4net
Copy link
Author

wxg4net commented Dec 28, 2014

yea. thx

@wxg4net wxg4net closed this as completed Dec 28, 2014
@wxg4net wxg4net reopened this Dec 28, 2014
@DarkDefender
Copy link
Owner

I have to admit that I'm new to using proxies.
Do you have any website with free proxies that I could use?
All I find when using google are sites that you can input http addresses into to connect to them via proxy :P

If you want to try it yourself, you should only have to add this after all the imports (line 73):

import socks
socks.set_default_proxy(socks.SOCKS4, <proxy>, <port>))
socket.socket = socks.socksocket

Replace and with the proxy address and port
There are three socket types: socks.SOCKS4, socks.SOCKS5 and socks.HTTP.
Replace the socket type with the correct one.

You got to have https://github.com/Anorov/PySocks installed ofcourse...

@wxg4net
Copy link
Author

wxg4net commented Jan 10, 2015

thx for u reply. by the way. i need't it (proxy) anymore。
Good Day :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants