Skip to content

Instantly share code, notes, and snippets.

View mangalan516's full-sized avatar
😄
I may be slow to respond.

Mangalan Gnanasegaram mangalan516

😄
I may be slow to respond.
  • Colombo srilanka
View GitHub Profile
@kennethreitz
kennethreitz / 0_urllib2.py
Created May 16, 2011 00:17
urllib2 vs requests
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import urllib2
gh_url = 'https://api.github.com'
req = urllib2.Request(gh_url)
password_manager = urllib2.HTTPPasswordMgrWithDefaultRealm()