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
SELECT rc.rc_title, | |
rc.rc_cur_id, | |
rc.rc_namespace, | |
cl.cl_timestamp | |
FROM recentchanges as rc | |
INNER JOIN recentchanges AS rc_talk | |
ON rc.rc_title = rc_talk.rc_title | |
AND rc.rc_namespace = (rc_talk.rc_namespace - (rc_talk.rc_namespace % 2)) | |
INNER JOIN categorylinks AS cl | |
ON rc_talk.rc_cur_id = cl.cl_from |
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
SELECT rc.rc_id, | |
rc.rc_cur_id, | |
rc.rc_title, | |
rc.rc_timestamp, | |
rc.rc_this_oldid, | |
rc.rc_last_oldid, | |
rc.rc_user_text, | |
rc.rc_old_len, | |
rc.rc_new_len, | |
rc.rc_comment |
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
Wikipedia+IFTTT traffic as of 8/1/2015: 9,100,671 requests served |
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
* add social search record count | |
* change hashtag job to run more frequently | |
* change hashtag job to only pull since the last found hashtag (or 24 hours) | |
* GeoSearch continuation followup | |
* GeoSearch trigger strategy | |
* Daily email update (MZMC) | |
* Weeklypedia translations | |
* Weeklypedia stats RSS |
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
#!/usr/bin/python | |
import shlex | |
import subprocess | |
import bisect | |
from collections import namedtuple | |
import itertools | |
import textwrap | |
from argparse import ArgumentParser |
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
function nextID($id) { | |
$avail_chars = $this->config->item('link_id_chars'); //a string, no dupe chars plz. | |
if($id === '') { | |
return $avail_chars[0]; | |
} else if($id[strlen($id)-1] === $avail_chars[strlen($avail_chars)-1]) { | |
return $this->nextID(substr($id, 0, -1)).$avail_chars[0]; | |
} else { | |
return substr($id, 0, -1).$avail_chars[strrpos($avail_chars,$id[strlen($id)-1])+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
see iterutils.remap under github.com/mahmoud/boltons |
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
Importer.py | |
/ftp/public | |
Traceback (most recent call last): | |
File "Importer.py", line 65, in <module> | |
importer.import_path(path) | |
File "Importer.py", line 56, in import_path | |
self.import_path(os.path.join(path,entry)) | |
File "Importer.py", line 56, in import_path | |
self.import_path(os.path.join(path,entry)) | |
File "Importer.py", line 56, in import_path |
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 random | |
PyDict_MINSIZE = 8 # from dictobject.h | |
class DictDestroyer(object): | |
def __init__(self): | |
self.hash = 1 | |
def __hash__(self): | |
self.hash = random.randint(0, 2**31) | |
return self.hash |
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
(for fixed sized inputs, so not terribly useful. It's VBScript, so also not terribly useful. Also, haven't run this.) | |
Dim myArray(4) | |
myArray(0) = A | |
myArray(1) = B | |
myArray(2) = C | |
myArray(3) = D | |
myArray(4) = E | |
Function MinN( vals ) |