Load the data

This commit is contained in:
Rémi Oudin 2018-02-25 13:17:44 +01:00
parent 3eb82a4a0b
commit d4aefb6bb7
1 changed files with 5 additions and 0 deletions

View File

@ -9,6 +9,11 @@ or to type in the search engine.
import random
from django.db import models
NICKNAMES = open("/usr/share/dict/american-english").read().splitlines()
LASTNAMES = open("../data/lastnames.txt").read().splitlines()
FIRSTNAMES = open("../data/firstnames.txt").read().splitlines()
EMAIL_DOMAINS = open("../data/email_domains.txt").read().splitlines()
class InvalidData(Exception):
''' Thrown when the DB contains invalid data, and cannot perform