Sanity check
This commit is contained in:
parent
22017cea91
commit
236e40d359
1 changed files with 10 additions and 8 deletions
|
@ -108,7 +108,8 @@ class History(models.Model):
|
||||||
""" Actually plays the history.
|
""" Actually plays the history.
|
||||||
"""
|
"""
|
||||||
self.played = True
|
self.played = True
|
||||||
runner = TorInstance(self.history)
|
runner = TorInstance(self.return_history())
|
||||||
|
runnner.run()
|
||||||
self.save()
|
self.save()
|
||||||
|
|
||||||
def to_xml(self, xml_root):
|
def to_xml(self, xml_root):
|
||||||
|
@ -232,6 +233,7 @@ def generate_history(user, start_time):
|
||||||
current_timestamp = \
|
current_timestamp = \
|
||||||
history_list[-1].timestamp + 5 * random.weibullvariate(1, 5)
|
history_list[-1].timestamp + 5 * random.weibullvariate(1, 5)
|
||||||
for (url, timestamp) in history_list:
|
for (url, timestamp) in history_list:
|
||||||
|
if len(url) < 200:
|
||||||
new_line = HistoryEntry(
|
new_line = HistoryEntry(
|
||||||
search=url,
|
search=url,
|
||||||
timestamp=datetime.fromtimestamp(timestamp),
|
timestamp=datetime.fromtimestamp(timestamp),
|
||||||
|
|
Loading…
Reference in a new issue