Skip to content
Snippets Groups Projects
Commit 19ae36f4 authored by Erik Reid's avatar Erik Reid
Browse files

randomize state for fun

parent 8bc599c8
No related branches found
No related tags found
No related merge requests found
...@@ -75,7 +75,7 @@ def things(): ...@@ -75,7 +75,7 @@ def things():
return { return {
'id': _hash(f'id-{idx}', 4), 'id': _hash(f'id-{idx}', 4),
'time': int(time.time() + random.randint(-six_months, six_months)), 'time': int(time.time() + random.randint(-six_months, six_months)),
'state': bool(idx % 2), 'state': random.choice([True, False]),
'data1': _hash(f'data1-{idx}', 2), 'data1': _hash(f'data1-{idx}', 2),
'data2': _hash(f'data2-{idx}', 8), 'data2': _hash(f'data2-{idx}', 8),
'data3': _hash(f'data3-{idx}', 32) 'data3': _hash(f'data3-{idx}', 32)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment