This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Room(): | |
@classmethod | |
def _process_calendar(self, s): | |
return [[x.split(':')[0],x.split(':')[1]] for x in s.replace('"','').replace(' ','').replace('{','').replace('}','').split(',')] | |
def __init__(self, s): | |
a = s[0:-1].split('\t') | |
self.url = a[0] | |
self.date_parsed = a[1] | |
self.bedrooms = a[9] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
MAX_THREADS = 5 | |
delay = 0.5 | |
import psycopg2 | |
import re | |
import sys | |
import time | |
import threading | |
import urllib2 | |
import urlparse |