Completely overhauled threadsearch to use threading and a synchronised queue now. Also, when searching for catalog, a new thread will be spawned per page. When searching through the whole board, the threads.json link is used instead of catalog.json, and a new python thread is spawned per 4chan thread on a page
Added a few lines to fetch the posts from the synchronous queue, and sed replaced all occurrences of 4 spaces with a tab character
temporarily tried adding another mutex to the urllib2.urlopen() call in get_json, but it reduced the problem; it didn't resolve it. I'll call it a night.