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
40692df0
Commit
40692df0
authored
Apr 19, 2019
by
lixiaofang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add
parent
6c25e328
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
90 additions
and
99 deletions
+90
-99
workspace.xml
.idea/workspace.xml
+83
-69
auto_click.py
auto_click.py
+0
-2
auto_request.py
auto_request.py
+1
-0
auto_user_id.py
auto_user_id.py
+0
-4
offline_comment.py
offline_comment.py
+6
-24
No files found.
.idea/workspace.xml
View file @
40692df0
<?xml version="1.0" encoding="UTF-8"?>
<project
version=
"4"
>
<component
name=
"ChangeListManager"
>
<list
default=
"true"
id=
"fd1f0b61-1139-44e5-87e7-f8b86ff52376"
name=
"Default Changelist"
comment=
""
/>
<list
default=
"true"
id=
"fd1f0b61-1139-44e5-87e7-f8b86ff52376"
name=
"Default Changelist"
comment=
""
>
<change
beforePath=
"$PROJECT_DIR$/auto_click.py"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/auto_click.py"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/auto_request.py"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/auto_request.py"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/auto_user_id.py"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/auto_user_id.py"
afterDir=
"false"
/>
<change
beforePath=
"$PROJECT_DIR$/offline_comment.py"
beforeDir=
"false"
afterPath=
"$PROJECT_DIR$/offline_comment.py"
afterDir=
"false"
/>
</list>
<option
name=
"EXCLUDED_CONVERTED_TO_IGNORED"
value=
"true"
/>
<option
name=
"SHOW_DIALOG"
value=
"false"
/>
<option
name=
"HIGHLIGHT_CONFLICTS"
value=
"true"
/>
...
...
@@ -24,7 +29,7 @@
<entry
key=
"batch_user_gen"
value=
"2"
/>
<entry
key=
"comment"
value=
"2"
/>
<entry
key=
"guanshui"
value=
"2"
/>
<entry
key=
"py"
value=
"12
5
"
/>
<entry
key=
"py"
value=
"12
6
"
/>
<entry
key=
"txt"
value=
"5"
/>
<entry
key=
"xuqiu"
value=
"2"
/>
</counts>
...
...
@@ -32,7 +37,7 @@
<usages-collector
id=
"statistics.file.types.open"
>
<counts>
<entry
key=
"PLAIN_TEXT"
value=
"13"
/>
<entry
key=
"Python"
value=
"12
5
"
/>
<entry
key=
"Python"
value=
"12
6
"
/>
</counts>
</usages-collector>
<usages-collector
id=
"statistics.file.extensions.edit"
>
...
...
@@ -40,14 +45,14 @@
<entry
key=
"comment"
value=
"59"
/>
<entry
key=
"dummy"
value=
"6"
/>
<entry
key=
"guanshui"
value=
"2"
/>
<entry
key=
"py"
value=
"3
861
"
/>
<entry
key=
"py"
value=
"3
914
"
/>
<entry
key=
"xuqiu"
value=
"223"
/>
</counts>
</usages-collector>
<usages-collector
id=
"statistics.file.types.edit"
>
<counts>
<entry
key=
"PLAIN_TEXT"
value=
"290"
/>
<entry
key=
"Python"
value=
"3
861
"
/>
<entry
key=
"Python"
value=
"3
914
"
/>
</counts>
</usages-collector>
</session>
...
...
@@ -118,11 +123,8 @@
<file
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/auto_at_once.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"270"
>
<caret
line=
"18"
column=
"152"
lean-forward=
"true"
selection-start-line=
"18"
selection-start-column=
"116"
selection-end-line=
"18"
selection-end-column=
"152"
/>
<folding>
<element
signature=
"e#0#15#0"
expanded=
"true"
/>
</folding>
<state
relative-caret-position=
"105"
>
<caret
line=
"7"
column=
"22"
selection-start-line=
"7"
selection-end-line=
"8"
/>
</state>
</provider>
</entry>
...
...
@@ -139,14 +141,13 @@
</provider>
</entry>
</file>
<file
pinned=
"false"
current-in-tab=
"
tru
e"
>
<file
pinned=
"false"
current-in-tab=
"
fals
e"
>
<entry
file=
"file://$PROJECT_DIR$/offline_comment.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
-34
"
>
<caret
line=
"
28"
column=
"35"
lean-forward=
"true"
selection-start-line=
"28"
selection-start-column=
"35"
selection-end-line=
"28"
selection-end-column=
"35
"
/>
<state
relative-caret-position=
"
45
"
>
<caret
line=
"
3"
column=
"26"
selection-start-line=
"3"
selection-start-column=
"26"
selection-end-line=
"3"
selection-end-column=
"26
"
/>
<folding>
<element
signature=
"e#0#15#0"
expanded=
"true"
/>
<marker
date=
"1555665806000"
expanded=
"true"
signature=
"2000:2003"
ph=
"..."
/>
<marker
date=
"1555667738000"
expanded=
"true"
signature=
"1847:1850"
ph=
"..."
/>
</folding>
</state>
</provider>
...
...
@@ -155,8 +156,8 @@
<file
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/auto_user_id.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
45
0"
>
<caret
line=
"
30"
column=
"18"
selection-start-line=
"30"
selection-start-column=
"18"
selection-end-line=
"30"
selection-end-column=
"18
"
/>
<state
relative-caret-position=
"
30
0"
>
<caret
line=
"
20"
column=
"19"
selection-start-line=
"20"
selection-start-column=
"19"
selection-end-line=
"20"
selection-end-column=
"19
"
/>
<folding>
<element
signature=
"e#1#15#0"
expanded=
"true"
/>
</folding>
...
...
@@ -167,10 +168,10 @@
<file
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/auto_click.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
255
"
>
<caret
line=
"
17"
column=
"106"
selection-start-line=
"17"
selection-start-column=
"13"
selection-end-line=
"17"
selection-end-column=
"106
"
/>
<state
relative-caret-position=
"
419
"
>
<caret
line=
"
28"
column=
"8"
lean-forward=
"true"
selection-start-line=
"28"
selection-start-column=
"8"
selection-end-line=
"28"
selection-end-column=
"8
"
/>
<folding>
<element
signature=
"e#0#1
5
#0"
expanded=
"true"
/>
<element
signature=
"e#0#1
1
#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
...
...
@@ -179,8 +180,8 @@
<file
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/auto_request.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
1365
"
>
<caret
line=
"
95"
column=
"4"
selection-start-line=
"95"
selection-start-column=
"4"
selection-end-line=
"95"
selection-end-column=
"4
"
/>
<state
relative-caret-position=
"
-1062
"
>
<caret
line=
"
31"
selection-start-line=
"31"
selection-end-line=
"31
"
/>
<folding>
<element
signature=
"e#0#15#0"
expanded=
"true"
/>
</folding>
...
...
@@ -191,12 +192,24 @@
<file
pinned=
"false"
current-in-tab=
"false"
>
<entry
file=
"file://$PROJECT_DIR$/user_session.txt"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
386
"
>
<state
relative-caret-position=
"
1020
"
>
<caret
line=
"68"
column=
"33"
selection-start-line=
"68"
selection-end-line=
"69"
/>
</state>
</provider>
</entry>
</file>
<file
pinned=
"false"
current-in-tab=
"true"
>
<entry
file=
"file://$PROJECT_DIR$/auto_click_n.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"735"
>
<caret
line=
"49"
lean-forward=
"true"
selection-start-line=
"49"
selection-end-line=
"49"
/>
<folding>
<element
signature=
"e#0#15#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
</entry>
</file>
</leaf>
</component>
<component
name=
"FileTemplateManagerImpl"
>
...
...
@@ -273,18 +286,19 @@
<option
value=
"$PROJECT_DIR$/_celery.py"
/>
<option
value=
"$PROJECT_DIR$/auto_at_once.py"
/>
<option
value=
"$PROJECT_DIR$/comment.txt"
/>
<option
value=
"$PROJECT_DIR$/auto_request.py"
/>
<option
value=
"$PROJECT_DIR$/auto_user_id.py"
/>
<option
value=
"$PROJECT_DIR$/instant.py"
/>
<option
value=
"$PROJECT_DIR$/auto_click.py"
/>
<option
value=
"$PROJECT_DIR$/offline_comment.py"
/>
<option
value=
"$PROJECT_DIR$/auto_user_id.py"
/>
<option
value=
"$PROJECT_DIR$/auto_request.py"
/>
<option
value=
"$PROJECT_DIR$/auto_click.py"
/>
</list>
</option>
</component>
<component
name=
"ProjectFrameBounds"
>
<option
name=
"y"
value=
"23"
/>
<option
name=
"width"
value=
"1280"
/>
<option
name=
"height"
value=
"725"
/>
<component
name=
"ProjectFrameBounds"
extendedState=
"6"
>
<option
name=
"x"
value=
"-322"
/>
<option
name=
"y"
value=
"-1080"
/>
<option
name=
"width"
value=
"1920"
/>
<option
name=
"height"
value=
"1080"
/>
</component>
<component
name=
"ProjectView"
>
<navigator
proportions=
""
version=
"1"
>
...
...
@@ -494,11 +508,12 @@
<servers
/>
</component>
<component
name=
"ToolWindowManager"
>
<frame
x=
"0"
y=
"23"
width=
"1280"
height=
"725"
extended-state=
"0"
/>
<frame
x=
"-322"
y=
"-1080"
width=
"1920"
height=
"1080"
extended-state=
"6"
/>
<editor
active=
"true"
/>
<layout>
<window_info
id=
"Structure"
order=
"0"
sideWeight=
"0.21188119"
side_tool=
"true"
weight=
"0.19112115"
/>
<window_info
id=
"Favorites"
order=
"1"
side_tool=
"true"
/>
<window_info
content_ui=
"combo"
id=
"Project"
order=
"2"
sideWeight=
"0.7872763"
visible=
"true"
weight=
"0.07625099
"
/>
<window_info
active=
"true"
content_ui=
"combo"
id=
"Project"
order=
"2"
sideWeight=
"0.7872763"
visible=
"true"
weight=
"0.1790416
"
/>
<window_info
id=
"DB Browser"
order=
"3"
/>
<window_info
anchor=
"bottom"
id=
"Message"
order=
"0"
/>
<window_info
anchor=
"bottom"
id=
"Find"
order=
"1"
weight=
"0.3284974"
/>
...
...
@@ -508,7 +523,7 @@
<window_info
anchor=
"bottom"
id=
"Inspection"
order=
"5"
weight=
"0.4"
/>
<window_info
anchor=
"bottom"
id=
"TODO"
order=
"6"
/>
<window_info
anchor=
"bottom"
id=
"Version Control"
order=
"7"
show_stripe_button=
"false"
/>
<window_info
a
ctive=
"true"
anchor=
"bottom"
id=
"Terminal"
order=
"8"
visible=
"true"
weight=
"0.050819673
"
/>
<window_info
a
nchor=
"bottom"
id=
"Terminal"
order=
"8"
visible=
"true"
weight=
"0.36683938
"
/>
<window_info
anchor=
"bottom"
id=
"Event Log"
order=
"9"
side_tool=
"true"
/>
<window_info
anchor=
"bottom"
id=
"Python Console"
order=
"10"
/>
<window_info
anchor=
"bottom"
id=
"DB Execution Console"
order=
"11"
/>
...
...
@@ -732,13 +747,6 @@
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/auto_click_n.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"-189"
>
<caret
line=
"6"
column=
"14"
lean-forward=
"true"
selection-start-line=
"6"
selection-start-column=
"14"
selection-end-line=
"6"
selection-end-column=
"14"
/>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/epp_scripts/test2.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"300"
>
...
...
@@ -865,6 +873,19 @@
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/user_id.txt"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
/>
</entry>
<entry
file=
"file://$PROJECT_DIR$/offline_comment.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"45"
>
<caret
line=
"3"
column=
"26"
selection-start-line=
"3"
selection-start-column=
"26"
selection-end-line=
"3"
selection-end-column=
"26"
/>
<folding>
<marker
date=
"1555667738000"
expanded=
"true"
signature=
"1847:1850"
ph=
"..."
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/instant.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"300"
>
...
...
@@ -875,63 +896,56 @@
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/user_id.txt"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
/>
</entry>
<entry
file=
"file://$PROJECT_DIR$/user_session.txt"
>
<entry
file=
"file://$PROJECT_DIR$/auto_user_id.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"386"
>
<caret
line=
"68"
column=
"33"
selection-start-line=
"68"
selection-end-line=
"69"
/>
<state
relative-caret-position=
"300"
>
<caret
line=
"20"
column=
"19"
selection-start-line=
"20"
selection-start-column=
"19"
selection-end-line=
"20"
selection-end-column=
"19"
/>
<folding>
<element
signature=
"e#1#15#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/auto_
click
.py"
>
<entry
file=
"file://$PROJECT_DIR$/auto_
request
.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
255
"
>
<caret
line=
"
17"
column=
"106"
selection-start-line=
"17"
selection-start-column=
"13"
selection-end-line=
"17"
selection-end-column=
"106
"
/>
<state
relative-caret-position=
"
-1062
"
>
<caret
line=
"
31"
selection-start-line=
"31"
selection-end-line=
"31
"
/>
<folding>
<element
signature=
"e#0#15#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/
auto_at_once.py
"
>
<entry
file=
"file://$PROJECT_DIR$/
user_session.txt
"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"270"
>
<caret
line=
"18"
column=
"152"
lean-forward=
"true"
selection-start-line=
"18"
selection-start-column=
"116"
selection-end-line=
"18"
selection-end-column=
"152"
/>
<folding>
<element
signature=
"e#0#15#0"
expanded=
"true"
/>
</folding>
<state
relative-caret-position=
"1020"
>
<caret
line=
"68"
column=
"33"
selection-start-line=
"68"
selection-end-line=
"69"
/>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/auto_
request
.py"
>
<entry
file=
"file://$PROJECT_DIR$/auto_
at_once
.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"1365"
>
<caret
line=
"95"
column=
"4"
selection-start-line=
"95"
selection-start-column=
"4"
selection-end-line=
"95"
selection-end-column=
"4"
/>
<folding>
<element
signature=
"e#0#15#0"
expanded=
"true"
/>
</folding>
<state
relative-caret-position=
"105"
>
<caret
line=
"7"
column=
"22"
selection-start-line=
"7"
selection-end-line=
"8"
/>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/auto_
user_id
.py"
>
<entry
file=
"file://$PROJECT_DIR$/auto_
click
.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"4
50
"
>
<caret
line=
"
30"
column=
"18"
selection-start-line=
"30"
selection-start-column=
"18"
selection-end-line=
"30"
selection-end-column=
"1
8"
/>
<state
relative-caret-position=
"4
19
"
>
<caret
line=
"
28"
column=
"8"
lean-forward=
"true"
selection-start-line=
"28"
selection-start-column=
"8"
selection-end-line=
"28"
selection-end-column=
"
8"
/>
<folding>
<element
signature=
"e#
1#15
#0"
expanded=
"true"
/>
<element
signature=
"e#
0#11
#0"
expanded=
"true"
/>
</folding>
</state>
</provider>
</entry>
<entry
file=
"file://$PROJECT_DIR$/
offline_comment
.py"
>
<entry
file=
"file://$PROJECT_DIR$/
auto_click_n
.py"
>
<provider
selected=
"true"
editor-type-id=
"text-editor"
>
<state
relative-caret-position=
"
-34
"
>
<caret
line=
"
28"
column=
"35"
lean-forward=
"true"
selection-start-line=
"28"
selection-start-column=
"35"
selection-end-line=
"28"
selection-end-column=
"35
"
/>
<state
relative-caret-position=
"
735
"
>
<caret
line=
"
49"
lean-forward=
"true"
selection-start-line=
"49"
selection-end-line=
"49
"
/>
<folding>
<element
signature=
"e#0#15#0"
expanded=
"true"
/>
<marker
date=
"1555665806000"
expanded=
"true"
signature=
"2000:2003"
ph=
"..."
/>
</folding>
</state>
</provider>
...
...
auto_click.py
View file @
40692df0
import
requests
import
time
import
datetime
import
pymysql
import
random
import
traceback
...
...
auto_request.py
View file @
40692df0
...
...
@@ -30,6 +30,7 @@ DATABASES = {
}
}
host
=
DATABASES
[
'default'
][
'HOST'
]
user
=
DATABASES
[
'default'
][
'USER'
]
...
...
auto_user_id.py
View file @
40692df0
...
...
@@ -8,8 +8,6 @@ from log_settings import *
def
get_data
():
try
:
pc
=
pymysql
.
connect
(
host
=
host
,
user
=
user
,
passwd
=
passwd
,
db
=
db
,
port
=
3306
)
cursor
=
pc
.
cursor
()
cursor
.
execute
(
"select user_id from user_extra where is_shadow = 1 "
)
...
...
@@ -21,8 +19,6 @@ def get_data():
except
:
logging
.
error
(
"catch exception,get_data:
%
s"
%
traceback
.
format_exc
())
return
None
data
=
get_data
()
file
=
open
(
"user_id.txt"
,
"w"
)
...
...
offline_comment.py
View file @
40692df0
import
requests
import
time
import
datetime
import
pymysql
import
random
import
pandas
as
pd
import
traceback
from
log_settings
import
*
import
traceback
import
logging
from
auto_request
import
get_offline_comment
from
auto_request
import
host
,
user
,
db
,
passwd
...
...
@@ -31,7 +28,6 @@ def get_user_id():
return
user_list
def
reply
(
id
,
content
,
user_id
):
try
:
post_dict
=
{
...
...
@@ -54,44 +50,30 @@ def get_data(num1, num2):
pc
=
pymysql
.
connect
(
host
=
host
,
user
=
user
,
passwd
=
passwd
,
db
=
db
,
port
=
3306
)
cursor
=
pc
.
cursor
()
cursor
.
execute
(
"SELECT id,user_id FROM topic WHERE is_online =1 and (id > 0 and id <= 10000) and (content_level = 4 or content_level = 5) "
)
"SELECT id,user_id FROM topic WHERE is_online =1 and (id > "
+
str
(
num1
)
+
" and id <= "
+
str
(
num2
)
+
") and (content_level = 4 or content_level = 5) "
)
data
=
cursor
.
fetchall
()
topic_id
=
list
(
data
)
# logging.info("Database version : %s " % topic_id)
user_list
=
get_user_id
()
# logging.info("get user_list:%s"%user_list)
topic_id_list
=
[]
if
topic_id
:
for
i
in
topic_id
:
print
(
i
[
1
])
print
(
"========"
)
if
int
(
i
[
1
])
in
user_list
:
topic_id_list
.
append
(
i
)
print
(
i
)
print
(
"--------"
)
pc
.
close
()
print
(
topic_id_list
)
logging
.
info
(
"get topic_id_list:
%
s"
%
topic_id_list
)
return
topic_id_list
except
:
logging
.
error
(
"catch exception,get_data:
%
s"
%
traceback
.
format_exc
())
return
None
if
__name__
==
"__main__"
:
try
:
time_list
=
[[
0
,
10000
],
[
10000
,
20000
]]
# [10000, 20000],
# [20000, 30000],
# ["2017-03-30 15:57:49.000000", "2016-03-30 15:57:49.000000"],
# ["2018-03-30 15:57:49.000000", "2017-03-30 15:57:49.000000"],
# ["2019-03-30 15:57:49.000000", "2018-03-30 15:57:49.000000"]]
time_list
=
[[
0
,
100000
],
[
100000
,
200000
],
[
200000
,
300000
],
[
300000
,
400000
],
[
400000
,
500000
][
600000
,
700000
]]
user_data
=
open
(
"user_id.txt"
,
"r"
)
...
...
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