login in facebook with python
===

i can login in facebook with this  code after  login i can  accessing a page that requires you to be logged in

    def SignIn(self):
        url = 'https://login.facebook.com/login.php?login_attempt=1'
        data = "locale=en_US&non_com_login=&email="+str(self.Username)+"&pass="+str(self.Password)+"&lsd=20TOl"
        self.cookie = cookielib.CookieJar()
        
        try:
            self.opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(self.cookie))
        except:
            sys.stderr.write("Unexpected error!".format(src))
        
        try:
             self.opener.open('https://www.facebook.com')
        except:
             sys.stderr.write("Unexpected error!1")
             
        try:
             self.opener.open(url, data)
        except:
            sys.stderr.write("Unexpected error!2")
            
        self.IsSignIned=True  
        return self.opener



but this  code  dont work 

    import requests
    
    
    headers = {'Host':'www.facebook.com',
    'Origin':'http://www.facebook.com',
    'Referer':'http://www.facebook.com/',
    'User-Agent':'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.11 (KHTML, like Gecko) Chrome/20.0.1132.47 Safari/536.11'}
    
    
    s = requests.session(headers=headers)
    login_data = {
        'locale':'en_US',
        'non_com_login':'',
        'email':'mymail@mail.com',
        'pass':'mypassword',
        'lsd':'20TOl'
        }
    
    r=s.post('https://login.facebook.com/login.php?login_attempt=1',data=login_data,verify=False)
    print r.content
    print r.status_code


it return 

> Facebook Login
> 
> Cookies Required
> 
> Cookies are not enabled on your browser. Please adjust this in your
> security preferences before continuing.

i must use requests library because i need  Gzip and keep-alive 

what is  problem ?
is any other library that handle all of this?(Gzip ,Keep-alive cookie ,..)