Clojure 1.2.1/1.3/1.4 ‘proxy generated in Grails 2.0.0 runtime fails. 1.2.0 is fine

I found an Issue called CLJ-944 on clojure.org. There you can find a fix for ClassCastException: clojure.lang.PersistentArrayMap cannot be cast to java.lang.Class issue The problem is: that the compiler injects an incorrect cast to clojure.lang.PersistentHashMap. In this case it should probably be cast to a clojure.lang.Associative, the highest common interface having the .containsKey method. Patch … Read more

How to get pip to work behind a proxy server [duplicate]

The pip’s proxy parameter is, according to pip –help, in the form scheme://[user:passwd@]proxy.server:port You should use the following: pip install –proxy http://user:password@proxyserver:port TwitterApi Also, the HTTP_PROXY env var should be respected. Note that in earlier versions (couldn’t track down the change in the code, sorry, but the doc was updated here), you had to leave … Read more

Connect with SSH through a proxy

Here’s how to do Richard Christensen’s answer as a one-liner, no file editing required (replace capitalized with your own settings, PROXYPORT is frequently 80): ssh USER@FINAL_DEST -o “ProxyCommand=nc -X connect -x PROXYHOST:PROXYPORT %h %p” You can use the same -o … option for scp as well, see my superuser answer. If you get this in … Read more

Using a socks proxy with git for the http transport

I tested with Git 1.8.2 and SOCKS v5 proxy, following setting works for me: git config –global http.proxy ‘socks5://127.0.0.1:7070’ UPDATE 2017-3-31: According to the document, despite the name http.proxy, it should work for both HTTP and HTTPS repository urls. Thanks @user for pointing out this. UPDATE 2018-11-27: To disable the proxy, run command: git config … Read more

C# Connecting Through Proxy

This is easily achieved either programmatically, in your code, or declaratively in either the web.config or the app.config. You can programmatically create a proxy like so: HttpWebRequest request = (HttpWebRequest)WebRequest.Create(“[ultimate destination of your request]”); WebProxy myproxy = new WebProxy(“[your proxy address]”, [your proxy port number]); myproxy.BypassProxyOnLocal = false; request.Proxy = myproxy; request.Method = “GET”; HttpWebResponse … Read more

How to create a simple http proxy in node.js?

I don’t think it’s a good idea to process response received from the 3rd party server. This will only increase your proxy server’s memory footprint. Further, it’s the reason why your code is not working. Instead try passing the response through to the client. Consider following snippet: var http = require(‘http’); http.createServer(onRequest).listen(3000); function onRequest(client_req, client_res) … Read more

Running Selenium Webdriver with a proxy in Python

Works for me this way (similar to @Amey and @user4642224 code, but shorter a bit): from selenium import webdriver from selenium.webdriver.common.proxy import Proxy, ProxyType prox = Proxy() prox.proxy_type = ProxyType.MANUAL prox.http_proxy = “ip_addr:port” prox.socks_proxy = “ip_addr:port” prox.ssl_proxy = “ip_addr:port” capabilities = webdriver.DesiredCapabilities.CHROME prox.add_to_capabilities(capabilities) driver = webdriver.Chrome(desired_capabilities=capabilities)

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)