2020-05-11 12:21:10 +00:00
|
|
|
#!/usr/bin/env python3
|
|
|
|
# -*-coding:UTF-8 -*
|
|
|
|
|
|
|
|
import os
|
|
|
|
import sys
|
|
|
|
import redis
|
|
|
|
|
|
|
|
sys.path.append(os.path.join(os.environ['AIL_BIN'], 'lib/'))
|
|
|
|
import ConfigLoader
|
2020-07-09 15:50:43 +00:00
|
|
|
import Username
|
2020-05-11 12:21:10 +00:00
|
|
|
|
|
|
|
config_loader = ConfigLoader.ConfigLoader()
|
|
|
|
r_serv_crawler = config_loader.get_redis_conn("ARDB_Onion")
|
|
|
|
config_loader = None
|
|
|
|
|
|
|
|
def save_item_correlation(username, item_id, item_date):
|
2020-07-09 15:50:43 +00:00
|
|
|
Username.save_item_correlation('telegram', username, item_id, item_date)
|
2020-05-11 12:21:10 +00:00
|
|
|
|
|
|
|
def save_telegram_invite_hash(invite_hash, item_id):
|
|
|
|
r_serv_crawler.sadd('telegram:invite_code', '{};{}'.format(invite_hash, item_id))
|