Skip to content

Commit

Permalink
Flake still ain't gonna be happy
Browse files Browse the repository at this point in the history
  • Loading branch information
ArtOfCode committed Mar 24, 2017
1 parent 3d4bf9d commit 133a4f1
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion findspam.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
# noinspection PyPackageRequirements
from tld.utils import TldDomainNotFound
from urlparse import urlparse
from helpers import all_matches_unique
from helpers import all_matches_unique, log

SIMILAR_THRESHOLD = 0.95
EXCEPTION_RE = r"^Domain (.*) didn't .*!$"
Expand Down
2 changes: 1 addition & 1 deletion globalvars.py
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ class GlobalVars:
metasmoke_host = config.get("Config", "metasmoke_host")
except ConfigParser.NoOptionError:
metasmoke_host = None
log("metasmoke host not found. Set it as metasmoke_host in the config file." \
log("metasmoke host not found. Set it as metasmoke_host in the config file."
"See https://github.com/Charcoal-SE/metasmoke.")

try:
Expand Down
1 change: 1 addition & 0 deletions helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ def environ_or_none(key):
def all_matches_unique(match):
return len(match[0][1::2]) == len(set(match[0][1::2]))


def log(*args):
log_str = "[{}] {}".format(datetime.now().isoformat()[11:-7], " ".join(args))
print(log_str)
1 change: 1 addition & 0 deletions metasmoke.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import apigetpost
import spamhandling
import classes
from helpers import log


# noinspection PyClassHasNoInit,PyBroadException,PyUnresolvedReferences,PyProtectedMember
Expand Down
1 change: 1 addition & 0 deletions spamhandling.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
import regex
import time
import classes
from helpers import log


# noinspection PyMissingTypeHints
Expand Down
1 change: 1 addition & 0 deletions ws.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
import requests
# noinspection PyPackageRequirements
from tld.utils import update_tld_names, TldIOError
from helpers import log

try:
update_tld_names()
Expand Down

0 comments on commit 133a4f1

Please sign in to comment.