Commit c4f49827 authored by 吴升宇's avatar 吴升宇

Merge branch 'wsy3' into 'master'

fix majia rule

See merge request alpha/physical!584
parents e9d49eef 696c2cae
......@@ -22,7 +22,7 @@ ontime_list = [
# "0 14,18,22 * * * source /srv/envs/physical/bin/activate && cd /srv/apps/physical && python manage.py trans2es_mapping2es -m principal_online_comment1",
"25 */1 * * * source /srv/envs/physical/bin/activate && cd /srv/apps/physical && python manage.py trans2es_mapping2es -m auto_reply_per_2h_to_topic",
"0 8 * * * source /srv/envs/physical/bin/activate && cd /srv/apps/physical && python manage.py trans2es_mapping2es -m auto_click_per_1d_by_post",
"1 8 * * * source /srv/envs/physical/bin/activate && cd /srv/apps/physical && python manage.py trans2es_mapping2es -m auto_follow_per_1d_by_regist",
# "1 8 * * * source /srv/envs/physical/bin/activate && cd /srv/apps/physical && python manage.py trans2es_mapping2es -m auto_follow_per_1d_by_regist",
"0 8 * * * source /srv/envs/physical/bin/activate && cd /srv/apps/physical && python manage.py trans2es_mapping2es -m auto_urge_per_1d_by_regist",
"2 8 * * * source /srv/envs/physical/bin/activate && cd /srv/apps/physical && python manage.py trans2es_mapping2es -m auto_follow_per_1d_by_post",
"3 8 * * * source /srv/envs/physical/bin/activate && cd /srv/apps/physical && python manage.py trans2es_mapping2es -m auto_reply_per_1d_to_pictorial",
......
......@@ -57,7 +57,7 @@ def auto_click_per_1d_by_post():
numtime1, numtime2 = time_convs(1, 1)
topic_ids = get_commnet_id(numtime2, numtime1, content_level_low=0, content_level_top=3)
for topic_id in topic_ids:
click_num = random.randint(6, 12)
click_num = random.randint(1, 3)
for i in range(click_num):
auto_click_list.append(topic_id)
......@@ -65,7 +65,7 @@ def auto_click_per_1d_by_post():
numtime1, numtime2 = time_convs(2, 15)
topic_ids = get_commnet_id(numtime2, numtime1, content_level_low=0, content_level_top=3)
for topic_id in topic_ids:
click_num = random.randint(0, 2)
click_num = random.randint(0, 1)
for i in range(click_num):
auto_click_list.append(topic_id)
......
......@@ -45,7 +45,7 @@ def auto_follow_per_1d_by_post():
numtime1, numtime2 = time_convs(1, 1)
user_ids = get_commnet_id(numtime2, numtime1, content_level_low=0, content_level_top=3)
for user_id in user_ids:
follow_num = random.randint(3, 6)
follow_num = random.randint(1, 3)
for i in range(follow_num):
auto_follow_list.append(user_id)
......
......@@ -62,12 +62,13 @@ def auto_follow_per_2h_by_post_and_regist():
for i in range(follow_num):
auto_follow_list.append(user_id)
numtime1, numtime2 = time_conv_hour(0, 1)
user_ids = get_commnet_id_by_regist(numtime2, numtime1, content_level_low=0, content_level_top=6)
for user_id in user_ids:
follow_num = random.randint(6, 10)
for i in range(follow_num):
auto_follow_list.append(user_id)
# 注册后不加粉
# numtime1, numtime2 = time_conv_hour(0, 1)
# user_ids = get_commnet_id_by_regist(numtime2, numtime1, content_level_low=0, content_level_top=6)
# for user_id in user_ids:
# follow_num = random.randint(6, 10)
# for i in range(follow_num):
# auto_follow_list.append(user_id)
except:
logging_exception()
......
......@@ -62,7 +62,7 @@ def auto_reply_per_1d_to_topic():
numtime1, numtime2 = time_convs(1, 1)
topic_ids = get_data(numtime1, numtime2, 0, 3)
for topic_id in topic_ids:
random_num = random.randint(3, 6)
random_num = random.randint(0, 1)
for num in range(random_num):
topic_id_list.append(topic_id)
......@@ -79,7 +79,7 @@ def auto_reply_per_1d_to_topic():
numtime1, numtime2 = time_convs(1, 1)
topic_ids = get_data(numtime1, numtime2, 4, 6)
for topic_id in topic_ids:
random_num = random.randint(1, 6)
random_num = random.randint(2, 5)
for num in range(random_num):
topic_id_list.append(topic_id)
......@@ -87,7 +87,7 @@ def auto_reply_per_1d_to_topic():
numtime1, numtime2 = time_convs(2, 6)
topic_ids = get_data(numtime1, numtime2, 4, 6)
for topic_id in topic_ids:
random_num = random.randint(1, 3)
random_num = random.randint(0, 3)
for num in range(random_num):
topic_id_list.append(topic_id)
......
......@@ -42,28 +42,27 @@ def auto_urge_per_1d_by_regist():
auto_urge_list = []
try:
# 1天前注册:[3-6]个催更
numtime1, numtime2 = time_convs(1, 1)
user_ids= get_commnet_id(numtime2, numtime1)
for user_id in user_ids:
follow_num = random.randint(3, 6)
for i in range(follow_num):
auto_urge_list.append(user_id)
# numtime1, numtime2 = time_convs(1, 1)
# user_ids= get_commnet_id(numtime2, numtime1)
# for user_id in user_ids:
# follow_num = random.randint(3, 6)
# for i in range(follow_num):
# auto_urge_list.append(user_id)
# 2-10天前注册:[0-1]个催更
numtime1, numtime2 = time_convs(2, 10)
user_ids = get_commnet_id(numtime2, numtime1)
for user_id in user_ids:
follow_num = random.randint(0, 1)
for i in range(follow_num):
auto_urge_list.append(user_id)
# 10天前注册:每隔9天[0-1]个催更
numtime1, numtime2 = time_convs(2, 10)
# todo 加一个过滤时间
# numtime1, numtime2 = time_convs(2, 10)
# user_ids = get_commnet_id(numtime2, numtime1)
# for user_id in user_ids:
# follow_num = random.randint(0, 1)
# for i in range(follow_num):
# auto_urge_list.append(user_id)
# 每隔9天[0-1]个催更
numtime1, numtime2 = time_convs(1, 1)
user_ids = get_commnet_id('2019-05-11', numtime2)
for user_id in user_ids:
follow_num = random.randint(1, 10)
follow_num = random.randint(1, 18)
if follow_num == 1:
auto_urge_list.append(user_id)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment