<jupyter_start><jupyter_text>Most recent laptimes<jupyter_code>ALREADY_SEEN_UNTIL = 5947
t = Track.objects.get(title__icontains="KIFFLOM")
laps = Laptime.objects.filter(track=t, pk__gte=ALREADY_SEEN_UNTIL).order_by('-pk')
seen_users = []
for l in laps:
    if l.player in seen_users:
        continue
    else:
        print (l.player, l.pk, l.created)
        seen_users.append(l.player)
        
l.link
t = Track.objects.get(title__icontains="KIFFLOM")
u = Player.objects.get(username='cronixx')
hle = Hotlapping.objects.get(pk=32)
print(t.title, u.username, hle.title)
laps = Laptime.objects.filter(player=u, track=t).order_by('-millis')
for lap in laps:
    hllt = lap.hotlappinglaptime_set.all()[0]
    print(hllt.pk, hllt.laptime_id, hllt.laptime.link)
Laptime.objects.filter(pk__in=[5824, 5800]).delete()
hle = Hotlapping.objects.get(pk=32)
hle.title
l = laps[1]
hllt = HotlappingLaptime.objects.all()[6]
hllt.approved, hllt.laptime, hllt.hotlapping.title
for hll in laps:
    x, y = HotlappingLaptime.objects.get_or_create(approved=True, laptime=hll, hotlapping=hle)
    print (x, y)
u = Player.objects.get(username__icontains="the_cuunt")
u.username
u.username = 'esqy'
u.save()<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.14461791290057519, 'fraction_numerical': 0.015612161051766639, 'mean_word_length': 5.059701492537314, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '333743', 'license': 'MIT', 'n_tokens_mistral': 529, 'n_tokens_neox': 512, 'n_words': 77, 'path': 'notebooks/tepcott3.ipynb', 'repo_name': 'abecede753/trax', 'size': '1217'}