This file contains 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
Traceback (most recent call last): | |
File "/usr/lib/python2.7/threading.py", line 551, in __bootstrap_inner | |
self.run() | |
File "/usr/lib/python2.7/threading.py", line 504, in run | |
self.__target(*self.__args, **self.__kwargs) | |
File "/usr/lib/python2.7/multiprocessing/pool.py", line 369, in _handle_results | |
cache[job]._set(i, obj) | |
File "/usr/lib/python2.7/multiprocessing/pool.py", line 533, in _set | |
self._callback(self._value) | |
File "concurrency.py", line 38, in __call__ |
This file contains 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
1,2c1 | |
< "forums_post_author_email" btree (author_email) | |
< "forums_post_author_email_like" btree (author_email varchar_pattern_ops) | |
--- | |
> "forums_post_author_date" btree (author_id, date) | |
4a4,5 | |
> "forums_post_deleted" btree (forum_id, date) WHERE killed = true | |
> "forums_post_forum_author" btree (forum_id, author_id) | |
6a8,13 | |
> "forums_post_forum_id_date_report_count" btree (forum_id, date, report_count) WHERE report_count > 0 |
This file contains 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
import time | |
from threading import Semaphore | |
from multiprocessing.pool import ThreadPool | |
class ThreadSafeCount(object): | |
def __init__(self): | |
self.mutex = Semaphore(1) |
This file contains 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
#!/bin/bash | |
unique_func_names=`grep -huRPo "def \w+" disqus | cut -d ' ' -f 2 | sort | uniq` | |
for func in $unique_func_names ; do | |
num_found=$(grep -r $func disqus | grep -v "def " | wc -l) | |
if [[ num_found -lt "0" ]]; then | |
echo $num_found $func | |
fi |
This file contains 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
4a5,7 | |
> import Queue | |
> import threading | |
> import heapq | |
13,16c16,29 | |
< class WebSpider(object): | |
< def __init__(self): | |
< self.results = {} | |
< | |
--- |
This file contains 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
4a5,7 | |
> import Queue | |
> import threading | |
> import heapq | |
13,16c16,29 | |
< class WebSpider(object): | |
< def __init__(self): | |
< self.results = {} | |
< | |
--- |
This file contains 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
4a5,7 | |
> import Queue | |
> import threading | |
> import heapq | |
13,16c16,29 | |
< class WebSpider(object): | |
< def __init__(self): | |
< self.results = {} | |
< | |
--- |
This file contains 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
4a5,7 | |
> import Queue | |
> import threading | |
> import heapq | |
13,16c16,29 | |
< class WebSpider(object): | |
< def __init__(self): | |
< self.results = {} | |
< | |
--- |
This file contains 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
with self.reraise(Exception, as=EvmError): | |
evm.count('pclick3')... |
This file contains 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
diff --git a/exam/objects.py b/exam/objects.py | |
index 7e6aaf1..7bedd18 100644 | |
--- a/exam/objects.py | |
+++ b/exam/objects.py | |
@@ -5,3 +5,19 @@ def always(value): | |
return lambda *a, **k: value | |
noop = no_op = always(None) | |
+ | |
+ |