Commit f996c80d authored by Jean Michel Rouly's avatar Jean Michel Rouly

Reduced number of possible students to a reasonable size

parent 95f4a469
......@@ -76,8 +76,9 @@ def anonymized( obj ):
obj.user.username )
h = user_hash_raw.hexdigest()
n = int(h, base=16)
noun_hash = int(str(n)[:4])*2 # 4 digits *2 allows for 20 000 nouns
adj_hash = int(str(n)[4:6])*8 # 2 digits *8 allows for 800 users
noun_hash = int(str(n)[:2])*3 # 2 digits *3 allows for 300 nouns
adj_hash = int(str(n)[2:4])*2 # 1 digits *20 allows for 200 adjs
# 300 * 200 = 60 000 total possible usernames
adj = "Anonymous"
adjs = open(settings.DICTIONARY_ADJECTIVES, 'r')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment