Skip to content

Instantly share code, notes, and snippets.

@mdengler
Created June 21, 2012 05:01
Show Gist options
  • Save mdengler/2963925 to your computer and use it in GitHub Desktop.
Save mdengler/2963925 to your computer and use it in GitHub Desktop.
#!/usr/bin/env python
"""
Proof of concept scraper for pinnacle sports
"""
FEED = "http://xml.pinnaclesports.com/pinnacleFeed.aspx"
import lxml.etree
import time
import urllib2
#tree = lxml.etree.parse(urllib.urlopen(FEED))
request = urllib2.Request(FEED)
t0 = time.time()
response = urllib2.urlopen(request).read()
t1 = time.time()
print "Read feed in %s seconds" % (t1 - t0)
tree = lxml.etree.fromstring(response)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment