Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Barry
/
discordbot
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
1fc2beff
authored
2016-01-06 05:59:57 +0000
by
Barry
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
Fixed a shitty bug that filled the HD of the host machine..
1 parent
040215f3
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
6 deletions
hellsbot.py
members.json
hellsbot.py
View file @
1fc2bef
...
...
@@ -22,10 +22,6 @@ muted_until = datetime.datetime.now()
client
=
discord
.
Client
()
json_data
=
open
(
credentials
)
.
read
()
creds
=
json
.
loads
(
json_data
)
client
.
login
(
creds
[
'username'
],
creds
[
'password'
])
def
leaders
(
xs
,
top
=
20
):
counts
=
defaultdict
(
int
)
for
x
in
xs
:
...
...
@@ -615,8 +611,14 @@ def on_ready():
print
(
client
.
user
.
id
)
print
(
'------'
)
while
1
:
retries
=
0
while
retries
<
1000
:
try
:
json_data
=
open
(
credentials
)
.
read
()
creds
=
json
.
loads
(
json_data
)
client
.
login
(
creds
[
'username'
],
creds
[
'password'
])
client
.
run
()
except
:
print
(
"Shit I crashed"
)
retries
+=
1
print
(
"Shit I crashed: Retry
%
s"
%
(
retries
,))
...
...
members.json
View file @
1fc2bef
This diff is collapsed.
Click to expand it.
Please
register
or
sign in
to post a comment