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
0fe9b638
Commit
0fe9b638
authored
Dec 07, 2018
by
lixiaofang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
majia new
parent
73f5596c
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
41 additions
and
47 deletions
+41
-47
auto_at_once.py
auto_at_once.py
+39
-39
auto_click_n.py
auto_click_n.py
+0
-6
auto_commnet.py
auto_commnet.py
+2
-2
No files found.
auto_at_once.py
View file @
0fe9b638
...
...
@@ -6,7 +6,7 @@ import random
import
pandas
as
pd
auto_click_url
=
"http://earth.igengmei.com/api/v1/like"
auto_
click
_url
=
"http://earth.igengmei.com/api/v1/reply/create"
auto_
reply
_url
=
"http://earth.igengmei.com/api/v1/reply/create"
auto_follow_url
=
"http://earth.igengmei.com/api/v1/follow"
login_url
=
"http://earth.igengmei.com/api/account/login_pwd"
...
...
@@ -124,7 +124,7 @@ def reply(cookies_get,id,content):
'topic_id'
:
id
,
'content'
:
content
}
response
=
requests
.
post
(
url
=
auto_
click
_url
,
response
=
requests
.
post
(
url
=
auto_
reply
_url
,
cookies
=
cookies_get
,
data
=
post_dict
)
...
...
@@ -184,7 +184,7 @@ def get_follw_majia(numtime,id):
if
__name__
==
"__main__"
:
numtime
=
time_conv
(
0
)
numtime
=
time_conv
()
topic_id
=
get_topic_id
(
numtime
)
...
...
@@ -202,42 +202,42 @@ if __name__ == "__main__":
click
(
cookies
,
id
)
#
#
time.sleep(random.randint(500, 1500))
#
#
comment_num = random.randint(1, 3)
#
#
for i in range(comment_num):
#
#
# time.sleep(random.randint(500, 1500))
#
#
cookies= login()
#
#
comment = get_comment()
#
#
reply(cookies, id, comment)
#
#
#
get majia zhanghao
#
#
data = get_follw_majia(numtime, id)
#
#
dict = {}
#
#
for i in data:
#
#
if i[0] not in dict:
#
dict.setdefault(i[0], [])
#
dict[i[0]].append(i[1])
#
#
else:
#
dict[i[0]].append(i[1])
#
#
for key, value in dict.items():
#
#
cookies = logins(key)
#
#
for id in value:
#
#
follow(cookies, id)
# time.sleep(random.randint(500, 1500))
comment_num
=
random
.
randint
(
1
,
3
)
for
i
in
range
(
comment_num
):
# time.sleep(random.randint(500, 1500))
cookies
=
login
()
comment
=
get_comment
()
reply
(
cookies
,
id
,
comment
)
#get majia zhanghao
data
=
get_follw_majia
(
numtime
,
id
)
dict
=
{}
for
i
in
data
:
if
i
[
0
]
not
in
dict
:
dict
.
setdefault
(
i
[
0
],
[])
dict
[
i
[
0
]]
.
append
(
i
[
1
])
else
:
dict
[
i
[
0
]]
.
append
(
i
[
1
])
for
key
,
value
in
dict
.
items
():
cookies
=
logins
(
key
)
for
id
in
value
:
follow
(
cookies
,
id
)
...
...
auto_click_n.py
View file @
0fe9b638
...
...
@@ -4,12 +4,6 @@ import datetime
import
pymysql
import
random
s
=
requests
.
session
()
s
.
keep_alive
=
False
requests
.
adapters
.
DEFAULT_RETRIES
=
5
auto_click_url
=
"http://earth.igengmei.com/api/v1/like"
login_url
=
"http://earth.igengmei.com/api/account/login_pwd"
...
...
auto_commnet.py
View file @
0fe9b638
...
...
@@ -6,7 +6,7 @@ import random
import
pandas
as
pd
auto_
click
_url
=
"http://earth.igengmei.com/api/v1/reply/create"
auto_
reply
_url
=
"http://earth.igengmei.com/api/v1/reply/create"
login_url
=
"http://earth.igengmei.com/api/account/login_pwd"
...
...
@@ -58,7 +58,7 @@ def reply(cookies_get,id,content):
'topic_id'
:
id
,
'content'
:
content
}
response
=
requests
.
post
(
url
=
auto_
click
_url
,
response
=
requests
.
post
(
url
=
auto_
reply
_url
,
cookies
=
cookies_get
,
data
=
post_dict
)
...
...
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