Steve Clement 2019-05-29 08:42:39 +09:00
parent 9d4cdd7e16
commit e74b4a5bff
No known key found for this signature in database
GPG Key ID: 69A20F509BE4AEE9
8 changed files with 60 additions and 34 deletions

View File

@ -1,16 +1,19 @@
import util
from util import getZrange
import math, random
import time
import os
import configparser
import json
import datetime
import json
import logging
import math
import os
import random
import time
import redis
import util
from util import getZrange
from . import users_helper
KEYDAY = "CONTRIB_DAY" # To be used by other module
KEYALLORG = "CONTRIB_ALL_ORG" # To be used by other module
@ -589,4 +592,3 @@ class Contributor_helper:
return { 'remainingPts': i-points, 'stepPts': prev }
prev = i
return { 'remainingPts': 0, 'stepPts': self.rankMultiplier**self.levelMax }

View File

@ -1,18 +1,21 @@
import math, random
import os
import datetime
import json
import datetime, time
import logging
import json
import redis
import math
import os
import random
import time
from collections import OrderedDict
import geoip2.database
import phonenumbers, pycountry
from phonenumbers import geocoder
import redis
import geoip2.database
import phonenumbers
import pycountry
import util
from helpers import live_helper
from phonenumbers import geocoder
class InvalidCoordinate(Exception):
pass

View File

@ -1,8 +1,9 @@
import os
import datetime
import json
import random
import datetime, time
import logging
import os
import random
import time
class Live_helper:

View File

@ -1,13 +1,16 @@
import math, random
import os
import json
import copy
import datetime, time
import datetime
import json
import logging
import math
import os
import random
import time
from collections import OrderedDict
import util
class Trendings_helper:
def __init__(self, serv_redis_db, cfg):
self.serv_redis_db = serv_redis_db

View File

@ -1,10 +1,13 @@
import math, random
import os
import datetime
import json
import datetime, time
import logging
import math
import os
import random
import time
import util
from . import contributor_helper

View File

@ -1,8 +1,13 @@
#!/usr/bin/env python3.5
import configparser
import redis
import sys,os
import datetime
import os
import sys
import redis
from helpers import geo_helper
sys.path.append('..')
configfile = 'test_config.cfg'
@ -14,7 +19,6 @@ serv_redis_db = redis.StrictRedis(
port=6260,
db=1)
from helpers import geo_helper
geo_helper = geo_helper.Geo_helper(serv_redis_db, cfg)
categ = 'Network Activity'

View File

@ -1,8 +1,14 @@
#!/usr/bin/env python3.5
import configparser
import datetime
import os
import sys
import time
import redis
import sys,os
import datetime, time
from helpers import trendings_helper
sys.path.append('..')
configfile = 'test_config.cfg'
@ -14,7 +20,6 @@ serv_redis_db = redis.StrictRedis(
port=6260,
db=1)
from helpers import trendings_helper
trendings_helper = trendings_helper.Trendings_helper(serv_redis_db, cfg)

View File

@ -1,8 +1,14 @@
#!/usr/bin/env python3.5
import configparser
import datetime
import os
import sys
import time
import redis
import sys,os
import datetime, time
from helpers import users_helper
sys.path.append('..')
configfile = 'test_config.cfg'
@ -14,7 +20,6 @@ serv_redis_db = redis.StrictRedis(
port=6260,
db=1)
from helpers import users_helper
users_helper = users_helper.Users_helper(serv_redis_db, cfg)