code: def dict_from_cookiejar(cj):
      
  
      cookie_dict = {}
  
      for _, cookies in cj._cookies.items():
          for _, cookies in cookies.items():
              for cookie in cookies.values():
                  # print cookie
                  cookie_dict[cookie.name] = cookie.value
  
      return cookie_dict
docs: Returns a key/value dictionary from a CookieJar.
  
      :param cj: CookieJar object to extract cookies from.