Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
C
cybertron
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
alpha
cybertron
Commits
e4a4dc41
Commit
e4a4dc41
authored
Dec 08, 2018
by
lixiaofang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
try except
parent
a777fa69
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
11 additions
and
11 deletions
+11
-11
workspace.xml
.idea/workspace.xml
+0
-0
auto_at_once.py
auto_at_once.py
+1
-1
auto_click.py
auto_click.py
+1
-1
auto_click_n.py
auto_click_n.py
+1
-1
auto_click_one.py
auto_click_one.py
+1
-1
auto_commnet.py
auto_commnet.py
+1
-1
auto_every_day.py
auto_every_day.py
+2
-2
auto_follow.py
auto_follow.py
+2
-2
auto_lunch_app.py
auto_lunch_app.py
+1
-1
auto_pick.py
auto_pick.py
+0
-0
auto_star_topic.py
auto_star_topic.py
+1
-1
No files found.
.idea/workspace.xml
View file @
e4a4dc41
This diff is collapsed.
Click to expand it.
auto_at_once.py
View file @
e4a4dc41
...
...
@@ -180,7 +180,7 @@ def get_topic_id(numtime):
db
=
pymysql
.
connect
(
host
=
"rm-2ze5k2we69904787l.mysql.rds.aliyuncs.com"
,
user
=
'work'
,
passwd
=
'Gengmei123'
,
db
=
"alpha"
,
port
=
3306
)
cursor
=
db
.
cursor
()
cursor
.
execute
(
"SELECT id FROM topic WHERE create_time >=
%
s"
,(
numtime
))
cursor
.
execute
(
"SELECT id FROM topic WHERE
is_online =1 and
create_time >=
%
s"
,(
numtime
))
data
=
cursor
.
fetchall
()
user_id
=
list
(
data
)
logging
.
info
(
"Database version :
%
s "
%
user_id
)
...
...
auto_click.py
View file @
e4a4dc41
...
...
@@ -114,7 +114,7 @@ def get_data(numtime):
db
=
pymysql
.
connect
(
host
=
"rm-2ze5k2we69904787l.mysql.rds.aliyuncs.com"
,
user
=
'work'
,
passwd
=
'Gengmei123'
,
db
=
"alpha"
,
port
=
3306
)
cursor
=
db
.
cursor
()
cursor
.
execute
(
"SELECT user_id,id FROM topic WHERE create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
cursor
.
execute
(
"SELECT user_id,id FROM topic WHERE
is_online=1 and
create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
data
=
cursor
.
fetchall
()
user_id
=
list
(
data
)
logging
.
info
(
"Database version :
%
s "
%
user_id
)
...
...
auto_click_n.py
View file @
e4a4dc41
...
...
@@ -110,7 +110,7 @@ def get_data(numtime):
db
=
"alpha"
,
port
=
3306
)
cursor
=
db
.
cursor
()
print
(
"---------"
)
cursor
.
execute
(
"SELECT user_id,id FROM topic WHERE create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
cursor
.
execute
(
"SELECT user_id,id FROM topic WHERE
is_online=1 and
create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
data
=
cursor
.
fetchall
()
user_id
=
list
(
data
)
logging
.
info
(
"Database version :
%
s "
%
user_id
)
...
...
auto_click_one.py
View file @
e4a4dc41
...
...
@@ -110,7 +110,7 @@ def get_data(numtime):
db
=
pymysql
.
connect
(
host
=
"rm-2ze5k2we69904787l.mysql.rds.aliyuncs.com"
,
user
=
'work'
,
passwd
=
'Gengmei123'
,
db
=
"alpha"
,
port
=
3306
)
cursor
=
db
.
cursor
()
cursor
.
execute
(
"SELECT user_id,id FROM topic WHERE create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
cursor
.
execute
(
"SELECT user_id,id FROM topic WHERE
is_online=1 and
create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
data
=
cursor
.
fetchall
()
user_id
=
list
(
data
)
logging
.
info
(
"Database version :
%
s "
%
user_id
)
...
...
auto_commnet.py
View file @
e4a4dc41
...
...
@@ -115,7 +115,7 @@ def get_topic_id(numtime):
try
:
db
=
pymysql
.
connect
(
host
=
"rm-2ze5k2we69904787l.mysql.rds.aliyuncs.com"
,
user
=
'work'
,
passwd
=
'Gengmei123'
,
db
=
"alpha"
,
port
=
3306
)
cursor
=
db
.
cursor
()
cursor
.
execute
(
"SELECT id FROM topic WHERE create_time LIKE '
%%%%%
s
%%%%
' "
%
numtime
)
cursor
.
execute
(
"SELECT id FROM topic WHERE
is_online=1 and
create_time LIKE '
%%%%%
s
%%%%
' "
%
numtime
)
data
=
cursor
.
fetchall
()
topic_id
=
list
(
data
)
logging
.
info
(
"Database version :
%
s "
%
topic_id
)
...
...
auto_every_day.py
View file @
e4a4dc41
...
...
@@ -132,7 +132,7 @@ def get_topic_new_user(numtime):
db
=
pymysql
.
connect
(
host
=
"rm-2ze5k2we69904787l.mysql.rds.aliyuncs.com"
,
user
=
'work'
,
passwd
=
'Gengmei123'
,
db
=
"alpha"
,
port
=
3306
)
cursor
=
db
.
cursor
()
cursor
.
execute
(
"SELECT user_id FROM topic WHERE create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
cursor
.
execute
(
"SELECT user_id FROM topic WHERE
is_online=1 and
create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
topic_data
=
cursor
.
fetchall
()
cursor
.
execute
(
"SELECT user_id FROM group_user_role WHERE create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
...
...
@@ -157,7 +157,7 @@ def get_topic_data(numtime):
db
=
pymysql
.
connect
(
host
=
"rm-2ze5k2we69904787l.mysql.rds.aliyuncs.com"
,
user
=
'work'
,
passwd
=
'Gengmei123'
,
db
=
"alpha"
,
port
=
3306
)
cursor
=
db
.
cursor
()
cursor
.
execute
(
"SELECT user_id,id FROM topic WHERE create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
cursor
.
execute
(
"SELECT user_id,id FROM topic WHERE
is_online=1 and
create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
data
=
cursor
.
fetchall
()
user_id
=
list
(
data
)
logging
.
info
(
"Database version :
%
s "
%
user_id
)
...
...
auto_follow.py
View file @
e4a4dc41
...
...
@@ -110,7 +110,7 @@ def get_data(numtime):
db
=
pymysql
.
connect
(
host
=
"rm-2ze5k2we69904787l.mysql.rds.aliyuncs.com"
,
user
=
'work'
,
passwd
=
'Gengmei123'
,
db
=
"alpha"
,
port
=
3306
)
cursor
=
db
.
cursor
()
cursor
.
execute
(
"SELECT distinct(user_id) FROM topic WHERE create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
cursor
.
execute
(
"SELECT distinct(user_id) FROM topic WHERE
is_online=1 and
create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
data
=
cursor
.
fetchall
()
user_id
=
list
(
data
)
logging
.
info
(
"Database version :
%
s "
%
user_id
)
...
...
@@ -137,7 +137,7 @@ def get_commnet_id(numtime):
data_reply
=
cursor
.
fetchall
()
cursor
.
execute
(
"SELECT user_id FROM group_
follow
WHERE create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
"SELECT user_id FROM group_
user_role
WHERE create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
data_group_follow
=
cursor
.
fetchall
()
...
...
auto_lunch_app.py
View file @
e4a4dc41
...
...
@@ -131,7 +131,7 @@ def get_data(numtime):
db
=
pymysql
.
connect
(
host
=
"rm-2ze5k2we69904787l.mysql.rds.aliyuncs.com"
,
user
=
'work'
,
passwd
=
'Gengmei123'
,
db
=
"alpha"
,
port
=
3306
)
cursor
=
db
.
cursor
()
cursor
.
execute
(
"SELECT user_id,id FROM topic WHERE create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
cursor
.
execute
(
"SELECT user_id,id FROM topic WHERE
is_online=1 and
create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
data
=
cursor
.
fetchall
()
user_id
=
list
(
data
)
logging
.
info
(
"Database version :
%
s "
%
data
)
...
...
auto_pick.py
View file @
e4a4dc41
auto_star_topic.py
View file @
e4a4dc41
...
...
@@ -150,7 +150,7 @@ def get_star_topic_id(numtime):
db
=
"alpha"
,
port
=
3306
)
cursor
=
db
.
cursor
()
cursor
.
execute
(
"SELECT id FROM topic WHERE content_level =4 or content_level =5 and create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
"SELECT id FROM topic WHERE
is_online=1 and
content_level =4 or content_level =5 and create_time LIKE '
%%%%%
s
%%%%
'"
%
numtime
)
data
=
cursor
.
fetchall
()
user_id
=
list
(
data
)
logging
.
info
(
"Database version :
%
s "
%
data
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment