How to fix add-apt-repository doesn’t work behind a proxy server

I am trying to add ubuntu ppa using add-apt-repository and i was not able to add because of some python error urllib2.URLError: